If you are installing or upgrading the commercial modules separately, follow the instructions in the INSTALL_MODULES file included with the package. You can get Modules for 1.X versions or Modules for 2.X. The main difference is that with 2.X, you can get a toolbar for groups of N hits at the bottom of the page, for cases where more than the maximum # of hits are returned.
Controlling output text
Using wgoutput.cfg , you have control over each piece of text
output by webglimpse in the results page. Here is a
sample wgoutput.cfg file. This file
is shipped as the default output configuration in version 1.7.4. Note, however, that in versions prior to 2.1 the file is named .wgoutput.cfg so it is hidden from the directory listing.
Each line in the wgoutput.cfg file starts with a special variable name
or a + character to continue the previous record. The variables are used
as follows to generate results output:
begin_html output once at the beginning of results neigh_msg output once if this is a neighborhood search noneigh_msg output once if not a neighborhood search lines_msg output once if using jump to line nolines_msg output once if not using jump to line begin_files output once if any files match query begin_file_marker output at start of each file match, before the actual link to the file begin_lines output before first matching line of each file, but after the actual link to the file begin_single_line output before each matching line of each file end_single_line output after each matching line of each file end_lines output after all matching lines of each file end_file_marker output after end_lines end_files output after all matching files (if any) end_html output at end of results page
in the wgoutput.cfg file.[VARNAME]
Pre-defined variables are as follows:
User-defined variables are set up in the .wgoutputfields file. The format is[QUERY] The original user query [SEARCHTITLE] Optional form variable in wgindex.html [MATCHED_LINES] Number of matching lines (Can ONLY be used in end_html variable above) [MATCHED_FILES] Number of matching files (Can ONLY be used in end_html variable above)
where TYPE may be FILE, to look for value in the actual matching file, or PATH, to look for the value in the directory pathTYPE<tab>NAME<tab>REGEXP
NAME should match a variable [NAME] in the wgoutput.cfg file in the archive directory. TITLE is a special name, and will be used for the linked text.
The value will be set to the first matching ()'s (using the $1 variable after a match)
For example, the .wgoutputfields line:
will cause each file returned by Glimpse to be parsed for the regular expression /^Reference Number:\s+(.+)$/, and if a match occurs, the subexpression corresponding to the ()'s is substituted forFILE REFNO ^Reference Number:\s+(.+)$
wherever that variable appears in the output text specified in wgoutput.cfg. Note, only one subexpression should be enclosed in parentheses.[REFNO]
will cause the path to each returned file, to be parsed for the regular expression /\/([^\/]+)\/[^\/]+$/. If a match occurs, the subexpression corresponding to the ()'s, in this case the last subdirectory containing the file, is substituted forPATH LASTSUBDIR \/([^\/]+)\/[^\/]+$
as it appears in wgoutput.cfg.[LASTSUBDIR]