Specification of Updated WWW->PennInfo Gateway

WWW->PennInfo gateway

Types of documents that the gateway will send back to WWW clients:

Bug Fix Needed

If the identifier is just a '/', then assume the local techinfo server name and port -- initialize tiserver and tiport better, and send back the main menu of the local tiserver. The selector would be /penninfo-srv.upenn.edu:9000/M/0.

Searching

Figure out how to get searching to work. Keywords, Titles, Modification date, Source name.

PennInfo menus

PennInfo Text Documents

GIF images

To make something look like an image, just add .gif to the selector. For example: /penninfo-srv.upenn.edu:9000/I/2918.gif could be the selector for nodeid 2918, an image on penninfo-srv.

JPEG images

To make something look like a JPEG, just add .jpg to the selector. For example: /marathon.mit.edu/9000/51085.jpg could be the selector for nodeid 51085, a JPEG on marathon.

HTML documents

To make something look like an HTML document, just add .html to the selector. For example: /marathon.mit.edu/9000/51054.html could be the selector for nodeid 51054, an HTML document on marathon.

BinHex files

To make something look like a BinHex file, just add .hqx to the selector. For example: /marathon.mit.edu/9000/51055.hqx could be the selector for nodeid 51055, a BinHex file on marathon.

Source Information

If the URL is http://www-penninfo:1962/source:{short-source-name} then ask the TechInfo server for the long source name, email address, phone number, and people's names that go with the source name. Send the data neatly formatted. The PRE directive might do it.

The TITLE and H1 directives for this kind of document should be "Information about %s", where %s is the long source name.

If the tiserve is the local ti server, then Source Information documents should contain a link to the full list of all PennInfo sources. (Which nodeid is the sources document?)

Document Information

If the URL is http://www-penninfo:1962/penninfo-srv.upenn.edu:9000/info:{type}/{nodeid} then return meta information about the nodeid.

Ask the TechInfo server for information about the nodeid. The long-source-name should be linked to the Source Information for that source (there's no need to include the phone number, email address, etc in the Document Information screen).

How to get the size: use the t: transaction to get the first 20 bytes of the document. The t: transaction tells how many bytes there are in the file altogether. (It also tells the last mod date & time).

I'm not sure if {type} needs to be part of the URL. It depends on whether there are different ways of getting node information from the TI server for different types. I don't think so. Or whether the TechInfo server returns the document type when you ask for node information; it probably does. So {type} probably isn't necessary. Don't show the modification date or size for menu documents or telnet documents. Only show modification date & size for Text & Images.

The TITLE and H1 directives should be "Information about %s" where %s is the PennInfo name of the menu or document.

Be sure to format the information neatly. (left-justify). For example:

Example for a menu:

Example of the same menu information, using the PRE directive:

Title:    PennInfo Main Menu
Source:   PennInfo Administration
Type:     Menu
Keywords:
          penninfo
          root 
          top
Nodeid:   0
Outline:  Click here to see the outline below this menu.
Path:     Click here to see the path(s) to this menu.

Extra credit: make each keyword in the Keywords list be an anchor to a keyword search which returns a menu containing all documents which contain that keyword in their keyword lists.

All TechInfo Sites

Where do I link this to?

It's a menu where each item is a link to nodeid 0 of the different TechInfo servers.

Replace penninfo-gopher.upenn.edu with gopher://gopher.upenn.edu/ (no reason to make them use the PennInfo->Gopher gateway since WWW clients all speak gopher).

Existing Source Code

Gophtech.c