Web Design Web Design Forum
Registration is free! Here you can view your subscribed threads, work with private messages and edit your profile and preferences Calendar Find other members Frequently Asked Questions Search
Home Web Design

Convenient web based access to our favorite web design Usenet groups

web design reviews

This is Interesting: Free Magazines for Graphics designers and webmasters  





  Last Thread  Next Thread
Author
Thread Post New Thread   

How to apply a style without using <font>?
 

Louis.




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
Hi all,

One can connect a CSS style to a HTML tag. I want to create a text in
the style footer. I can do:

<font class="footer">Here is my great footer.</font>

However, the <font> tag is depreciated in HTML 4.0 and I would like to
stick to the rules as much as possible. I tried to create my own tag
(see below), but that did not work. I do not want to use <p> or
<table> in this case.

<footer>Here is my great footer.</footer>

What can I do?

Thank you in advance,
Louis.


Please post to this newsgroup, email may not reach me.







Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Terry Kimpling




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
Louis. wrote:
> Hi all,
>
> One can connect a CSS style to a HTML tag. I want to create a text in
> the style footer. I can do:
>
> <font class="footer">Here is my great footer.</font>
>
> However, the <font> tag is depreciated in HTML 4.0 and I would like to
> stick to the rules as much as possible. I tried to create my own tag
> (see below), but that did not work. I do not want to use <p> or
> <table> in this case.
>
> <footer>Here is my great footer.</footer>
>
Why not <p class="footer">???</p>  The styling for class="footer" can be
placed after the <p> styling in the css file and override everything
declared.

--
TK
www.wejuggle2.com
Still Having a Ball




-----= Posted via codecomments.com, Uncensored Usenet News =-----
http://www.codecomments.com - The #1 Newsgroup Service in the World!
-----==  Over 100,000 Newsgroups - 19 Different Servers! =-----


Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Steve Pugh




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
Louis. <louis@despammed.com> wrote:

>One can connect a CSS style to a HTML tag. I want to create a text in
>the style footer. I can do:
>
><font class="footer">Here is my great footer.</font>
>
>However, the <font> tag is depreciated in HTML 4.0

deprecated not depreciated, though it is that as well.

> and I would like to
>stick to the rules as much as possible. I tried to create my own tag
>(see below), but that did not work. I do not want to use <p> or
><table> in this case.

What is the footer? It's probably not a paragraph or a table so <p> or
<table> would indeed be poor choices. Is it a division of your page?
In that case the <div> element would make the most sense.
However, as straight replacement for <font> the <span> element is
simplest.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie."  - The Doctor

Steve Pugh        <steve@pugh.net>        <http://steve.pugh.net/>


Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Stan Brown




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
"Louis." <louis@despammed.com> wrote in
comp.infosystems.www.authoring.stylesheets:
>One can connect a CSS style to a HTML tag. I want to create a text in
>the style footer. I can do:
>
><font class="footer">Here is my great footer.</font>
>
>However, the <font> tag is depreciated in HTML 4.0 and I would like to
>stick to the rules as much as possible.

"span" and "div" are the tags you want. Use "span" for text level
(in the middle of a paragraph, say) and "div" for block level.

If you have a footer then probably it's outside the normal text flow
and you want
<div class="footer">I use Dr.Scholl's.</div>
I have a class "key" for key words and phrases, so I might wrote
something like
<p>When your statistical test fails to reject H<sub>o</sub>,
you must write your conclusion in <span class="key">neutral
language</span>.</p>

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator:      http://validator.w3.org/
CSS 2 spec:     http://www.w3.org/TR/REC-CSS2/
2.1 changes: http://www.w3.org/TR/CSS21/changes.html
validator:      http://jigsaw.w3.org/css-validator/


Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Stan Brown




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
"Stan Brown" <the_stan_brown@fastmail.fm> wrote in
comp.infosystems.www.authoring.stylesheets:
>"span" and "div" are the tags you want. Use "span" for text level
>(in the middle of a paragraph, say) and "div" for block level.

I should add that you use "span" and "div" when no other tag is more
appropriate. For instance, <font> is wildly inappropriate to mark a
footer. <p> might make sense, but if the footer is multiple
paragraphs then you'd need to wrap all of them in a <div>.

But in my example
>	<p>When your statistical test fails to reject H<sub>o</sub>,
>	you must write your conclusion in <span class="key">neutral
>	language</span>.</p>

it could be as good -- maybe better -- to use the "strong" tag since
any browser will then show some emphasis:

<p>When your statistical test fails to reject H<sub>o</sub>,
you must write your conclusion in <strong class="key">neutral
language</strong>.</p>

And in fact that's what I actually do. I was trying to keep things
simple in my earlier note.

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator:      http://validator.w3.org/
CSS 2 spec:     http://www.w3.org/TR/REC-CSS2/
2.1 changes: http://www.w3.org/TR/CSS21/changes.html
validator:      http://jigsaw.w3.org/css-validator/


Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Lars Eighner




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
In our last episode,
<0097g0pip1uqg3jkqi26tqc67l8kupvmrn@4ax.com>,
the lovely and talented Louis
broadcast on comp.infosystems.www.authoring.stylesheets:

> Hi all,

> One can connect a CSS style to a HTML tag. I want to create a text in
> the style footer. I can do:

><font class="footer">Here is my great footer.</font>

> However, the <font> tag is depreciated in HTML 4.0 and I would like to
> stick to the rules as much as possible. I tried to create my own tag
> (see below), but that did not work. I do not want to use <p> or
><table> in this case.

><footer>Here is my great footer.</footer>

> What can I do?

Use <span> or if you mean it to be a block element, use <div>


--
Lars Eighner -finger for geek code-  eighner@io.com [url]http://www.io.com/~eighner/[/u
rl]
If it wasn't for muscle spasms, I wouldn't get any exercise at all.


Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Louis.




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
Thank you kindly. I did not know about span and div. I looked into it
and started using it. Works great.

Louis.

On Sun, 25 Jul 2004 08:58:12 -0400, Stan Brown
<the_stan_brown@fastmail.fm> wrote:

>"Stan Brown" <the_stan_brown@fastmail.fm> wrote in
>comp.infosystems.www.authoring.stylesheets: 
>
>I should add that you use "span" and "div" when no other tag is more
>appropriate. For instance, <font> is wildly inappropriate to mark a
>footer. <p> might make sense, but if the footer is multiple
>paragraphs then you'd need to wrap all of them in a <div>.
>
>But in my example 
>
>it could be as good -- maybe better -- to use the "strong" tag since
>any browser will then show some emphasis:
>
>	<p>When your statistical test fails to reject H<sub>o</sub>,
>	you must write your conclusion in <strong class="key">neutral
>	language</strong>.</p>
>
>And in fact that's what I actually do. I was trying to keep things
>simple in my earlier note.



Post Follow-Up to this message ]
Re: How to apply a style without using <font>?
 

Christoph Paeper




quote this post edit post

IP Loged report this post

Old Post  07-25-04 - 05:15 PM  
*Louis.* <louis@despammed.com>:
>
> One can connect a CSS style to a HTML tag.

No.

> I tried to create my own tag

Funny what people try to do instead of reading up on the matter.

> I do not want to use <p> or <table> in this case.

Depending on what your footer contains, 'address' may be the most
appropriate element. Anyway, why do you post such a mark-up question to
ciwas instead of ciwah?

> Please post to this newsgroup,

Sure, who would do differently?

--
Save the whales, eat more dolphins!


Post Follow-Up to this message ]
Sponsored Links
 





All times are GMT. The time now is 02:13 PM. Post New Thread   
  Previous Last Thread   Next Thread next
Stylesheets archive | Show Printable Version | Email this Page | Subscribe to this Thread

Popular forums

Adobe Photoshop forum Macromedia Flash Web Site Design
Dreamweaver FrontPage forum
JavaScript Forum XML forum
Style Sheets VRML
Forum Jump:
Rate This Thread:

 

XML RSS Feed web design latest articles Syndicate our forum via XML or simple JavaScript

Web Design archive  Database administration help  


Top Home  -  Register  -  Control Panel   -  Memberlist  -  Calendar  -  Faq  -  Search Top