hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Web Design and Content : <font> and <center> etc...
Reply

Web Design and Content Subjects include, HTML, graphics, editors, CSS, Flash, graphics creation, placing of ads, ad serv companies, copyright, content and nearly anything else design related. Also talk about businesses that provide design services. If you link to your site, you must post in Web Site Reviews.
Forum Jump

<font> and <center> etc...

Reply Post New Thread In Web Design and Content Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 09-12-2003, 11:12 AM
trenzterra trenzterra is offline
Junior Guru Wannabe
 
Join Date: Oct 2001
Posts: 44

<font> and <center> etc...


I experimented today with xHtml 1.1 strict, and noticed that <font> and <center> doesn't validate... what are the new codes for them?

__________________
http://phalenium.uni.cc - My tiny little website/blog
http://getsmilies.com - Looking for smilies? Come to my smiley database

Reply With Quote


Sponsored Links
  #2  
Old 09-12-2003, 12:07 PM
Rich2k Rich2k is offline
Web Hosting Master
 
Join Date: May 2002
Location: UK
Posts: 2,994
use CSS

If you want to use <font> and <center> use XHTML 1.0 transitional

Reply With Quote
  #3  
Old 09-12-2003, 12:31 PM
trenzterra trenzterra is offline
Junior Guru Wannabe
 
Join Date: Oct 2001
Posts: 44
Yeah, but how do I incorporate it?

I thought <style> can only be used in headers

__________________
http://phalenium.uni.cc - My tiny little website/blog
http://getsmilies.com - Looking for smilies? Come to my smiley database

Reply With Quote
Sponsored Links
  #4  
Old 09-12-2003, 01:13 PM
switch switch is offline
Junior Guru Wannabe
 
Join Date: Jul 2001
Location: #!/usr/bin/Detroit
Posts: 85
In your case, you'll need to use other decriptive tags then assign properties to them via css.

For example -
<p class="text1">
<h1 class="text2">

For inline styles -
<p style="border:1px black solid;color:red>

__________________
Juvenall Wilson
http://www.yabbforum.com


Last edited by switch; 09-12-2003 at 01:21 PM.
Reply With Quote
  #5  
Old 09-12-2003, 01:37 PM
Website Rob Website Rob is offline
learning is in the doing
 
Join Date: Sep 2000
Location: Alberta, Canada
Posts: 3,109
Sounds like someone has some learning to do.

The 'font' & 'center' tags, along with a bunch of others, have be deprecated for a couple of years now. After HTML, CSS is the next language a person should learn as it can be used to apply styling; as opposed to the old fashioned way of doing it within HTML code.

Font is now determined by; font-family, font-size, font-weight, etc. and center is determined by using 'margin' and/or 'position' coding. Style can be applied inline to most any HTML tag.

The big trick is to learn about how 'Parent & Child' relationships work within CSS and the bug in IE 6 that will sometimes center everything.

Some helpful, if somewhat outdated sites are:

Transitioning from Proprietary DOMs and Markup to W3C Standards
http://sites.netscape.net/ekrock/upgrade/standards.html

Is Your Site Ready for Communicator 5?
http://hotwired.lycos.com/webmonkey/00/04/index1a.html

Specific to centering content with CSS.
http://allmyfaqs.com/cgi-bin/wiki.pl?Center_with_CSS

Blue Robot centered layout, be sure to look at the rest of the site
http://www.bluerobot.com/web/css/center1.html

Centering tables with CSS.
http://www.evolt.org/article/Does_IE...tent/17/15341/

The last one is a particular article about IE 6 quirks mode, and how the cell *contents* of a centered table got centered, and how people were suddenly facing the daunting tasks of adding align=left to all their table cells!

__________________
PotentProducts.com - for all your Hosting needs
Helping people Host, Create and Maintain their Web Site
ServerAdmin Services also available

Reply With Quote
  #6  
Old 09-12-2003, 03:12 PM
chrisrhee chrisrhee is offline
Junior Guru Wannabe
 
Join Date: Aug 2003
Posts: 33
Also, to align your text, you can include this line in your CSS:

text-align: center;

(or left, or right).

Reply With Quote
  #7  
Old 09-12-2003, 03:15 PM
sstamour sstamour is offline
Junior Guru Wannabe
 
Join Date: Aug 2003
Posts: 89
If you specify a valid, strict doc-type in your headers, that should take IE 6 out of quirks mode. It can fix MOST of the problems IE has, though not all.

Reply With Quote
  #8  
Old 09-12-2003, 04:04 PM
Rich2k Rich2k is offline
Web Hosting Master
 
Join Date: May 2002
Location: UK
Posts: 2,994
Quote:
Originally posted by Website Rob
The last one is a particular article about IE 6 quirks mode, and how the cell *contents* of a centered table got centered, and how people were suddenly facing the daunting tasks of adding align=left to all their table cells!
Actually that isn't a quirk it's working properly.

I believe in XHTML / CSS2 alignments are inherited whereas in HTML 4 they weren't. Thus in a centred table the cells inherit the centred status.

Reply With Quote
  #9  
Old 09-12-2003, 06:45 PM
Dan L Dan L is offline
Web Developer
 
Join Date: Feb 2003
Location: Connecticut
Posts: 5,441
<span> is the preferred alternative to <font>. However, with <span> you need CSS, which was mentioned earlier.

Reply With Quote
  #10  
Old 09-12-2003, 08:59 PM
trenzterra trenzterra is offline
Junior Guru Wannabe
 
Join Date: Oct 2001
Posts: 44
so I can replace:

<td (everything else goes here)>
blahblah

<font size="4" face="arial">
testing
</font>

blah

<font size="6" face="arial">
etc...
</font>
</td>

with:

<td (everything else goes here)>
blahblah

<span style="font-size: 14pt; font-family: arial";>
testing
</font>

blah

<span style="font-size: 16pt; font-family: arial";>
etc...
</font>
</td>

__________________
http://phalenium.uni.cc - My tiny little website/blog
http://getsmilies.com - Looking for smilies? Come to my smiley database

Reply With Quote
  #11  
Old 09-13-2003, 12:24 AM
Website Rob Website Rob is offline
learning is in the doing
 
Join Date: Sep 2000
Location: Alberta, Canada
Posts: 3,109
Quote:
Originally posted by Rich2k
Actually that isn't a quirk it's working properly.

I believe in XHTML / CSS2 alignments are inherited whereas in HTML 4 they weren't. Thus in a centred table the cells inherit the centred status.
Not quite true. This is long known bug and only in IE 6. A child setting should be able to over-ride the parent setting and this doesn't happen with 'centering' -- within IE 6 any version.


trenzterra, doesn't seem like you'v interpeted those articles correctly. Or were those typos?

Should be:

<span style="font-size: 14pt; font-family: arial";>
testing
</span>

blah

<span style="font-size: 16pt; font-family: arial";>
etc...
</span>

But setting up 'classes' for TD would be much easier.

<td class="setup1">blah blah</td>

<td class="setup2">blah blah</td>

The "classes" of course, would be stated in your CSS file. That's how one really sees the beauty of using CSS. Want to change what "setup1" means -- in a few hundred Web pages -- make the change in the CSS file and every Web page picks up and applies the change.

__________________
PotentProducts.com - for all your Hosting needs
Helping people Host, Create and Maintain their Web Site
ServerAdmin Services also available

Reply With Quote
  #12  
Old 09-13-2003, 05:02 AM
Rich2k Rich2k is offline
Web Hosting Master
 
Join Date: May 2002
Location: UK
Posts: 2,994
Quote:
Originally posted by Website Rob
Not quite true. This is long known bug and only in IE 6. A child setting should be able to over-ride the parent setting and this doesn't happen with 'centering' -- within IE 6 any version.
I don't have any problems overriding parent settings with child settings in CSS?

Reply With Quote
  #13  
Old 09-13-2003, 09:54 PM
trenzterra trenzterra is offline
Junior Guru Wannabe
 
Join Date: Oct 2001
Posts: 44
span seems to have a problem in mozilla browsers, i see a huge spacing in between lines, anyone know whats wrong?

__________________
http://phalenium.uni.cc - My tiny little website/blog
http://getsmilies.com - Looking for smilies? Come to my smiley database

Reply With Quote
  #14  
Old 09-13-2003, 10:15 PM
Website Rob Website Rob is offline
learning is in the doing
 
Join Date: Sep 2000
Location: Alberta, Canada
Posts: 3,109
What's the code being used?

__________________
PotentProducts.com - for all your Hosting needs
Helping people Host, Create and Maintain their Web Site
ServerAdmin Services also available

Reply With Quote
  #15  
Old 09-13-2003, 11:42 PM
platinum platinum is offline
Aspiring Evangelist
 
Join Date: Jan 2002
Location: Adelaide, Australia
Posts: 405
You don't need to use span evem if it's a wrapped in another element

td {
font-family: verdana;
font-weight: bold;
color: blue;
}

will set all of your cells to contain that style without the need for unneeded spans

Reply With Quote
Reply

Related posts from TheWhir.com
Title Type Date Posted
Cogeco Data Services Opens Data Center in Barrie, Ontario Web Hosting News 2013-06-13 13:44:41
Strategies to Reduce Operating Costs, Avoid Email Blacklisting and Improve Deliverability Webinars 2013-06-06 13:59:25
WHD.india 2013 Web Hosting Events 2013-05-22 13:02:04
Carter Validus Mission Critical REIT Acquires Raleigh Data Center Web Hosting News 2013-03-27 14:24:26
What the new version of Google Analytics brings to your business Blog 2011-12-20 15:56:29


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?