homepage Welcome to WebmasterWorld Guest from 54.198.148.191
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Pubcon Website
Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
Learning HTML and having a problem
Page loads correctly in IE but not firefox
Acekicker




msg:583345
 9:31 am on Jun 4, 2006 (gmt 0)

I am currently on the third chapter of a book I got on HTML and I was working through one of the exercises and I couldn't for the life of me get it to work like the book showed. That is until I opened the page in IE instead of firefox (the browser I use). Here is the code:

<html>
<head><title>Experiment With Fonts and Color</title></head>
<body>
<basefont face="Arial" size="5" color="blue" />
<p>All the text on this page will display in a <br />
blue Arial font. The base size of the font is 5.</p>
<p><font face="times new roman" size="-2" color="black">
To change to a smaller, black Times New Roman font, use the font<br />
element. The -2 in the size indicated that we are reducing<br />
the font two settings relative to the basefont of 5.</font></p>

Just for fun <font color="mediumvioletred">we're going<br />
to change the color of our original font.<br />
Also, did you notice that everything after the closing font<font><br />
tag is back to the original setting (except size of course).</p>
</body>
</html>

Could someone help me figure out why it will work for IE and not firefox? Btw, I have checked it many times and it's verbatim to the book example.

Thanks

 

larryhatch




msg:583346
 11:00 am on Jun 4, 2006 (gmt 0)

Use the handy, authoritative online validator:
[validator.w3.org...]

You could have a typo hiding in plain sight. -Larry

Iguana




msg:583347
 11:03 am on Jun 4, 2006 (gmt 0)

The <basefont> tag has been depreciated. Try
<body style="font-family:Arial; font-size:large; color:blue">.
Ideally you would want to set your default font properties in a CSS file.

IE is sometimes more forgiving than Firefox

rocknbil




msg:583348
 5:05 pm on Jun 4, 2006 (gmt 0)

Acekicker sorry to veer off topic but that has to be a really old book. The font tag is also deprecated:

What's wrong with FONT? [mcsr.olemiss.edu]

If you're learning from scratch, learn both HTML and CSS. HTML for document structure, CSS for presentation (and other things.) A GREAT place to start:

W3 Schools [w3schools.com]

Acekicker




msg:583349
 11:36 am on Jun 5, 2006 (gmt 0)

lol, I feel like an idiot. The very next page in the book tells me that font is deprecated and the next lesson is CSS.

Thanks for the replies everyone.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About
© Webmaster World 1996-2014 all rights reserved