You are here: Re: CSS stylesheet with * attribute « HTML « IT news, forums, messages
Re: CSS stylesheet with * attribute

Posted by Chris F.A. Johnson on 08/15/07 16:37

On 2007-08-15, qbert@gmx.at wrote:
> I am using this stylesheet :
>
> * {font-family:verdana;font-size:15px}
> #ta{font-size:30px;color:red}
>
> With the #ta class i want to make my table's text look red and big.
><table id="ta">...
>
> Bad thing: only the red color shows up, font-size stays as defined in
> *
> What am i doing wrong?

You have set every element to 15px (which is the wrong way to do
it; use relative sizing), unless it is specifically changed.
Elements will not inherit font-size from the containing element.

Since you cannot use text directly in a <table> element, the 30px
will not affect anything. You need to apply the styling to the
cells that contain text, <td> and <th>.

--
Chris F.A. Johnson <http://cfaj.freeshell.org>
===================================================================
Author:
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация