OZONE Asylum
Forums
CSS - DOM - XHTML - XML - XSL - XSLT
Optimizing JavaScript Ad Sizes
This page's ID:
28844
Search
QuickChanges
Forums
FAQ
Archives
Register
Edit Post
Who can edit a post?
The poster and administrators may edit a post. The poster can only edit it for a short while after the initial post.
Your User Name:
Your Password:
Login Options:
Remember Me On This Computer
Your Text:
Insert Slimies »
Insert UBB Code »
Close
Last Tag
|
All Tags
UBB Help
An ad will be served up via a script tag [code]<script type="text/javascript" src="[site]/ad.php"></script>[/code] The code from ad.php will generate a block of HTML that will be output to the browser via a document.write call from inside the ad.php javascript file. The ad that is being generated is a simple header and footer with a number of links in the middle. Originally the html was [code]<table border='1' with='120' height='600' bordercolor='#000000' cellspacing='0' cellpadding='5'><tr><td valign='top'> <center><font face=Verdana size=2 color=black><b>[Site Name]</b></font></center><br> <a href="[ad link]"><font face=Verdana size=1>[link title]</font></a><br> ... <p><center><b><a href='[Parent Site Link']><font face=verdana size=1 color=red>[Parent Site Name]</font></a></b></center></p> </td></tr></table>[/code] I have made the code a bit more compliant [code]<div style="border:1px solid black;width:110px;height:590px;padding:5px;font-size:x-small;font-family:verdana;"> <h1 style="margin:0;padding:0;font-size:13px;text-align:center;margin-bottom:20px;">[Site Name]</h1> <ul style="list-style:none;margin:0;padding:0;"> <li><a href="[ad link]">[link title]</a></li> ... </ul> <p><a href="[Parent Site Link]" style="color:red;font-weight:bold;">[Parent Site Name]</a></p> </div>[/code] With the updated code I get about a 2k saving per ad set served, which is pretty good, but is still ugly. I am wondering if there might be a better way to do this? Dan @ [url=http://www.codetown.org]Code Town[/url] [small](Edited by [url=http://www.ozoneasylum.com/user/191]WarMage[/url] on 01-18-2007 17:52)[/small]
Loading...
Options:
Enable Slimies
Enable Linkwords
« Backwards
—
Onwards »