                                     ?                                         WASD Hypertext Services >                                         - Environment Overview      #                    17th August 1997                       Supercedes:  "                     1st June 1997,=                     17th May 1996 (initial freeware release), #                     19th July 1995, !                     1st May 1995, %                     1st December 1995                       Please Note  G                    As of July 1997 High Frequency Radar Division (HFRD) F                    underwent a change of role and name. It is now WideF                    Area Surveillance Division (WASD). This package has8                    been renamed in accordance with that.                      Abstract   C                    This document is a guide to supporting hypertext C                    documentation within the WASD Hypertext Services D                    environment. It is not a tutorial on writing HTML                    documents.   G                    It covers the environment supported by the version 3 G                    release of the WASD VMS Hypertext Services (December                     1995).   H                    It is strongly suggested those using printed versionsI                    of this document also access the hypertext version. It C                    provides online demonstrations of some concepts.                                      Author   !                    Mark G. Daniel 2                    Senior Information Technologist2                    Wide Area Surveillance Division>                    Defence Science and Technology Organisation  2                    Mark.Daniel@dsto.defence.gov.au  )                    +61 (8) 82596031 (bus) )                    +61 (8) 82596673 (fax)                       PO Box 1500                    Salisbury'                    South Australia 5108                       Printed Copy   F                    This book is available for printing to a PostScriptE                    printer. Use a hypertext browser to access a print .                    menu in this same location.                                                                       ii                                                                                     L                 WASD VMS Hypertext Services, Copyright (C) 1996,1997 Mark G.                Daniel.  L                This package is free software; you can redistribute it and/orJ                modify it under the terms of the GNU General Public LicenseM                as published by the Free Software Foundation; version 2 of the -                License, or any later version.   F                This package is distributed in the hope that it will beI                useful, but WITHOUT ANY WARRANTY; without even the implied F                warranty of MERCHANTABILITY or FITNESS FOR A PARTICULARL                PURPOSE. See the GNU General Public License for more details.  H                You should have received a copy of the GNU General PublicI                License along with this package; if not, write to the Free L                Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,                USA.                        P                Contents_________________________________________________________  P                Chapter_1__Introduction__________________________________________      P                Chapter_2__HyperText_Transport_Protocol_Daemon___________________  P                2.1    Auto-Scripting.........................................2-2    P                Chapter_3__Document_Access_and_Specification_____________________  P                3.1    Document Specification.................................3-2  P                       3.1.1     Absolute File Path...........................3-3  P                       3.1.2     Partial (or Relative) File Path..............3-3  P                Chapter_4__Directory_Listing_____________________________________  P                4.1    Controlling Access To A Directory......................4-2  P                4.2    "Hidden" Files.........................................4-2  P                4.3    Server Directives......................................4-3  P                       4.3.1     Listing Refresh and Expiry...................4-3  P                       4.3.2     Scripting From Directory Listings............4-3  P                       4.3.3     README Files.................................4-3  P                       4.3.4     Auto-Scripting...............................4-4  P                       4.3.5     Layout.......................................4-4  P                4.4    Directory Tree.........................................4-5  P                Chapter_5__Server_Side_Includes_(SSI)____________________________  P                5.1    Pre-Expiring Documents.................................5-1  P                5.2    Directive Syntax.......................................5-2  P                5.3    Directive Commands.....................................5-2  P                       5.3.1     ACCESSES.....................................5-2  P                       5.3.2     CONFIG.......................................5-3  P                       5.3.3     DIR..........................................5-3  P                       5.3.4     DCL..........................................5-4  P                       5.3.5     ECHO.........................................5-5  P                       5.3.6     EXEC.........................................5-7  P                       5.3.7     FCREATED.....................................5-7  P                       5.3.8     FLASTMOD.....................................5-8  1                                               iii                  M                    5.3.9     FSIZE........................................5-8   M                    5.3.10    INCLUDE......................................5-8   M             5.4    File and Virtual Specifications........................5-9   M             5.5    Time Format............................................5-9   M             Chapter_6__Clickable_Image_Support_______________________________   M             6.1    Image Configuration File...............................6-1   M             6.2    Examples...............................................6-3   M             Chapter_7__Document_Searching____________________________________   M             7.1    Plain-Text Search......................................7-1   M             7.2    HTML Search............................................7-2   M             7.3    Search Syntax..........................................7-2   M                    7.3.1     ISINDEX Search...............................7-2   M                    7.3.2     Forms-Based Search...........................7-3   M                    7.3.3     Search Options...............................7-3   M                    7.3.4     Example Search Form..........................7-4   M             Chapter_8__VMS_Help_and_Text_Libraries___________________________   M             Chapter_9__Bookreader_Books_and_Libraries________________________   M             Chapter_10__Web_Document_Update__________________________________   M             Chapter_11__dBASEIV_Query_Interface______________________________     M             Chapter_12__Document_Printing____________________________________                     .                                             iv                 M             Chapter_13__PostMail_/_SendMail_Script___________________________   M             13.1   Usage Similar to MAILTO:..............................13-2   M             13.2   Example Use...........................................13-2   M             Chapter_14__Menus________________________________________________                                                                                       .                                              v                     M             Chapter__1_______________________________________________________                Introduction    M                As of July 1997 High Frequency Radar Division (HFRD) underwent J                a change of role and name. It is now Wide Area SurveillanceK                Division (WASD). This package has been renamed in accordance                 with that.   K                This document primarily written for use internal to WASD and G                assumes that perpsective without apology. Any additional J                usage is subordinate to its role within WASD. The hypertextK                software has been written expressly for supporting an intra- F                organisational hypertext environment on a VMS platform.G                It too, is unreservedly tailored to this purpose and the $                requirements of WASD.  F                The document assumes a basic understanding of hypertextG                technologies and uses some terms without explaining them H                (e.g. HTTP, HTML, URL, CGI, etc.) It is not a tutorial onI                writing HTML documents. The reader is refered to documents G                specifically on these topics (some are available on-line J                within WASD, but are often best consulted from the Internet                WWW).  H                WASD is using hypertext technologies (a.k.a. Web and WWW)K                to assist in providing an integrated and commonly-accessable J                information environment. The VMS implementation of this hasM                gone to considerable lengths to integrate as much as possible, E                all forms of VMS information. This includes plain-text L                documents such as programming sources and environment/includeD                files, release notes, etc., as well as non-plain-text6                information like HELP, Bookreader, etc.  F                The purpose of this document is to describe some of theH                facilities within the WASD VMS hypertext environment thatH                can be used from within WASD HTML documents. The WASD VMSM                hypertext infrastructure conforms to all the basic conventions K                of Web technology, although having some facilities specific- 7                to, or tailored-for its VMS environment.   L                It is strongly suggested those using printed versions of thisM                document also access the Hypertext version. It provides online /                demonstrations of some concepts.   H                Some of the online demonstrations may not work due to theM                local organisation of the hypertext environment differing from 4                WASD where it was originally written.  N                                                              Introduction  1-1                     M             Chapter__2_______________________________________________________   /             HyperText Transport Protocol Daemon     G                The most fundamental component of the WASD VMS hypertext H                environment is the HTTPd, or HyperText Protocol TransportI                Daemon, a program serving the hypertext environment to the                 browser clients.   M                The WASD version provides a complete implementation of a basic &                HTTP server, including:  +                o  concurrent client support                   o  file access   ;                o  directory listing (generic and VMS-style)   M                o  CGI-compliant scripting (with configurable, automatic, MIME 4                   content-type initiated activation)  <                o  HTML pre-processing (server-side includes)  A                o  clickable-image support (NCSA and CERN formats)   G                o  "If-Modified-Since:"/"304 Not Modified" functionality   )                o  on-line document update   L                o  HTTP cookie-aware (document is only sent if modified since+                   time specified by client)                   Scripts  J                The WASD scripting mechanism is based on the WWW CGI CommonH                Gateway Interface (CGI, modelled on the CERN and NCSA VMS                 implementations).  D                Scripts are programs external to the main server thatH                behave as gateways to non-hypertext data formats, usuallyK                interpreting those formats into HTML before transport to and I                use by the browser. The WASD environment provides a number K                of scripts for accessing VMS-specific, DEC-specific and some /                other WASD-specific information.       N                                       HyperText Transport Protocol Daemon  2-1                              2.1 Auto-Scripting  L                A script can be automatically activated by the server throughM                it detecting the content-type of the specified document (based 2                on the file extension (e.g. .TXT)).  I                This auto-scripting can occur whenever the document speci- J                fication includes no file version number. If a file versionL                number is present the file is always returned directly to theJ                browser. The browser must then process the document in someK                fashion (often by activating a save as dialog). A simple way I                of suppressing the auto-scripting facility is to include a H                latest-version number (i.e. ;0), as in this specification0                /SYS$COMMON/SYSHLP/HELPLIB.HLB;0.  K                The current scripts supported by the WASD hypertext environ-                 ment include:  F                o  Search and Extract (retrieves sections of plain-text7                   documents in conjunction with Search)   J                o  Conan The Librarian, providing VMS help and text library                   access  K                o  HyperReader, providing access to Bookreader libraries and                    books   4                o  A dBASEIV database query interface  /                o  A crude WordPerfect interface   5                o  Print (local printing of documents)   A                o  Teledex (WASD and DSTOS telephone number lists)   A                o  MX (MadGoat application) mailing-list interface   H                A specific script can also be explicitly requested in theI                request URL. See subsequent sections describing individual                 scripts.                     4             2-2  HyperText Transport Protocol Daemon                     M             Chapter__3_______________________________________________________   -             Document Access and Specification     7                Arbitrary documents may not be accessed.   I                The server can only access files where the path is allowed I                according to a specified set of rules specified within the %                hypertext environment.   1                Documents must be read-accessable.   H                The server can only access files that are world readable,F                or that have an ACL specifically controlling access for1                "HTTP$SERVER", the server account.                   Document Types   F                Document (file) retrieval is initiated by providing theG                server with the file specification as a URL path. Server G                configuration determines the format in which the file is D                returned to the client. It may contain text or imagesD                immediately diplayable by the browser, or by a viewerE                external to the browser may be spawned. The server may F                automatically activate a script to provide a gateway toF                non-native information (see Section 2.1). The file typeJ                (extension) determines the content type by which the server4                returns (and/or interprets) the file.  G                The following table lists some of the current file types J                (as examples) and their associated MIME-style content type.J                HTML documents are presented layed-up according to the fullI                HTML-capabilities of the browser. Plain-text documents arerG                presented in a fixed-font format. Other types require an /                external viewer to be activated.                         N                                         Document Access and Specification  3-1 f  w            D                   .C          C source                    text/plainD                   .COM        DCL procedure               text/plainD                   .CONF       configuration file          text/plainD                   .CPP        C++ source                  text/plain]                   .DBF        dBaseIV database            text/html, gateway script activated ]                   .DECW$BOOK  Bookreader document         text/html, gateway script activated D                   .FOR        Fortran source              text/plainC                   .GIF        GIF image                   image/gif D                   .H          C header                    text/plain]                   .HLB        VMS Help library            text/html, gateway script activated C                   .HTML       HyperText Markup Language   text/htmlcC                   .HTM        HyperText Markup Language   text/htmllD                   .JPG        JPEG image                  image/jpegD                   .LIS        Listing                     text/plainD                   .MAR        Macro source                text/plainE                   .MENU       Menu                        text/x-menu E                   .MNU        Menu                        text/x-menuaD                   .PAS        Pascal source               text/plainD                   .PRO        IDL source                  text/plainP                   .PS         PostScript                  application/PostScriptD                   .TEXT       Text                        text/plain]                   .TLB        VMS text library            text/html, gateway script activated D                   .TXT        Text                        text/plainQ                   .SHTML      HyperText Markup Language   pre-processed text/htmlnQ                   .SHT        HyperText Markup Language   pre-processed text/html I                   .XBM        X bitmap                    image/x-xbitmap L                   .ZIP        zipped file                 application/binary  I                If other file types are required to be defined contact VMSk"                systems management.  &             3.1 Document Specification  I                For the "http:" protocol, file and directory locations areeJ                specified using URL path syntax where slash-separated ("/")L                elements delineate a hierarchy leading to a data item. AnyoneK                familiar with the syntax of the Unix file system, or the MS-tM                DOS file system (where back-slashes are hierarchy delimiters), J                will feel at home with URL syntax. Specifications under VMS&                are not case-sensitive.  ,                A VMS directory specification  -                   WEB:[TECHNICAL.HTML-PRIMER]   4                would be represented in URL syntax as  -                   /web/technical/html-primer/   +                and a VMS file specification   2             3-2  Document Access and Specification _  _            =                   WEB:[TECHNICAL.HTML-PRIMER]HTML-PRIMER.HTML_                  represented as   =                   /web/technical/html-primer/html-primer.html_  1                                              Noteg  C                      It is not required (although not forbidden) torA                      supply a VMS master file directory component E                      ("[000000]", "[000000.", etc.) in a URL specifi-39                      cation. Hence the file specification.  ,                        WEB:[000000]HOME.HTML  -                      should be represented as.  %                        /web/home.html_  $             3.1.1 Absolute File Path  L                A file may be specified using an absolute, or full path. ThisL                must specify the location of the file exactly. Absolute pathsD                always begin with a forward-slash ("/"). For example:  <                   /web/committee/minutes/1994/1994-09-27.txt1                   /web/committee/constitution.txt.;                   /web/committee/membership/fred-bloggs.txtc  1             3.1.2 Partial (or Relative) File Path   D                (Strictly speaking, it is a function of the client toK                construct a full URL from such a relative URL before sending *                the request to the server.)  M                A file may be specified relative to its current location. That.L                is, a current document (or menu) may specify another documentK                file relative to itself. This may be at the current level, agM                subdirectory, or in another part of the directory tree relatedvL                to the current. Relative paths never begin with forward-slash                ("/")..  M                For example, documents at the same level as the current may be.>                specified without any hierachy being indicated:                      1994-07-22.txt                    1994-08-24.txt                    1994-09-27.txt  E                Documents at an inferior point in the hierarchy may be.5                specified as in the following example:   %                   1993/1993-02-17.txt.-                   1993/reports/membership.txt                    other/etc.txt.  N                                         Document Access and Specification  3-3 .  .            M                Documents in a related part of the hierarchy may be referenced.M                using the "../" construct. As with MS-DOS and Unix this syntax <                indicates the immediately superior directory.  8                   ../other_committee/1993/1993-02-17.txtC                   ../other_committee/1993/reports/balance-sheet.txt.@                   ../../other_section/committee/constitution.txt                                                                                      2             3-4  Document Access and Specification _  _                M             Chapter__4_______________________________________________________-               Directory Listing.    H                A directory listing is sometimes refered to as a document@                Index, and is generally titled "Index of . . . ".  I                Unless disabled by the server's configuration, a directory F                listing is recognised by the server whenever a wildcardI                is present in a specification and there is no query string.M                directing another activity (e.g. a document search). Compliant.K                with other hypertext implementations, a directory listing is.J                also generated if a URL specifies a directory only and that/                directory contains no home page.   I                All specifications must be made using URL-style paths. See_                Section 3.1._  K                The directory listing is designed to look very much like therM                basic layout of other servers, except that all directories are_K                grouped at the top. In the opinion of the author, this looksfM                and functions better than when interspersed with the files, asnA                is otherwise common. The default listing provides:   4                o  iconic indication of the data type                  o  file namet  (                o  last revison date/time                  o  size                  o  description.  H                The description can be either be just that, a descriptionJ                of the role of that type of file under VMS, or if presentedI                within quotes, an HTML document's own internal description 6                taken from the <TITLE></TITLE> element.  G                Note that directory listings only processes the physical K                file system. This may or may not correspond to the hypertext .                environment's virtual mappings.  K                The following link illustrates the directory listing format:g  '                   <A HREF="*.*">*.*</A>v  /                <online hypertext demonstration>a  N                                                         Directory Listing  4-1    u                            VMS-ish FormatW  M                The default listing has a "generic" WWW look about it, however F                it can be made to look a little more like the format ofJ                the VMS DIRECTORY command. In this mode the directories areL                presented as VMS subdirectories, the version number is shown,K                if a version wildcard was included in the specification then H                all matching versions are shown, the size is presented inI                used and allocated blocks, and automatic script activationmK                is disabled. The VMS-style format is enabled by providing aneM                explicit or wildcard version number with the specification, as I                in the following example: <online hypertext demonstration>   1             4.1 Controlling Access To A Directoryu  J                The following files (empty, or not), when within a specificK                directory regulate access to that directory, and the listing 9                of any parent directory or subdirectories.a                  o  .WWW_HIDDENeM                   Renders the directory completely invisible to the directoryaL                   listing mechanism. Files within the directory may still beL                   accessed if specified explicitly but the directory content7                   itself cannot be listed by any means.f                  o  .WWW_NOP5                   Any parent directory is not listed.                   o  .WWW_NOS4                   Any subdirectories are not listed.                  o  .WWW_NOPScH                   Any parent directory or subdirectories are not listed.               4.2 "Hidden" Files  G                Any file name beginning with a period is hidden from thelL                directory listing mechanism (i.e. in VMS parlance it has onlyK                a type/suffix/extension). If specifically accessed they willeH                be retrieved however. Hence the following files would not-                appear in a directory listing:                   o  .WWW_NOPSd                  o  .CANT_BE_SEENa  #                o  .HIDDEN_FROM_VIEW                   o  .;1o  "             4-2  Directory Listing                 !             4.3 Server Directivesn  E                The WASD server behaviour can be modified using server.M                directives. For directory listings this involves the inclusion1H                of a query string beginning with ?HTTPD=INDEX. The serverE                detects this query string and processes it internally,tA                changing the default action of directory listings.t  M                Multiple directives can be combined by concatenating them witht@                intervening ampersands, as per normal URL syntax.  ,                   ?httpd=index&autoscript=no(                   ?httpd=index&readme=no,                   ?httpd=index&layout=format1                   ?httpd=index&script=script-name ;                   ?httpd=index&script=script-name&readme=no   ,             4.3.1 Listing Refresh and Expiry  L                Directory listings and trees may be pre-expired. That is, theI                listing is reloaded each time the page is referenced. ThistJ                is convenient in some environments where directory contentsK                change frequently, but adds considerable over-head and so is K                often disabled by default. Individual directory listings may M                have either default behaviour over-ridden using syntax similarn)                to the following examples:   8                   /dir1/dir2/*.*?httpd=index?expired=yes7                   /dir1/dir2/*.*?httpd=index?expired=noo:                   /tree/dir1/dir2/?httpd=index?expired=yes9                   /tree/dir1/dir2/?httpd=index?expired=not  3             4.3.2 Scripting From Directory Listingsl  I                When a directory listing is requested a script name can bedK                specified to be used as a prefix to all of the file links inoJ                the listing. When the client selects a file link the script1                specified is implicitly activated.   1                   ?httpd=index&script=script_name   F                   <A HREF="*.*?httpd=index&script=print">print *.*</A>  /                <online hypertext demonstration>2               4.3.3 README Files  L                When a directory listing is generated any README., README.TXTC                or README.HTML file (or others as configured for the I                particualr server) in the directory will have its contents.M                displayed immediately below the title of the page. This allowseL                additional information on the directory's contents, function,M                etc., to be presented. This can be suppressed by appending thee  N                                                         Directory Listing  4-3                 K                following query-string to the directory specification, as ine(                the accompanying example:  (                   ?httpd=index&readme=no  Q                   <A HREF="*.*?httpd=index&readme=no">*.* (no <I>readme</I>s)</A>;                4.3.4 Auto-Scripting  I                The server's auto-scripting facility (see Section 2.1) can K                be suppressed by appending the following query-string to the G                directory specification, as in the accompanying example:   ,                   ?httpd=index&autoscript=no  H                   <A HREF="*.*?httpd=index&autoscript=no">get me *.*</A>  H                This implies that any file accessed from the listing willH                be transfered without any data conversion possible due toM                script activation (see Scripts). The browser must then process J                the document in some fashion (often by activating a save as                dialog).a               4.3.5 Layout  L                Allows specification of the directory listing layout from theJ                URL, overriding the server default. The layout directive isJ                a short string that specifies the included fields, relativeD                placement and optionally the width of the fields in aM                directory listing. Each field is controlled by a single letter M                and optional leading decimal number specifying its width. WhennJ                a width is not specified an appropriate default applies. AnK                underscore is used to indicate a single space and is used toi@                separate the fields (two consecutive works well).  #                o  C - creation dateb  J                o  D - description (having no field-width attribute this is-                   always best specified last)a  ;                o  I - icon (takes no field-width attribute)e  J                o  L - link (highlighted anchor using the name of the file)  <                o  N - name (no link, why bother? who knows!)  @                o  O - owner (this may be disabled by the server)  #                o  R - revision datei                  o  S - size  L                o  U - file and directory names upper-case (must be the first*                   character in the string)  8                As illustrated in the following examples:  "             4-4  Directory Listing t  l            4                   ?httpd=index&layout=UI__L__R__S__D3                   ?httpd=index&layout=I__L__R__S__D 2                   ?httpd=index&layout=I__15L__S__D0                   ?httpd=index&layout=15L__9R__S1                   ?httpd=index&layout=15N_9C_9R_So  /                <online hypertext demonstration>                4.4 Directory Tree  E                The TREE internal script allows a directory tree to be G                generated. This script is supplied with a directory namesJ                from which it displays all subdirectories in a hierarchicalG                layout, showing subordinancies. Selecting any one of thetJ                subdirectories displayed generates a directory listing (see                Chapter 4).  I                Appending a file specification (with or without wildcards) I                to the directory name results in the any directory listing K                displaying only files matching the specification. To display 9                all files a *.* should always be appended.   M                Note that this script only processes the physical file system. L                This may or may not correspond to the hypertext environment's                 virtual mappings.  J                To enable the VMS-style directory listing format, or to useG                any of the directory server directives, append one, or a K                combination of, the following query strings to the directorya                specification:   ,                   ?httpd=index&autoscript=no(                   ?httpd=index&readme=no1                   ?httpd=index&script=script-name ;                   ?httpd=index&script=script-name&readme=nom  /                <online hypertext demonstration>   G                Note that this activity is I/O intensive, and can take a <                considerable period if the tree is extensive.  1                                              Note   G                      The "tree" internal script supercededs the "Dtree"u<                      external script which has been retired.          N                                                         Directory Listing  4-5                     M             Chapter__5_______________________________________________________i  &             Server Side Includes (SSI)    L                The HTML pre-processor is used to provide dynamic informationD                inside of an otherwise static, HTML (HyperText MarkupM                Language) document. The HTTPd server provides this as internaleE                functionality, scanning the input document for specialTF                pre-processor directives, which are replaced by dynamic?                information based upon the particular directive.   I                The HTML pre-processor is invoked when the document file's L                extension is .SHTML (the "S" may have originated from the SSIJ                nomenclature). As there is a significant overhead with pre-M                processed HTML compared to normal HTML, it should only be used L                when it serves a useful documentary purpose, and not just for                the novelty.t  J                One effective use for pre-processed HTML is the creation ofL                single virtual documents from two or more physical documents.E                That is, the pre-processed document is used to includelJ                multiple physical documents, that may even be independentlyJ                administered, to return a composite document to the client.I                This is a relatively low-overhead activity, but because it J                is a dynamic document loses the advantages of "If-Modified-2                Since:" processing (see Chapter 2).  &             5.1 Pre-Expiring Documents  L                HTML-preprocessed documents are dynamic in the sense that theM                information presented can be different every time the documentrI                is generated (e.g. if time directives are included). If itgI                is important that each time the document is accessed it is L                regenerated then an HTML META tag can be included in the HTMLJ                header to cause the document to expire. This will result in<                the document being reloaded with each access.  M                Ensure the document is structured similar to the following and L                include the <META HTTP-EQUIV= ...> tag with a legitimate date                 well in the past:              N                                                Server Side Includes (SSI)  5-1 i  e            C                   <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">o                   <HTML>                   <HEAD>V                   <META HTTP-EQUIV="expires" CONTENT="Thu, 01-Jan-1970, 00:00:01 GMT">'                   <TITLE> etc. </TITLE>g                   </HEAD>                    <BODY>                      etc.t                   </BODY>n                   </HEAD>                   5.2 Directive Syntax  J                The syntax follows closely that used by the other implemen-I                tations, but some directives are tailored to the VMS envi-.L                ronment. The directive is enclosed within an HTML comment and                takes the form:  5                   <!--#command [[tag="value"] ...]-->   K                A directive cannot be split over multiple lines. It must all H                be contained within the one line. This restriction may be(                lifted in later versions.  I                The command and tag keywords are case insensitive. The tag I                value may or may not be case sensitive, depending upon the0K                command/tag. Generally the effect of a command is to produce >                additional text to be inserted in the document.  "             5.3 Directive Commands               5.3.1 ACCESSES  M                The accesses directive allows the number of times the document.I                has been accessed to be included. It does this by creating E                a counter file in the same location and using the same J                name with a dollar symbol appended to the type (extension).F                The count may be reset by deleting the file. This is anH                expensive function (in terms of file system activity) andL                so should be used appropriately. It can be disabled by serverH                configuration. Two tags provide additional functionality:                  o  SINCEu  3                      <!--#accesses since="text" -->   L                   This tag includes the specified text immediately after theK                   access count is displayed, then adds the creation date of_#                   the counter file.   +             5-2  Server Side Includes (SSI)     d                            o  TIMEFMTo  K                      <!--#accesses since="text" timefmt="[time-format]" -->.  I                   Allows the time format of the since tag to be supplied, J                   where time-format is specified according to Section 5.5.               5.3.2 CONFIG  H                The config directive allows time and file size formats toI                be specified for all subsequent directives providing these H                values. Optional specifications for individual directivesE                may still be made, and override, do not supercede, anyrD                specification made using a config directive. A configF                directive may be made once, or any number of times in aH                document, and applies until another is made, or until the#                end of the document.h                  o  ERRMSG  G                   This directive, provided in other implementations, isaJ                   ignored for the WASD HTTPd. It controls whether an errorH                   message is generated upon encountering a pre-processorG                   error. For the WASD implementation an error is always E                   reported and aborts the processing of the document.i                  o  TIMEFMT   :                      <!--#config timefmt="time-format" -->  J                   Where time-format is specified according to Section 5.5.                  o  SIZEFMTo  :                      <!--#config sizefmt="size-format" -->  D                   Where size-format is specified using the following                   keywords:   6                   o  ABBREV (as bytes, kbytes, Mbytes)  .                   o  BLOCKS (VMS blocks, used)  3                   o  BYTES (e.g. "1,256,731 bytes")t               5.3.3 DIR   F                The dir directive generates an Index of . . . directoryI                listing inside an HTML document. Apart from not generatingrH                a title (it is up to the pre-processed document to title,E                or otherwise caption, the listing) it provides all thehE                functionality of the WASD HTTPd directory listing (see I                Chapter 4). It is an WASD HTTPd extension to pre-processede                HTML.                  o  FILE  N                                                Server Side Includes (SSI)  5-3 o  s            :                   Listing specified using a VMS file path.  N                      <!--#dir file="file-name" [par="server-directive(s)"] -->                  o  VIRTUAL   ;                   Listing specified using URL-style syntax.a  L                      <!--#dir virtual="path" [par="server-directive(s)"] -->               5.3.4 DCLe  H                The dcl directive executes a DCL command and incorporatesJ                the output into the processed document. It is an WASD HTTPdI                extension to the more common exec directive, which is alsol                included.  M                By default, output from the DCL command has all HTML-forbidden I                characters (e.g. "<", "&") escaped before inclusion in the G                processed document. Thus command output cannot interfereoH                with document markup, but nor can the DCL command provideJ                HTML markup. This behaviour may be changed by appending the.                following tag to the directive:  "                   type="text/html"  E                Some dcl directives are for privileged documents only,tL                documents defined as those being owned by the SYSTEM account,H                and not being world-writeable. The reason for this shouldI                be obvious. There are implicit security concerns about any L                document being able to execute any DCL command(s), even if itL                is being executed in a completely unprivileged process. HenceI                only innocuous commands are allowed in standard documents.l                  o  SAY   E                   Execute the DCL WRITE SYS$OUTPUT command, using the &                   specified parameter.  .                      <!--#dcl say="hello." -->                  o  SHOW  K                   Execute the DCL SHOW command, using the specified parame--                   ter.  ;                      <!--#dcl show="device/full tape1:" -->                   o  DIRh  L                   Execute the DCL DIRECTORY command, using the supplied fileK                   specification. Qualifiers may be included in the optionali?                   PAR tag to control the format of the listing.r  4                      <!--#dcl dir="web:[000000]" -->J                      <!--#dcl dir="web:[000000]" par="/nohead/notrail" -->E                      <!--#dcl dir="web:[000000]" par="/size/date" -->   +             5-4  Server Side Includes (SSI)a                 #                o  EXEC (privileged)   4                   Execute the specified DCL command.  @                      <!--#dcl exec="show device/full tape1:" -->  #                o  FILE (privileged)x  F                   Execute the DCL command procedure specified as a VMSI                   file path, with any specified parameters applied to thet                   procedure.  T                      <!--#dcl file="HT_ROOT:[SHTML]TEST.COM" par="PARAM1 PARAM2" -->  &                o  VIRTUAL (privileged)  J                   Execute the DCL command procedure specified in URL-styleF                   syntax, with any specified parameters applied to the                   procedure.  Q                      <!--#dcl virtual="../shtml/test.com" par="PARAM1 PARAM2" -->w               5.3.5 ECHO  M                The echo directive incorporates the specified information into*&                the processed document.                  o  CREATEDd  C                   The date/time of the current document's creation.n  :                      <!--#echo created[="time-format"] -->                  o  DATE_LOCAL  0                   Include the current date/time.  =                      <!--#echo date_local[="time-format"] -->i                  o  DATE_GMT  J                   Include the current Greenwich Mean Time (UTC) date/time.  ;                      <!--#echo date_gmt[="time-format"] -->=                  o  DOCUMENT_NAMEA  8                   The current document's URL-style path.  0                      <!--#echo document_name -->                  o  FILE_NAME   7                   The current document's VMS file path..  ,                      <!--#echo file_name -->                  o  LAST_MODIFIED   L                   The date/time of the current document's last modification.  @                      <!--#echo last_modified[="time-format"] -->  N                                                Server Side Includes (SSI)  5-5                                 o  HTTP_ACCEPTb  I                   Comma separated list of browser accepted content-types.   .                      <!--#echo http_accept -->  &                o  HTTP_ACCEPT_LANGUAGE  E                   Comma separated list of browser accepted languages.   7                      <!--#echo http_accept_language -->                   o  HTTP_REFERER  I                   URL of document containing link to current document (ifi                   any).s  /                      <!--#echo http_referer -->a  !                o  HTTP_USER_AGENTp  3                   Identification string of browser.   2                      <!--#echo http_user_agent -->                  o  PATH_INFOt  /                   URL path of current document.=  ,                      <!--#echo path_info -->  !                o  PATH_TRANSLATEDy  4                   VMS file name of current document.  2                      <!--#echo path_translated -->                  o  QUERY_STRING  @                   Query string of URL (unusual if there is one!)  /                      <!--#echo query_string -->                   o  REMOTE_ADDR   /                   IP address of browser system.c  .                      <!--#echo remote_addr -->                  o  REMOTE_HOSTt  J                   IP host-name of browser system (if DNS lookup is config-                   ured).  .                      <!--#echo remote_host -->                  o  REMOTE_USERa  2                   Authenticated username (if any).  .                      <!--#echo remote_user -->                  o  SERVER_NAMEi  +             5-6  Server Side Includes (SSI)i o  p            0                   IP host name of server system.  .                      <!--#echo server_name -->                  o  SERVER_PORT   K                   IP port number server host accepted client connection on.b  .                      <!--#echo server_port -->  !                o  SERVER_PROTOCOL                      "HTTP/1.0"  2                      <!--#echo server_protocol -->  !                o  SERVER_SOFTWARE   ;                   Identification string of server software.   2                      <!--#echo server_software -->               5.3.6 EXEC  M                The exec directive executes a DCL command and incorporates thetK                output into the processed document. It is the VMS equivalentnK                of the exec shell directive of some Unix implementations. It)K                is implemented in the same way as the #DCL directive, and so-M                the general detail of that directive applies. It supports only=K                the cmd tag, the cgi tag, allowing execution of CGI scripts,                  is not supported.  =                   <!--#exec cmd="show device/full tape1:" -->   M                The exec directive is for privileged documents only, documentsdJ                defined as those being owned by the SYSTEM account, and notL                being world-writeable. The reason for this should be obvious.F                There are implicit security concerns about any documentL                being able to execute any DCL command(s), even if it is being=                executed in a completely unprivileged process.i               5.3.7 FCREATED  L                The fcreated directive incorporates the creation date/time ofE                a specified file/document into the processed document.h                  o  FILE  ;                   Document specified using a VMS file path.l  K                      <!--#fcreated file="file-name" [fmt="time-format"] -->l                  o  VIRTUAL   <                   Document specified using URL-style syntax.  I                      <!--#fcreated virtual="path" [fmt="time-format"] -->v  N                                                Server Side Includes (SSI)  5-7 e  r                         5.3.8 FLASTMOD  H                The flastmod directive incorporates the last modificationH                date/time of a specified file/document into the processed                document.                  o  FILE  ;                   Document specified using a VMS file path.o  K                      <!--#flastmod file="file-name" [fmt="time-format"] -->i                  o  VIRTUALe  <                   Document specified using URL-style syntax.  I                      <!--#flastmod virtual="path" [fmt="time-format"] -->                5.3.9 FSIZEi  J                The fsize directive incorporates the size, in bytes, kbytesI                or Mbytes, of a specified file/document into the processedu                document.                  o  FILE  ;                   Document specified using a VMS file path.   H                      <!--#fsize file="file-name" [fmt="size-format"] -->                  o  VIRTUAL_  <                   Document specified using URL-style syntax.  F                      <!--#fsize virtual="path" [fmt="size-format"] -->               5.3.10 INCLUDE  M                The include directive incorporates the contents of a specifiedu9                file/document into the processed document.                   o  FILE  6                      <!--#include file="file-name" -->                  o  VIRTUALw  K                   Include the contents of the document specified using URL-l                   style syntax.T  4                      <!--#include virtual="path" -->  J                The contents of the specified file are included differentlyG                depending on the MIME content-type of the file. Files of M                text/html content-type (HTML documents) are included directly,uH                and any HTML tags within them contribute to the markup ofI                the document. Files of text/plain content-type (plain-textfK                documents) are encapsulated in <PRE></PRE> tags and have alleG                HTML-forbidden characters (e.g. "<", "&") escaped before-  +             5-8  Server Side Includes (SSI)     m            G                inclusion in the processed document. An HTML file can beeI                forced to be included as plain-text by using the followingr                syntax:  K                   <!--#include virtual="example.html" type="text/plain" -->a  /             5.4 File and Virtual Specificationss  J                Documents may be specified using either the FILE or VIRTUAL                tags.  G                The FILE tag expects an absolute VMS file specification.e  G                The VIRTUAL tag expects an URL-style path to a document. H                This can be an absolute or relative path. See Section 3.1#                for further details.s               5.5 Time Formatn  J                Note:  Time formatting only applies if the HTTPd server has)                been compiled using DEC C.l  G                Whenever a time directive is used an optional tag can be H                included to specify the format of the output. The defaultH                looks a little VMS-ish. If a format specification is madeE                it must confirm to the C programming language function                 strftime().  E                The format specifier follows a similar syntax to the C D                standard library printf()  family of functions, whereJ                conversion specifiers are introduced by percentage symbols.*                Here are some example uses:  A                   The date is <!--#date_local fmt="%d/%m/%y" -->.D;                   The time is <!--#date_local fmt="%r" -->. F                   The day-of-the-week is <!--#date_local fmt="%A" -->.  M                A problem with any supplied time formatting specification willh                be reported.t  I                The following table provides the general conversion speci-nL                fiers. For futher information on the formatting process referK                to a C programming library document on the strftime()  func-                 tion.  ,                   Specifier      Replaced by^                   ---------      -------------------------------------------------------------  F                   a              The locale's abbreviated weekday name  ?                   A              The locale's full weekday namec  D                   b              The locale's abbreviated month name  =                   B              The locale's full month namea  N                                                Server Side Includes (SSI)  5-9                 V                   c              The locale's appropriate date and time representation  Z                   C              The century number (the year divided by 100 and truncatedM                                  to an integer) as a decimal number (00 - 99)a  S                   d              The day of the month as a decimal number (01 - 31)   1                   D              Same as %m/%d/%yn  W                   e              The day of the month as a decimal number (1 - 31) in aoT                                  2 digit field with the leading space character fill  V                   Ec             The locale's alternative date and time representation  S                   EC             The name of the base year (period) in the locale'se;                                  alternative representatione  M                   Ex             The locale's alternative date representation   M                   EX             The locale's alternative time representation   T                   Ey             The offset from the base year (%EC) in the locale's;                                  alternative representationp  R                   EY             The locale's full alternative year representation  +                   h              Same as %bc  W                   H              The hour (24-hour clock) as a decimal number (00 - 23)u  W                   I              The hour (12-hour clock) as a decimal number (01 - 12)d  T                   j              The day of the year as a decimal number (001 - 366)  H                   m              The month as a decimal number (01 - 12)  I                   M              The minute as a decimal number (00 - 59)   6                   n              The newline character  T                   Od             The day of the month using the locale's alternative1                                   numeric symbolsi  U                   Oe             The date of the month using the locale's alternative 0                                  numeric symbols  X                   OH             The hour (24-hour clock) using the locale's alternative0                                  numeric symbols  X                   OI             The hour (12-hour clock) using the locale's alternative0                                  numeric symbols  Y                   Om             The month using the locale's alternative numeric symbols   [                   OM             The minutes using the locale's alternative numeric symbolsi  [                   OS             The seconds using the locale's alternative numeric symbols,  T                   Ou             The weekday as a number in the locale's alternative:                                  representation (Monday=1)  ,             5-10  Server Side Includes (SSI) n               \                   OU             The week number of the year (Sunday as the first day of theU                                  week) using the locale's alternative numeric symbolsw  \                   OV             The week number of the year (Monday as the first day of theV                                  week) as a decimal number (01 -53) using the locale's_                                  alterntative numeric symbols. If the week containing January 1 X                                  has four or more days in the new year, it is consideredZ                                  as week 1.  Otherwise, it is considered as week 53 of theL                                  previous year, and the next week is week 1.  V                   Ow             The weekday as a number (Sunday=0) using the locale's<                                  alternative numeric symbols  X                   OW             The week number of the year (Monday as the first day ofY                                  the week) using the locale's alternative numeric symbolsc  \                   Oy             The year without the century using the locale's alternative0                                  numeric symbols  ]                   p              The locale's equivalent of the AM/PM designations associateds5                                  with a 12-hour clock   ;                   r              The time in AM/PM notationo  E                   R              The time in 24-hour notation (%H:%M)i  I                   S              The second as a decimal number (00 - 61)y  2                   t              The tab character  4                   T              The time (%H:%M:%S)  [                   u              The weekday as a decimal number between 1 and 7 (Monday=1)i  [                   U              The week number of the year (the first Sunday as the firsteM                                  day of week 1) as a decimal number (00 - 53))  \                   V              The week number of the year (Monday as the first day of the\                                  week) as a decimal number (00 - 53). If the week containingW                                  January 1 has four or more days in the new year, it is ]                                  considered as week 1. Otherwise, it is considered as week 53oS                                  of the previous year, and the next week is week 1.-  Q                   w              The weekday as a decimal number (0 [Sunday] - 6)-  [                   W              The week number of the year (the first Monday as the firstsM                                  day of week 1) as a decimal number (00 - 53)e  M                   x              The locale's appropriate date representation   M                   X              The locale's appropriate time representation   W                   y              The year without century as a decimal number (00 - 99)0  J                   Y              The year with century as a decimal number  Z                   Z              Timezone name or abbreviation. If timezone information isG                                  not available, no character is output.p  N                                               Server Side Includes (SSI)  5-11    m            "                   %              %                                                                                                  ,             5-12  Server Side Includes (SSI) S  O                M             Chapter__6_______________________________________________________t  #             Clickable Image Supportn    I                Clickable image support is provided as an integral part oftF                HTTPd functionality (i.e. it is does not require scriptI                execution), and so can be quite efficient. It will process L                both NCSA and CERN configuration formats (in the same file ifG                necessary, although for clarity that should be avoided).     ,                Digression . . . How It Works  I                When the image specified in the anchor is clicked upon the-H                browser sends a mapping configuration file URL, specifiedI                in the HTML anchor, along with the pixel coordinate of the-H                click, as a query string, to the HTTPd server. The serverL                interprets region specifications in the configuration file toK                determine which region corresponds to the coordinates in the I                query string. A matching specification's URL, or a defaultdK                if none match, is then accessed by the server (if local), orrM                sent back to, and then transparently reaccessed by the browser =                (redirected, if a different protocol or host).e  0                Steps For Using a Clickable Image  G                1. create an image configuration file (see Section 6.1), J                   mapping pixel coordinates of regions within the image to                   URLs  J                2. specify an HTML anchor using an inline <IMG...> tag, theJ                   HREF= specifies the path to the image configuration file  3                3. specify ISMAP in the <IMG...> tag                      For example:  0                      <A HREF="ismap_demo.ismap">9                      <IMG SRC="ismap_demo.gif" ISMAP></A>R  (             6.1 Image Configuration File  M                Image configuration is done using a plain-text file containing E                region keywords specifying image pixel coordinates andNL                associated URLs. Clicking within these coordinates results inK                the corresponding URL being returned. Four keywords defining M                geometrically shaped series of coordinates are provided, along_  N                                                   Clickable Image Support  6-1 c  e            M                with a default keyword. These can be supplied in either of twoRB                formats. The NCSA format may be more commonly used.                  1. NCSA  +                   o  circle URL x1,y1 x2,y2 L                      URL to be returned when the click is within a circle ofL                      centre-point x1,y1 and a circumference specified by the&                      edge-point x2,y2.  .                   o  rectangle URL x1,y1 x2,y2L                      URL to be returned when the click is within a rectangle=                      having opposite corners x1,y1 and x2,y2.e  "                   o  point URL x,yI                      With multiple points specified, the URL of the point *                      closest to the click.  >                   o  polygon URL x1,y1 x2,y2 x3,y3 [... xn,yn]M                      URL to be returned when the click is within an arbitrary N                      polygon having adjacent verticies specified by the seriesN                      of coordinates (x1,y1) through to (xn,yn). If the polygonN                      is not explcitly closed it is treated as if the first and5                      last coordinates were connected.                       o  default URLK                      URL to be returned when the click is not within any of K                      the specified coordinates, and there has been no pointd                      specified.                   2. CERN  '                   o  circle (x,y) r URL L                      URL to be returned when the click is within a circle of4                      radius r at centre-point (x,y).  1                   o  rectangle (x1,y1)(x2,y2) URLiL                      URL to be returned when the click is within a rectangleA                      having opposite corners (x1,y1) and (x2,y2).o  &                   o  point (x1,y1) URLI                      With multiple points specified, the URL of the pointsJ                      closest to the click (strictly speaking, this is NCSA                      only).o  9                   o  polygon (x1,y1)(x2,y2)...(xn,yn) URLnM                      URL to be returned when the click is within an arbitrarynN                      polygon having adjacent verticies specified by the seriesN                      of coordinates (x1,y1) through to (xn,yn). If the polygonN                      is not explcitly closed it is treated as if the first and5                      last coordinates were connected.i  (             6-2  Clickable Image Support h                                   o  default URLK                      URL to be returned when the click is not within any ofdK                      the specified coordinates, and there has been no point                       specified.d  K                For online examples of rule usage within configuration filesf0                see Section 6.2 below. Note that:  E                o  There must be only one region keyword on each line.   J                o  The region keywords are scanned from first towards last,G                   the first one with coordinates encompassing the clickdJ                   having its URL returned. Region coordinates within other2                   regions should be defined first.  I                o  Either full URLs (protocol://host/path) or partial URLsiF                   (/path) may be specified against the keywords. As anJ                   extension to NCSA and CERN capability, this image mapperG                   will also accept relative URLs (path, ../path, etc.).   M                o  The image mapping utility may return textual error messages L                   if the configuration keywords or parameters are incorrect.  K                o  The keywords may be abbreviated to circ, rect, poly, poind                   and def.  *                o  Blank lines are ignored.  H                o  Commentary must be preceded by a "#" or "!" character.  4                                           hint . . .  E                      To establish the region keywords and coordinates B                      required for the configuration file it may beE                      necessary to use a program such as XV to display B                      the image, then by using the mouse locate theH                      required parts of the image, reading off and notingE                      the coordinate pairs, and finally using these tol4                      compose the configuration file.               6.2 Examples  H                Here are two examples, essentially just removed fom theirM                original CERN environment and placed within WASD's, with linkssH                allowing the respective configuration files to be viewed.  /                <online hypertext demonstration>   &                <online hypertext link>  /                <online hypertext demonstration>p  &                <online hypertext link>  N                                                   Clickable Image Support  6-3 r  e                M             Chapter__7_______________________________________________________                Document Searching    K                The query and extract scripts provide real-time searching ofdI                plain-text and HTML documents, and document retrieval. The I                search is a simple-string search, not a GREP-style search. H                It is designed to provide a useful mechanism for locatingL                documents containing a keyword, not for document analysis. ItJ                has the useful feature for plain-text documents of allowingI                the selective extraction of only the portion near the hit.   1                                              Notee  E                      Searching is a notoriously CPU and I/O intensiveeE                      activity. Longer searches progressively decreaseTF                      scheduling priority by one every 10 seconds, fromD                      normal to zero, helping to reduce impact on anyG                      interactive users of the server system. The search F                      algorithm itself is efficient, but searching willH                      take longer on a more heavily loaded system because'                      of this mechanism.e  G                Only files with a plain-text or HTML MIME data type (seerJ                Chapter 3) will be searched. Others may be specified, or beK                selected from wildcard file specification, but they will note5                actually have their contents searched._  !             7.1 Plain-Text Search   K                A search of a plain-text file is straight-forward. Each linefI                in the file is searched for the required string. The first J                time it is encountered is considered a hit. The line is not3                searched for any further occurances.   J                Searches of plain text files allow the subsequent selectionH                of partial documents (i.e. the retrieval of only a numberG                of lines around any actual hit). This allows the user to H                selectively extract a portion of a document, avoiding theI                need to explcitly scan through to the section of interest.               N                                                        Document Searching  7-1 u  w                         7.2 HTML Search   J                A search of an HTML file is a little more complex. As mightG                be expected, only text presented in the document text is F                searched, markup text is ignored. That is, all text notK                part of an HTML tag construct is extracted and searched. For :                example, out of the following HTML fragment  3                   <!-- an example HTML document -->                    <P> U                   The document entitled <A HREF="example.html">"Example Document"</A> T                   provides only an <I>overview</I> of the full capabilities of HTML.  A                only the following text would actually be searchedn  T                   The document entitled "Example Document" provides only an overview3                   of the full capabilities of HTML.   E                The mechanism for partial document retrieval available H                with plain-text files is not present with HTML documents.H                HTML files generally must be treated as a whole, with theI                formatting of current sections often very dependent on the G                formatting of previous sections. This makes extracting a L                subsection perilous without extensive syntactical analyis. OnK                the positive side, HTML documents tend to be already divided J                into meaningful subdocuments (files), making retrieval of a9                hit naturally more-or-less within context.                7.3 Search Syntax   <                A search may be initiated in one of two ways:  M                1. Appending a question-mark and search string to a file spec- K                   ification (the simple syntax of ISINDEX-style searching).6K                   This is standard HTTP, and of course must conform to HTTP)                   syntax.   K                2. Forms-based search, which allows the format and mechanism 1                   of the search to be controlled.d                7.3.1 ISINDEX Search  I                Placing the HTML tag <ISINDEX> within a document's text islK                sufficient to inform the browser that searching is available'J                for that document. The browser will inform the user of thisI                and allow a search of that document to be initiated at anyaA                time. Note that it is limited to the one document.   K                Using the keyword search syntax explicitly is another method M                of initiating a search, and additionally can use a wildcard in 7                the document specification. For example:b  6                   /web/html/html-primer/*.html?problem  #             7-2  Document Searchingl                 $             7.3.2 Forms-Based Search  J                A "forms-based" search is initiated by the server receivingK                a file specification, which of course may contain wildcards, K                followed by a search parameter. This is a typical HTML formsS'                format URL. For example:   &                    *.txt?search=SIMPLE+                    /web/.../*.*?search=THIS 0                    sub_directory/*.*?search=THAT;                    ../sibling_directory/*.HTML?search=OTHERT  /                <online hypertext demonstration>                 7.3.3 Search Options  J                Additional URI components may be appended after the initialK                "search=" parameter. These are appended with intervening "&"                 characters.  L                o  Case-Sensitivity.  An optional URI component of "case=yes"H                   or "case=no" makes the search case-sensistive or case-J                   insensistive (the default). The following example illus-0                   trates the use of this syntax:  B                      /web/html/.../*.html?search=Protocol&case=yesA                      /web/html/.../*.html?search=PrOtOcOl&case=no   2                   <online hypertext demonstration>  H                o  Hits.  An optional URI component of "hits=document" orG                   "hits=line" makes the search results be presented by- G                   document (file) or by line-by-line (the default). The G                   following example illustrates the use of this syntax:a  G                      /web/html/.../*.html?search=protocol&hits=document C                      /web/html/.../*.html?search=protocol&hits=linen  2                   <online hypertext demonstration>  M                o  About.  An optional URI component of "about=search" providenK                   the user with information about the search itself, how itc.                   works what the options mean.  '                      /web/?about=search   2                   <online hypertext demonstration>      N                                                        Document Searching  7-3    d            %             7.3.4 Example Search Formd  H                To allow the client to enter a search string and submit aH                search to the server a HTML level 2 form construct can be(                used. Here is an example:  6                   <FORM ACTION="/web/html/.../*.html">,                   Search HTML documents for:1                   <INPUT TYPE=text NAME="search"> 7                   <INPUT TYPE=submit VALUE="[execute]">r                   </FORM>   /                <online hypertext demonstration>n  !                Bells and Whistles   K                A form providing all the options refered to in Section 7.3.3 I                is shown below (some additional white-space introduced forh                clarity):  6                   <FORM ACTION="/web/html/.../*.html">  ,                   Search HTML documents for:1                   <INPUT TYPE=text NAME="search"> 7                   <INPUT TYPE=submit VALUE="[execute]">e  R                   <BR><TT><A HREF="/web/?about=search">About</A> this search.</TT>  $                   <BR><TT>Output By:J                   line <INPUT TYPE=radio NAME="hits" VALUE="line" CHECKED>O                   document <INPUT TYPE=radio NAME="hits" VALUE="document"></TT>   )                   <BR><TT>Case Sensitive:aF                   no <INPUT TYPE=radio NAME="case" VALUE="no" CHECKED>E                   yes <INPUT TYPE=radio NAME="case" VALUE="yes"></TT>                      </FORM>   /                <online hypertext demonstration>                       #             7-4  Document Searching  l  s                M             Chapter__8________________________________________________________  '             VMS Help and Text Librariesg    H                Affectionately known as Conan the Librarian, and with allG                due acknowlegement to Wierd Al.Yankovic :^), this scriptuL                makes VMS Help and Text libraries accessable in the hypertext                environment.   J                The librarian script will be automatically activated if theM                file specified has an extension of .HLB or .TLB. AlternativelysG                it may be explicitly activated by specifying /conan as aaK                prefix to the file specification (but the ability to provideiH                a relative specification is lost). The following examples%                illustrate the syntax:   G                   <A HREF="/sys$common/syshlp/helplib.hlb">VMS help</A>iX                   <A HREF="/conan/sys$common/syshlp/helplib.hlb">VMS help via /Conan</A>  /                <online hypertext demonstration>   ,                Other Librarian Functionality  K                To obtain an index of matching libraries explicitly activate H                the Conan script providing a wildcard file specification.  ]                   <A HREF="/conan/sys$common/syshlp/*.hlb">All Help libraries in SYS$HELP</A>   /                <online hypertext demonstration>   J                To obtain the library header information add a query stringK                to the library file specification, as shown in the following                 example:   f                   <A HREF="/conan/sys$common/syshlp/helplib.hlb?do=header">VMS help library header</A>  /                <online hypertext demonstration>                     N                                               VMS Help and Text Libraries  8-1 R  "                M             Chapter__9_______________________________________________________.  *             Bookreader Books and Libraries    G                Access to DEC's Bookreader format documentation (and any F                generated internally) is provided in the WASD hypertextI                environment via two integrated scripts, HyperReader, which K                reads the books, and HyperShelf, which reads the Library and                  Shelf structures.  G                The HyperReader and HyperShelf scripts are automatically M                activated when the document file's extension is .DECW$BOOK and J                .DECW$BOOKSHELF respectively. Alternatively, the respectiveF                scripts may be explicitly specified (but the ability toG                provide a relative specification is lost). The following .                examples illustrate the syntax:  K                   <A HREF="env.decw$book">This document from Bookreader</A> Z                   <A HREF="env.decw$bookshelf">The shelf DEC Document creates for this</A>  G                   <A HREF="/HyperReader/ht_root/doc/env/env.decw$book">c5                     This document from Bookreader</A>,K                   <A HREF="/HyperShelf/ht_root/doc/env/env.decw$bookshelf">tH                     The shelf DEC Document creates for this document</A>  /                <online hypertext demonstration>n                                          N                                            Bookreader Books and Libraries  9-1                     M             Chapter__10______________________________________________________i               Web Document Updatef    M                The Update facility allows Web documents and file environmentsfK                to be administered from a standard browser. This facility is J                available to Web administrator and user alike. AvailabilityM                and capability depends on the authorization environment withinh                the server.  H                It should be stressed that this is not designed as a fullK                hypertext administration or authoring tool, and for documentkD                preparation relies on the editing capabilities of theH                <TEXTAREA> widget of the user's browser. It does however,M                allow ad-hoc changes to be made to documents fairly easily, as K                well as allowing documents to be deleted, and directories top&                be created and deleted.  I                Consult the current Update documentation for usage detail.o  &                <online hypertext link>  '                Update Access Permission   G                Of course, the user must have write (POST/PUT) access to I                the document or area on the server (i.e. the path) and the K                server account have file system permission to write into the                  parent_directory.  K                Contact the Web Administrator for further information on theiL                availablility of authentication and authorization permissions2                to do on-line updates of Web paths.  G                The server will report "Insufficient privilege or object H                protection violation ... /path/" if it does not have file;                system permission to write into a directory.   L                The following shows an example of setting an ACL to allow theK                HTTPd server acount to write into a directory. This does noteD                propagate into any subdirectories created beneath it:  0                   $ SET SECURITY directory.DIR ->                     /ACL=(IDENT=HTTP$SERVER,ACCESS=READ+WRITE)  G                This example shows setting an ACL that will propagate tos&                created subdirectories:  0                   $ SET SECURITY directory.DIR -R                     /ACL=((IDENT=HTTP$SERVER,OPTIONS=DEFAULT,ACCESS=READ+WRITE), -@                           (IDENT=HTTP$SERVER,ACCESS=READ+WRITE))  N                                                      Web Document Update  10-1                     M             Chapter__11______________________________________________________g  #             dBASEIV Query Interfacer    L                The DBASEIV script provides query access to VMS-based dBASEIV                databases.o  L                The user can, by radio button, select to generate a report inM                a fixed-font format (the default), or using native HTML tablesmM                (supported by Netscape v1.n, but not supported by Mosaic v2.4, (                the current VMS browser).  I                Another set of radio buttons allow selection of the report L                layout as a table (the default), where fields are columnated,H                or as a listing, where fields are presented sequentially.  I                Parameters for the query are presented using a combinationtG                of checkboxes and/or text entry boxes against one, more,rG                or all of the fields in a database. The checkboxes allowaF                the inclusion of that field in a report. The text entryJ                boxes allow the specification of query strings, and provideI                the ability to selectively report on records of a database 7                depending on the contents of the fields.   J                A Submit Query button allows the completed query form to beK                sent to the server, and the report generated and returned toi                the user.                  Query Strings  F                A query string allows a field to be selected based on aK                wildcard match. Wildcards supported are the "*" and "%". For I                fields containing numeric values selection can be based onp'                arithmetic comparisions.   !                Query Form Builders  L                To assist in building query interfaces for specific databasesK                the DBASEIV script will provide a form allowing the specifi- L                cation of the fields to be queried and/or displayed, and thenM                build and return a custom hypertext form to do just that. ThiscL                form can then be saved for use from, or inclusion in, another                document.        N                                                  dBASEIV Query Interface  11-1 u               $                Online Demonstrations  /                <online hypertext demonstration>                                                                                               )             11-2  dBASEIV Query Interface                      M             Chapter__12______________________________________________________i               Document Printing     K                The print script allows the printing of PostScript, text and I                other files on WASD printers. It is restricted to browsersp4                from WASD hosts for obvious reasons!.  I                The print script may be accessed by specifying /print as asL                prefix to the document specification to be printed, as in the!                following example:d  K                   <A HREF="/print/ht_root/doc/htd/htd.ps">This Document</A>t  L                When this link is selected an online form is presented to theJ                user allowing the selection of the print queue required. AnL                optional check-box allows the selection of two document pagesI                per printed sheet on supporting print queues, allowing theqM                ready conservation of paper. The form can then be submitted to                 print the file.  /                <online hypertext demonstration>                                                   N                                                        Document Printing  12-1 n                   M             Chapter__13______________________________________________________h  &             PostMail / SendMail Script    J                The PostMail script allows an HTML forms-based mail messageI                to be generated and sent. It relies on authentication of amH                user with an VMS account. The message originates from the&                authenticated username.  G                The SendMail script also allows an HTML forms-based mailuL                message to be generated and sent. Unlike PostMail it does notL                require any authentication and relies on the user of the formL                to enter their e-mail address and optionally personal name. AM                disclaimer at the beginning of the message body explains it is .                from a non-ahtneticated source.  3                The script can provide its own help."  &                <online hypertext link>  J                The HTTP GET method is used to request a message generationF                form. The following URL form field names may be used toH                control the format of, and/or provide default values for,J                the message generation form. The URL must of course conformK                to URL specification rules and have escaped characters wheree                necessary.n  /                <online hypertext demonstration>t  L                Each of the following list represents an HTML form field nameI                which can be used to construct a mailing form (see examplef#                Section 13.2 below).   5                o  sender (non-authenticated use only) 8                   Specifies the sender's e-mail address.  :                o  sender_name (non-authenticated use only)7                   Specifies the sender's personal name.                   o  to@                   Specifies the default destination address(es).                  o  listI                   Specifies the URL-style location of a file comprising a K                   distribution list. If TO is null it generates a selection D                   box, if "*" (an asterisk) defaults to all in list.                  o  subjecti6                   Specifies the default subject field.  N                                               PostMail / SendMail Script  13-1                                 o  body5                   Specifies the default message body.s                  o  messageiK                   Specifies the URL-style location of a file comprising theu'                   default message body.d                  o  fixedsM                   If this field is non-null it fixes any defaults supplied sos.                   that they cannot be changed.                  o  TextAreaH                   Allows the specification of the message body text areaA                   window size, in columns by rows (e.g. "80x24").a  F                The HTTP POST method is used to send a message. This isC                handled by the message generation form and is not ofm#                operational concern.   )             13.1 Usage Similar to MAILTO:p  J                The PostMail script may be used in a similar fashion to the                mailto: URL.                   o  mailtoH                   Any fields in a form following this field name will beB                   mailed to the destination in URL-escaped format.                  o  deformH                   Any fields in a form following this field name will beH                   mailed to the destination in deformed format, that is,I                   processed for easy reading. Each form field name occurs.L                   on a line by itself, terminated by a full-colon. The valueL                   of the field occurs immediately below it. Multi-line fieldK                   values (such as TEXTAREA) appear as multiple lines. Where J                   a blank line was input that line is replaced with a lineL                   containing a single period. Each field name and value pair?                   is separated from the next with a blank line.t               13.2 Example Use                    ,             13-2  PostMail / SendMail Script                                    <P><HR>s7                   <FORM METHOD=POST ACTION="/SendMail"> 6                   <P>Demonstration message originator:                   <BR>O                   <INPUT TYPE=text NAME=sender SIZE=45> <I>(e-mail address)</I>r                   <BR>\                   <INPUT TYPE=text NAME=sender_name SIZE=30> <I>(optional personal name)</I>7                   <P>Demonstration message destination:u                   <BR>3                   <INPUT TYPE=text NAME=to SIZE=48>hX                   <INPUT TYPE=hidden NAME=subject VALUE="Demonstration of DEFORM Field">_                   <!-- NOTE: everything following the deform field will be the message body --> 1                   <INPUT TYPE=hidden NAME=deform> R                   <P> ay <INPUT TYPE=checkbox NAME=one VALUE="ay checked" CHECKED>H                   bee <INPUT TYPE=checkbox NAME=two VALUE="bee checked">J                   see <INPUT TYPE=checkbox NAME=three VALUE="see checked">X                   <P> one <INPUT TYPE=radio NAME=radio-box VALUE="one selected" CHECKED>L                   two <INPUT TYPE=radio NAME=radio-box VALUE="two selected">P                   three <INPUT TYPE=radio NAME=radio-box VALUE="three selected">.                   <P> Multi-line message area:                   <BR>E                   <INPUT TYPE=textarea NAME=text-area ROWS=4 COLS=48>t;                   <P> <INPUT TYPE=submit VALUE="mail form">e=                   <INPUT TYPE=reset VALUE="reset all fields">i                   </FORM>e                   <P><HR>i  /                <online hypertext demonstration>.                                            N                                               PostMail / SendMail Script  13-3    I                M             Chapter__14______________________________________________________A               Menus<    K                To allow easy management of information by users not needingrD                to explore the complexities of HTML (HyperText MarkupF                Language) a simple menuing system is provided, allowingL                versatile document access and searching. A plain-text file isL                interpreted by the server, providing a uniform and functionalL                menu to the client. This plain-text file may be edited on anyJ                platform (PC, VMS, Unix) and then just placed into the data                area.  C                A menu is distinguished from other files by its type_F                extension, .MENU (or .MNU for "8.3" MS-DOS compliance).  I                The "WASD Hypertext Management Primer" provides a completed/                description on the use of menus.s  +                <online document available>.l                                                      N                                                                    Menus  14-1