home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Linux / Divers / lynx2.8.1dev.10.tar.gz / lynx2.8.1dev.10.tar / lynx2-8 / userdefs.h < prev    next >
C/C++ Source or Header  |  1998-04-18  |  59KB  |  1,407 lines

  1. /*
  2.  * Lynx - Hypertext navigation system
  3.  *
  4.  *   (c) Copyright 1992, 1993, 1994 University of Kansas
  5.  *     1995, 1996: GNU General Public License
  6.  */
  7.  
  8. /*******************************************************************
  9.  * There are four sections to this document:
  10.  *  Section 1.  Things you MUST change or verify
  11.  *    Section 1a)  VMS specific things
  12.  *    Section 1b)  UNIX specific things
  13.  *    Section 1c)  ALL Platforms
  14.  *
  15.  *  Section 2.  Things you should probably check!
  16.  *
  17.  *  Section 3.  Things you should only change after you have a good
  18.  *              understanding of the program!
  19.  *
  20.  *  Section 4.  Things you MUST check only if you plan to use Lynx in
  21.  *              an anonymous account (allow public access to Lynx)!
  22.  *
  23.  */
  24.  
  25. #ifndef USERDEFS_H
  26. #define USERDEFS_H
  27.  
  28. #ifdef HAVE_CONFIG_H
  29. #include <lynx_cfg.h>
  30. #endif
  31.  
  32. /*******************************************************************
  33.  * Things you must change
  34.  *  Section 1.
  35.  */
  36.  
  37. /*******************************************************************
  38.  * Things you must change  VMS specific
  39.  *  Section 1a).
  40.  */
  41. #ifdef VMS
  42. /**************************
  43.  * TEMP_SPACE is where Lynx temporary cache files will be placed.
  44.  * Temporary files are removed automatically as long as nothing
  45.  * goes terribly wrong :)  If you include "$USER" in the definition
  46.  * (e.g., "device:[dir.$USER]"), Lynx will replace the "$USER" with
  47.  * the username of the account which invoked the Lynx image.  Such
  48.  * directories should already exist, and have protections/ACLs set
  49.  * so that only the appropriate user(s) will have read/write access.
  50.  * On VMS, "sys$scratch:" defaults to "sys$login:" if it has not been
  51.  * defined externally, or you can use "sys$login:" explicitly here.
  52.  * If the path has SHELL syntax and includes a tilde (e.g, "~/lynxtmp"),
  53.  * Lynx will replace the tilde with the full path for the user's home
  54.  * and convert the result to VMS syntax.
  55.  * The definition here can be overridden at run time by defining a
  56.  * "LYNX_TEMP_SPACE" VMS logical.
  57.  */
  58. #define TEMP_SPACE "sys$scratch:"
  59.  
  60. /**************************
  61.  * LYNX_CFG_FILE is the location and name of the default lynx
  62.  * global configuration file.  It is sought and processed at
  63.  * startup of Lynx, followed by a seek and processing of a
  64.  * personal RC file (.lynxrc in the user's HOME directory,
  65.  * created if the user saves values in the 'o'ptions menu).
  66.  * You also can define the location and name of the global
  67.  * configuration file via a VMS logical, "LYNX_CFG", which
  68.  * will override the "LYNX_CFG_FILE" definition here.  SYS$LOGIN:
  69.  * can be used as the device in either or both definitions if
  70.  * you want lynx.cfg treated as a personal configuration file.
  71.  * You also can use Unix syntax with a '~' for a subdirectory
  72.  * of the login directory, (e.g., ~/lynx/lynx.cfg).
  73.  * The -cfg command line switch will override these definitions.
  74.  * You can pass the compilation default via build.com or descrip.mms.
  75.  *
  76.  * Note that some implementations of telnet allow passing of
  77.  * environment variables, which might be used by unscrupulous
  78.  * people to modify the environment in anonymous accounts.  When
  79.  * making Lynx and Web access publically available via anonymous
  80.  * accounts intended to run Lynx captively, be sure the wrapper
  81.  * uses the -cfg switch and specifies the startfile, rather than
  82.  * relying on the LYNX_CFG, LYNX_CFG_FILE, or WWW_HOME variables.
  83.  *
  84.  * Note that any SUFFIX or VIEWER mappings in the configuration
  85.  * file will be overidden by any suffix or viewer mappings
  86.  * that are established as defaults in src/HTInit.c.  You can
  87.  * override the src/HTInit.c defaults via the mime.types and
  88.  * mailcap files (see the examples in the samples directory).
  89.  */
  90. #ifndef LYNX_CFG_FILE
  91. #define LYNX_CFG_FILE "Lynx_Dir:lynx.cfg"
  92. #endif /* LYNX_CFG_FILE */
  93.  
  94. /**************************
  95.  * The EXTENSION_MAP file allows you to map file suffix's to
  96.  * mime types.
  97.  * These global and personal files override anything in
  98.  * lynx.cfg or src/HTInit.c
  99.  */
  100. #define GLOBAL_EXTENSION_MAP "Lynx_Dir:mime.types"
  101. #define PERSONAL_EXTENSION_MAP "mime.types"
  102.  
  103. /**************************
  104.  * The MAILCAP file allows you to map file MIME types to
  105.  * external viewers.
  106.  * These global and personal files override anything in
  107.  * lynx.cfg or src/HTInit.c
  108.  */
  109. #define GLOBAL_MAILCAP "Lynx_Dir:mailcap"
  110. #define PERSONAL_MAILCAP ".mailcap"
  111.  
  112. /**************************
  113.  * XLOADIMAGE_COMMAND will be used as a default in src/HTInit.c
  114.  * for viewing image content types when the DECW$DISPLAY logical
  115.  * is set.  Make it the foreign command for your system's X image
  116.  * viewer (commonly, "xv").  Make it "exit" or something like that
  117.  * if you don't have one.  It can be anything that will handle GIF,
  118.  * TIFF and other popular image formats.  Freeware ports of xv for
  119.  * VMS are available in the ftp://ftp.wku.edu/vms/unsupported and
  120.  * http://www.openvms.digital.com/cd/XV310A/ subdirectories.  You
  121.  * must also have a "%s" for the filename.  The default defined
  122.  * here can be overridden in lynx.cfg, or via the global or personal
  123.  * mailcap files.
  124.  */
  125. #define XLOADIMAGE_COMMAND "xv %s"
  126.  
  127. /**************************
  128.  * SYSTEM_MAIL must be defined here to your mail sending command,
  129.  * and SYSTEM_MAIL_FLAGS to approrpriate qualifiers.  They can be
  130.  * changed in lynx.cfg.
  131.  *
  132.  * The mail command will be spawned as a subprocess of lynx
  133.  * and used to send the email, with headers specified in a
  134.  * temporary file for PMDF.  If you define SYSTEM_MAIL to the
  135.  * "generic" MAIL utility for VMS, headers cannot be specified
  136.  * via a header file (and thus may not be included), and the
  137.  * subject line will be specified by use of the /subject="SUBJECT"
  138.  * qualifier.
  139.  *
  140.  * If your mailer uses another syntax, some hacking of the
  141.  * mailform(), mailmsg() and reply_by_mail() functions in
  142.  * LYMail.c, and printfile() function in LYPrint.c, may be
  143.  * required.
  144.  */
  145. #define SYSTEM_MAIL "PMDF SEND"
  146. #define SYSTEM_MAIL_FLAGS "/headers"
  147. /* #define SYSTEM_MAIL "MAIL"   */
  148. /* #define SYSTEM_MAIL_FLAGS "" */
  149.  
  150. /*************************
  151.  * Below is the argument for an sprintf command that will add
  152.  * "IN%""ADDRESS""" to the Internet mail address given by the user.
  153.  * It is structured for PMDF's IN%"INTERNET_ADDRESS" scheme.  The %s
  154.  * is replaced with the address given by the user.  If you are using
  155.  * a different Internet mail transport, change the IN appropriately
  156.  * (e.g., to SMTP, MX, or WINS), here or in lynx.cfg.
  157.  */
  158. #define MAIL_ADRS "\"IN%%\"\"%s\"\"\""
  159.  
  160. /*********************************
  161.  * On VMS, CSwing (an XTree emulation for VTxxx terminals) is intended for
  162.  * use as the Directory/File Manager (sources, objects, or executables are
  163.  * available from ftp://narnia.memst.edu/).  CSWING_PATH should be defined
  164.  * here or in lynx.cfg to your foreign command for CSwing, with any
  165.  * regulatory switches you want included.  If not defined, or defined as
  166.  * a zero-length string ("") or "none" (case-insensitive), the support
  167.  * will be disabled.  It will also be disabled if the -nobrowse or
  168.  * -selective switches are used, or if the file_url restriction is set.
  169.  *
  170.  * When enabled, the DIRED_MENU command (normally 'f' or 'F') will invoke
  171.  * CSwing, normally with the current default directory as an argument to
  172.  * position the user on that node of the directory tree.  However, if the
  173.  * current document is a local directory listing, or a local file and not
  174.  * one of the temporary menu or list files, the associated directory will
  175.  * be passed as an argument, to position the user on that node of the tree.
  176.  */
  177. /* #define CSWING_PATH "swing" */
  178.  
  179. /*********************************
  180.  * If USE_FIXED_RECORDS is set to TRUE here and/or in lynx.cfg, Lynx will
  181.  * convert 'd'ownloaded binary files to FIXED 512 record format before saving
  182.  * them to disk or acting on a DOWNLOADER option.  If set to FALSE, the
  183.  * headers of such files will indicate that they are Stream_LF with Implied
  184.  * Carriage Control, which is incorrect, and can cause downloading software
  185.  * to get confused and unhappy.  If you do set it FALSE, you can use the
  186.  * FIXED512.COM command file, which is included in this distribution, to do
  187.  * the conversion externally.
  188.  */
  189. #define USE_FIXED_RECORDS    TRUE    /* convert binaries to FIXED 512 */
  190.  
  191. /********************************
  192.  * If NO_ANONYMOUS_EMAIL is defined, Lynx will not offer to insert X-From
  193.  * and X_Personal_Name lines in the body of email messages.  On VMS, the
  194.  * actual From and Personal Name (if defined for the account) headers always
  195.  * are those of the account running the Lynx image.  If the account is not
  196.  * the one to which the recipient should reply, you can indicate the alternate
  197.  * address and personal name via the X-From and X_Personal_Name entries, but
  198.  * the recipient must explicitly send the reply to the X_From address, rather
  199.  * than using the VMS REPLY command (which will use the actual From address).
  200.  *
  201.  * This symbol constant might be defined on Unix for security reasons that
  202.  * don't apply on VMS.  There is no security reason for defining this on VMS,
  203.  * but if you have no anonymous accounts (i.e., the From always will point to
  204.  * the actual user's email address, you can define it to avoid the bother of
  205.  * X-From and X_Personal_Name offers.
  206.  */
  207. /*#define NO_ANONYMOUS_EMAIL TRUE */
  208.  
  209. /**************************
  210.  * LYNX_LSS_FILE is the location and name of the default lynx
  211.  * character style sheet file.  It is sought and processed at
  212.  * startup of Lynx only if experimental character style code has
  213.  * been compiled in, otherwise it will be ignored.  Note that use
  214.  * of the character style option is _experimental_ AND _unsupported_.
  215.  * There is no documentation other than a sample lynx.lss file in
  216.  * the samples subdirectory.  This code probably won't even work on
  217.  * VMS.  You can define the location and name of this file via an
  218.  * environment variable, "lynx_lss", which will override the definition
  219.  * here.  You can use '~' to refer to the user's home directory.  The
  220.  * -lss command line switch will override these definitions.
  221.  */
  222. #ifndef LYNX_LSS_FILE
  223. #define LYNX_LSS_FILE "Lynx_Dir:lynx.lss"
  224. #endif /* LYNX_LSS_FILE */
  225.  
  226. /*******************************************************************
  227.  * Things you must change  UNIX specific
  228.  *  Section 1b).
  229.  */
  230. #else     /* UNIX */
  231.  
  232. /**************************
  233.  * NOTE: This variable is set by the configure scrip; editing changes will
  234.  * be ignored.
  235.  *
  236.  * LYNX_CFG_FILE is the location and name of the default lynx
  237.  * global configuration file.  It is sought and processed at
  238.  * startup of Lynx, followed by a seek and processing of a
  239.  * personal RC file (.lynxrc in the user's HOME directory,
  240.  * created if the user saves values in the 'o'ptions menu).
  241.  * You also can define the location and name of the global
  242.  * configuration file via an environment variable, "LYNX_CFG",
  243.  * which will override the "LYNX_CFG_FILE" definition here.
  244.  * You can use '~' in either or both definitions if you want
  245.  * lynx.cfg treated as a personal configuration file.  The
  246.  * -cfg command line switch will override these definitions.
  247.  * You can pass the compilation default via the Makefile.
  248.  *
  249.  * If you are building Lynx using the configure script, you should specify
  250.  * the default location of the configuration file via that script, since it
  251.  * also generates the makefile and install-cfg rules.
  252.  *
  253.  * Note that many implementations of telnetd allow passing of
  254.  * environment variables, which might be used by unscrupulous
  255.  * people to modify the environment in anonymous accounts.  When
  256.  * making Lynx and Web access publically available via anonymous
  257.  * accounts intended to run Lynx captively, be sure the wrapper
  258.  * uses the -cfg switch and specifies the startfile, rather than
  259.  * relying on the LYNX_CFG, LYNX_CFG_FILE, or WWW_HOME variables.
  260.  *
  261.  * Note that any SUFFIX or VIEWER mappings in the configuration
  262.  * file will be overidden by any suffix or viewer mappings
  263.  * that are established as defaults in src/HTInit.c.  You can
  264.  * override the src/HTInit.c defaults via the mime.types and
  265.  * mailcap files (see the examples in the samples directory).
  266.  */
  267. #ifndef HAVE_CONFIG_H
  268. #ifndef LYNX_CFG_FILE
  269. #ifdef DOSPATH
  270. #define LYNX_CFG_FILE "./lynx.cfg"
  271. #else
  272. #define LYNX_CFG_FILE "/usr/local/lib/lynx.cfg"
  273. #endif /* DOSPATH */
  274. #endif /* LYNX_CFG_FILE */
  275. #endif /* HAVE_CONFIG_H */
  276.  
  277. /**************************
  278.  * The EXTENSION_MAP file allows you to map file suffix's to
  279.  * mime types.
  280.  * These global and personal files override anything in
  281.  * lynx.cfg or src/HTInit.c
  282.  */
  283. #define GLOBAL_EXTENSION_MAP "/usr/local/lib/mosaic/mime.types"
  284. #define PERSONAL_EXTENSION_MAP ".mime.types"
  285.  
  286. /**************************
  287.  * The MAILCAP file allows you to map file MIME types to
  288.  * external viewers.
  289.  * These global and personal files override anything in
  290.  * lynx.cfg or src/HTInit.c
  291.  */
  292. #define GLOBAL_MAILCAP "/usr/local/lib/mosaic/mailcap"
  293. #define PERSONAL_MAILCAP ".mailcap"
  294.  
  295. /**************************
  296.  * the full path and name of the telnet command
  297.  */
  298. #define TELNET_COMMAND "telnet"
  299.  
  300. /**************************
  301.  * the full path and name of the tn3270 command
  302.  */
  303. #define TN3270_COMMAND "tn3270"
  304.  
  305. /**************************
  306.  * the full path and name of the rlogin command
  307.  */
  308. #define RLOGIN_COMMAND "rlogin"
  309.  
  310. /**************************
  311.  * XLOADIMAGE_COMMAND will be used as a default in src/HTInit.c for
  312.  * viewing image content types when the DISPLAY environment variable
  313.  * is set.  Make it the full path and name of the xli (also known as
  314.  * xloadimage or xview) command, or other image viewer.  Put 'echo' or
  315.  * something like it here if you don't have a suitable viewer.  It can
  316.  * be anything that will handle GIF, TIFF and other popular image formats
  317.  * (xli does).  The freeware distribution of xli is available in the
  318.  * ftp://ftp.x.org/contrib/ subdirectory.  The shareware, xv, also is
  319.  * suitable.  You must also have a "%s" for the filename; "&" for
  320.  * background is optional.  The default defined here can be overridden
  321.  * in lynx.cfg, or via the global or personal mailcap files.  Note that
  322.  * open is used as the default for NeXT, instead of the XLOADIMAGE_COMMAND
  323.  * definition.
  324.  */
  325. #define XLOADIMAGE_COMMAND "xli %s &"
  326.  
  327. /**************************
  328.  * For UNIX systems, SYSTEM_MAIL and SYSTEM_MAIL_FLAGS are set by the
  329.  * configure-script.
  330.  */
  331.  
  332. /**************************
  333.  * A place to put temporary files, it's almost always in "/tmp/"
  334.  * for UNIX systems.  If you include "$USER" in the definition
  335.  * (e.g., "/tmp/$USER"), Lynx will replace the "$USER" with the
  336.  * username of the account which invoked the Lynx image.  Such
  337.  * directories should already exist, and have protections/ACLs set
  338.  * so that only the appropriate user(s) will have read/write access.
  339.  * If the path includes a tilde (e.g, "~" or "~/lynxtmp"), Lynx will
  340.  * replace the tilde with the full path for the user's home.
  341.  * The definition here can be overridden at run time by setting a
  342.  * "LYNX_TEMP_SPACE" environment symbol.
  343.  */
  344. #define TEMP_SPACE "/tmp/"
  345.  
  346. /********************************
  347.  * Don't let the user enter his/her email address when sending a message.
  348.  * Anonymous mail makes it far too easy for a user to spoof someone else's
  349.  * email address.
  350.  * This requires that your mailer agent put in the From: field for you.
  351.  *
  352.  * The default should be to uncomment this line but there probably are too
  353.  * many mail agents out there that won't do the right thing if there is no
  354.  * From: line.
  355.  */
  356. /* #define NO_ANONYMOUS_EMAIL TRUE */
  357.  
  358. /********************************
  359.  * LIST_FORMAT defines the display for local files when LONG_LIST
  360.  * is defined in the Makefile.  The default set here can be changed
  361.  * in lynx.cfg.
  362.  *
  363.  * The percent items in the list are interpreted as follows:
  364.  *
  365.  *    %p    Unix-style permission bits
  366.  *    %l    link count
  367.  *    %o    owner of file
  368.  *    %g    group of file
  369.  *    %d    date of last modification
  370.  *    %a    anchor pointing to file or directory
  371.  *    %A    as above but don't show symbolic links
  372.  *    %k    size of file in Kilobytes
  373.  *    %K    as above but omit size for directories
  374.  *    %s    size of file in bytes
  375.  *
  376.  * Anything between the percent and the letter is passed on to sprintf.
  377.  * A double percent yields a literal percent on output.  Other characters
  378.  * are passed through literally.
  379.  *
  380.  * If you want only the filename:  "    %a"
  381.  *
  382.  * If you want a brief output:     "    %4K %-12.12d %a"
  383.  *
  384.  * For the Unix "ls -l" format:    "    %p %4l %-8.8o %-8.8g %7s %-12.12d %a"
  385.  */
  386. #define LIST_FORMAT "    %p %4l %-8.8o %-8.8g %7s %-12.12d %a"
  387.  
  388. /*
  389.  *  If NO_FORCED_CORE_DUMP is set to TRUE, Lynx will not force
  390.  *  core dumps via abort() calls on fatal errors or assert()
  391.  *  calls to check potentially fatal errors.  The default defined
  392.  *  here can be changed in lynx.cfg, and the compilation or
  393.  *  configuration default can be toggled via the -core command
  394.  *  line switch.
  395.  */
  396. #define NO_FORCED_CORE_DUMP    FALSE
  397.  
  398. /**************************
  399.  * LYNX_LSS_FILE is the location and name of the default lynx
  400.  * character style sheet file.  It is sought and processed at
  401.  * startup of Lynx only if experimental character style code
  402.  * has been compiled in, otherwise it will be ignored.  Note
  403.  * that use of the character style option is _experimental_ AND
  404.  * _unsupported_.  There is no documentation other than a sample
  405.  * lynx.lss file in the samples subdirectory.  You also can
  406.  * define the location and name of this file via environment
  407.  * variables "LYNX_LSS" or "lynx_lss" which will override the
  408.  * "LYNX_LSS_FILE" definition here.  You can use '~' in either or
  409.  * both definitions to refer to the user's home directory.  The
  410.  * -lss command line switch will override these definitions.
  411.  */
  412. #ifndef LYNX_LSS_FILE
  413. #define LYNX_LSS_FILE "/usr/local/lib/lynx.lss"
  414. #endif /* LYNX_LSS_FILE */
  415.  
  416. #endif /* VMS OR UNIX */
  417.  
  418. /*************************************************************
  419.  *  Section 1c)   Every platform must change or verify these
  420.  *
  421.  */
  422.  
  423. /*****************************
  424.  * STARTFILE is the default file if none is specified in lynx.cfg,
  425.  *  on the command line, or via a WWW_HOME environment variable.
  426.  *
  427.  * note: STARTFILE must be a URL.  See the Lynx online help for more
  428.  *       information on URLs
  429.  */
  430. #define STARTFILE "http://lynx.browser.org/"
  431.  
  432. /*****************************
  433.  * HELPFILE must be defined as a URL and must have a
  434.  * complete path if local:
  435.  * file://localhost/PATH_TO/lynx_help/lynx_help_main.html
  436.  *   Replace PATH_TO with the path to the lynx_help subdirectory
  437.  *   for this distribution (use SHELL syntax including the device
  438.  *   on VMS systems).
  439.  * The default HELPFILE is:
  440.  * http://www.crl.com/~subir/lynx/lynx_help/lynx_help_main.html
  441.  *   This should be changed here or in lynx.cfg to the local path.
  442.  */
  443. #define HELPFILE "http://www.crl.com/~subir/lynx/lynx_help/lynx_help_main.html"
  444. /* #define HELPFILE "file://localhost/PATH_TO/lynx_help/lynx_help_main.html" */
  445.  
  446. /*****************************
  447.  * DEFAULT_INDEX_FILE is the default file retrieved when the
  448.  * user presses the 'I' key when viewing any document.
  449.  * An index to your CWIS can be placed here or a document containing
  450.  * pointers to lots of interesting places on the web.
  451.  */
  452. #define DEFAULT_INDEX_FILE "http://www.ncsa.uiuc.edu/SDG/Software/Mosaic/MetaIndex.html"
  453.  
  454. /*****************************
  455.  * If USE_TRACE_LOG is set FALSE, then when TRACE mode is invoked the
  456.  * syserr messages will not be directed to a log file named Lynx.trace
  457.  * in the account's HOME directory.  The default defined here can be
  458.  * toggled via the -tlog command line switch.  Also, it is set FALSE
  459.  * automatically when Lynx is executed in an anonymous or validation
  460.  * account (if indicated via the -anonymous or -validate command line
  461.  * switches, or via the check for the ANONYMOUS_USER, defined below).
  462.  * When FALSE, the TRACE_LOG command (normally ';') cannot be used to
  463.  * examine the Lynx Trace Log during the current session.  If left
  464.  * TRUE, but you wish to use command line piping of stderr to a file
  465.  * you specify, include the -tlog toggle on the command line.  Note
  466.  * that once TRACE mode is turned on during a session and stderr is
  467.  * directed to the log, all stderr messages will continue going to
  468.  * the log, even if TRACE mode is turned off via the TOGGLE_TRACE
  469.  * (Control-T) command.
  470.  */
  471. #define USE_TRACE_LOG    TRUE
  472.  
  473. /*******************************
  474.  * If GOTOBUFFER is set to TRUE here or in lynx.cfg the last entered
  475.  * goto URL, if any, will be offered as a default for reuse or editing
  476.  * when the 'g'oto command is entered.  All previously used goto URLs
  477.  * can be accessed for reuse or editing via a circular buffer invoked
  478.  * with the Up-Arrow or Down-Arrow keys after entering the 'g'oto
  479.  * command, whether or not a default is offered.
  480.  */
  481. #define GOTOBUFFER      FALSE
  482.  
  483. /*****************************
  484.  * JUMPFILE is the default local file checked for shortcut URLs when
  485.  * the user presses the 'J' (JUMP) key.  The user will be prompted for
  486.  * a shortcut entry (analogously to 'g'oto), and can enter one
  487.  * or use '?' for a list of the shortcuts with associated links to
  488.  * their actual URLs.  See the sample jumps files in the samples
  489.  * subdirectory.  Make sure your jumps file includes a '?' shortcut
  490.  * for a file://localhost URL to itself:
  491.  *
  492.  * <dt>?<dd><a href="file://localhost/path/jumps.html">This Shortcut List</a>
  493.  *
  494.  * If not defined here or in lynx.cfg, the JUMP command will invoke
  495.  * the NO_JUMPFILE statusline message (see LYMessages_en.h).  The prompt
  496.  * associated with the default jumps file is defined as JUMP_PROMPT in
  497.  * LYMessages_en.h and can be modified in lynx.cfg.  Additional, alternate
  498.  * jumps files can be defined and mapped to keystrokes, and alternate
  499.  * prompts can be set for them, in lynx.cfg, but at least one default
  500.  * jumps file and associated prompt should be established before adding
  501.  * others.
  502.  *
  503.  * On VMS, use Unix SHELL syntax (including a lead slash) to define it.
  504.  *
  505.  * Do not include "file://localhost" in the definition.
  506.  */
  507. /* #define JUMPFILE "/Lynx_Dir/jumps.html" */
  508.  
  509. /*******************************
  510.  * If JUMPBUFFER is set to TRUE here or in lynx.cfg the last entered
  511.  * jump shortcut, if any, will be offered as a default for reuse or
  512.  * editing when the JUMP command is entered.  All previously used
  513.  * shortcuts can be accessed for reuse or editing via a circular buffer
  514.  * invoked with the Up-Arrow or Down-Arrow keys after entering the JUMP
  515.  * command, whether or not a default is offered.  If you have multiple
  516.  * jumps files and corresponding key mappings, each will have its own
  517.  * circular buffer.
  518.  */
  519. #define JUMPBUFFER      FALSE
  520.  
  521. /********************************
  522.  * If PERMIT_GOTO_FROM_JUMP is defined, then a : or / in a jump target
  523.  * will be treated as a full or partial URL (to be resolved versus the
  524.  * startfile), and will be handled analogously to a 'g'oto command.
  525.  * Such "random URLs" will be entered in the circular buffer for goto
  526.  * URLs, not the buffer for jump targets (shortcuts).  If the target
  527.  * is the single character ':', it will be treated equivalently to an
  528.  * Up-Arrow or Down-Arrow following a 'g'oto command, for accessing the
  529.  * circular buffer of goto URLs.
  530.  */
  531. /* #define PERMIT_GOTO_FROM_JUMP */
  532.  
  533. /*****************************
  534.  * If LYNX_HOST_NAME is defined here and/or in lynx.cfg, it will be
  535.  * treated as an alias for the local host name in checks for URLs on
  536.  * the local host (e.g., when the -localhost switch is set), and this
  537.  * host name, "localhost", and HTHostName (the fully qualified domain
  538.  * name of the system on which Lynx is running) will all be passed as
  539.  * local.  A different definition in lynx.cfg will override this one.
  540.  */
  541. /* #define LYNX_HOST_NAME "www.cc.ukans.edu" */
  542.  
  543. /*********************
  544.  * LOCAL_DOMAIN is used for a tail match with the ut_host element of
  545.  * the utmp or utmpx structure on systems with utmp capabilites, to
  546.  * determine if a user is local to your campus or organization when
  547.  * handling -restrictions=inside_foo or outside_foo settings for ftp,
  548.  * news, telnet/tn3270 and rlogin URLs.  An "inside" user is assumed
  549.  * if your system does not have utmp capabilities.  CHANGE THIS here
  550.  * or in lynx.cfg.
  551.  */
  552. #define LOCAL_DOMAIN "ukans.edu"
  553.  
  554. /********************************
  555. * The DEFAULT_CACHE_SIZE specifies the number of WWW documents to be
  556. * cached in memory at one time.
  557. *
  558. * This so-called cache size (actually, number) may be modified in lynx.cfg
  559. * and or with the command line argument -cache=NUMBER  The minimum allowed
  560. * value is 2, for the current document and at least one to fetch, and there
  561. * is no absolute maximum number of cached documents.  On Unix, and VMS not
  562. * compiled with VAXC, whenever the number is exceeded the least recently
  563. * displayed document will be removed from memory.
  564. *
  565. * On VMS compiled with VAXC, the DEFAULT_VIRTUAL_MEMORY_SIZE specifies the
  566. * amount (bytes) of virtual memory that can be allocated and not yet be freed
  567. * before previous documents are removed from memory.  If the values for both
  568. * the DEFAULT_CACHE_SIZE and DEFAULT_VIRTUAL_MEMORY_SIZE are exceeded, then
  569. * least recently displayed documents will be freed until one or the other
  570. * value is no longer exceeded.  The value can be modified in lynx.cfg.
  571. *
  572. * The Unix and VMS but not VAXC implementations use the C library malloc's
  573. * and calloc's for memory allocation, and procedures for taking the actual
  574. * amount of cache into account still need to be developed.  They use only
  575. * the DEFAULT_CACHE_SIZE value, and that specifies the absolute maximum
  576. * number of documents to cache (rather than the maximum number only if
  577. * DEFAULT_VIRTUAL_MEMORY_SIZE has been exceeded, as with VAXC/VAX).
  578. */
  579. #define DEFAULT_CACHE_SIZE 10
  580.  
  581. #if defined(VMS) && defined(VAXC) && !defined(__DECC)
  582. #define DEFAULT_VIRTUAL_MEMORY_SIZE 512000
  583. #endif /* VMS && VAXC && !__DECC */
  584.  
  585. /********************************
  586.  * If ALWAYS_RESUBMIT_POSTS is set TRUE, Lynx always will resubmit forms
  587.  * with method POST, dumping any cache from a previous submission of the
  588.  * form, including when the document returned by that form is sought with
  589.  * the PREV_DOC command or via the history list.  Lynx always resubmits
  590.  * forms with method POST when a submit button or a submitting text input
  591.  * is activated, but normally retrieves the previously returned document
  592.  * if it had links which you activated, and then go back with the PREV_DOC
  593.  * command or via the history list.
  594.  *
  595.  * The default defined here can be changed in lynx.cfg, and can be toggled
  596.  * via the -resubmit_posts command line switch.
  597.  */
  598. #define ALWAYS_RESUBMIT_POSTS FALSE
  599.  
  600. /********************************
  601.  * CHARACTER_SET defines the default character set, i.e., that assumed
  602.  * to be installed on the user's termimal.  It determines which characters
  603.  * or strings will be used to represent 8-bit character entities within
  604.  * HTML.  New character sets may be defined as explained in the README
  605.  * files of the src/chrtrans directory in the Lynx source code distribution.
  606.  * For Asian (CJK) character sets, it also determines how Kanji code will
  607.  * be handled.  The default defined here can be changed in lynx.cfg, and
  608.  * via the 'o'ptions menu.  The 'o'ptions menu setting will be stored in
  609.  * the user's RC file whenever those settings are saved, and thereafter
  610.  * will be used as the default.  Also see lynx.cfg for information about
  611.  * the -raw switch and LYE_RAW_TOGGLE command.
  612.  *
  613.  * The default character sets include:
  614.  *
  615.  *   Display Character Set name        MIME name
  616.  *   ==========================        =========
  617.  *   7 bit approximations        us-ascii
  618.  *   Chinese                euc-cn
  619.  *   DEC Multinational            dec-mcs
  620.  *   DosArabic (cp864)            cp864
  621.  *   DosBaltRim (cp775)            cp775
  622.  *   DosCyrillic (cp866)        cp866
  623.  *   DosGreek (cp737)            cp737
  624.  *   DosGreek2 (cp869)            cp869
  625.  *   DosHebrew (cp862)            cp862
  626.  *   DosLatin1 (cp850)            cp850
  627.  *   DosLatin2 (cp852)            cp852
  628.  *   DosLatinUS (cp437)            cp437
  629.  *   ISO 8859-10            iso-8859-10
  630.  *   ISO 8859-5 Cyrillic        iso-8859-5
  631.  *   ISO 8859-6 Arabic            iso-8859-6
  632.  *   ISO 8859-7 Greek            iso-8859-7
  633.  *   ISO 8859-8 Hebrew            iso-8859-8
  634.  *   ISO 8859-9 (Latin 5)        iso-8859-9
  635.  *   ISO Latin 1            iso-8859-1
  636.  *   ISO Latin 2            iso-8859-2
  637.  *   ISO Latin 3            iso-8859-3
  638.  *   ISO Latin 4            iso-8859-4
  639.  *   Japanese (EUC)            euc-jp
  640.  *   Japanese (SJIS)            shift_jis
  641.  *   KOI8-R Cyrillic            koi8-r
  642.  *   Korean                euc-kr
  643.  *   Macintosh (8 bit)            macintosh
  644.  *   NeXT character set            next
  645.  *   RFC 1345 Mnemonic            mnemonic
  646.  *   RFC 1345 w/o Intro            mnemonic+ascii+0
  647.  *   Taipei (Big5)            big5
  648.  *   Transparent            x-transparent
  649.  *   UNICODE UTF-8            utf-8
  650.  *   Vietnamese (VISCII)        viscii
  651.  *   WinArabic (cp1256)            windows-1256
  652.  *   WinBaltRim (cp1257)        windows-1257
  653.  *   WinCyrillic (cp1251)        windows-1251
  654.  *   WinGreek (cp1253)            windows-1253
  655.  *   WinHebrew (cp1255)            windows-1255
  656.  *   WinLatin1 (cp1252)            windows-1252
  657.  *   WinLatin2 (cp1250)            windows-1250
  658.  */
  659. #define CHARACTER_SET "ISO Latin 1"
  660.  
  661. /*****************************
  662.  * PREFERRED_LANGUAGE is the language in MIME notation (e.g., "en",
  663.  * "fr") which will be indicated by Lynx in its Accept-Language headers
  664.  * as the preferred language.  If available, the document will be
  665.  * transmitted in that language.  This definition can be overriden via
  666.  * lynx.cfg.  Users also can change it via the 'o'ptions menu and save
  667.  * that preference in their RC file. This may be a comma-separated list
  668.  * of languages in decreasing preference.
  669.  */
  670. #define PREFERRED_LANGUAGE "en"
  671.  
  672. /*****************************
  673.  * PREFERRED_CHARSET specifies the character set in MIME notation (e.g.,
  674.  * "ISO-8859-2", "ISO-8859-5") which Lynx will indicate you prefer in
  675.  * requests to http servers using an Accept-Charsets header.
  676.  * This definition can be overriden via lynx.cfg.  Users also can change it
  677.  * via the 'o'ptions menu and save that preference in their RC file.
  678.  * The value should NOT include "ISO-8859-1" or "US-ASCII", since those
  679.  * values are always assumed by default.
  680.  * If a file in that character set is available, the server will send it.
  681.  * If no Accept-Charset header is present, the default is that any
  682.  * character set is acceptable. If an Accept-Charset header is present,
  683.  * and if the server cannot send a response which is acceptable
  684.  * according to the Accept-Charset header, then the server SHOULD send
  685.  * an error response with the 406 (not acceptable) status code, though
  686.  * the sending of an unacceptable response is also allowed. (RFC2068)
  687.  */
  688. #define PREFERRED_CHARSET ""
  689.  
  690. /*****************************
  691. * If MULTI_BOOKMARK_SUPPORT is set TRUE, and BLOCK_MULTI_BOOKMARKS (see
  692. * below) is FALSE, and sub-bookmarks exist, all bookmark operations will
  693. * first prompt the user to select an active sub-bookmark file or the
  694. * default bookmark file.  FALSE is the default so that one (the default)
  695. * bookmark file will be available initially.  The default set here can
  696. * be overridden in lynx.cfg.  The user can turn on multiple bookmark
  697. * support via the 'o'ptions menu, and can save that choice as the startup
  698. * default via the .lynxrc file.  When on, the setting can be STANDARD or
  699. * ADVANCED.  If support is set to the latter, and the user mode also is
  700. * ADVANCED, the VIEW_BOOKMARK command will invoke a statusline prompt at
  701. * which the user can enter the letter token (A - Z) of the desired bookmark,
  702. * or '=' to get a menu of available bookmark files.  The menu always is
  703. * presented in NOVICE or INTERMEDIATE mode, or if the support is set to
  704. * STANDARD.  No prompting or menu display occurs if only one (the startup
  705. * default) bookmark file has been defined (define additional ones via the
  706. * 'o'ptions menu).  The startup default, however set, can be overridden on
  707. * the command line via the -restrictions=multibook or the -anonymous or
  708. * -validate switches.
  709. */
  710. #ifndef MULTI_BOOKMARK_SUPPORT
  711. #define MULTI_BOOKMARK_SUPPORT FALSE
  712. #endif /* MULTI_BOOKMARK_SUPPORT */
  713.  
  714. /*****************************
  715. * If BLOCK_MULTI_BOOKMARKS is set TRUE, multiple bookmark support will
  716. * be forced off, and cannot be toggled on via the 'o'ptions menu.  This
  717. * compilation setting can be overridden via lynx.cfg.
  718. */
  719. #ifndef BLOCK_MULTI_BOOKMARKS
  720. #define BLOCK_MULTI_BOOKMARKS FALSE
  721. #endif /* BLOCK_MULTI_BOOKMARKS */
  722.  
  723. /********************************
  724.  * URL_DOMAIN_PREFIXES and URL_DOMAIN_SUFFIXES are strings which will be
  725.  * prepended (together with a scheme://) and appended to the first element
  726.  * of command line or 'g'oto arguments which are not complete URLs and
  727.  * cannot be opened as a local file (file://localhost/string).  Both
  728.  * can be comma-separated lists.  Each prefix must end with a dot, each
  729.  * suffix must begin with a dot, and either may contain other dots (e.g.,
  730.  * .com.jp).  The default lists are defined here, and can be changed
  731.  * in lynx.cfg.  Each prefix will be used with each suffix, in order,
  732.  * until a valid Internet host is created, based on a successful DNS
  733.  * lookup (e.g., foo will be tested as www.foo.com and then www.foo.edu
  734.  * etc.).  The first element can include a :port and/or /path which will
  735.  * be restored with the expanded host (e.g., wfbr:8002/dir/lynx will
  736.  * become http://www.wfbr.edu:8002/dir/lynx).  The prefixes will not be
  737.  * used if the first element ends in a dot (or has a dot before the
  738.  * :port or /path), and similarly the suffixes will not be used if the
  739.  * the first element begins with a dot (e.g., .nyu.edu will become
  740.  * http://www.nyu.edu without testing www.nyu.com).  Lynx will try to
  741.  * guess the scheme based on the first field of the expanded host name,
  742.  * and use "http://" as the default (e.g., gopher.wfbr.edu or gopher.wfbr.
  743.  * will be made gopher://gopher.wfbr.edu).
  744.  */
  745. #define URL_DOMAIN_PREFIXES "www."
  746. #define URL_DOMAIN_SUFFIXES ".com,.edu,.net,.org"
  747.  
  748. /********************************
  749.  * If LIST_NEWS_NUMBERS is set TRUE, Lynx will use an ordered list
  750.  * and include the numbers of articles in news listings, instead of
  751.  * using an unordered list.
  752.  *
  753.  * The default defined here can be changed in lynx.cfg.
  754.  */
  755. #define LIST_NEWS_NUMBERS FALSE
  756.  
  757. /********************************
  758.  * If LIST_NEWS_DATES is set TRUE, Lynx will include the dates of
  759.  * articles in news listings.  The dates always are included in the
  760.  * articles, themselves.
  761.  *
  762.  * The default defined here can be changed in lynx.cfg.
  763.  */
  764. #define LIST_NEWS_DATES FALSE
  765.  
  766. /*************************
  767.  * Set NEWS_POSTING to FALSE if you do not want to support posting to
  768.  * news groups via Lynx.  If left TRUE, Lynx will use its news gateway to
  769.  * post new messages or followups to news groups, using the URL schemes
  770.  * described in the "Supported URL" section of the online 'h'elp.  The
  771.  * posts will be attempted via the nntp server specified in the URL, or
  772.  * if none was specified, via the NNTPSERVER configuration or environment
  773.  * variable.  Links with these URLs for posting or sending followups are
  774.  * created by the news gateway when reading group listings or articles
  775.  * from nntp servers if the server indicates that it permits posting.
  776.  * The setting here can be changed in lynx.cfg.
  777.  */
  778. #define NEWS_POSTING TRUE
  779.  
  780. /*************************
  781.  * Define LYNX_SIG_FILE to the name of a file containing a signature which
  782.  * can be appended to email messages and news postings or followups.  The
  783.  * user will be prompted whether to append it.  It is sought in the home
  784.  * directory.  If it is in a subdirectory, begin it with a dot-slash
  785.  * (e.g., ./lynx/.lynxsig).  The definition here can be changed in lynx.cfg.
  786.  */
  787. #define LYNX_SIG_FILE ".lynxsig"
  788.  
  789. /********************************
  790.  * If USE_SELECT_POPUPS is set FALSE, Lynx will present a vertical list
  791.  * of radio buttons for the OPTIONs in SELECT blocks which lack the
  792.  * MULTIPLE attribute, instead of using a popup menu.  Note that if
  793.  * the MULTIPLE attribute is present in the SELECT start tag, Lynx
  794.  * always will create a vertical list of checkboxes for the OPTIONs.
  795.  *
  796.  * The default defined here can be changed in lynx.cfg.  It can be
  797.  * set and saved via the 'o'ptions menu to override the compilation
  798.  * and configuration defaults, and the default always can be toggled
  799.  * via the -popup command line switch.
  800.  */
  801. #define USE_SELECT_POPUPS TRUE
  802.  
  803. /********************************
  804.  * If COLLAPSE_BR_TAGS is set FALSE, Lynx will not collapse serial
  805.  * BR tags.  Note that the valid way to insert extra blank lines in
  806.  * HTML is via a PRE block with only newlines in the block.
  807.  *
  808.  * The default defined here can be changed in lynx.cfg.
  809.  */
  810. #define COLLAPSE_BR_TAGS TRUE
  811.  
  812. /********************************
  813.  * If SET_COOKIES is set FALSE, Lynx will ignore Set-Cookie headers
  814.  * in http server replies.
  815.  *
  816.  * The default defined here can be changed in lynx.cfg, and can be toggled
  817.  * via the -cookies command line switch.
  818.  */
  819. #define SET_COOKIES TRUE
  820.  
  821.  
  822. /****************************************************************
  823.  *   Section 2.   Things that you probably want to change or review
  824.  *
  825.  */
  826.  
  827. /*****************************
  828.  * The following three definitions set the number of seconds for
  829.  * pauses following statusline messages that would otherwise be
  830.  * replaced immediately, and are more important than the unpaused
  831.  * progress messages.  Those set by INFOSECS are also basically
  832.  * progress messages (e.g., that a prompted input has been cancelled)
  833.  * and should have the shortest pause.  Those set by MESSAGESECS are
  834.  * informational (e.g., that a function is disabled) and should have
  835.  * a pause of intermediate duration.  Those set by ALERTSECS typically
  836.  * report a serious problem and should be paused long enough to read
  837.  * whenever they appear (typically unexpectedly).  The default values
  838.  * defined here can be modified via lynx.cfg, should longer pauses be
  839.  * desired for braille-based access to Lynx.
  840.  */
  841. #define INFOSECS 1
  842. #define MESSAGESECS 2
  843. #define ALERTSECS 3
  844.  
  845. /******************************
  846.  * SHOW_COLOR controls whether the program displays in color by default.
  847.  */
  848. #ifdef COLOR_CURSES
  849. #define SHOW_COLOR TRUE
  850. #else
  851. #define SHOW_COLOR FALSE
  852. #endif
  853.  
  854. /******************************
  855.  * SHOW_CURSOR controls whether or not the cursor is hidden or appears
  856.  * over the current link, or current option in select popup windows.
  857.  * Showing the cursor is handy if you are a sighted user with a poor
  858.  * terminal that can't do bold and reverse video at the same time or
  859.  * at all.  It also can be useful to blind users, as an alternative
  860.  * or supplement to setting LINKS_AND_FORM_FIELDS_ARE_NUMBERED or
  861.  * LINKS_ARE_NUMBERED.
  862.  *
  863.  * The default defined here can be changed in lynx.cfg.  It can be
  864.  * set and saved via the 'o'ptions menu to override the compilation
  865.  * and configuration defaults, and the default always can be toggled
  866.  * via the -show_cursor command line switch.
  867.  */
  868. #define SHOW_CURSOR FALSE
  869.  
  870. /******************************
  871. * VERBOSE_IMAGES controls whether or not Lynx replaces the [LINK], [INLINE] and
  872. * [IMAGE] comments (for images without ALT) with filenames of these images. 
  873. * This is extremely useful because now we can determine immediately what images
  874. * are just decorations (button.gif, line.gif) and what images are important. 
  875. * The default defined here can be changed in lynx.cfg. 
  876. */ 
  877. #define VERBOSE_IMAGES FALSE 
  878.  
  879. /****************************** 
  880.  * BOXVERT and BOXHORI control the layout of popup menus.  Set to 0 if your
  881.  * curses supports line-drawing characters, set to '*' or any other character
  882.  * to not use line-drawing (e.g., '|' for vertical and '-' for horizontal).
  883.  */
  884. #ifndef HAVE_CONFIG_H
  885. #ifdef DOSPATH
  886. #define BOXVERT 0
  887. #define BOXHORI 0
  888. #else
  889. #define BOXVERT '|'
  890. /* #define BOXVERT 0 */
  891. #define BOXHORI '-'
  892. /* #define BOXHORI 0 */
  893. #endif /* DOSPATH */
  894. #endif    /* !HAVE_CONFIG_H */
  895.  
  896. /******************************
  897.  * LY_UMLAUT controls the 7-bit expansion of characters with dieresis or
  898.  * umlaut.  If defined, a digraph is displayed, e.g., auml --> ae
  899.  * Otherwise, a single character is displayed,  e.g., auml --> a
  900.  * Note that this is currently not supported with the chartrans code,
  901.  * or rather it doesn't have an effect if translations for a display
  902.  * character set are taken from one of the *.tbl files in src/chrtrans.
  903.  * One would have to modify the corresponding *.tbl file for this.
  904.  */
  905. #define LY_UMLAUT
  906.  
  907. /*******************************
  908.  * Execution links/scripts configuration.
  909.  *
  910.  * Execution links and scripts allow you to run
  911.  * local programs by activating links within Lynx.
  912.  *
  913.  * An execution link is of the form:
  914.  *
  915.  *     lynxexec:<COMMAND>
  916.  * or:
  917.  *     lynxexec://<COMMAND>
  918.  * or:
  919.  *     lynxprog:<COMMAND>
  920.  * or:
  921.  *     lynxprog://<COMMAND>
  922.  *
  923.  * where <COMMAND> is a command that Lynx will run when the link is
  924.  * activated.  The double-slash should be included if the command begins
  925.  * with an '@', as for executing VMS command files.  Otherwise, the double-
  926.  * slash can be omitted.
  927.  * Use lynxexec for commands or scripts that generate a screen output which
  928.  * should be held via a prompt to press <return> before returning to Lynx
  929.  * for display of the current document.
  930.  * Use lynxprog for programs such as mail which do require a pause before
  931.  * Lynx restores the display of the current document.
  932.  *
  933.  * Execution scripts take the form of a standard
  934.  * URL.  Extension mapping or MIME typing is used
  935.  * to decide if the file is a script and should be
  936.  * executed.  The current extensions are:
  937.  * .csh, .ksh, and .sh on UNIX systems and .com on
  938.  * VMS systems.  Any time a file of this type is
  939.  * accessed Lynx will look at the user's options
  940.  * settings to decide if the script can be executed.
  941.  * Current options include: Only exec files that
  942.  * reside on the local machine and are referenced
  943.  * with a "file://localhost" URL, All execution
  944.  * off, and all execution on.
  945.  *
  946.  * The following definitions will add execution
  947.  * capabilities to Lynx.  You may define none, one
  948.  * or both.
  949.  *
  950.  * I strongly recommend that you define neither one
  951.  * of these since execution links/scripts can represent
  952.  * very serious security risk to your system and its
  953.  * users.  If you do define these I suggest that
  954.  * you only allow users to execute files/scripts
  955.  * that reside on your local machine.
  956.  *
  957.  * YOU HAVE BEEN WARNED!
  958.  *
  959.  * Note: if you are enabling execution scripts you should
  960.  * also see src/HTInit.c to verify/change the execution
  961.  * script extensions and/or commands.
  962.  */
  963. /* #define EXEC_LINKS  */
  964. /* #define EXEC_SCRIPTS  */
  965.  
  966. /**********
  967.  * UNIX:
  968.  * =====
  969.  * CGI script support. Defining LYNXCGI_LINKS allows you to use the
  970.  *
  971.  *   lynxcgi:path
  972.  *
  973.  * URL which allows lynx to access a cgi script directly without the need for
  974.  * a http daemon. Redirection or mime support is not supported but just about
  975.  * everything else is. If the path is not an executable file then the URL is
  976.  * rewritten as file://localhost and passed to the file loader. This means that
  977.  * if your http:html files are currently set up to use relative addressing, you
  978.  * should be able to fire up your main page with lynxcgi:path and everything
  979.  * should work as if you were talking to the http daemon.
  980.  *
  981.  * Note that TRUSTED_LYNXCGI directives must be defined in your lynx.cfg file
  982.  * if you wish to place restrictions on source documents and/or paths for
  983.  * lynxcgi links.
  984.  *
  985.  * The cgi scripts are called with a fork()/execve() sequence so you don't
  986.  * have to worry about people trying to abuse the code. :-)
  987.  *
  988.  *     George Lindholm (George.Lindholm@ubc.ca)
  989.  *
  990.  * VMS:
  991.  * ====
  992.  * The lynxcgi scheme, if enabled, yields an informational message regardless
  993.  * of the path, and use of the freeware OSU DECthreads server as a local
  994.  * script server is recommended instead of lynxcgi URLs.  Uncomment the
  995.  * following line to define LYNXCGI_LINKS, and when running Lynx, enter
  996.  * lynxcgi:advice  as a G)oto URL for more information and links to the
  997.  * OSU server distribution.
  998.  */
  999. /* #define LYNXCGI_LINKS */
  1000.  
  1001. #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS)
  1002.  
  1003. /**********
  1004.  * if ALLOW_USERS_TO_CHANGE_EXEC_WITHIN_OPTIONS
  1005.  * is defined then the user will be able to change
  1006.  * the execution status within the options screen.
  1007.  */
  1008. /* #define ALLOW_USERS_TO_CHANGE_EXEC_WITHIN_OPTIONS */
  1009.  
  1010. /**********
  1011.  * if NEVER_ALLOW_REMOTE_EXEC is defined then local execution of
  1012.  * scripts or lynxexec and lynxprog URLs will only be implemented
  1013.  * from HTML files that were accessed via a "file://localhost/" URL,
  1014.  * and the options menu for "L)ocal executions links" will only
  1015.  * allow toggling between "ALWAYS OFF" and "FOR LOCAL FILES ONLY".
  1016.  */
  1017. /* #define NEVER_ALLOW_REMOTE_EXEC */
  1018.  
  1019. /*****************************
  1020.  * These are for executable shell scripts and links.
  1021.  * Set to FALSE unless you really know what you're
  1022.  * doing.
  1023.  *
  1024.  * This only applies if you are compiling with EXEC_LINKS or
  1025.  * EXEC_SCRIPTS defined.
  1026.  *
  1027.  * The first two settings:
  1028.  * LOCAL_EXECUTION_LINKS_ALWAYS_ON
  1029.  * LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE
  1030.  * specify the DEFAULT setting of the users execution link
  1031.  * options, but the user may still change those options.
  1032.  * If you do not wish the user to be able to change the
  1033.  * execution link settings you may wish to use the commandline option:
  1034.  *    -restrictions=exec_frozen
  1035.  *
  1036.  * LOCAL_EXECUTION_LINKS_ALWAYS_ON will be FALSE
  1037.  * if NEVER_ALLOW_REMOTE_EXEC has been defined.
  1038.  *
  1039.  * if LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS is
  1040.  * true all execution links will be disabled when the
  1041.  * -anonymous command line option is used.  Anonymous
  1042.  * users are not allowed to change the execution options
  1043.  * from within the Lynx options menu so you might be able
  1044.  * to use this option to enable execution links and set
  1045.  * LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE to TRUE to
  1046.  * give anonymous execution link capability without compromising
  1047.  * your system (see comments about TRUSTED_EXEC rules in
  1048.  * lynx.cfg for more information).
  1049.  *
  1050.  */
  1051. #define LOCAL_EXECUTION_LINKS_ALWAYS_ON          FALSE
  1052. #define LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE  FALSE
  1053. #define LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS FALSE
  1054.  
  1055. #endif /*  defined(EXEC_LINKS) || defined(EXEC_SCRIPTS) */
  1056.  
  1057. /*********************************
  1058.  *  MAIL_SYSTEM_ERROR_LOGGING will send a message to the owner of
  1059.  *  the information if there is one, every time
  1060.  *  that a document cannot be accessed!
  1061.  *
  1062.  *  NOTE: This can generate A LOT of mail, be warned.
  1063.  */
  1064. #define MAIL_SYSTEM_ERROR_LOGGING   FALSE  /*mail a message for every error?*/
  1065.  
  1066. /*********************************
  1067.  * If CHECKMAIL is set to TRUE, the user will be informed (via a statusline
  1068.  * message) about the existence of any unread mail at startup of Lynx, and
  1069.  * will get statusline messages if subsequent new mail arrives.  If a jumps
  1070.  * file with a lynxprog URL for invoking mail is available, or your html
  1071.  * pages include an mail launch file URL, the user thereby can access mail
  1072.  * and read the messages.  The checks and statusline reports will not be
  1073.  * performed if Lynx has been invoked with the -restrictions=mail switch.
  1074.  *
  1075.  *  VMS USERS !!!
  1076.  * New mail is normally broadcast as it arrives, via "unsolicitied screen
  1077.  * broadcasts", which can be "wiped" from the Lynx display via the Ctrl-W
  1078.  * command.  You may prefer to disable the broadcasts and use CHECKMAIL
  1079.  * instead (e.g., in a public account which will be used by people who
  1080.  * are ignorant about VMS).
  1081.  */
  1082. #define CHECKMAIL    FALSE    /* report unread and new mail messages */
  1083.  
  1084. /*********************************
  1085.  * VI_KEYS can be turned on by the user in the options
  1086.  * screen or the .lynxrc file.  This is just the default.
  1087.  */
  1088. #define VI_KEYS_ALWAYS_ON    FALSE /* familiar h,j,k, & l */
  1089.  
  1090. /*********************************
  1091.  * EMACS_KEYS can be turned on by the user in the options
  1092.  * screen or the .lynxrc file.  This is just the default.
  1093.  */
  1094. #define EMACS_KEYS_ALWAYS_ON    FALSE /* familiar ^N, ^P, ^F, ^B */
  1095.  
  1096. /*********************************
  1097.  * DEFAULT_KEYPAD_MODE specifies whether by default the user
  1098.  * has numbers that work like arrows or else numbered links
  1099.  * DEFAULT KEYPAD MODE may be set to
  1100.  *    NUMBERS_AS_ARROWS   or
  1101.  *    LINKS_ARE_NUMBERED  or
  1102.  *    LINKS_AND_FORM_FIELDS_ARE_NUMBERED
  1103.  */
  1104. #define DEFAULT_KEYPAD_MODE    NUMBERS_AS_ARROWS
  1105.  
  1106. /********************************
  1107.  * The default search.
  1108.  * This is a default that can be overridden by the user!
  1109.  */
  1110. #define CASE_SENSITIVE_ALWAYS_ON    FALSE /* case sensitive user search */
  1111.  
  1112. /********************************
  1113.  * If NO_DOT_FILES is set TRUE here or in lynx.cfg, the user will not be
  1114.  * allowed to specify files beginning with a dot in reply to output filename
  1115.  * prompts, and files beginning with a dot (e.g., file://localhost/foo/.lynxrc)
  1116.  * will not be included in the directory browser's listings.  The setting here
  1117.  * will be overridden by the setting in lynx.cfg.  If FALSE, you can force it
  1118.  * to be treated as TRUE via -restrictions=dotfiles (or -anonymous, which sets
  1119.  * this and most other restrictions).
  1120.  *
  1121.  * If it's FALSE at startup of Lynx, the user can regulate it via the
  1122.  * 'o'ptions menu, and may save the preference in the RC file.
  1123.  */
  1124. #define NO_DOT_FILES    TRUE  /* disallow access to dot files */
  1125.  
  1126. /********************************
  1127.  * If MAKE_LINKS_FOR_ALL_IMAGES is TRUE, all images will be given links
  1128.  * which can be ACTIVATEd.  For inlines, the ALT or pseudo-ALT ("[INLINE]")
  1129.  * strings will be links for the resolved SRC rather than just text.  For
  1130.  * ISMAP or other graphic links, the ALT or pseudo-ALT ("[ISMAP]" or "[LINK]")
  1131.  * strings will have '-' and a link labeled "[IMAGE]" for the resolved SRC
  1132.  * appended.
  1133.  *
  1134.  * The default defined here can be changed in lynx.cfg, and the user can
  1135.  * use LYK_IMAGE_TOGGLE to toggle the feature on or off at run time.
  1136.  *
  1137.  * The default also can be toggled via an "-image_links" command line switch.
  1138.  */
  1139. #define MAKE_LINKS_FOR_ALL_IMAGES    FALSE /* inlines cast to links */
  1140.  
  1141. /********************************
  1142.  * If MAKE_PSEUDO_ALTS_FOR_INLINES is FALSE, inline images which do not
  1143.  * specify an ALT string will not have "[INLINE]" inserted as a pseudo-ALT,
  1144.  * i.e., they'll be treated as having ALT="".  If MAKE_LINKS_FOR_ALL_IMAGES
  1145.  * is defined or toggled to TRUE, however, the pseudo-ALTs will be created
  1146.  * for inlines, so that they can be used as links to the SRCs.
  1147.  *
  1148.  * The default defined here can be changed in lynx.cfg, and the user can
  1149.  * use LYK_INLINE_TOGGLE to toggle the feature on or off at run time.
  1150.  *
  1151.  * The default also can be toggled via a "-pseudo_inlines" command line
  1152.  * switch.
  1153.  */
  1154. #define MAKE_PSEUDO_ALTS_FOR_INLINES    TRUE /* Use "[INLINE]" pseudo-ALTs */
  1155.  
  1156. /********************************
  1157.  * If SUBSTITUTE_UNDERSCORES is TRUE, the _underline_ format will be used
  1158.  * for emphasis tags in dumps.
  1159.  *
  1160.  * The default defined here can be changed in lynx.cfg, and the user can
  1161.  * toggle the default via a "-underscore" command line switch.
  1162.  */
  1163. #define SUBSTITUTE_UNDERSCORES    FALSE /* Use _underline_ format in dumps */
  1164.  
  1165. /********************************
  1166.  * If QUIT_DEFAULT_YES is defined as TRUE then when the QUIT command
  1167.  * is entered, any response other than n or N will confirm.  Define it
  1168.  * as FALSE if you prefer the more conservative action of requiring an
  1169.  * explicit Y or y to confirm.  The default defined here can be changed
  1170.  * in lynx.cfg.
  1171.  */
  1172. #define QUIT_DEFAULT_YES    TRUE
  1173.  
  1174. /********************************
  1175.  * These definitions specify files created or used in conjunction
  1176.  * with traversals.  See CRAWL.ANNOUNCE for more infomation.
  1177.  */
  1178. #define TRAVERSE_FILE "traverse.dat"
  1179. #define TRAVERSE_FOUND_FILE "traverse2.dat"
  1180. #define TRAVERSE_REJECT_FILE "reject.dat"
  1181. #define TRAVERSE_ERRORS "traverse.errors"
  1182.  
  1183. /****************************************************************
  1184.  * The LYMessages_en.h header defines default, English strings
  1185.  * used in statusline prompts, messages, and warnings during
  1186.  * program execution.  See the comments in LYMessages_en.h for
  1187.  * information on translating or customizing them for your site.
  1188.  */
  1189. #ifndef HTTELNET_H
  1190. #include "LYMessages_en.h"
  1191. #endif /* !HTTELNET_H */
  1192.  
  1193.  
  1194. /****************************************************************
  1195.  *   Section 3.   Things that you should not change until you
  1196.  *            have a good knowledge of the program
  1197.  */
  1198.  
  1199. #define LYNX_NAME "Lynx"
  1200. /* The strange-looking comments on the next line tell PRCS to replace
  1201.  * the version definition with the Project Version on checkout. Just
  1202.  * ignore it. - kw */
  1203. /* $Format: "#define LYNX_VERSION \"$ProjectVersion$\""$ */
  1204. #define LYNX_VERSION "2.8.1dev.10"
  1205.  
  1206. #ifndef MAXINT
  1207. #define MAXINT 2147483647    /* max integer */
  1208. #endif /* !MAXINT */
  1209. #define MAXBASE 100        /* max length of base directory */
  1210. #define MAXHIGHLIGHT 160    /* max length of highlighted text */
  1211. #define MAXTARGET 130        /* max length of target string */
  1212. #define LINESIZE 1024        /* max length of line to read from file */
  1213. #define MAXFNAME 1280        /* max filename length DDD/FILENAME.EXT */
  1214. #define MAXCOMMAND MAXFNAME    /* max length of command should be the same */
  1215. #define MAXHIST  1024        /* max links we remember in history */
  1216. #define MAXLINKS 1024        /* max links on one screen */
  1217.  
  1218. #ifndef SEARCH_GOAL_LINE
  1219. #define SEARCH_GOAL_LINE 4    /* try to position search target there */
  1220. #endif
  1221.  
  1222. #define MAXCHARSETS 60        /* max character sets supported */
  1223. #define MAXCHARSETSP 61        /* always one more than MAXCHARSETS */
  1224.  
  1225. /* Win32 may support more, but old win16 helper apps may not. */
  1226. #if defined(__DJGPP__) || defined(_WINDOWS)
  1227. #define FNAMES_8_3
  1228. #endif
  1229.  
  1230. #ifdef FNAMES_8_3
  1231. #define HTML_SUFFIX ".htm"
  1232. #else
  1233. #define HTML_SUFFIX ".html"
  1234. #endif
  1235.  
  1236. #ifdef VMS
  1237. /*
  1238. **  Use the VMS port of gzip for uncompressing both .Z and .gz files.
  1239. */
  1240. #define UNCOMPRESS_PATH  "gzip -d"
  1241. #define GZIP_PATH "gzip"
  1242.  
  1243. #else
  1244.  
  1245. #ifdef DOSPATH
  1246. /*  Something has to be defined for this or we don't compile. */
  1247. #define SYSTEM_MAIL "sendmail"
  1248. #define SYSTEM_MAIL_FLAGS "-t -oi"
  1249. /*
  1250. **  Following executables may be sought from your PATH at run-time.
  1251. **  To get those programs look for GNU-port stuff elsewhere.
  1252. **  Currently, if compiled with -DUSE_ZLIB (default), you need only "cp"
  1253. **
  1254. **    WINDOWS
  1255. **  ===========
  1256. */
  1257. #define COMPRESS_PATH   "compress"
  1258. #define UNCOMPRESS_PATH "uncompress"
  1259. #define UUDECODE_PATH   "uudecode"
  1260. #define ZCAT_PATH       "zcat"
  1261. #define GZIP_PATH       "gzip"
  1262. #define INSTALL_PATH    "install"
  1263. #define TAR_PATH        "tar"
  1264. #define TOUCH_PATH      "touch"
  1265.  
  1266. /*
  1267. **    WINDOWS/DOS
  1268. **  ===========
  1269. */
  1270. #define ZIP_PATH        "zip"
  1271. #define UNZIP_PATH      "unzip"
  1272. #define MKDIR_PATH      "mkdir"
  1273. #define MV_PATH         "mv"
  1274. #define RM_PATH         "rm"
  1275. #define COPY_PATH       "cp"
  1276. #define CHMOD_PATH      "chmod"
  1277.  
  1278. #else    /* Unix */
  1279.     /* this is done via the configure script */
  1280. #endif /* DOSPATH */
  1281. #endif /* VMS */
  1282.  
  1283.  
  1284. /****************************************************************
  1285.  *  Section 4.  Things you MUST check only if you plan to use Lynx
  1286.  *              in an anonymous account (allow public access to Lynx).
  1287.  *              This section may be skipped by those people building
  1288.  *              Lynx for private use only.
  1289.  *
  1290.  */
  1291.  
  1292. /*****************************
  1293.  * Enter the name of your anonymous account if you have one
  1294.  * as ANONYMOUS_USER.  UNIX systems will use a cuserid
  1295.  * or get_login call to determine if the current user is
  1296.  * the ANONYMOUS_USER.  VMS systems will use getenv("USER").
  1297.  *
  1298.  * You may use the "-anonymous" option for multiple accounts,
  1299.  * or for precautionary reasons in the anonymous account, as well.
  1300.  *
  1301.  * Specify privileges for the anonymous account below.
  1302.  *
  1303.  * It is very important to have this correctly defined or include
  1304.  * the "-anonymous" command line option for invocation of Lynx
  1305.  * in an anonymous account!  If you do not you will be putting
  1306.  * yourself at GREAT security risk!
  1307.  */
  1308. #define ANONYMOUS_USER ""
  1309.  
  1310. /*******************************
  1311.  * In the following four pairs of defines,
  1312.  * INSIDE_DOMAIN means users connecting from inside your local domain,
  1313.  * OUTSIDE_DOMAIN means users connecting from outside your local domain.
  1314.  *
  1315.  * set to FALSE if you don't want users of your anonymous
  1316.  * account to be able to telnet back out
  1317.  */
  1318. #define CAN_ANONYMOUS_INSIDE_DOMAIN_TELNET    TRUE
  1319. #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_TELNET    FALSE
  1320.  
  1321. /*******************************
  1322.  * set to FALSE if you don't want users of your anonymous
  1323.  * account to be able to use ftp
  1324.  */
  1325. #define CAN_ANONYMOUS_INSIDE_DOMAIN_FTP        TRUE
  1326. #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_FTP    FALSE
  1327.  
  1328. /*******************************
  1329.  * set to FALSE if you don't want users of your anonymous
  1330.  * account to be able to use rlogin
  1331.  */
  1332. #define CAN_ANONYMOUS_INSIDE_DOMAIN_RLOGIN    TRUE
  1333. #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_RLOGIN    FALSE
  1334.  
  1335. /*******************************
  1336.  * set to FALSE if you don't want users of your anonymous
  1337.  * account to be able to read news
  1338.  */
  1339. #define CAN_ANONYMOUS_INSIDE_DOMAIN_READ_NEWS    TRUE
  1340. #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_READ_NEWS    FALSE
  1341.  
  1342. /*******************************
  1343.  * set to FALSE if you don't want users of your anonymous
  1344.  * account to be able to goto random URLs. (The 'g' command)
  1345.  */
  1346. #define CAN_ANONYMOUS_GOTO        TRUE
  1347.  
  1348. /*******************************
  1349.  * set to FALSE if you don't want users of your anonymous
  1350.  * account to be able to goto particular URLs.
  1351.  */
  1352. #define CAN_ANONYMOUS_GOTO_CSO        FALSE
  1353. #define CAN_ANONYMOUS_GOTO_FILE        FALSE
  1354. #define CAN_ANONYMOUS_GOTO_FINGER    TRUE
  1355. #define CAN_ANONYMOUS_GOTO_FTP        FALSE
  1356. #define CAN_ANONYMOUS_GOTO_GOPHER    FALSE
  1357. #define CAN_ANONYMOUS_GOTO_HTTP        TRUE
  1358. #define CAN_ANONYMOUS_GOTO_HTTPS    FALSE
  1359. #define CAN_ANONYMOUS_GOTO_LYNXCGI    FALSE
  1360. #define CAN_ANONYMOUS_GOTO_LYNXEXEC    FALSE
  1361. #define CAN_ANONYMOUS_GOTO_LYNXPROG    FALSE
  1362. #define CAN_ANONYMOUS_GOTO_MAILTO    TRUE
  1363. #define CAN_ANONYMOUS_GOTO_NEWS        FALSE
  1364. #define CAN_ANONYMOUS_GOTO_NNTP        FALSE
  1365. #define CAN_ANONYMOUS_GOTO_RLOGIN    FALSE
  1366. #define CAN_ANONYMOUS_GOTO_SNEWS    FALSE
  1367. #define CAN_ANONYMOUS_GOTO_TELNET    FALSE
  1368. #define CAN_ANONYMOUS_GOTO_TN3270    FALSE
  1369. #define CAN_ANONYMOUS_GOTO_WAIS        TRUE
  1370.  
  1371. /*******************************
  1372.  * set to FALSE if you don't want users of your anonymous
  1373.  * account to be able to specify a port in 'g'oto commands
  1374.  * for telnet URLs.
  1375.  */
  1376. #define CAN_ANONYMOUS_GOTO_TELNET_PORT    FALSE
  1377.  
  1378. /*******************************
  1379.  * set to FALSE if you don't want users of your anonymous
  1380.  * account to be able to jump to URLs (The 'J' command)
  1381.  * via the shortcut entries in your JUMPFILE.
  1382.  */
  1383. #define CAN_ANONYMOUS_JUMP    FALSE
  1384.  
  1385. /*******************************
  1386.  * set to FALSE if you don't want users of your anonymous
  1387.  * account to be able to mail
  1388.  */
  1389. #define CAN_ANONYMOUS_MAIL    TRUE
  1390.  
  1391. /*******************************
  1392.  * set to FALSE if you don't want users of your anonymous
  1393.  * account to be able to print
  1394.  */
  1395. #define CAN_ANONYMOUS_PRINT    FALSE
  1396.  
  1397. /*****************************
  1398.  * Be sure you have read about and set defines above in Sections
  1399.  * 1, 2 and 3 that could  affect Lynx in an anonymous account,
  1400.  * especially LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS.
  1401.  *
  1402.  * This ends the section specific to anonymous accounts.
  1403.  */
  1404.  
  1405. #endif /* USERDEFS_H */
  1406.