AFN Alachua FreeNet

How to Create *.list files on AFN

In this file:
How to Create a Menu Space
Format of the .list file : Fields
Types of Field 5
An Example
Conclusion
or try this Menu tutorial by another AFNer
This hotspot [Top] will take you back here.

I. INTRODUCTION

In the following examples, we assume you will be working on a menu called sampmenu for the Alachua Free-Net (AFN). Note that AIX/UNIX is text case sensitive, sampmenu.list is not the same as SampMenu.list or SAMPMENU.LIST By convention, use lower case for the menu list filenames.

If you haven't read the Intro for Information Suppliers yet, do read it first.


II. To create a menu:

  1. Follow the steps in the instructions on creating a Menu Space, (a.k.a. option #2 in the Information Supplier Tools menu (menu=infosup). The steps to follow once the space is created are repeated below (but in less detail than there).

  2. LOG IN to the appropriate (information-provider) account.

  3. CHANGE DIRECTORY to the subdirectory for the menu you are going to work on. Use the homefiles menu to do this. (Note: the subdirectory was created when you created a "menu space" in step 1.)

  4. UPLOAD or input all document files called by the menu, either by using an editor on the system or by creating it offline and uploading. This has to include the menu list file; see below for format.

  5. When all your files are ready, CONTACT SOMEONE FROM TECHNICAL SUPPORT i.e. send email to newsupplier@freenet so that your menu information can be incorporated into the Free-Net environment.

Menu list files are used as source for generating menu shell programs; an example .list file follows this explanation.

Menu list files consist of normal text lines, with one line (record) for each menu line, and a colon (:) to separate each of five variable-length fields in the line.

[Top]


III. FORMAT OF THE MENU LIST FILE:

Field 1: level (2 or 3):

This field is currently used only for documentation, and will normally be a 2 or 3 depending whether the referenced menu is at the second or third level below the main menu (the "Information by Subject" menu is at the first level below the main menu).

Field 2: line number

This field is the number the user enters to select this option on the menu. All menu list files must start with menu line number 0 for the title, then should increment in the order that they are listed in the file, to a maximum of 15.

Field 3: description

This field contains the text that is displayed describing the menu line. (e.g. "Widgets International, Inc -- Products and Services")

Field 4: object

This field is the object (or objects) of the menu line, depending on the type of the menu item (see Field 5 below).
Field 4 Object Types. For
- titles, menus, and scripts: the name of a shell program.
- docs: the filename of a text document that is to be displayed.
- exe files: the name of a binary executable program.
- ftp, gopher, http, or telnet selections:
  1. the server/host domain name (including "//" for http URLs),
  2. a semi-colon (;), and
  3. the filename of the "leaving the Free-Net" warning document.
[Top]

Field 5: type

This field defines the type of menu item for this line, and must be one of ten valid menu types: title, doc, menu, exe, script, gopher, http, telnet, ftp, or future.

  1. TITLE The text displayed is the title of the menu.
    The associated object is the name of the shell program that runs this menu. This is always the name of the menu with ".sh" suffix. By convention this text should include the menu name in parentheses, e.g. "(menu = sampmenu)".

  2. DOC A text document to be read with the pager (page display program).
    The associated object is the filename of the text file.

  3. MENU A shell program that runs another menu.
    The associated object is the menu shell program name.

  4. EXE An executable program.
    The associated object is the executable program name.

  5. SCRIPT A shell script program other than a menu.
    The associated object is the shell program name.

  6. GOPHER A gopher-protocol server.
    The associated objects are the domain name of the gopher server, a semi-colon, and the filename of the "leaving the Free-Net" warning message.

  7. HTTP A WWW-protocol server.
    The associated objects are the URL of the WWW server (starting with //), a semi-colon, and the filename of the "leaving the Free-Net" warning message.

  8. FTP An FTP-protocol host.
    The associated objects are the domain name of the FTP host, a semi-colon, and the filename of the "leaving the Free-Net" warning message.

  9. TELNET A telnet-protocol host.
    The associated objects are the domain name of the telnet host, a semi-colon, and the filename of the "leaving the Free-Net" warning message.

  10. FUTURE A menu line that is not yet developed.
    The associated object may be any valid object, but some object must be provided in the object field. This item on the menu will show an asterisk (*) by the selection number.
Note: Gopher, http, telnet, and ftp menu types will require the user to have seen the internet warning.

Note 2: Other types will be added soon. Watch this file for info..

[Top]


IV. EXAMPLE

Here is an example of a menu list file: sampmenu.list

1  2                   3                               4              5
-- --  -------------------------------------------  -----------      -----
2:0: This is the sample menu title (menu=sampmenu): sampmenu.sh:    title
2:1: Here is a text file sample:                    sampmenu.doc:   doc
2:2: Something for the future:                      future.sh:      future
2:3: Gopher sample:             gopher.ufl.edu;gophufl.disclaimer:  gopher
2:4: HTTP sample: //www.sample.net/sample.html;wwwsamp.disclaimer:  http
2:5: Telnet sample: madlab.sprl.umich.edu 3000;weather.disclaimer:  telnet
                                              |
                                          note^ the semicolons;

(Note: The top row of numbers, the underscores and the spaces were added for visual clarity -- do not use them in your menu.list. It should really look like this:

2:0:This is the sample menu title (menu=sampmenu):sampmenu.sh:title
2:1:Here is a text file sample:sampmenu.doc:doc
2:2:Something for the future:future.sh:future
2:3:Gopher sample:gopher.ufl.edu;gophufl.disclaimer:gopher
2:4:HTTP sample://www.sample.net/sample.html;wwwsamp.disclaimer:http
2:5:Telnet sample:madlab.sprl.umich.edu 3000;weather.disclaimer:telnet
In the above examples,
line 0 is the title,
line 1 is a text file,
line 2 is a future planned item,
line 3 is a gopher server,
line 4 is a world-wide web (WWW) hypertext transfer protocol (HTTP) item, and
line 5 is a telnet host at port 3000 (note the absence of a colon before "3000").

[Top]


V. CONCLUSION

That's just about all you need. You should be ready to create your menu space, create your .list file, (upload it,) and have your menu up and running shortly.

You can either scroll back to the previous sections, or jump there with

the following links:
Top of this Document
How to Create a Menu
Format: the Fields
Field 5 Types
An Example
Don't forget to send an email to newsupplier@freenet when everything is ready (or if you need more help.)

Now, if you want to learn about making WWW documents, a.k.a. HTML (HyperText Markup Language) click on the next spot: Freenet WWW Tutorial


Menus

Hypertext Help Index |Main Menu |Go to Menu by Name