Viewing and Cleaning Up HTML to Ensure Consistency


FrontPage is flexible enough to enable both novices and experienced programmers to design Web pages the way they want to. Beginners can use menus , toolbars , and buttons to weave Web pages. Advanced users can work directly with the source HyperText Markup Language (HTML) for a Web page. You can highlight specific HTML commands in different colors, or use search-and-replace to edit multiple occurrences of commands.

View HTML Tags

You can always switch to Code View when you want to view the HTML for a page. But if you re in a hurry, and you like to see the tags in context ”that is, wrapped around the Web page contents you create ”you can have FrontPage reveal the tags to you in Design View. Just:

See Also  

See Chapter 10, Streamlining HTML and XML Markup, for a detailed discussion of FrontPage s Code View, Split View, and other features for viewing and editing Web page HTML and XML code.

  1. Open the page you want to work on.

  2. Choose View, Reveal Tags.

  3. Pass the mouse pointer over a tag to view; the entire text of the tag appears as a screen tip (see Figure 19-10).

    click to expand
    Figure 19-10: You can view and edit HTML tags directly in Design view using Reveal Tags.

Once you ve revealed the HTML tags for a page you re working on, it s easy to edit them. But you ve got to switch from Design to Code View. Just:

  1. Position the cursor where you want to insert new HTML.

  2. Click Code to switch to Code View. Then, select a word, or entire line of code.

  3. Click Cut, Copy, or Paste to make changes to the page s HTML if needed.

Doing an HTML Cleanup

It s up to the editors and writers who provide your Web site s content to make sure the words contained on your Web pages are free of grammatical errors and typos. But it s up to you to make sure your site s behind-the-scenes content ”its HTML code ”has the correct syntax.

If you create all of your content from scratch using FrontPage, you can be certain that your HTML is correct. But often, Webmasters import text from word processing programs or other Web page editors that sometimes add unnecessary HTML commands to your Web page code. You can tell FrontPage to clean up the code so that your Web pages appear consistently in all browsers, and no unnecessary commands appear online by mistake. Just follow these steps:

  1. Open any page in the Web site that has the HTML you want to clean up.

  2. Choose Tools, Optimize HTML.

    See Also  

    See Chapter 20, Customizing and Maintaining FrontPage 2003, for more on using the Drawing toolbar to draw images on your Web pages.

  3. In the Optimize HTML dialog box (see Figure 19-11), choose the options you want to optimize. Click Word HTML if you have created some of your Web pages in Microsoft Office Word 2003 and you want to delete the extra commands that Word adds. Click Delete VML content if you have used the Microsoft Office Drawing toolbar to draw images, which use Vector Markup Language (VML) that older browsers cannot display.

    click to expand
    Figure 19-11: Cleaning up your HTML ensures that your pages will appear quickly and without commands visible online.

  4. When you re done, click OK.

Aha!  

Optimize HTML When You Publish
You can instruct FrontPage to automatically optimize the HTML of Web pages that you publish ”that is, that you move from your local Web site to a remote Web site. In Remote Web Site view, click Remote Web Site Properties. In the Remote Web Site Properties dialog box, on the Web Site tab, click Optimize Published HTML. Select the options that you want FrontPage to optimize, then click OK.




Faster Smarter Microsoft Office FrontPage 2003
Faster Smarter Microsoft Office FrontPage 2003
ISBN: 0735619727
EAN: 2147483647
Year: 2004
Pages: 179

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net