Publishing a web page with WinSCP

Once you have created one or more web pages in a public_html folder, you'll want to publish it, meaning that you copy the files to a computer which can act as a web server.  A web server will allow anyone on the internet to see the files you publish in your folder on the web server, but only the files in a folder you create and name public_html.  All they need to do is point their web browser to this URL (Uniform Resource Locator):  http://personal.bgsu.edu/~zirbel (replace zirbel with your username!).

We need to distinguish between your local computer, the one you are physically touching, and the web server, which is likely to be a remote computer, one you cannot touch, but can only interact with over a network.  On your local computer, you have created a folder called public_html in which you have various files, like .html and .jpg and .gif files:

To put a copy of this folder on the remote computer, you can use an FTP (File Transfer Protocol) program.  For the PC, you can obtain WinSCP here, and that is what I'll use for this illustration.  It usually easiest to download the Installer with new software.  On a Macintosh, there should be an application called Fetch that you can use, or you can download it from the internet.

After starting WinSCP, you'll see a login page something like this:

The first time I access an FTP site from a computer that I own, I use the New button to add a "session" which will make it faster to get connected the next time.  The next dialog box looks like this:

If you are using a computer that is totally secure for your own use, you might consider filling in the Password field.  But if not, leave it blank, and you'll have the opportunity to give your password each time you connect.  Please use SFTP, since this is SECURE - your password will be encrypted before it is sent over the network.  Click the save button to save this session:

Now the stored session screen looks like this:

Click the Login button to connect to personal.bgsu.edu.  Supply your password:

After clicking OK, you'll see an interface something like this, which shows files on the local computer in the left pane, and those on the remote computer in the right pane:

In my case, I've already navigated to the Math 592 folder in the left pane, which shows files on the local computer system.  When you do this the first time, the right pane will not have a public_html folder in it.  To copy the public_html folder from the local computer to the remote one, click and drag it from the left pane to the right pane.  To help you avoid doing something you shouldn't, you'll face a confirmation dialog box like this:

This would allow you to do more fancy types of copying, but probably you'll just click the Copy button.

Once it's copied, your web page should be ready for you to see.  Go to a web browser and visit "http://personal.bgsu.edu/~(your user name)

After you edit your web page and want to publish the changes

At this point, there is a public_html folder on your local machine, and a public_html folder on the remote machine.  The one on the local machine has new changes, but the one on the remote machine doesn't have the changes yet.  You can drag the local public_html folder from the left pane to the right.  Be careful not to drag the public_html folder from the left pane INTO the public_html folder on the remote machine, because that would create a folder within a folder.

Note that, even if you delete files from the public_html folder on the local machine, they will still exist on the remote machine until you delete them.  For this reason, I recommend that, before you copy the changes from the local machine to the remote machine, you RENAME the public_html folder on the remote machine; right click it, select Rename, and give it a name like public_html_2008-01-08.  Because it is no longer called public_html, it will not be viewable from the Internet, but it will continue to exist as a backup of your web page.  Once you've done the renaming, copy the public_html folder from the local machine to the remote machine.  You can continue to do this until you have used up your total disk usage quota on the remote machine, which is about 15 megabytes on personal.bgsu.edu.  By then, you'll be well beyond this simple introduction.  (If you need to delete a folder on the remote machine, right click it and select Delete.)

 
/ / Department of Mathematics and Statistics / Math 592 / Disclaimer