Jump to content

font size="2" inside table does not work in IE6?


htmlnewbie23

Recommended Posts

I use font "size" quite a lot in my webpages. I know that CSS is the way to go, but that is not how I have written my pages. When I recently set the font size as ="2" within a table, it worked in Firefox 2 but I was surprised to see no effect on the font size when viewed in IE6. The actual code I wrote is

		<table align="center" border="3" cellPadding="0" cellSpacing="0" width="20%">		<tbody>			<tr>				<td  bgColor="blue">					<div align="center">						<b>						<a href="xxx.htm#History">						<img src="im/history.gif" width="32" height="32" alt="Menu of Articles and Links on History" border="0">						</a>						</b>					</div>				</td>				<td bgColor="blue">					<div align=center>						<b><a href="yyy.htm#History" title="Menu of Articles and Links on History">							<font face="arial, helvetica, sans-serif" color="white" size="2">								History							</font>							</a>						</b>					</div>				</td>			</tr>

The size="2" works to reduce the text as seen in Firefox but not in IE6. Is this a peculiarity of IE6 or am I writing the code wrong?The webpage can be seen at www.SephardicGen.comThank you.

Link to comment
Share on other sites

The font tag is deprecated, meaning it won't be supported much longer and you should replace it with CSS styling.

<span style="font-size: 1.5em;"> Text here </span>

might be what you are looking for. Adjust the 1.5em to suit, or possibly use 14px, or such.

Link to comment
Share on other sites

Guest FirefoxRocks

Ok I picked out what the problem is here:

<b><a href="yyy.htm#History" title="Menu of Articles and Links on History"><font face="arial, helvetica, sans-serif" color="white" size="2">History</font></a></b>

And hopefully this can solve it:

<a href="yyy.htm#History" title="Menu of Articles and Links on History" style="font-weight:bold;font-family:Arial,Helvetica,sans-serif;color:#fff;font-size:small">History</a>

Replace small with a measuring unit or something to suit your style.

Link to comment
Share on other sites

hi htmlnewbie23,try out this...........<font face="arial, helvetica, sans-serif" font size="2" color="white">try out with adding the "font size" it will help u out optherwise go with the css ...bye

Ok I picked out what the problem is here:
<b><a href="yyy.htm#History" title="Menu of Articles and Links on History"><font face="arial, helvetica, sans-serif" color="white" size="2">History</font></a></b>

And hopefully this can solve it:

<a href="yyy.htm#History" title="Menu of Articles and Links on History" style="font-weight:bold;font-family:Arial,Helvetica,sans-serif;color:#fff;size:small">History</a>

Replace small with a measuring unit or something to suit your style.

Link to comment
Share on other sites

no thats not the case, what Firefoxrocks said should work fine only instead ofstyle="font-weight:bold;font-family:Arial,Helvetica,sans-serif;color:#fff;size:small"try 'font-size' instead of 'size' i.e. style="font-weight:bold;font-family:Arial,Helvetica,sans-serif;color:#fff;font-size: small" that should work cross-browser

Link to comment
Share on other sites

no thats not the case, what Firefoxrocks said should work fine only instead ofstyle="font-weight:bold;font-family:Arial,Helvetica,sans-serif;color:#fff;size:small"try 'font-size' instead of 'size' i.e. style="font-weight:bold;font-family:Arial,Helvetica,sans-serif;color:#fff;font-size: small" that should work cross-browser
Thanks. I'll give it a try.Am I correct in assuming that IE6 just shows text in larger displayed size than the same page displayed in Firefox 2 or is it some bad setting on my side or in my code. An example is the page in question http://www.sephardicgen.com . All the text seems larger in IE6 than in Firefox. (I use the "IE Tab" add-on in Firefox to view the same page in IE6. So the browser size and everything else is identical. But I also check by opening the page in a separate IE6 and find the same difference in displayed text size: larger in IE6 than in Firefox. Isn't font face="arial, helvetica, sans-serif" the same in both IE and Firefox?)
Link to comment
Share on other sites

The 'cascade' part of the term CSS is kicking in there. Changing the Browser's default font-size and having it over-ride the page's font-size declaration is useful for people with vision problems. They can set their sizes to suit their vision, and the page author can't alter that on them.http://www.w3.org/TR/CSS21/cascade.html#cascadeThis might help, also:http://www.w3.org/TR/CSS21/cascade.html#specificity

Link to comment
Share on other sites

The 'cascade' part of the term CSS is kicking in there. Changing the Browser's default font-size and having it over-ride the page's font-size declaration is useful for people with vision problems. They can set their sizes to suit their vision, and the page author can't alter that on them.http://www.w3.org/TR/CSS21/cascade.html#cascadeThis might help, also:http://www.w3.org/TR/CSS21/cascade.html#specificity
Thanks for taking the time to reply and for the links. I will go to them and see what they say.But, this is my own webpage and both IE6 and Firefox 2 browsers are on my own PC. I know that I did not use any cascade SS when writing the html code for that page. Do you mean that IE6 has a default CSS built in that forces a certain size of text to be displayed that is larger than the same page displayed on Firefox even though the html code and everything else is the same?
Link to comment
Share on other sites

try using <span style="font-size: 10px;"> Text Here</span>or<div style="font-size: 10px;"> Text Here</div>they will workchange the font size to what ever you need it to be!hope that has solved your problem

Link to comment
Share on other sites

Do you mean that IE6 has a default CSS built in that forces a certain size of text to be displayed that is larger than the same page displayed on Firefox even though the html code and everything else is the same?
correct
Link to comment
Share on other sites

Archived

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

×
×
  • Create New...