Working with Files
You can use the following procedures to work with files, regardless of their location (local drive, network drive, or remote server).
Opening and saving files refer to the current directory. For information about how HomeSite determines the current directory with two Files tabs, see "About the Files Tabs".
Setting startup options
To set startup options:
- Select Options > Settings > Startup to select which files and folders open when you load the program.
- Select any of the startup options to:
- Open all the documents that were open when the program last closed
- Open the project that was open when the program last closed
- Open a blank document
- Select one of the following startup folder options to:
- Open the folder that was last active in the Files tab
- Open the folder that was last selected in the File > Open dialog box
- Specify a default folder to open at startup
- Click OK to close the Settings dialog box and save your new settings.
Use the procedures below to open a file in the file list.
To open a standard file:
- On the Files tab, use the Drive List and the Directory List to navigate to the directory that contains the file you want to open.
- Double-click the file in the file list or right-click the file and choose Edit from the menu.
Read-only files are marked with a red dot in the file list. You can right-click a file and choose Properties from the menu to set read and write access. This is not recommended, however, if you are using a source control application to manage read and write privileges.
To open an encoded file:
If you attempt to open a Unicode file without having selected the Enable non-ANSI file encoding option, the encoding format of the file cannot be detected or handled properly. The file is loaded as an ANSI string of the same type as is specified in your system language settings.
To open a recently used file:
- Select the File > Recent Files list .
- Open any of the last ten closed files.
If you use this feature regularly, you can maintain the list by clearing it or removing obsolete files when needed.
Copying, moving, renaming, or deleting a file
You can right-click a file in the file list and select a command in the popup menu to copy, move, rename, or delete the file.
Adding a link to an open file
To create a link to a file:
- Open the page you want to place the link in the Editor.
- Drag the file you want to create a link to from the file list to the page in the Editor. Release the mouse button when the cursor is in the location where you want the link to be added.
Alternatively, you can right-click a file and select Insert As Link from the menu. The link is inserted in the current page at the cursor location.
This section describes standard file saving behavior and the file saving behavior when saving a file with encoding.
Saving standard files
Unsaved changes in a document are indicated by an "X" next to the file name in the Document tab at the bottom of the Editor window.
Use the Save commands from the File menu or the Standard toolbar icons to save and close files. Open the Settings dialog box (F8) and use the File Settings pane to specify a format for saved files. The default is PC, but UNIX and Macintosh formats are available. You can set a default file extension on this tab, as well.
When you add a link or image to a new file, you are prompted to save the file. This ensures that the relative path to each of these page elements is resolved correctly.
Saving files with encoding
If you work with non-ANSI encoded documents, you can select character encoding from the Save As dialog box.
For this release, do not save a file as Unicode or Unicode Big Endian on an SSL-enabled FTP server, or else the files will not be created and saved correctly.
Also, saving Unicode files may result in 0-byte files being written. This is a known problem that tends to occur when changing Unicode encoding selections.
To save a file with encoding enabled:
- Open the document to save with encoding and select File > Save As.
- In the Save As dialog box, select a format from the Encoding drop-down list.
- (Optional) Select Check the document character set.
This displays a warning message if the Save As encoding selection conflicts with the file's document character set statement (the <meta> charset statement in HTML), or the encoding attributes in an XML processing instruction. You can then cancel the Save As operation and reconcile the encoding formats.
- Complete the other fields as you would in a normal Save As operation and click Save. The file is saved with the encoding you specified.
Backing up files
This section describes how you can use Auto-Backup to your best advantage.
This much requested feature is similar in operation to the backup systems in many desktop applications. It is a convenient way to save files while working, but more importantly, it can be a safeguard against the loss of local and remote files caused by program or system crashes, network disruptions, or power outages.
Auto-Backup can do the following:
- Create a backup before the original file is saved.
- Create a backup of all open, modified files at a timed interval.
- Create a backup of files modified by search and replace operations.
In addition, the Search > Extended Replace dialog box lets you backup files affected by a Replace operation and select a Backup Location.
How Auto-Backup works
Following are the steps that the product takes in order to back up your files:
- A default AutoBackup folder is created below the product directory during installation. You can change the location to a different local or network directory as needed.
- A control file named AutoBackup.ini is automatically created to track files in the selected backup location. If you change the backup location, a new .ini file is created there.
- When working on a file, Auto-Backup creates a backup file with the following name convention: filename + an incremented 3 digit number + the file extension, for example, myfile000.htm.
- If the application closes abnormally, all open files saved by Timed Backup will open in the editor when the application re-starts.
- If Timed Backup is not enabled and the application closes abnormally, you can open the last backup version of a lost file from the backup location.
- A Timed Backup file is deleted when the original file is saved or when the application closes normally.
This section provides instructions for setting Auto-Backup options and using Auto-Backup to manage backups or to recover a lost file.
To set Auto-Backup options:
- Open the Options > Settings > Editor > Auto-Backup pane.
Auto-Backup is enabled by default.
- Accept the default backup directory or select a different one.
- For Auto-Backup on Save, set the following as necessary:
- Use the backup directory for local and network files, or save the backup with the original file. Note that the backup directory is always used for remote files.
- Set a time interval (in days) after which backup files are deleted.
- For Timed Auto-Backup, set a time interval (in minutes) to save all open modified files.
To manage backups created by the Auto-Backup:
- Use the Options > Auto-Backup File Maintenance dialog box to manage backups created during Save and Extended Search and Replace operations.
To recover unsaved files after the application closes abnormally:
- Open HomeSite again.
- If you have set options for Timed Auto-Backup, the Timed Auto-Backup Recover dialog box automatically appears. Recover each lost file by selecting it and clicking OK.
- Otherwise, select Options > Auto-Backup File Maintenance and, in the Auto-Backup File Maintenance dialog box, check the files that you need to recover and select File > Open Selected Files for Edit.
The files are opened in the Editor.
Changing the file list display
You can arrange the file list to display exactly what you want.
To filter the file list:
- Right-click in the file list and choose Filter from the menu.
- From the Filter submenu, choose the file type you want displayed:
- Web Documents displays Web documents only
- Web Images displays Web images only (JPEG, JPG, PNG, and GIF)
- All Web Files displays both Web documents and Web images
- All Files displays all files in the selected directory
Use the File Settings pane in the Settings dialog box (F8) to view and edit the list of file extensions that are included for Web documents and Web images.
To change the file list view:
- Right-click in the file list and choose View from the menu.
- From the View submenu, you can toggle the display of the document title, document size, modified date/time, and document type.
Press F5 to refresh the file list display.
Dragging files from Windows Explorer
You can drag a file from the Windows Explorer into the active document in the editor window create a link to it.
If you hold down the Ctrl key while dragging the file into the editor, the file will open in a new document. If the file is not a recognized file type, you are prompted to open it in the associated program for that file type.
Building a favorite folders list
You can build a list of favorite folders to make accessing their files easier.
To add a folder to the favorites list:
- Select the folder in the Directory List.
- In the file list, right-click and select Favorite Folders > Add Current Folder to Favorites.
The folder is added to your favorites list for easy selection.
To view a favorite folder:
- Right-click in the file list and select Favorite Folders from the menu.
- From the Favorite Folder submenu, select the folder you want to see.
The folder is opened in the Directory List and its files are displayed in the file list.
To organize your favorite folders:
- Right-click in the file list and select Favorite Folders > Organize Favorites from the menu to see the Favorite Folders dialog box.
- Select a folder and use the up and down arrows to move its location in the favorite folders list.
- Select a folder and click Remove to remove it from the favorite folders list. When you are prompted to confirm the deletion, click Yes to delete the folder.
- Click OK to close the Favorite Folders dialog box and apply your changes.
Downloading Web pages
You can download any HTML page and open it in the editor. These files cannot be saved back to the server.
To open a page from a Web site:
- Select File > Open From Web.
- Enter the URL for the page or select from your Bookmarks or Favorites list.
- If the site is accessed via a proxy server, click Proxy and enter the server name and port number.
- You can optionally set a time-out limit for the connection.
- Click OK to open the file as an untitled document.
To copy Web page content do one of the following:
- To select a block of text on a Web page and insert it into a document, use Windows copy and paste commands. Note that page formatting is not preserved.
- To copy the code behind a Web page, use the browser's command to view the page source code, and then copy and paste the content you want.
Please adhere to any copyright and other restrictions on Web document content.