NetForms 2.5 User's Guide

Creating Recent Articles Lists


Allowing users to retrieve a list of articles that have been recently added to the server is a key advantage of NetForms. In fact, you may create multiple lists of recently added articles, which is one of the easier functions to implement for the server administrator.

First, using the RECENTLIST directive, like this:

    <RECENTLIST>LinkText</RECENTLIST>

will automatically add the user entry to the internal database of recently added articles. See the "NetForms Directives" section for details on the RECENTLIST directive.

To access the database of recently entered articles, you request a special URL to be returned by NetForms, which contains the all-uppercase text "RECENT". "RECENT" links can be used on any page on your server. There are three forms of the command:

  1. "/NetForms.acgi$RECENT" - Specifying this URL will display for the user a list of the documents since the last time that user accessed the list. What happens is:

  2. "/NetForms.acgi$RECENT_MIN" - This version of the RECENT command allows you to specify a time frame for what is considered a recent article. Replace "MIN" with a number of minutes. For example:

    You might need to do some multiplication to get the time frame you want (a week would be 7 x 24 x 60, or 10080 minutes) but specifying the time in minutes allows a great deal of control on your part.

  3. "/NetForms.acgi$RECENT_[A-Z]" - You may allow users to access one or more of up to 26 lists of recent articles by appending a single letter to the end the command with an underscore ("_"). The default directive is "RECENT_A", although you do not need to use "_A" to identify it as such. When the "RECENT" command is used in the URL to retrieve a recent list, specify the group letter like this: "RECENT_B". For example, to link to the default, second, and a specific time frame of a third list, the syntax would be as follows:

Here is an example that should make use of the "RECENT" command clearer. A section like this might be found on your server's home page:

    Click on one of these links to view articles entered...
    <UL>
    <LI><A HREF="/NetForms.acgi$RECENT">since I last checked</A>
    <LI><A HREF="/NetForms.acgi$RECENT_60">in the Last Hour</A>
    <LI><A HREF="/NetForms.acgi$RECENT_480">in the Last 8 Hours</A>
    <LI><A HREF="/NetForms.acgi$RECENT_1440">in the Last Day</A>
    <LI><A HREF="/NetForms.acgi$RECENT_4320">in the Last 3 Days</A>
    </UL>

If your web server supports web server "actions" and "suffix mappings", and you have set up your web server so that ".fdml" files are mapped to the NetForms CGI, then you don't need to include the path to the NetForms.acgi application in URLs for recent lists. You can simply request a fictitious FDML file named for the specific "recent list" you want to see, using all the variations described above. In this case, the previous example could instead be written as:

Click on one of these links to view articles entered...

    <UL>
    <LI><A HREF="/RECENT.FDML">since I last checked</A>
    <LI><A HREF="/RECENT_60.FDML">in the Last Hour</A>
    <LI><A HREF="/RECENT_480.FDML">in the Last 8 Hours</A>
    <LI><A HREF="/RECENT_1440.FDML">in the Last Day</A>
    <LI><A HREF="/RECENT_4320.FDML">in the Last 3 Days</A>
    </UL>

Finally, remember that each list can contain up to 256 links with a maximum of 26 lists.

Note: The URL you use to access a recent list must contain an underscore character ('_') before the list ID and the minutes value. However, the syntax of the RECENTLIST directive in your FDML files does not use an underscore - it uses a space character instead.


[ Previous | Table Of Contents | Next ]

Copyright © 1996-8 Maxum Development Corporation
820 South Bartlett Road - Suite 104
Streamwood, IL 60107
http://www.maxum.com/