In order to style an HTML page using "select" elements we are using selectors as one of the most important aspects of CSS .
CSS Selector:Syntax
In a typical CSS statements you have the
following:
SELECTOR { PROPERTY: VALUE }
You wish to manipulate
and "VALUE" represents the value of the specified property whereas the property is the CSS element.
For example, you could mark up the page in the following way if you want to target the first paragraph and first list items on a page to make them stand out:
<body>
<p class="big">This is some <em>text</em></p>
<p>This is some text</p>
<ul>
<li class="big">List item</li>
<li>List item</li>
<li>List <em>item</em></li>
</ul>
</body>
CSS Selector Name
The HTML tag is a direct relationship to the selector name which you want to edit. If you wanted to change the way a
paragraph tag behaved the CSS code would look like:
p { PROPERTY: VALUE }
Whenever you are manipulating the paragraph HTML element,the above example is a template that you can
use . In the next lessons we will teach why
and where you should use CSS and where to place your CSS .
Share And Enjoy:These icons link to social bookmarking sites where readers can share and discover new web pages.