сверстал шаблон для joomla сначало в html, чтоб таблица тянуласть по высоте на 100% и не было отступов от границ броузера. <html> <head> </head> <body> <table width="780" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td width="539" height="151"><img src="images/1.jpg" width="539" height="151" /></td> <td width="241" height="151"><img src="images/4.jpg" width="241" height="151" /></td> </tr> <tr> <td width="539" height="46"><img src="images/2.jpg" width="539" height="46" /></td> <td width="241" height="46" align="center" background="images/menu.jpg"> </td> </tr> <tr> <td width="539" height="77"><img src="images/3.jpg" width="539" height="77" /></td> <td width="241" height="77" align="center" background="images/search.jpg"> </td> </tr> </table> <table width="780" height="100%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td height="38" colspan="5" align="center" background="images/bar.jpg"> </td> </tr> <tr> <td width="4" rowspan="2" background="images/contur.jpg"> </td> <td valign="top"> </td> <td width="2" valign="top" bgcolor="#dddddd"> </td> <td width="150" valign="top" bgcolor="#fbfbfb"> </td> <td width="4" rowspan="2" background="images/contur.jpg"> </td> </tr> <tr> <td height="47" colspan="3" align="center" background="images/footer.jpg"> </td> </tr> </table> <table width="780" height="4" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td><img src="images/kontur.jpg" width="780" height="4"></td> </tr> </table> </body> </html> потом переделал в php b добавил css * { margin: 0; padding: 0; } body { /*background:;*/ /*font:;*/ font-family: Georgia, "Times New Roman", Times, serif; font-size: 76.1%; color: #0b0b0b; /*background-color:;*/ /*background-image:;*/ /*background-repeat:;*/ /*background-position:;*/ } <?php defined( '_VALID_MOS' ) or die( 'Доступ запрещен' ); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <?php $iso = split( '=', _ISO ); echo '<?xml version="1.0" encoding="'. $iso[1] .'"?' .'>'; ?> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; <?php echo _ISO; ?>" /> <?php mosShowHead(); ?> <?php if ( $my->id ) { initEditor(); } ?> <meta http-equiv="Content-Type" content="text/html; <?php echo _ISO; ?>" /> <link href="<?php echo $GLOBALS['mosConfig_live_site'];?>/templates/<?php echo $GLOBALS['cur_template']; ?>/css/template_css.css" rel="stylesheet" type="text/css" /> <?php if ( $my->id ) { initEditor(); } ?> <meta http-equiv="Content-Type" content="text/html;><?php echo _ISO; ?>" /> <?php mosShowHead(); ?> <?php echo "<link rel="stylesheet" href="$GLOBALS[mosConfig_live_site]/templates/$GLOBALS[cur_template]/css/template_css.css" type="text/css"/>"; ?><?php echo "<link rel="shortcut icon" href="$GLOBALS[mosConfig_live_site]/images/favicon.ico" />"; ?> </head> <body> <!-- Шапка --> <table width="780" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td width="539" height="151"><img src="templates/<?php echo $cur_template; ?>/images/1.jpg" width="539" height="151" /></td> <td width="241" height="151"><img src="templates/<?php echo $cur_template; ?>/images/4.jpg" width="241" height="151" /></td> </tr> <tr> <td width="539" height="46"><img src="templates/<?php echo $cur_template; ?>/images/2.jpg" width="539" height="46" /></td> <td width="241" height="46" align="center" background="templates/<?php echo $cur_template; ?>/images/menu.jpg"><?php mosLoadModules ( 'top' ); ?></td> </tr> <tr> <td width="539" height="77"><img src="templates/<?php echo $cur_template; ?>/images/3.jpg" width="539" height="77" /></td> <td width="241" height="77" align="center" background="templates/<?php echo $cur_template; ?>/images/search.jpg"><form action="index.php" method="post"> <div align="center"> <input class="inputbox" type="text" name="searchword" size="15" value="<?php echo _SEARCH_BOX; ?>" onblur="if(this.value=='') this.value='<?php echo _SEARCH_BOX; ?>';" onfocus="if(this.value=='<?php echo _SEARCH_BOX; ?>') this.value='';" /> <input type="hidden" name="option" value="search" /> </div> </form> </td> </tr> </table> <!-- Тело --> <table width="780" height="100%" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td height="38" colspan="5" align="center" background="templates/<?php echo $cur_template; ?>/images/bar.jpg"><?php mosLoadModules ( 'user2' ); ?></td> </tr> <tr> <td width="4" rowspan="2" background="templates/<?php echo $cur_template; ?>/images/contur.jpg"> </td> <td valign="top"><?php mosMainBody(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"></td> <td width="2" valign="top" bgcolor="#dddddd"> </td> <td width="150" valign="top" bgcolor="#fbfbfb"><?php mosLoadModules ( 'user1' ); ?></td> <td width="4" rowspan="2" background="templates/<?php echo $cur_template; ?>/images/contur.jpg"> </td> </tr> <tr> <td height="47" colspan="3" align="center" background="templates/<?php echo $cur_template; ?>/images/footer.jpg"><?php mosLoadModules ( 'bottom' ); ?></td> </tr> </table> <!-- Футер --> <table width="780" height="4" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td><img src="templates/<?php echo $cur_template; ?>/images/kontur.jpg" width="780" height="4"></td> </tr> </table> <div align="center"> <?php include_once('includes/footer.php'); ?> </div> </body> </html> шаблон перестал выравниваться по центру, поместил таблицу в таблица выровнялась по центру, но появились отступы. что исправить, чтоб было выравнивание по центру и не было отступов от окна броузера?