Planetary Image Research Laboratory PIRL User Notes
Research Missions People Resources Software
Location | FTP | Connecting | User Room | User's Guide | Web Server
Printers | CD Recorder | Film Recorder | Jukebox | System Software | Web Pages

Setting up a web page on PIRL

To set up a web page you must have a collection of HTML files that are the content of your pages. To create these, I highly suggest learning HTML, it's really quite easy, and no more difficult than it would be to learn a complicated software package that would author it for you. Take a look at the pages for the HTML Class that was given at LPL a while ago for some places to start.

So if you have the HTML and other files for your web page, how do you get it up on the PIRL web pages?

Well, its real easy, you need to log in to your PIRL UNIX account. This is probably where you get your e-mail. In your home directory on PIRL (the directory that you're in when you log in) you must create a directory called public_html (you can do this with the command mkdir public_html). You have to make this directory world readable, so that everyone can see your webpage. To do this, you can use the command chmod a+rx public_html, from your home directory. Now, you're all set. Put all the HTML files into this directory (or make more directories under this), and you'll be able to see them on the web.

So what's the address of your new pages? The address of the HTML files in your public_html directory will be:

http://pirlwww.lpl.arizona.edu/~username/some_file.html

Where username is your username. For example, the web address for Joe Plassmann's web page (whose username is joep) is http://pirlwww.lpl.arizona.edu/~joep.

So you've got a bunch of files and directories in your public_html directory, and you can get at them by being specific about the filename. However, you want to designate a default HTML file such that when someone just points a web browser at your HTML directory, they will get a page (just like the link to Joe's homepage above, no filename there). This default file is known as a DirectoryIndex, and it must have a special name. The PIRL webserver knows to look for DirectoryIndexes with the following names:

index.html index.cgi index.shtml index.php

So pick the HTML file that you want to be your default file for that directory, and rename it to one of the above DirectoryIndex names (or create a symbolic link if you prefer that sort of thing). So now in any of your public_html directories if you have a file with one of the above DirectoryIndex names, when you point a web browser at just that directory (no filename), the PIRL webserver should find your DirectoryIndex file and display it.

Why does a directory without a DirectoryIndex file show as forbidden?

That's a good question. It's basically a security measure that we felt was a good default setting. If you'd like any directory in your personal web pages to display a directory listing, it's easy to do. You just need to create (or add to) a special access file. In whichever directory you'd like the listings to be displayed for, create (or add to) a special file called .htaccess. Add the following line:
Options +Indexes

This directive in your .htaccess file will cause directory listings to be displayed for the current directory and all directories which are subdirectories of the current directory.

Those are the basics, if you have questions, don't hesitate to e-mail webmaster@pirlmail.lpl.arizona.edu.

The University of Arizona Lunar & Planetary Lab
PIRL Webmaster
  03 Dec 2001