MS FrontPage

Adding Text

FrontPage makes adding text pretty straightforward. When you open a new blank page, your cursor sits at the top-left corner of the editing window. As you type, text moves from left to right, and when it's reached the right margin of the page, your words wrap automatically, continuing on the line below. Text aligns left and wraps like this within table cells, too. When you want to start a new paragraph, just press Enter. So far, so good.

Inserting Spaces

Where things get a bit tricky is when you start to insert spaceseither between paragraphs or between words. Most of the problems stem from the funky rules HTML has for dealing with spaces and the way FrontPage interprets those rules.

Spaces between paragraphs

You may already have noticed that when you type a line, press Enter, and type another line, the text appears double-spaced and there are no options to adjust it.

What's happening is that when you hit Enter, FrontPage creates a new paragraph. In HTML-ese, each paragraph is nestled between paragraph tags (<p>), which translates into a big honking double space between each paragraph. But what if you don't want that space? What if you want a garden-variety book-style single-space between each paragraph?

Enter the line break. A line break inserts a return without creating a new paragraph. To insert a line break hold down the Shift key when you press Enter or select Insert » Break » Normal line break (see Figure 2-1).

Figure 2-1. To see how HTML differentiates paragraph and line breaks, write a few lines of text, separating them with a few breaks of each kind. Then highlight the text and click the Split view button on the lower-left corner of the document window. In the HTML code for the page, you'll see that wherever you entered a line break, FrontPage has inserted a <br> break tag instead of a </p> end paragraph tag.

Fortunately, you're not stuck choosing between these two relatively rudimentary tools. FrontPage gives you a lot more options for spacing text. For more details, see "Aligning and Spacing Paragraphs" on Section 2.4.1.

Spaces between words

When you create spaces between your words, you'll encounter a similar bit of quirkiness. If all you want to do is Web-ify normal-looking sentences like the one you're reading right nowwith a single space between each wordno problem. Type away blissfully in FrontPage, and your brilliant one-space-between-each-word prose will end up on Web browser screens everywhere. But where things get weird is when you want to insert multiple spaces between words. In the normal world of programs like Microsoft Word (or your typewriter, for that matter), each time you hit the Space bar, that's what you'd get on your page: a new space.

But HTML doesn't work like that. When a Web browser is presented with a page of HTML, the browser doesn't care how many spaces are between the words. So, the following:

    <p>I've been working on the railroad.<p>

will display in a browser exactly the same way as:

    <p>I've been      working     on the      railroad.<p>

The engineers at Microsoft decided that most people probably still want to have their Space bar work the way it always has, so FrontPage steps in and performs a little trick: it inserts a nonbreaking space whenever you hit a Space bar more than once. A nonbreaking space is a small string of characters in HTML code (&nbsp;) that tells a browser to display a space no matter what. Hit the Space bar nine times, and FrontPage plunks eight nonbreaking spaces into your underlying HTML. (The program doesn't know you're serious about making space until the second tap on your Space bar, so the first doesn't count.)


Tip: To see what nonbreaking spaces look like, set your document window to Split view. Find your cursor and type two spaces, or press Ctrl+Shift+Spacebar. In the top pane, you'll see the code for a nonbreaking space appear: &nbsp;.

Similarly, striking the Tab key in FrontPage inserts three nonbreaking spaces, letting you indent a paragraph or divide items on a horizontal menu.

Beware of holding down the Space bar, however. Doing so creates a string of nonbreaking spaces, sending adjacent text far off to the right, increasing the width of your page. This is because, true to their name, these spaces don't break away from one another or away from the words on either side of them even at the end of a line. Lean on that Space bar too much and your Web site viewers are going to have to do an awful lot of horizontal scrolling to see what you've written.

The bottom line? Don't use lots of nonbreaking spaces to design or organize your page. The results will be unpredictable and disastrous, guaranteed. There are much better ways to lay out a page, which you'll learn about in the tutorials that follow.

Adding Special Characters

At some point, you'll probably want to add a character that doesn't appear on your keyboard, like a £ (Pound sign) or © (copyright symbol). It's easy to insert symbols and other special characters. Just select Insert » Symbol, and the Symbol dialog box appears (see Figure 2-2). Search through it for the symbol or accented character that you want. Select the symbol and click Insert. Click Close when you're finished.

Figure 2-2. To see additional symbol options, click the "from" drop-down list on the lower right and select Unicode (a more complex coding format that some symbols require).