Jump to content

[SOLVED] table border


verN

Recommended Posts

table border

 

--------------------------------------------------------------------------------

 

hi, i have a problem with the way my webpage is rentered. I have a page which uses includes to get the header for the top which is a banner. I also use another include to produce the footer bottom of the page. My problem is that the web page gets rendered perfectly when usng firefox but in internet explorer rather then the table coming in the middle it appears in the left. I know where the problem lies. When i view the individual files called header.php and footer.php the table appears fine but when i add a border around the table it doesn't get rendered properly in the another file.

 

Since I wish to use an outline around the page the border appears perfectly in firefox but not in explorer. Howver, when i delete the css code for the border the page gets rendered perfectly in both browsers. I wish to inlcude the border around the page. Here is the css code

 

.maintable {

    margin: 0px auto; 
    width: 750px; 
    border-color: #990099; 
    border-width: 1px 1px 1px; 
    border-style: solid;     
} 

 

 

parts of the header.php code

 

<div class="maintable"> 
<table width="750" align="center"> 
<tr bgcolor="#996699"><td> 
       
      <div class="banner">   
      <table width="524" border="0" cellpadding="0" cellspacing="0"> 
      <tr> 
      <td><img src="../includes/logo1.jpg" width="508" height="100"></td> 
      <td><a href="http://www.test.uk"><img src="../includes/logo2.jpg" width="237" height="100" border="0"></a></td> 
      </tr> 
      </divl></table> 
      </td> 
      </tr> 
   
<tr><td align=center><div class="printbanner"><img src="../includes/logo3.gif" width="118" height="70" /></div></td> 
</tr> 
</div> 
</table> 

 

 

parts of the footer.php code

 

<body> 
<table width="750" align="center"> 
  <tr bgcolor="#996699"> 
    <th height="19" bordercolor="#FF00FF"><span class="style1">© 2007</span> <a href="mailto:[email protected]">name</a></th> 
  </tr> 
</table>      

</body> 

 

 

thanks in advance

Link to comment
https://forums.phpfreaks.com/topic/46244-solved-table-border/
Share on other sites

If you copied and pasted your code, there are a few things that could be causing your issue. First of all, with both  of the tables you have in your header, you need to close the tags in the reverse order in which you opened them. So, if you open your div before your table, you need to close it after your table. Also, check your tag spellings. You have a closing </divl> tag instead of </div>

<div class="maintable"> 
<table width="750" align="center"> 
<tr bgcolor="#996699"><td> 
       
      <div class="banner">   
      <table width="524" border="0" cellpadding="0" cellspacing="0"> 
      <tr> 
      <td><img src="../includes/logo1.jpg" width="508" height="100"></td> 
      <td><a href="http://www.test.uk"><img src="../includes/logo2.jpg" width="237" height="100" border="0"></a></td> 
      </tr> 
      </table>
      </div> 
      </td> 
      </tr> 
   
<tr><td align=center><div class="printbanner"><img src="../includes/logo3.gif" width="118" height="70" /></div></td> 
</tr> 
</table> 
</div> 

Link to comment
https://forums.phpfreaks.com/topic/46244-solved-table-border/#findComment-224909
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.