Help with SPAN tags

liunx

Guest
Im trying to position a clock into a TD that has a height of 20 and a width of 239, when i enter the clock code... <br />
<span id=clock style="position:relative;"></span> it puts it on the left side of the TD, which is expected, but then i added center tags before and closing after the span to get it to appear in teh center of the TD, it does, but this, for some reason, resized the TD in the browser to about twice the regular height, and put the clock on the bottom of the td, :o this is really buggin me, how do i get it to STAY at 20 height like the code specifies, and center the clock?<!--content-->how about attaching the HTML for us to have a look at? or at least the relevant bits.<!--content-->heres the page where the problem takes place,<!--content--><TABLE ALIGN="center"BORDER="1"BORDERCOLOR="#2F67FF"CELLSPACING="3"CELLPADDING="2"><TR><TD HEIGHT="20"WIDTH="239">&nbsp;<BASEFONT SIZE="2"><br />
<CENTER><span id=clock style="position:relative;"></span><br />
</TD><TD HEIGHT="20"WIDTH="240"><CENTER><B><FONT FACE="ARIALOUS"COLOR="MAROON">&nbsp;&bull;JBr&oslash;&ntilde;&iacute;&eacute;&bull;&nbsp;&nbsp;V&middot;1.3</FONT></B></CENTER></TD><TD HEIGHT="20"WIDTH="239"><CENTER><BASEFONT SIZE="2"><SCRIPT LANGUAGE = "JavaScript"> <br />
<br />
urgh, do you always write code like this?<br />
<br />
you don't have a closing </center> tag in the first table cell.<br />
<br />
btw - <center> is a deprecated element now - its recommended that you use a style sheet instead, or you could use the align attribute of the <td>.<!--content-->i am aware that there is no CENTER closing tag, i did that on purpose, i originally had it with a closing tag bit i was so desperate i was trying everything, even stuff i knew wouldnt work, it still has the same problem wether or not i use the closing tag<!--content-->here:<br />
<br />
TD HEIGHT="20"WIDTH="239" align="center"><br />
<span id=clock style="position:relative;"></span><br />
</TD><!--content-->TD in the browser to about twice the regular height,<br />
yes, if you put a &n bsp; <br />
before the span.<br />
And why no spaces in the code?<br />
BORDER="1"BORDERCOLOR="#2F67FF"CELLSPACING="3"CELLPADDING="2"><br />
has to be<br />
BORDER="1" &nbsp; BORDERCOLOR="#2F67FF" &nbsp; CELLSPACING="3" &nbsp; CELLPADDING="2"><br />
Arachnophilia has discoverd a lot of errors:<br />
in table and td tags.<!--content-->The usage of the <basefont> tag is also not correct. This [deprecated] tag usually appears soon after the <body> tag, not somewhere deep inside a <table> structure.<br />
<br />
I would recommend running the code through <!-- m --><a class="postlink" href="http://validator.w3.org/">http://validator.w3.org/</a><!-- m --> as this will pick up the syntax errors, and problems with the logic and structure of the HTML code.<br />
<br />
<br />
<br />
<br />
<br />
[Can someone please fix the thread stretch]<!--content-->
 
Back
Top