Previous Page TOC Next Page



7


Working with Webs


by William Robert Stanek

The previous chapter looked at pages. This chapter focuses on webs and the directory structure associated with webs. Webs contain sets of pages and resource files for the pages, such as images, sound files, and video files. All the pages and resource files in webs are organized into easy-to-manage directory structures. Because this chapter contains basic concepts, advanced users might want to skim the chapter for key points.

Creating Webs


You create, edit, and manage webs in the FrontPage Explorer. When you installed FrontPage, a base web called the root web was created on your server. As long as you work with the same server, all webs you create in the Explorer are organized in subdirectories under the same root web.

Getting Started and Selecting a Template


To create a web, press Ctrl+N in the FrontPage Explorer. This opens the New FrontPage Web dialog box, shown in Figure 7.1. Now you can choose a template or wizard to base your web on by double-clicking the left mouse button when the pointer is over the template or wizard title. Alternatively, you can use the arrow keys on your keyboard to highlight a template or wizard and then press the Enter key to make a selection.

Figure 7.1. Selecting a template or wizard for your new web.

For now, you probably want to base your web on the normal web template. All this template does is create a new web with a single page. To learn all about creating webs with wizards and templates, see Chapter 22, "Instant Web Sites with Web Wizards."

If you create a new web in the Explorer and another web is already open, you can select the Add to the Current Web field to merge the contents of the new web with the current web. However, if any of the pages added by the new web have the same filename as a file in the current web, you see the dialog box shown in Figure 7.2. This dialog box asks you to confirm that you want to replace the existing file with the new file. Although you usually do not want to overwrite existing files, you can click the Yes button to confirm that you want the new file to replace the old file.

Figure 7.2. The Confirm Save dialog box asks you to confirm that you want to replace old files with new files.


CAUTION

As you can see from the figure, the Confirm Save dialog box also has a button labeled Yes to All. Use this button only when you know for sure what files the Explorer plans to overwrite. You could accidentally replace all the files in your web with a template outline.



Specifying How to Create the Web


After you select the web template, click the OK button and the FrontPage Explorer opens the dialog box shown in Figure 7.3. In this dialog box, you need to specify how you want to create the new web. You have two options: You can either create the web using a designated server or create the web on your local file system without using a server.

Figure 7.3. Before you can create a web, you must specify where to place the web.

Creating a Web Using the Server

As long as you know the host information for a local or remote server, you can access the server via FrontPage. Simply enter a valid designator for the server and a name for the web. The server designator should be an Internet Protocol address or a valid host name for a Web server. The IP address is a series of numbers separated by periods that is used to determine the machine's location on a network. A sample IP address is 198.5.16.29. The host name is a string of characters that usually forms a word with periods used to separate key parts of the naming structure. A sample host name is tvpress.com.

Generally speaking, you use host names because words are easier to remember than numbers. The host name is for users such as you and me, and IP addresses are for the computers that do the work for us.

Because FrontPage supports publishing on multiple servers, the Web server field has a drop-down list that provides quick access to IP addresses and host names you have used before. To activate the drop-down list, click the down arrow on the right side of the Web server input field. With the drop-down list activated, move the mouse pointer up or down and click the left mouse button to make a selection. If you want to make a secure connection to the server, select the Connect Using SSL option.


TIP

If you are not on a network or do not want to access the network, use the local host IP address of 127.0.0.1 as the server designator. In this way, you can set up a web without connecting to the Internet or a corporate intranet.


After you enter the server designator, you should name the web. Web names can contain numbers, letters, and punctuation characters, but they cannot contain spaces. The best web names are short but descriptive. Visitors to your web might have to type the complete URL path to your web documents in their browsers to reach your Web site. If you use long names, they have to type more and might become irritated.

When you are finished specifying the information for the new web, click the OK button. If this is the first time you have manipulated webs during this session with the FrontPage Explorer, you are prompted with the dialog box shown in Figure 7.4. As the dialog box instructs, you must enter the user name and password for the FrontPage administrator before the web can be created.

Figure 7.4. Only FrontPage administrators can create webs.

After the Explorer authenticates your user name and password, it creates your new web as a child of the root web. What this means is that the new web is located in a subdirectory under the main directory for the root web and because of this, actions you take in the root web might affect the new web.

Because FrontPage creates a subdirectory named after the web, all web names must be unique. If you try to create a web with the same name as an existing web, you see the error message shown in Figure 7.5. Unfortunately, when you click the OK button in this situation, the FrontPage Explorer kicks you back to the New Web dialog box, and you must select the type of web you want to create.

Figure 7.5. All web names must be unique, or you get this error message.

Creating a Web Without Using the Server

If you create a web without using a server, you create the web in a folder on your local file system. FrontPage converts the folder to a FrontPage web and uses the base web in the directory as the root web.

Creating a web without using a server is similar to creating a web with a server. Instead of entering an IP address or host name, you must enter the directory path for the new web. To make it easier to access file locations, you can click the input field to reveal a drop-down list of directories that you've created webs in previously (see Figure 7.6).

Figure 7.6. Using the pull-down list, you can easily select directories or servers you've used previously.

After you select a folder, you should name the web. As stated earlier, web names can contain numbers, letters, and punctuation characters, but they cannot contain spaces. When you are finished, click the OK button. Because you are not using a server, FrontPage does not ask you to authenticate yourself and immediately creates the web.

Opening Existing Webs


FrontPage can access any web you created on any local or remote system. To open a web, select Open FrontPage Web from the File menu in the FrontPage Explorer. As you can see from Figure 7.7, the Open FrontPage Web dialog box is very similar to the New FrontPage Web dialog box. The Web Server or File Location field allows you to open webs with or without a server. The key difference in whether or not you use a server is in the path you enter into this field. If you enter an IP address or URL to a host on the Web, you will use a server. If you enter the path to a file on the local file system, you will not use a server. As with the New FrontPage Web dialog box, the Open FrontPage Web dialog box supports a drop-down list feature that remembers webs and folders you used in the past.

Figure 7.7. Opening a web in the FrontPage Explorer.

After you select a server or folder, click the List Webs button to see a listing of available webs for the server or folder you chose. Keep in mind that all FrontPage servers and folders have root webs. Any time you create webs within a root web, you actually create a subdirectory to use with FrontPage. When you click the List Webs button, these subdirectories are listed.

Sometimes when you try to open a web, you cannot establish a connection to the web's server. If this happens, you see an error similar to the one shown in Figure 7.8. After you click the OK button, you should check the following:

  1. Make sure that the Personal Web Server is started.
  2. If you want to access a remote server, be sure you have a connection to the network or to the Internet.

Figure 7.8. A server connection error message.


NOTE

For FrontPage to work with remote servers, you might have to install FrontPage server extensions on the remote server.



Editing Webs


Because webs represent complex structures of pages and files, editing webs is very different from editing pages. Generally, when you edit a web, you manipulate the web's attributes. Attributes for a web include its title, name, and location.

Changing a Web's Title and Name


The two primary attributes for a web are its title and name. The only use for the web title is as an identifier in the FrontPage Explorer. Otherwise, the web title is not used anywhere else. For this reason, when you create a web, the web title is set the same as the web name.

The web name, on the other hand, identifies part of the URL path to the files in the web. When you change a web's name, you actually move the web to a new subdirectory.

You can change a web's title and name using the Configuration tab of the Web Settings dialog box shown in Figure 7.9. To open this dialog box, select Web Settings from the Tools menu in the FrontPage Explorer.

Figure 7.9. Using the Web Settings dialog box to change a web's name and title.

Creating a New Directory in a Web


Sometimes, you want to create subdirectories for files and pages within a web. To create a new directory in a web, change to the Folder View in the FrontPage Explorer. Select New from the File menu and then select Folder on the submenu.

FrontPage creates a new folder with the folder name highlighted for editing. Now, enter a name for your folder. You can move pages, images, and other files into the new folder. When you do this, FrontPage automatically updates all references to the files.

Displaying Hidden Documents in a Web


In the previous chapter, you learned that you could create directories that are hidden from users. These directories use the underscore as the first character of a directory name, which means that they are private. As a Web administrator, you might need to view and edit files in private directories. To show these directories in the FrontPage Explorer views, you use the Advanced tab of the Web settings dialog box. As shown in Figure 7.10, select the Show Documents in Hidden Directories field and then click the OK button.

Figure 7.10. Using the Advanced Tab in the Web Settings dialog box to display hidden directories.

When you make changes in the Advanced tab, the Explorer displays the dialog box shown in Figure 7.11. This dialog box asks if you want to refresh the web. Generally, you want to click the Yes button to tell FrontPage to refresh the web. When you refresh a web, the FrontPage Explorer instructs the server to retrieve the web with the new settings, make updates as necessary, and build a new text index for the web.

Figure 7.11. Refreshing the web updates the views.

Importing Files to the Current Web


If you have already published on the web, you probably have web documents and images on your hard drive. When you want to use these files in FrontPage, you should import them for use in a specific web. This makes the files easier to manage and makes it possible for you to get all the benefits of using FrontPage.

You can import files of any type in the Explorer. When you import text-based documents that are in a format other than HTML, the Explorer does not convert the page to HTML format. Another reason you might want to import files is to preserve the original formatting of the file.


NOTE

Be sure to configure an editor for all files you import that are not in an HTML or standard image format. To learn how to configure editors for use in FrontPage, see the section "Associating Files with Editors," in Chapter 6, "Working with Pages and Files."


Before you import files, start the FrontPage Explorer and make the web to which you want to add the files the current web. From the Explorer's File menu, select Import to open the Import File to FrontPage Web dialog box shown in Figure 7.12. Initially, almost all the dialog box's buttons are grayed out; you need to add files to the import list before you can use the other options. Your first step is to select the files you want to import.

Figure 7.12. Using the Import dialog box to import files.

You have two ways to select files. Using the Add File button, you can select individual files to import. Using the Add Folder button, you can select entire folders to import.

Clicking the Add Folder button opens the Browse for Folder dialog box (see Figure 7.13). Using this dialog box, you can search for the folder you want to bring into the current web. All files in the folder are added to the import list.

Figure 7.13. Adding folders to the import list.

Clicking the Add File button opens the Add File to Import List dialog box shown in Figure 7.14. As you can see, this dialog box has all the features of the normal open file dialog box. Any files you select are added to the import list.

Figure 7.14. Adding files to the import list.

After you select files for importing, they are displayed in the import list until they are removed from the list with the Remove button or imported into the current web with the OK button. Because of this, you can click the Close button to close the dialog box. Exit the Explorer and then restart the Explorer, and the files are still on the import list.


TIP

Your import list can contain dozens of files. Sometimes you do not want to import them all at the same time. You can select individual files from the import list by moving the mouse pointer to the filename in the list and clicking the left mouse button. You can add files to the selection list by holding down the Ctrl key as you select the additional files. You can select a group of consecutively listed files by clicking the first file you want to select and then moving the mouse pointer to the last item and holding the Shift key as you click the left mouse button.


Another useful button on the Import dialog box is the Edit URL button, which opens the Edit URL dialog box shown in Figure 7.15. Using the Edit URL dialog box, you can change the URL associated with a file you are importing.

Figure 7.15. Editing the URL of a file you plan to import.

An error you might see when adding files to the import list is shown in Figure 7.16. Be careful when you see this error message. The file you are trying to import already exists on the current web, and if you click the Yes button, you overwrite a file in the current web. Unless you are quite sure you want to replace the file, click the No button.

Figure 7.16. Be careful when you see this error message.

Creating a New Web from Existing Folders


The Import Web Wizard is a handy tool to get to know. Using this wizard, you can create a new web from an existing folder.

Your first step is to open the New FrontPage Web dialog box by pressing Ctrl+N and then selecting Import Web Wizard. As you can see from Figure 7.17, the Import Web Wizard dialog box is almost identical to the dialog box you use to create webs. You can create the web with or without a server.

Figure 7.17. Preparing to create a new web from an existing folder.

To create a web using a server, enter the host name or IP address of a local or remote server.Alternately, you can create a web without a server. To do this, simply enter a file path for the new web. A drop-down menu provides quick access to directories you've used before.

Next, enter a name for the new web and click the OK button. If a web with the name you selected already exists on the designated server, you see an error message. Otherwise, the Import Web Wizard launches.

The Import Web Wizard dialog box is similar to other dialog boxes used in FrontPage (see Figure 7.18). Using the buttons labeled Back and Next, you can move backward or forward through the Wizard pages, respectively. Using the Cancel button, you can exist the Wizard without importing the folder.

Figure 7.18. Choose a source directory.

The first wizard page lets you choose a source directory on the chosen server or file system. Click the Browse button to choose a directory name by pointing and clicking your way through the server's file system. By default, the Import Web Wizard includes subdirectories of your chosen directory. Be sure to deselect this option if you don't want to include subdirectories.

After you select a source directory, click the Next button. The Import Web Wizard shows you a complete list of files that you are about to import (see Figure 7.19). You can exclude individual files from the list by selecting the filename in the list and then clicking the Exclude button. By holding down the Ctrl or Shift key as described earlier, you can select groups of files to exclude. To bring back all files from the original unedited list, click the Refresh button. You can then edit the list of files again.

Figure 7.19. Edit the file list.

When you are satisfied with the list of files to import, click the Next button. This brings you to the final wizard page (see Figure 7.20). All you need to do is click the Finish button and the Import Web Wizard imports the files and creates the new web for you.

Figure 7.20. To import files and create the new web, click the Finish button.

Exporting Files


Just as you might need to import files for use with FrontPage, sometimes you want to export files from FrontPage. When you export files from FrontPage, you really only save the files to a location other than the web they are stored in. Although you could use the Save As function of the FrontPage Editor to perform the same task, the reason to use the Explorer to export files is that you can export files without opening them.

To export files, select the file in any view and choose the Export option of the File menu. If you are in Folder View, you can select multiple files for exporting. The dialog box associated with the Export Selected option is shown in Figure 7.21. You use this dialog box as you do the Save As dialog box.

Figure 7.21. Exporting files from the current web.


NOTE

If a page you are exporting contains images or other objects, the Explorer displays a dialog box asking if you want to save the images and objects with the page. Saving these objects with your pages ensures that you have everything you need to publish the pages in one place.



Deleting, Copying, and Moving Webs


Occasionally, you need to delete a web and all the files associated with the web. To delete a web, select Delete FrontPage Web from the File menu in the FrontPage Explorer. After you delete the web, there is no way to get the web back, so the Explorer displays a warning to tell you this.

To copy an entire web to a new location, you use the Publish FrontPage Web option in the File menu. As you see in Figure 7.22, the Publish FrontPage Web dialog box allows you to publish a web to a server and copy a web to a file system. Although FrontPage distinguishes between copying a web to your file system and copying a web to a server, there really is no difference in how the web is copied. However, when you copy a web to a local or remote server, you are publishing the web and making it available for others. When you copy a web to your file system, you are copying the web to a new location that will probably not be accessed directly by users.

Figure 7.22. Copying your webs.

When you want to publish a web, enter the host name or IP address of the host where you want to copy the web. When you want to copy a web to a new location on your file system, simply enter a directory path.

In the Name of Destination FrontPage Web field, enter the name for the web. Although the web name is used to build the directory path to the web, you cannot enter a directory path that includes subdirectories, such as /samples/docs.

The Publish FrontPage Web dialog box has three optional fields: Copy Changed Pages Only, Add to an Existing FrontPage Web, and Copy Child Webs. When you select the Copy Changed Pages Only field, only pages that have been updated are copied. This is a good option to use if you have copied or published files to the destination web before and want to ensure that only the latest changes to the web are copied.

If you check the Add to an Existing FrontPage Web field, the FrontPage Explorer allows you to merge the web you are copying into an existing web. When you insert files into a web, you might find that some files have duplicate names. Usually, you do not want the new files to overwrite the old files.

The final optional field, Copy Child Webs, is available only when you copy the root web. If you check the Copy Child Webs field, all webs listed when you access the root web's server are copied to the new destination.

As you can see, copying a web is essentially the same as moving the web to a new location. When you want to move a web from one server to another, you use the File menu's Publish FrontPage Web option.

Summary


Although webs are more complex than pages, FrontPage has great features that make creating, editing, and deleting webs easy. After reading this chapter, you should be able to work with webs in FrontPage. You are now ready to learn how to create powerful web documents.

Previous Page Page Top TOC Next Page