Using the Site Definition Wizard
In the Site Definition wizard, give your site a name. This name is used only inside Dreamweaver, so you can use spaces and characters in it if you want. The site name should be meaningfulit should identify the purpose of the Web site when you drop down the Site menu to change sites. My Dreamweaver has about 30 to 40 sites defined at times, so clear names help me quickly find the site I want to edit. Click the Next button.
The next page of the wizard, Editing Files, Part 2 (shown in Figure 3.3), enables you to specify whether you will be using server-side scripting to create dynamic Web pages. Your Web pages in this book will be regular HTML pages, so you should select the top radio button that says No, I Do Not Want to Use a Server Technology. Click the Next button.
The next page, Editing Files, Part 3, helps you specify where the files in your site are located. The site that you are creating here is your development site not the final site that other people will view over the Web. You will need to move the files in your development site up to a server for people to view the files over the Web (the subject of Hour 20). The Web site located on a Web server and available to the public is called the live site. I always work on an up-to-date copy of a Web site that is located on my local hard drive.
You can store your development files in three places: on your local machine, on a network drive, or on a server somewhere. Select the top radio button to elect to store the development files on your local machine. If you are working in a networked environment (at your office, for instance), you could use either of the other two choices.
Don't Develop on the Live Site
Do not ever link to the final live site for development. You do not want to make a mistake on the real site; always make sure you are working on a copy of the site.
As shown in Figure 3.4, the text box at the bottom of the dialog box asks you to enter the location of the site directory. Click the folder icon to the right of the text box to navigate to the directory. Use an existing directory on your hard drive or create a new directory for your site. Click the Next button.
Figure 3.4 You enter the directory that will house your development files.
Name Your Files Properly to Avoid Problems
Spaces, punctuation, and special characters in file and directory names may cause problems. You can use underscores instead of spaces in names. All files should be named using a combination of letters, numbers, and underscores. If you are planning on adding scripting (using Dreamweaver behaviors, covered in Hour 16, "Inserting Scripted Functionality by Using Behaviors"), you shouldn't name any files, including image files, beginning with a number.
Servers May Be Case-Sensitive
Filenames are case-sensitive on some servers. Servers running the various flavors of the Unix operating system enable you to create files named mydog.gif, Mydog.gif, and MYDOG.gif all in the same directory because the capitalization differs. Microsoft servers are not case-sensitive.
The next section in the Site Definition wizard enables you to configure how you share files. You can set up a central location where members of your team can share files. Or you can set up a location on a public Web server where you share your Web site with the world. You'll learn how to configure this section and transfer files in Hour 20. For now, simply drop down the top menu and select None, as shown in Figure 3.5. Click the Next button.
Figure 3.5 To set up the connection information later, simply select None.
The last page of the wizard displays a summary of your site, as shown in Figure 3.6. You can come back to this wizard at any time to change your site definition by selecting the Edit Sites command from the Site menu (either the one in the Files panel or the one in the Document window). Click the Done button.
Figure 3.6 The Site Definition wizard displays a summary of your site definition.
After you click the Done button, Dreamweaver displays a message, telling you that it will now create the initial site cache. When you click OK, a progress bar like the one in Figure 3.7 appears (and disappears very quickly if you have nothing in your site yet). The initial site cache is created each time you create a new site. The site cache is used to store information about the links in your site so that they can be quickly updated if they change. Dreamweaver continues to update the cache as you work.
Figure 3.7 You may see a progress bar as Dreamweaver creates a cache for your site. This file speeds the updating of links when you move or rename a file.