22.06.2015 Views

Step by Step HTML5

Create successful ePaper yourself

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

338 Chapter 17<br />

Look in the section of the code. Notice that a tag has been<br />

inserted, creating an internal CSS style sheet for the document:<br />

<br />

.auto-style1 {<br />

font-family: Arial, Helvetica, sans-serif;<br />

font-size: xx-large;<br />

color: #FFFFFF;<br />

}<br />

<br />

Tip If you want to avoid using an internal style sheet, you can select the style (.autostyle1<br />

{font-family: Arial, Helvetica, sans-serif;}) and then cut and paste it over to the<br />

default.css style sheet. Some Web designers prefer to keep all styles in one place. This<br />

way, they don’t need to be concerned about where a particular style is stored.<br />

24. Press Ctrl+S to save index.html.<br />

A Save Embedded Files dialog box opens, prompting you to also save the associated<br />

style sheet.<br />

25. Click OK to save both files.<br />

CLEAN UP Leave the page and the Web site open in Expression Web for the next<br />

exercise.<br />

Formatting a Division<br />

As you just saw, one way to format text is to apply certain formatting to the division that<br />

contains the text. You can also format divisions in other ways, such as specifying certain<br />

positions, margins, or padding for them. Making changes such as these is easy in Expression<br />

Web; you can resize and reposition a division <strong>by</strong> simply dragging elements in the<br />

Design pane.<br />

In this exercise, you will apply text formatting in several ways, resulting in several types of<br />

tags and attributes being created in the code.<br />

SET UP Start in Expression Web, with the Web site still open from the previous<br />

exercise.<br />

1. At the bottom of the editing pane, click Design to display the page in Design view<br />

only (not split).<br />

2. Click in the Masthead division to select it.<br />

3. Position the mouse pointer over the bottom of the Masthead division.<br />

White square selection handles appear around the division.

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

Saved successfully!

Ooh no, something went wrong!