10.07.2017 Views

246996016-HTML5-Step-by-Step

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Applying Bold and Italics 113<br />

In this exercise, you will apply bold and italic styles to ordered and unordered lists.<br />

SET UP Use the foliage.htm file in the practice folder for this topic. This file is located<br />

in the Documents\Microsoft Press\<strong>HTML5</strong> SBS\07Text\ApplyingBold folder. Open the<br />

foliage file in Notepad and in Internet Explorer.<br />

1. In the section, add bold formatting to the definition of an ordered list.<br />

ol {list-style-type: decimal; font-weight: bold}<br />

2. Save the file, and then refresh the Internet Explorer display to see the change.<br />

The text of the entire list becomes bold.<br />

3. Create a new style rule for unordered lists, setting the font weight to normal.<br />

ul {font-weight: normal}<br />

4. Save the file, and then refresh the display in Internet Explorer.<br />

The unordered list items are no longer bold, but the ordered list items are.<br />

5. Create a new style rule for unordered lists within unordered lists, setting the font<br />

style to italic.<br />

ul ul {font-style: italic}<br />

6. Save the file, and then refresh the display in Internet Explorer.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!