Jump to content

table displayed outside the first table


php_begins

Recommended Posts

I have the following code which has a table nested inside a table.

But the nested table does not seem to fall inside the box. i.e inside the first table.

It displays outside the border line. can someone point out the flaw in my code:

here is my code:

 

<table cellpadding="5"  cellspacing="1" bgcolor="#DDEEFF" border="0" width="900" align="center" style='border-top: 1px; border-right: 1px; border-left: 1px; border-bottom: 1px; border-color: black; border-style: solid;'>
<tr>
<td bgcolor='#40382b' align='left'><b><font color='#FFFFFF' size='2' face='verdana'>our Forum Advertising</font></b></td>
</tr>
<tr>
	<td bgcolor='white'align='left'><br>
		<font face="Verdana" size="4" color='black'><B>Advertising Overview</B></font>

		<font face="Verdana" size="2" color='black'>Advertising at our Forum gives you direct access to the exact market you are looking to advertise to. Our dedicated audience of jeep our enthusiasts are here to learn, be entertained and buy products.

		As print magazines decline, online magazines like our Forum are filling the void for readers. We are fast become a major locale for articles, reviews, tutorials, photos, classifieds and discussion.</font>

		<font face="Verdana" size="4" color='black'><B>Advertising Options</B></font>

		<font face="Verdana" size="2" color='black'>We offer a variety of advertising and sponsorship options, from large campaigns for retailers, to small campaigns for custom shops. Our proprietary advertising application gives us a lot of flexiblity to come up with a plan that works for you. We offer you the ability to upload banners yourself if you desire. You also have the option to run multiple banners in your ad slot to see which one works best for you. If you lack a graphical banner, our system allows you to create your own text based advertisement in minutes.
		Advertising options include;

		<ul>
			<li>Vendor Program</li>
			<li>Banner Advertising</li>
			<li>Newsletter Advertising</li>
		</ul>


	</td>
</tr>


<table align= 'center' width='50%' bgcolor='#5B6451'><tr>
  <td>
   <form action="" method="post">
      <tr height='40'>
         <td>
           <font color="white"><B> First Name: </B></font>
         </td>
 <td><input type="text" size ="40" name="first_name" value="" />
            	 </td>

      </tr>
      <tr height='40'>
     <td><font color="white"><B> Last Name: </B></font></td>
     <td><input type="text" size ="40" name="last_name" value=""/>
                  </td>
      </tr>

      <tr height='35'>
         <td></td>
         <td><input type="submit" name="submit" value="submit" /></td>
      </tr>

   </form>
   </tr>
   </td>
   </table>
</table>

Link to comment
https://forums.phpfreaks.com/topic/253027-table-displayed-outside-the-first-table/
Share on other sites

Yeah the 2nd table was kind of floating as it wasn't within it's own row and table cell.

 

That said, is there a reason you are using tables and the font tag? It's not very semantic and won't help with SEO or accessibility.

 

Try using a proper semantic structure such as paragraphs, ordered lists etc. Also move all inline styles and fonts into your external stylesheet :)

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.