Class Selectors.

CSS

A class selectors is an identifier you can to assign a style to a subset of elements in a document.To apply a class selector,you first invent an identifier for the class name.To allow for the potential scripting of class names,it is wise to adhere to the rules of JavaScript identifiers when devising class names.A JavaScript identifier is a one-word name that can include numerals,letters and limited punctuation.Also the first character of an identifier cannot be a numbered.The CSS2 guidelines for selector identifiers are less stringent:you can embed hyphens.Unicode characters above 160,and escaped characters in an identifier,but the name must not began with a numeral or hyphen.If you are now or may eventually script class selectors follow the JavaScript rules instead of the more liberal CSS2 rules.The class identifier goes in both the style sheet rule and the HTML tag for the element that is to obey the rule.While the identifier name is the same in both cases,the syntax for specifying it is quite different in each place.

Add comment

Please comment relevant to the topic. Not relevant comments will not be posted and user will be banned from the website.


Security code
Refresh

Login Form (Can use your Gmail Acct)

Latest Comments

Copyright © 2013 Interview Questions, Tutorials, Certification Questions. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.