How to setup a server mapping in HomeSite
You are trying to use the "Browse" tab in HomeSite with server side pages and you get an error "Unable to open file, do you want to download it?". The problem is, you do not have it mapped in either the web server or HomeSite.
The first thing you need is a Web Server. Using server side extensions like .cfm and .asp need to pass the pages through the web server before it views in a browser.
Setting up the mapping in the web server:
You need to set up mappings in the web server to create a URL address for the folder you are working in. By creating a URL for the folder, you will be able to view the pages under that directory structure using the browser. With server side applications that is required. All web server interfaces are different, so listed below are generic instructions to give you an idea of the process.
- Open up the web server program.
- Find and open the option to edit your Default Web Site (WWW Root folder).
- Select the folder you will be working in. For this example, we will call it "work" (c:\work).
- Select Properties (or New, Virtual Directory) for the folder (you might be able to right click on the folder).
- Add a "Virtual Directory" with an Alias. The Alias name could be "work".
- In Properties select "Execute (including script).
Now, open your browser (either IE or Netscape) and enter in http://localhost/work. It should open the folder you just set up in the web server. If you add a default or index page in the folder, then the page will open in the browser.
Take a look at the article Setting up Server Mappings in HomeSite for more information.
Note: If you are able to view the page, then you are ready to setup the mapping in HomeSite to preview your server side pages internally. If you are not able to get it to view in the browser then you didn't setup the mapping in the web server correctly.
Setting up the mapping in HomeSite:
When you have the web server setup to pass the page through the web server then you are ready to setup the mapping in HomeSite.
- Select F8.
- Select the Browse tab.
- Enable "Enable server mapping."
- Select "Add."
- In "Map From:" you need to enter in the path to the folder you are working in (in our example, "c:\work"). Selecting the folder icon will allow you to browse to the folder.
- In "Map To:" enter in the URL you created in the web server (http://locahost/work).
After you do this, you should be able to use the "Browse" tab on .cfm, .asp and other server side files.
This content requires Flash
To view this content, JavaScript must be enabled, and you need the latest version of the Adobe Flash Player.
Download the free Flash Player now!
