Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   HTML (http://www.velocityreviews.com/forums/f31-html.html)
-   -   Where to put the css class for text? (http://www.velocityreviews.com/forums/t156953-where-to-put-the-css-class-for-text.html)

John Sutter 02-03-2004 12:23 AM

Where to put the css class for text?
 

I have a list of orders in a html table. Each order is a link and it's
contained in a td. I would like to format the text displayed using css.
Where should I put the css class name? In the TD tag or in the font tag or
somewhere better?

For example:

..... <TD class="ordertext"><a href=...>Order #1</a> </td>
or
.... <TD><font class="ordertext"><a href=...>Order #1</a></font> </td>
or
??

John

Mark Parnell 02-03-2004 12:34 AM

Re: Where to put the css class for text?
 
On Mon, 2 Feb 2004 16:23:51 -0800, John Sutter <johnjjj@yahoo.com>
declared in alt.html:

> I have a list of orders in a html table.


Sounds like it *could* be tabular data. ;-)

> Each order is a link and it's
> contained in a td. I would like to format the text displayed using css.


Glad to hear it.

> Where should I put the css class name? In the TD tag or in the font tag or
> somewhere better?
>


What font tag? You don't mean you are thinking of using <font>, which
was deprecated in favour of CSS, to apply CSS styles?

Anyway...

>
> .... <TD class="ordertext"><a href=...>Order #1</a> </td>


If it applies to every link in the table, why not apply it to the table?
Then you only have to put it in once. :-)

--
Mark Parnell
http://www.clarkecomputers.com.au

Richard 02-03-2004 03:02 AM

Re: Where to put the css class for text?
 
John Sutter wrote:


> I have a list of orders in a html table. Each order is a link and it's
> contained in a td. I would like to format the text displayed using css.
> Where should I put the css class name? In the TD tag or in the font tag
> or somewhere better?


> For example:


> .... <TD class="ordertext"><a href=...>Order #1</a> </td>
> or
> ... <TD><font class="ordertext"><a href=...>Order #1</a></font> </td>
> or
> ??


> John


Depends on how you want to use it.
<table class="x"> would be for the entire table.
<tr class="x"> for the entire row.
<td class="x"> for the single cell.

Don't use the font tag. Instead, put that in your css stuff using the font:
attribute.






Richard 02-03-2004 03:07 AM

Re: Where to put the css class for text?
 
Mark Parnell wrote:

> On Mon, 2 Feb 2004 16:23:51 -0800, John Sutter <johnjjj@yahoo.com>
> declared in alt.html:


>> I have a list of orders in a html table.


> Sounds like it *could* be tabular data. ;-)


I'd still like to know who it is that defined tabular=tables.
Probably the same guy who designed css.
Why do people use tables for layout presentation?
Because it's simple and easy to do and accepted worldwide.
Show me a web editor that creates divisions in the same manner as tables.

I'll bet a peso you can't do it.
But every editor I've seen has a table generator.





All times are GMT. The time now is 02:02 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.