View Full Version : Ad Code Placement


weesneak
08-18-2006, 11:20 AM
Ok this is a really simple problem, i did it with my last layout, and i dont have a clue why i cant do it this time.
If you copy this html code and view it, imagine it with the images and all that. Heres my problem. The sites ad code MUST be placed on the right hand side, outside of the layout. With my last layout i did this by making a two cell table, placing the layout in the first one, and the ad in the second, hey presto. For whatever reason this time it dosent work.

btw, excuse my crappy html. (The adcode is in bold at the bottom

DOUBLE POSTED BECAUSE OF CHARACTER LIMIT

<table>
<tr><td bgcolor="#000000">
<div align="center">
<center>

<table border="0" cellspacing="0" cellpadding="0" width="780" style="border-collapse: collapse" bordercolor="#111111" bgcolor="#000000">

<tr>
<td width="808" colspan="2" height="20" bgcolor=#999999 align="left">

&nbsp;<a href="main.php">Home</a> | <a href="http://www.dreamstation.cc/cgi-bin/lspro/lspro.cgi?click=1155682411" TARGET="_top">Top Sites</a> | <a

href="links.shtml">Affiliates</a> | <a href="faq.shtml">F.A.Q</a>


</td>
</tr><tr><td bgcolor="#FFFFFF" colspan='3' width="780"><img src="images/header.jpg"></td></tr>



</center>
</div>
</td>
</tr>
</table>
<table border="0" cellspacing="0" cellpadding="0" width="780" align="center" bordercolor="#999999"><td valign="top" bgcolor="#999999">
<div align="center">
<center>
<br>
<!-- end header --!>
<!-- left menu --!>
<table border="1" cellspacing="0" cellpadding="0" width="90%" style="border-collapse: collapse" bordercolor="#111111">
<tr><td bgcolor="#666666" class="gensmall"><font color="#FFFFFF" face=verdana size=2><b><img src="images/side1.jpg"></td></tr>
<tr><td class="gensmall" bgcolor="#666666">
- <a href="main.php" style="text-decoration: none">Home</a><br>

- <a href="linktous.shtml" style="text-decoration: none">Link To Us</a><br>
- <a href="gethosted.html" style="text-decoration: none">Get Hosted</a><br>

</td></tr>
</table></center>
</div><br>
<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side2.jpg"></font></b></td>
</tr>
<tr>
<td width="100%">


- <a href="1info.shtml" style="text-decoration: none">Information</a><br>
- <a href="1characters.shtml" style="text-decoration: none">Characters</a><br>
- <a href="1locations.shtml" style="text-decoration: none">Locations</a><br>
- <a href="1themovie.shtml" style="text-decoration: none">The Movie</a><br>
- <a href="1guide.shtml" style="text-decoration: none">Guide</a><br>
- <a href="1movies.shtml" style="text-decoration: none">Movies</a><br>

</td>
</tr>
</table>
</center>
</div>
<br>

<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side3.jpg"></font></b></td>
</tr>
<tr>
<td width="100%">

weesneak
08-18-2006, 11:22 AM
- <a href="2info.shtml" style="text-decoration: none">Information</a><br>
- <a href="2characters.shtml" style="text-decoration: none">Characters</a><br>
- <a href="2locations.shtml" style="text-decoration: none">Locations</a><br>
- <a href="2guide.shtml" style="text-decoration: none">Guide</a><br>
- <a href="2movies.shtml" style="text-decoration: none">Movies</a><br>

</td>
</tr>
</table>
</center>
</div>
<br>

<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side4.jpg"></font></b></td>
</tr>
<tr>
<td width="100%">


- <a href="3info.html" style="text-decoration: none">Information</a><br>

</td>
</tr>
</table>
</center>
</div>
<br>

<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side8.jpg"></font></b></td>
</tr>
<tr>
<td width="100%">
- <a href="onlineinfo.shtml" style="text-decoration: none">Information</a><br>
- <a href="sonewpics.shtml" style="text-decoration: none">Pictures</a><br>
- <a href="onmovies.shtml" style="text-decoration: none">Movies</a><br>

</td>
</tr>
</table>
</center>
</div>
<br>


<div align="center">
<center>

<table border="1" cellspacing="0" cellpadding="0" width="90%" style="border-collapse: collapse" bordercolor="#111111">
<tr><td bgcolor="#666666" class="gensmall"><font color="#FFFFFF" face=verdana size=2><b><img src="images/side5.jpg"></b></font></td></tr>
<tr><td class="gensmall" bgcolor="#666666">

- <a href="beta.shtml" style="text-decoration: none">Beta</a><br>

- <a href="whatsshenmue.shtml" style="text-decoration: none">What's Shenmue?</a><br>
- <a href="pberkley.shtml" style="text-decoration: none">Project Berkley</a><br>

</td></tr>
</table></center>
</div>
<br>

<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side6.jpg"></font></b></td>
</tr>
<tr>
<td width="100%">


- <a href="downloads.shtml" style="text-decoration: none">Downloads</a><br>
- <a href="humour.shtml" style="text-decoration: none">Humour</a><br>
- <a href="yusuzuki.shtml" style="text-decoration: none">Yu Suzuki</a><br>
- <a href="merchandise.shtml" style="text-decoration: none">Merchandise</a><br>


</td>
</tr>
</table>
</center>
</div>
<br>


<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side9.jpg"></font></b></td>
</tr>
<tr>
<td width="100%" valign="top">




</center>



</td>
</tr>
</table>
</center>
</div>
<br>


<div align="center">
<center>
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="90%" id="AutoNumber1" bgcolor="#666666">
<tr>
<td width="100%"><b><font color="#FFFFFF" face=verdana size=2><img src="images/side7.jpg"></font></b></td>
</tr>
<tr>
<td width="100%">
<BR>
<center></center><br>

</td>
</tr>
</table>
</center>
</div>
<br>


</td>

<td width="650" valign="top" bgcolor="#FFFFFF">
<table border="0" cellspacing="0" cellpadding="5" width="100%">
<tr>
<td width="650" colspan="2" height="20" bgcolor=#999999 align="right">


</td>
</tr><tr><td>



<font color="#000000" face=verdana size=1>
<center>News <br><br>
<?PHP
$number=30;
include("/home2/sarchive/public_html/cutenews/show_news.php");
?>

</tr></td>
<td> <iframe src='http://www.gamingsource.net/misc/2.php' framespacing='0' frameborder='no' scrolling='no' width='160' height='650'></iframe></td>


</table>
[/QUOTE]

Thanks for any help.

J to the izzosh
08-18-2006, 11:49 AM
Well, one thing I feel I should note is that you have a lot of unlcosed HTML elements. Open center and font tags exist. Some tags are not nested properly, as well. Also, the end tag for your comment tags is "-->" and not "--!>". Because of that, two of your comments were technically left open, encompassing most of your page, so I'm somewhat surprised that anything after those displays. :) You may want to focus on correcting these syntactical errors beofre advancing with your design.

Part of the problem with your table is some extra rows and cells, also, one of the row tags actually closes inside of a table cell (this is the improper nesting that I referenced). Try adjusting your code here...
<table border="0" cellspacing="0" cellpadding="5" width="100%">
<tr>
<td width="650" colspan="2" height="20" bgcolor=#999999 align="right">
</td>
</tr><tr><td>
<font color="#000000" face=verdana size=1>
<center>News <br><br>
<?PHP
$number=30;
include("/home2/sarchive/public_html/cutenews/show_news.php");
?>
</tr></td>
<td> <iframe src='http://www.gamingsource.net/misc/2.php' framespacing='0' frameborder='no' scrolling='no' width='160' height='650'></iframe></td>
</table>

...to this:

<table border="0" cellspacing="0" cellpadding="5" width="100%">
<tr>
<td width="650" colspan="2" height="20" bgcolor=#999999 align="right">
<font color="#000000" face=verdana size=1>
<center>News</center></font> <br><br>
<?PHP
$number=30;
include("/home2/sarchive/public_html/cutenews/show_news.php");
?>
</td>
<td> <iframe src='http://www.gamingsource.net/misc/2.php' framespacing='0' frameborder='no' scrolling='no' width='160' height='650'></iframe></td></tr>
</table>

</td>
</tr>
</table>
The extra closing tags at the end are there because the cell and table which contain the above table aren't closed in your source or, at least, were cut off in the sample you posted.

weesneak
08-18-2006, 11:54 AM
Thanks much, as i said its real sloppy coding. But it works, so who am i to complain.

J to the izzosh
08-18-2006, 11:59 AM
That's just it: it doesn't work. :D

Trust me, taking the time to correct (and ideally, prevent) those syntactical errors will save you a lot of headache over time.

weesneak
08-18-2006, 12:40 PM
No its still not working im afraid.
www.shenmuearchive.co.uk/main.php

I want the ad to be outside of the table, not in its own cell.

J to the izzosh
08-18-2006, 12:58 PM
Here is what I see when I look at the page with the corrections I made: tables (http://jfweb.fastmail.fm/table_ad/table_ad.htm). I stuck in the header from your above link, and to me it looks pretty similar. Perhaps you missed something in making the corrections.