You are here: Re: class vs. style « HTML « IT news, forums, messages
Re: class vs. style

Posted by Jukka K. Korpela on 01/19/07 19:21

Scripsit Robin Rattay:

> I need to delurk for a moment, since I'm confused.

Fine. (I mean your delurking, not confusion. :-) )

> I've re-read the CSS specification on specificity, and tested it in
> FF, resulting in the conclusion, that ".no_left_border" is more
> specific than "table td" (0010 verses 0002). So both examples of the
> OP should be showing no border, i.e. "working".

You are quite right. I was careless enough to think only in terms of names
in a selector, but indeed the context matters: any selector with at least
one class selector has higher specificity than a selector that contains
element names only.

So I guess we'd next need to know where it didn't work. The OP probably had
a syntax error somewhere and that error was fixed when he tried some of the
suggestions. As usual, posting a URL would have saved some time and effort.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

 

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

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