diff --git a/ACKNOWLG b/ACKNOWLG index f21eaf0..b3ffc2b 100644 --- a/ACKNOWLG +++ b/ACKNOWLG @@ -1,46 +1,55 @@ -ACKNOWLEDGEMENTS for MHonArc - - - -I would like to thank everyone who has given feedback on MHonArc. -Sorry for not listing everyone, but it has become too hard to keep -track of all the names. However, I'd like to give special thanks to -the following: - - A. P. Barrett - For developing a base64 library. The library has been adapted - to decode base64 messages by MHonArc. - - Susie Blackstock - For helping me with the documentation. Any problems with the - documentation is purely my fault. - - Achim Bohnet - For his help in testing, and contributing to, mhonarc and for - setting up the mhonarc mailing list. - - Roman Czyborra - For his help with the MosaicMail script. - - Timothy Finin - Whose initial feedback on mbox2html (my first mail->HTML - program) caused the ball rolling on developing a more complete - mail-to-HTML program. - - Ken Harward - For helping me tackle Perl problems and for bouncing ideas - off. - - Phyllis Imperatrice - For the initial sketch of the MHonArc logo. - - Steve Pacenka - For his great help in getting MHonArc to run under MS-DOS, and - for his help in trouble-shooting. - - NIIBE Yutaka - For the contribution of a text/plain filter to process - ISO-2022 encoded mail messages (ie. Japanese character set). - ---------------------------------------------------------------------------- -Earl Hood, ehood@isogen.com +ACKNOWLEDGEMENTS for MHonArc + + http://www.oac.uci.edu/indiv/ehood/mhonarc.html + +I would like to thank everyone who has given feedback on MHonArc. +Sorry for not listing everyone, but it has become too hard to keep +track of all the names. However, I'd like to give special thanks to +the following: + + A. P. Barrett + For developing a base64 library. The library has been adapted + to decode base64 messages by MHonArc. + + Susie Blackstock + For helping me with the documentation. Any problems with the + documentation is purely my fault. And she's cute too. + + Achim Bohnet + For his help in testing, and contributing to, mhonarc and for + setting up, and maintaining, the mhonarc mailing list. + + Roman Czyborra + For his help with the MosaicMail script. + + Timothy Finin + Whose initial feedback on mbox2html (my first mail->HTML + program) caused the ball rolling on developing a more complete + mail-to-HTML program. + + Stephen Franlin + For providing the machine facilities for housing the MHonArc + home page. + + Ken Harward + For helping me tackle Perl problems and for bouncing ideas + off. + + Phyllis Imperatrice + For the initial sketch of the MHonArc logo. + + Steve Pacenka + For his great help in getting MHonArc to run under MS-DOS, and + for his help in trouble-shooting. + + Achille Petrilli + For his initial patches for MacPerl support to get the + ball rolling for MacPerl usage. + + NIIBE Yutaka + For the contribution of a text/plain filter to process + ISO-2022 encoded mail messages (ie. Japanese character set). + +--------------------------------------------------------------------------- +Earl Hood, ehood@medusa.acs.uci.edu +@(#) ACKNOWLG 97/05/14 19:06:19 @(#) diff --git a/BUGS b/BUGS new file mode 100644 index 0000000..8311291 --- /dev/null +++ b/BUGS @@ -0,0 +1,216 @@ + BUGS 97/05/22 18:54:46 + Bug History for MHonArc + +Each bug listing has the following fields: + + Version: Lists the version of MHonArc that the bug was + reported against. + Problem: A description of the bug. + Solution: A description of what was done to fix the bug. + Version Fixed: The version that the solution exists in, if + applicable. + + +Bug List +------------------------------------------------------------------------ +Version: 2.0.0 +Problem: Bogus empty entry shows up in the database. Bogus + entry appears if a duplicate message is detected. + Potential visible problems of bogus entry are: mailto + links in headers corrupted; a blank listing in the + index. Maybe other potential problems. +Solution: There is a be a bug in some versions of Perl where a + hash key gets added invalidly. The section of code that + this occurs has been modified to avoid the problem. + For existing databases with a bogus empty entry, + MHonArc now removes any empty key entries. + However, it is recommed to rebuild the archive. +Version Fixed: 2.0.1 +------------------------------------------------------------------------ +Version: 2.0.0 +Problem: Index pages are not properly updated if zero messages + are in the archive (like through the -rmm option). + Even -editidx cannot cause a proper update. +Solution: Page count was set to zero when no messages exist. This + caused problems in conditional checks in the write index + routines. To fix, page count is forced to 1 if their + are no messages. +Version Fixed: 2.0.1 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Index pages with last page links are not updated + when a new page is added. +Solution: All index pages are regenerated if a new page + is added. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: "-idxsize 0" does not give unlimited page size. +Solution: Problem fixed and now works as documented. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: "-maxsize 0" does not reset archive with + unlimited messages allowed. +Solution: Problem fixed and now works as documented. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Non-ASCII text encodings (=?ISO-..?...) are not + properly decoded when EDITIDX is set. +Solution: The charset filter libraries are now loaded + for EDITIDX. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: MODTIME resource setting not remembered across + archive updates. +Solution: MODTIME resource is now properly stored in the + database. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Specifying -rmm and -single caused confusion on + what MHonArc does. +Solution: The case is properly handled, with -rmm taking + precedence. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: 4 digit year not checked before 2 digit year + when parsing dates. +Solution: Fixed. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Some index pages in multipage indexes not + updated when messages expire. +Solution: Fixed; all pages are regenerated when a message + expires. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Setting MONTHS and MONTHSABR had no effect. +Solution: Fixed. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: $TNEXTFROM$ actually gave the value of $NEXTFROM$. +Solution: Fixed. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Numerical timezone offsets not handled properly + when the offset contained non-zero minutes. This + caused message to be sorted wrong by date. +Solution: Fixed. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Some characters were not properly escaped when + specifying the "in URL" modifier to a resource + variable. +Solution: Fixed. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: Thread (formatting) information lost when a + thread is split across multiple pages. +Solution: Fixed. New resources (TCONTBEGIN, TCONTEND, + TINDENTBEGIN, TINDENTEND) exist to preserve + formatting of threads across pages. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 3 +Problem: If specifying the REVERSE resource, the next/prev + links in messages do not point to the proper + message as one may expect. +Solution: This should be fixed by the new behavior of + $NEXT...$ and $PREV...$ resource variables. +Version Fixed: 2.0.0 +------------------------------------------------------------------------ +Version: 2.0.0 beta 2 +Problem: Perl aborts with message "Undefined subroutine + &main::output_db called ..." when the GENIDX resource + is set. +Solution: Fixed. The output_db function is not applicable when + GENIDX is active. +Version Fixed: 2.0.0 beta 3 +------------------------------------------------------------------------ +Version: 2.0.0 beta 2 +Problem: Duplicate resource filenames are not removed from the + OTHERINDEXES resource. This caused duplicate work + to be performed. +Solution: Fixed. Any duplicate filenames are removed before + applying the OTHERINDEXES resource. +Version Fixed: 2.0.0 beta 3 +------------------------------------------------------------------------ +Version: 2.0.0 beta 2 +Problem: Indexes created via the OTHERINDEXES resource contain + no messages. +Solution: Fixed. +Version Fixed: 2.0.0 beta 3 +------------------------------------------------------------------------ +Version: 2.0.0 beta 2 +Problem: The markup defined by TSUBLISTEND may appear when there + is no corresponding TSUBLISTBEG. +Solution: Fixed. +Version Fixed: 2.0.0 beta 3 +------------------------------------------------------------------------ +Version: 2.0.0 beta 1 +Problem: A multipart boundary specified with a capital boundary + parameter, and not in quotes, was not recognized. +Solution: Fixed +Version Fixed: 2.0.0 beta 2 +------------------------------------------------------------------------ +Version: 1.2.3 +Problem: Generation of links of message-ids when editting + messages w/o consideration that the message-ids + may already be linked. This caused nested anchor + markup. +Solution: Fixed. Only new message-ids are checked for. +Version Fixed: 2.0.0 beta 1 +------------------------------------------------------------------------ +Version: 1.2.2 +Problem: The ';' character may appear in derived files if the + "usename" option is set for the mhexternal.pl filter. +Solution: Fixed. +Version Fixed: 1.2.3 +------------------------------------------------------------------------ +Version: 1.2.2 +Problem: The '/' character is not properly recognized in e-mail + addresses when e-mail addressess are being converted + to mailto links in message headers. +Solution: Fixed. +Version Fixed: 1.2.3 +------------------------------------------------------------------------ +Version: 1.2.2 +Problem: Database read failures occur in add operations on + MS-DOS systems. +Solution: Fixed (?) +Version Fixed: 1.2.3 +------------------------------------------------------------------------ +Version: 1.2.1 +Problem: The TIDXPGEND resource actually sets the value of the + TIDXPGBEG resource. +Solution: Fixed. +Version Fixed: 1.2.2 +------------------------------------------------------------------------ +Version: 1.2.0 +Problem: MHonArc will abort execution under MS-DOS due to + regular expression error. +Solution: Fixed. +Version Fixed: 1.2.1 +------------------------------------------------------------------------ +Version: 1.2.0 +Problem: install.me will abort execution under MS-DOS due to + regular expression error. +Solution: Fixed. +Version Fixed: 1.2.1 +------------------------------------------------------------------------ +Version: 1.2.0 +Problem: A reverse index listing is incorrect if the index size + is less than the archive size. +Solution: Fixed. +Version Fixed: 1.2.1 +------------------------------------------------------------------------ diff --git a/CHANGES b/CHANGES index 417e31a..f7b26c1 100644 --- a/CHANGES +++ b/CHANGES @@ -1,477 +1,942 @@ -CHANGES for MHonArc - - - -Revision history for MHonArc. Changes listed are brief. Consult -the documentation for further information/clarification. - -MM/DD/YY -======================================================================= -####################################################################### -======================================================================= -07/12/96 (1.2.3) - - o Extracted initialization of data structures into mhinit.pl. - The file is just required from the main source. - - o Use q{} instead of qq{} when trying to read database file. - Should fix require problem under MS-DOS. - - o Added comments at beginning - of messages. May aid in database recovery techniques. - - o ';'s are now deleted in filenames in mhexternal.pl - (applicable only when "usename" option specified) - - o Added recognition of '/' when converted e-mail addresses - to mailto links in message headers. - - o Simple fix to mhtxt2022.pl for execution under Perl 5. - -======================================================================= -####################################################################### -======================================================================= -04/18/96 (1.2.2) - - o Increased the speed performance of base64 decoding. Speed - increase is much greater under Perl 4 than Perl 5. - - o Added -time option to print out total CPU execution time. - Mainly used for debugging reasons (like checking on - base64 decoding times). Time information is sent to - standard error. - - o Added M2H_LOCKDELAY envariable and -lockdelay option. - Either can be used to adjust the sleep time between - attempts to lock the archive. - - o Added -force option to override a lock on an archive if - attempts to lock fail. - - o Added image/x-bmp and image/x-pcx to the default supported - MIME types. - - o Ignore "Sv:" at the beginning of subjects when sorting by - subject. "Sv:" is Danish for "Re:". - - o Fixed bug in mhutil.pl where TIDXPGEND actually set - TIDXPGBEG. - - o Dynamically define exclude_field routine after reading - user options. exclude_field is utilized when formatting - a message header in HTML. Defining the routine at run-time - helps reduce the regular expression overhead the old version - of the routine entailed. There should be an increase in - overall execution time. - -======================================================================= -03/22/96 (1.2.1) - - o Added support for x-uuencode content-transfer-encoding. - - o Added -locktries command-line option. - - o Added the resource variable $OUTDIR$. - - o mhexternal.pl filter will use the name parameter string - on the content-type field as the anchor text to the file - if there is no content-description. - - o application/x-patch is recognized and processed by the - text/plain filter (mhtxtplain.pl). - - o Fixed bug in install.me and osinit.pl where setting - $'PROG caused perl to terminate if $'DIRSEP was a backslash - (occured under MS-DOS usage). - - o Fixed bug in install.me in the create_dir routine. - If $DIRSEP was a backslash, the regular expression setting - @a would cause perl to abort with an error. - - o Fixed database bug where the MIMEARGS resource setting - was not being stored. - - o Fixed index listing bug where a reverse listing was not - correct if an index size was specified less than the - current size of the archive. - -======================================================================= -03/01/96 (1.2.0) - - o Rewrote message parser routine so it will work under Perl 5 - for multipart messages. The rewrite also allows some - additional features that are mentioned below. - - o The -mbox and -mh options are no longer required. MHonArc - will automatically determine which mode to operate in - based upon the file arguments. Hence, one can specify - MH folders and mailbox files on the same command-line. - Both options are ignored if specified. - - o An HTML index of an archive contents can be generated to - standard output (-genidx). - - o Message header lines not conforming to RFC 822 are ignored. - (Eg: Those pesky "From " lines should not show up anymore -- - please do not confuse this with the regular "From:" lines; - note the colon vs the space). - - o New resources: - - BOTLINKS - May be used to completely customize - the links at the bottom of messages. - IDXPGBEGIN - Opening markup for main index page. - Allows one to redefine opening HTML - element, HEAD element, TITLE element, - opening BODY element, etc. - IDXPGEND - Closing markup for main index page. - IDXSIZE - Set the maximum number of messages - listed in index. This is different - in MAXSIZE where MAXSIZE will remove - older messages when the MAXSIZE limit - is reached in the archive. - MIMEARGS - Define arguments to filters - MSGPGBEGIN - Opening markup for message pages. - Allows one to redefine opening HTML - element, HEAD element, TITLE element, - opening BODY element, etc. - MSGPGEND - Closing markup for message pages. - NEXTBUTTON - Defines the 'Next' button. - NEXTBUTTONIA - Defines the 'Next' button when it is - inactive. - NEXTLINK - Defines the 'Next' link. - NEXTLINKIA - Defines the 'Next' link when it is - inactive. - NOTSUBSORT - Do not sort threads by subject. - OTHERINDEXES - List other resource files defining - other indexes to create when creating, - or updating, an archive. - PREVBUTTON - Defines the 'Prev' button. - PREVBUTTONIA - Defines the 'Prev' button when it is - inactive. - PREVLINK - Defines the 'Prev' link. - PREVLINKIA - Defines the 'Prev' link when it is - inactive. - TIDXPGBEGIN - Opening markup for thread index page. - Allows one to redefine opening HTML - element, HEAD element, TITLE element, - opening BODY element, etc. - TIDXPGEND - Closing markup for thread index page. - TOPLINKS - May be used to completely customize - the buttons at the top of messages. - TSUBSORT - Sort threads listed by subject. - - o Removed resources: - - INDEXBL, INDEXFL, MBOX, MH, NEXTBL, NEXTFL, PREVBL, - PREVFL, TINDEXBL, TINDEXFL - - Resource were removed because they were no longer applicable - and/or have been superceded by other resources. MHonArc - will still honor old resource settings (where applicable) of - older archives and incorporate them into the new resource - settings. - - o When specifying the resource file, mhonarc will now do - the following to determine its location: - - 1. If its an absolute pathname, mhonarc uses it. - 2. If it is a relative pathname, mhonarc checks for - it relative to the current working directory. - 3. Otherwise, mhonarc checks for it relative to - location of the archive as specified by outdir. - - This resolution will allow you to place resource files with - the archive if desired (can be useful when using the - OTHERINDEXES resource element). - - o Because of the new resources available, many
's are no - longer hard-coded and are controllable by resources.
's - are still used in message pages to separate message data - from mhonarc data. - - o Added resource variables: - (NOTE: Some variables are only valid in certain contexts) - - $DDMMYY$ - Date of message in dd/mm/yy format - $IDXSIZE$ - Max size of index list - $MMDDYY$ - Date of message in mm/dd/yy format - $MSGID$ - Message id - $NEXTBUTTON$ - Next button markup - $NEXTFROM$ - From field of next listed message - $NEXTFROMADDR$ - From e-mail address of next listed message - $NEXTFROMNAME$ - From name of next listed message - $NEXTLINK$ - Next link markup - $NEXTMSGNUM$ - Number of next listed message - $NEXTSUBJECT$ - Subject text of next listed message - $NUMOFIDXMSG$ - Number of messages in index list - $PREVBUTTON$ - Previous button markup - $PREVFROM$ - From field of previous listed message - $PREVFROMADDR$ - From e-mail address of prev listed message - $PREVFROMNAME$ - From name of previous listed message - $PREVLINK$ - Previous link markup - $PREVMSGNUM$ - Number of previous message - $PREVSUBJECT$ - Subject text of previous listed message - $YYMMDD$ - Date of message in yy/mm/dd format - - o Can specify a 'U' with variable length specifier to denote - replacement string is to be used in a URL. Examples: - - $SUBJECTNA:40U$ - $MSGID:U$ - - The 'U' causes the replace text to have special characters - escaped as denoted by the URL spec. NOTE: Specify ":U" - should NOT be used in the MAILTOURL resource; the variables - will automatically be expanded according to the URL spec. - Specifyind ":U" or a length specifier in the MAILTOURL - resource will prevent mhonarc from detecting the variable. - - o New command-line options: - - -genidx - Generate HTML index of archive contents - to stdout. - -idxsize - Maximum number of messages shown in indexes - -notsubsort - Do not sort threads listed by subject. - -savemem - Write message data while processing - -tsubsort - Sort threads listed by subject. - - o The library mhtxt2022.pl has been added that provides - a filter to process ISO-2022 (Japanese) encoded mail messages. - See mhtxt2022.pl on how to hook it in. - - o The mhexternal.pl filter by default ignores any filename - specification in the message for creating derived files. - This avoids name conflicts and security problems. - The "usename" filter option may be used to override this. - - o Mime filters are now called with two additional arguments: - - $converted_data = &function( - $header, *parsed_header_assoc_array, - *message_data, $decoded_flag, - $optional_filter_arguments); - - The $decoded_flag is set to 1 if the *message_data has been - decoded. $optional_filter_arguments contains an optional - argument string as determined by the filter. - - o Mime filters can now be registered for multipart types - and message types. This allows one to override mhonarc's - conversion of these types, and completely replace mhonarc's - message->HTML conversion process. - - o Mime filters should now use $'FieldSep instead of $'X for - accessing parsed message headers. - - o Mime filters can be registered for a base type. Ie. - It is no longer required to explicitly list each possible - subtype if a single filter is to be used for them all. - Example: - - - image/*:myfilter'imagefilter:myfilter.pl - - - Registers "myfilter'filter" for all image data types, - regardless of subtype. However, if an explicit entry - exists for a subtype, then that filter is called. - Example: - - - image/*:myfilter'imagefilter:myfilter.pl - image/gif:myfilter'giffilter:myfilter.pl - - - "myfilter'giffilter" is called for all image/gif data. - "myfilter'imagefilter" is called for all other image data. - - o A new resource, MIMEARGS, may be used to pass optional arguments - to filters to control their behavior. The format of the - argument string is controlled by the various filters. The - arguments can be specified by a specific content-type, or - for the filter routine in general. A content-type argument - will be used over any arguments specified for a filter. - - Example usage: - - - image/gif:inline usename - m2h_external'filter:usename - - - See the documentation for possible arguments to filters. - - o Installation program can now be invoked in batch mode. - - o Thread index properly includes docurl as main index. - -nodocurl will prevent the inclusion as with the main index. - - o Fixed bug in mhtxthtml.pl on properly propogating a base - URL to relative URLs starting with a "/". - - o Fixed bug where single quotes, and backslashed in keys of - associative arrays in the database file were not getting - escaped. - - o Fixed bug where spaces and special characters were not - properly escaped in URL strings: spaces were left as-is, - and special characters were deleted. - - o Removed illegal invocation choices in the Synopsis of the - documentation. - -======================================================================= -04/24/95 (1.1.1) - - o Fixed bug in -scan output where month in date was off by - one. - -======================================================================= -04/21/95 (1.1.0) - - o Made modifications to make MHonArc suitable to run - under MS-DOS without modification. MHonArc will - automatically detect if it is running under Unix or MS-DOS. - - o Added support for a thread index. MHonArc will create a - complimentary index to the main index showing message - threads. - - o Archive messages can be deleted. - - o A listing to stdout of an archives contents can be - generated. - - o Maximum number of messages for an archive can be set. - Older messages (based on sort method) are removed - automatically during add operations. - - o MHonArc will now recognize if you try to add in a message - that already exists in an archive. - - o The -editdx option will now also cause a updating of all - mail messages. Guarantees resource changes to affect all - messages. - - o Added the following resource file elements: - - MSGFOOT -- Footer text for converted messages - MSGHEAD -- Header text for converted messages - NODOC -- Do not put link to documentation - NOTHREAD -- Do not create thread index - TFOOT -- Text at bottom of thread index page - THEAD -- Text at top of thread index page - THREAD -- Create thread index - TLEVELS -- Depth of thread listing - TLITXT -- Template text for entry in thread - index - TIDXFNAME -- Thread index filename - TINDEXBL -- Top button label in messages to - thread index - TINDEXFL -- Verbose label in message to thread - index - TTITLE -- Title of thread index page - - o Added the following command-line options: - - -maxsize -- Maxinum # messages in an archive - -nodoc -- Do not put link to documentation - -nothread -- Do not create thread index - -rmm -- Remove messages from an archive - -scan -- Listing of archive to stdout - -thread -- Create thread index - -tidxfname -- Thread index filename - -tlevels -- Depth of thread listing - -ttitle -- Title of thread index page - - o Added the following environment variables: - - M2H_MAXSIZE -- Maxinum # messages in an archive - M2H_THREAD -- If non-zero, create thread index - M2H_TIDXFNAME -- Thread index filename - M2H_TLEVELS -- Depth of thread listing - M2H_TTITLE -- Title of thread index page - - o Added the following variables for template resources - (applicability of variables vary depending on the resource): - - $DOCURL$ -- URL to documentation - $IDXFNAME$ -- Main index page filename - $IDXTITLE$ -- Main index page title - $NEXTMSG$ -- Next message filename - $PREVMSG$ -- Previous message filename - $PROG$ -- Program name - $TIDXFNAME$ -- Thread index page filename - $TIDXTITLE$ -- Thread index page title - $VERSION$ -- Version number of the program - - o Added $FROM$, $MSGID$, and $SUBJECT$ variables to be used - in the MAILTOURL resource. - - o The string `$$' in template resources will produce a `$' in - the output. - - o Fixed problem with messages (with follow-ups) getting - unnecessarily updated when messages are added to an archive. - - o Only a CR/LF, or LF, pair will terminate a message head. - Before, MHonArc was terminating message heads when - encountering an empty line or a line that only contained - whitespace (which was incorrect behavior). - - o Fixed bug in mhexternal.pl dealing with the `name' parameter - in the content-type field. Surrounding "s or 's were not - being deleted causing filenames with quotes to be written. - - o mhexternal.pl: The head of a pathname in the `name' - parameter in the content-type field is stripped off before - writing the external file. I.e. Only the base filename is - used. - - o Only one
after the H1 subject in messages will appear - if no message header fields are printed. - - o Added recognition of the following content-types in - mhexternal.pl: - - application/mac-binhex40 - - o Added a extras/ directory containing useful programs for - MHonArc. See README in the directory for information on - the programs contained in there. - - o To support -rmm, MIME filters now return an array. The - first array value is the HTML for the message, and any other - array values are filenames of files generated by the - filter. This allows MHonArc to know of any extra files that - must be deleted when a message is removed. - - o Some routines from the main mhonarc source file have been - moved into a separate librarys: readmail.pl, mhdb.pl, - mhutil.pl - - o The default URL to the documentation is now, - - http://www.oac.uci.edu/indiv/ehood/mhonarc.html - - The old URL, - - http://www.oac.uci.edu/indiv/ehood/mhonarc.doc.html - - is still valid. - - o There's probably other stuff, but I cannot remember. - - -======================================================================= -10/01/94 (1.0.0) - - o First release -- See RELNOTES about compatibility issues - with mail2html. - - -======================================================================= -####################################################################### -======================================================================= -Earl Hood, ehood@isogen.com +CHANGES for MHonArc + + http://www.oac.uci.edu/indiv/ehood/mhonarc.html + +Revision history for MHonArc. Changes listed are brief. Consult +the documentation for further information/clarification. It is +possible that not all changes are documented here. + +MM/DD/YY +======================================================================= +####################################################################### +======================================================================= +05/23/97 (2.0.1) + + Bug Fixes + --------- + + Problem: Bogus empty entry shows up in the database. Bogus + entry appears if a duplicate message is detected. + Potential visible problems of bogus entry are: mailto + links in headers corrupted; a blank listing in the + index. Maybe other potential problems. + Solution: There is a be a bug in some versions of Perl where a + hash key gets added invalidly. The section of code that + this occurs has been modified to avoid the problem. + For existing databases with a bogus empty entry, + MHonArc now removes any empty key entries. + However, it is recommed to rebuild the archive. + + Problem: Index pages are not properly updated if zero messages + are in the archive (like through the -rmm option). + Even -editidx cannot cause a proper update. + Solution: Page count was set to zero when no messages exist. This + caused problems in conditional checks in the write index + routines. To fix, page count is forced to 1 if their + are no messages. + +======================================================================= +05/16/97 (2.0.0) + + Enhancements: + + o Added TCONTBEGIN, TCONTEND, TINDENTBEGIN, TINDENTEND + resources. They are provided to support the formatting + of threads that split across multiple pages of a + multipage index. + + o Added "nonfixed", "maxwidth", and "keepspace" options + to text/plain (mhtxtplain.pl) filter. + + o A directory file is now used for performing archive + locking. This should provide better portability across + operating systems. + + o Dervied files returned from filters can be directories. + If so, the any directory is completely removed if the + message is removed. + + o The mhexternal.pl filter can now output files into + a subdirectory with the "subdir" option. This may be + useful for those wanting to use the "usename" option + and avoid potential filename conflicts. + + o The $NEXT...$ and $PREV...$ resource variables now + behave as one may expect. I.e. The are always relative + to the base sort method: date, author, subject, message + number. The REVERSE resource has no effect on their + values. Therefore, the variables no longer refer to + the actual physical listing order. This new behavior + no longer requires a users to redefine button and link + resources for the sake of specifying REVERSE. + + o "Resent-To" and "Resent-Cc" will now have e-mail + address hyperlinked. + + o Unknown types processed by mhexternal.pl now default + to have a ".bin" extension. This should cause HTTP + servers to treat the file as application/octet-stream. + + o Standard input can be specified as the source of a + mailbox by using a lone "-" on the command-line. Note: + You may need to specify "--" first to shut-off option + processing so the "-" is not interpreted as the start + of an option. + + Bug Fixes: + + o Problem: Index pages with last page links are not updated + when a new page is added. + Solution: All index pages are regenerated if a new page + is added. + + o Problem: "-idxsize 0" does not give unlimited page size. + Solution: Problem fixed and now works as documented. + + o Problem: "-maxsize 0" does not reset archive with + unlimited messages allowed. + Solution: Problem fixed and now works as documented. + + o Problem: Non-ASCII text encodings (=?ISO-..?...) are not + properly decoded when EDITIDX is set. + Solution: The charset filter libraries are now loaded + for EDITIDX. + + o Problem: MODTIME resource setting not remembered across + archive updates. + Solution: MODTIME resource is now properly stored in the + database. + + o Problem: Specifying -rmm and -single caused confusion on + what MHonArc does. + Solution: The case is properly handled, with -rmm taking + precedence. + + o Problem: 4 digit year not checked before 2 digit year + when parsing dates. + Solution: Fixed. + + o Problem: Some index pages in multipage indexes not + updated when messages expire. + Solution: Fixed; all pages are regenerated when a message + expires. + + o Problem: Setting MONTHS and MONTHSABR had no effect. + Solution: Fixed. + + o Problem: $TNEXTFROM$ actually gave the value of $NEXTFROM$. + Solution: Fixed. + + o Problem: Numerical timezone offsets not handled properly + when the offset contained non-zero minutes. This + caused message to be sorted wrong by date. + Solution: Fixed. + + o Problem: Some characters were not properly escaped when + specifying the "in URL" modifier to a resource + variable. + Solution: Fixed. + + o Problem: Thread (formatting) information lost when a + thread is split across multiple pages. + Solution: Fixed. New resources (TCONTBEGIN, TCONTEND, + TINDENTBEGIN, TINDENTEND) exist to preserve + formatting of threads across pages. + + o Problem: If specifying the REVERSE, the next/prev + links in messages do not point to the proper + message as one may expect. + Solution: This should be fixed by the new behavior of + $NEXT...$ and $PREV...$ resource variables. + + +======================================================================= +02/28/97 (2.0.0 beta 3) + + o Removed bogus call to output_db() when GENIDX is active. + The routine is not loaded when GENIDX is active and the + call causes Perl to abort. + + o Duplicates of the OTHERINDEXES resource should no longer + occur. Before, if the OTHERINDEXES resource gets set + during invocation, mhonarc would store duplicate values, + causing unnecessary work to be performed. + + o Fixed problem with blank indexes being created for + OTHERINDEXES. Apparently, there is a bug in Perl, and + a work-around fix has been done. + + o Fixed bug where an extra TSUBLISTEND could get generated. + + +======================================================================= +02/17/97 (2.0.0 beta 2) + + o Added element and -nosubsort option. + + o Changed M2H_DATEFMT envariable to M2H_GMTDATEFMT. + + o Documented LOCKTRIES and LOCKDELAY resources. + + o New resources: + + AUTHORBEGIN - Markup for start of author group + AUTHOREND - Markup for end of author group + AUTHSORT - Sort messages by author + DAYBEGIN - Markup for start of day group + DAYEND - Markup for end of day group + IDXLABEL - Label for main index + MSGGMTDATEFMT - Format of $MSGGMTDATE$ + MSGLOCALDATEFMT - Format of $MSGLOCALDATE$ + SUBJECTBEGIN - Markup for start of subject group + SUBJECTEND - Markup for end of subject group + TIDXLABEL - Label for thread index + + o New resource variables + + $IDXLABEL$ - Label for main index + $MSGGMTDATE$ - Date of message in GMT format + $MSGLOCALDATE$ - Date of message in local format + $TIDXLABEL$ - Label for thread index + + o Some enhancements to the documentation. + + o Some code changes. + + +======================================================================= +01/31/97 (2.0.0 beta 1) + + o RFC 1522 support. Charset filters can be plugged in to + handle character sets not recognized by mhonarc. + The library, iso8859.pl, contains charset filters for + character sets iso-8859-[1-10]. + + o Multi-page index generation. + + o Subject-based threading is done inconjunction with explicit + threading. + + o Missing messages in a thread are recognized when processing + messages that utilize the References field. + + o New resources for customizing thread indexes. There is + now complete user control on how thread indexes are + formatted. + + o Resource are available to access the next and previous messages + in thread from messages. + + o Inclusion of files containing resource settings can be + done within a resource file. + + o Support for a default resource file. The default resource + file is one of the following, in the order of precedence: + + 1. File specified by the M2H_DEFRCFILE envariable + 2. $HOME/.mhonarc.rc + 3. /.mhonarc.rc + + "" is the path of the MHonArc library + directory defined during installation. For MS-DOS, replace + ".mhonarc.rc" with "MHONARC.RC". + + o Support for user defined resource variables. + + o Support for user defined derived files for messages. + + o Support for the Content-Length field. + + o Modification time of messages, and derived files, can be + set to the Received/Date time specified in the message. + + o More control on how mail headers get formatted. + + o Added filter in mhexternal.pl to be the default filter + for main content-types: application, image, video, audio. + + o List of enhancements to mhexternal.pl: + + - Show content-type if the data is not recognized. + - New `ext' filter option to define the extension to + use for the created file. + - New `type' filter option to define the "english" + type name of the create file. + - Content-Disposition is supported. Filenames are + ignored still unless `usename' argument passed to + filter. + - Added recognition of few more content-types + + o Updated date parsing to figure out the date of a message to be + more robust on how it parses a date. If unable to parse + date, the message will take on the current time for sorting + purposes. Also, character case is ignored in month and weekday + names. + + o The comment declaration "" is + now inserted between the message header and body. Helps + in the building of some search indexes to restrict searches + on message data. + + o Many resource settings are no longer stored in database if + the resource is the default value. Save some disk space and + allows resources to self adjust when a dependent resource is + changed. + + o The text/plain filter in mhtxtplain.pl has the following + enhancements: + + - Check for charset to control character conversion. + - Integrated iso-2022-jp filter (keys off charset) + - Filter option "quote" cause quoted text in message + to be italicized. + - Filter option "asis" defines a list of charsets to + not convert to sgml entitites. Example usage: + + asis=iso-8859-1:iso-8859-2 + + o mhtxt2022.pl has been removed since the code has been + integrated into mhtxtplain.pl. + + o Resource file elements that have textual content (ie. no + line oriented content) can specify the "chop" attribute + to have the last end-of-line stripped from the content. + Example usage: + + + [Next] + + + o Fixed bug in creating links of message-ids. Mhonarc blindingly + made links of message-ids when editting messages w/o + consideration that the message-ids may already be linked. This + caused markup like the following to occur: + + ...... + + Browsers handle the invalid markup with no problems, causing + the bug to go unnoticed for a long time. Now, only new + added message-ids are scanned for when creating links. + + o $readmail'FieldSep should now be used instead of $FieldSep + for separating duplicate fields in a parsed message header. + + o The -scan output now prints a 4 digit year. + + o Bogus space no longer appears in subjects and dates. + + o Outdir permissions are not checked if -single specified. + + o Some internal changes to how data is stored in databases + (needed for 1522 support). v2.0 will automatically + modify 1.x databases to the 2.0 format. + + o The -single option utilizes the same mail output routine + utilized by regular archive processing. + + o MhonArc will now handle numbers with leading zeros when + the -rmm option is specified. + + o New resources: + + CHARSETCONVERTERS + - Specify character set filters + CONLEN - Honor content-lengths + DECODEHEADS - Decode 1522 encoded data, set for decode + only, as message headers are read (see + note below) + DEFINEVAR - Define resource variables + DEFINEDERIVED - Define user defined derived file + EXPIREDATE - Message cut-off date + EXPIREAGE - Time in seconds from current if msg expires + FIELDSBEG - Begin markup of converted mail header + FIELDSEND - End markup of converted mail header + FLDBEG - Begin markup of mail header field text + FLDEND - End markup of mail header field text + FOLREFS - Print links to explicit follow-ups & refs + GMTDATEFMT - Format of $GMTDATE$ + HEADBODYSEP - Markup between converted mail header & body + IDXPREFIX - Prefix for multi-page main index filenames + INCLUDE - Read resources from other files + LABELBEG - Begin markup of mail header label + LABELEND - End markup of mail header label + LOCALDATEFMT - Format of $LOCALDATE$ + MAIN - Create main index + MHPATTERN - Expression for mesg files in a directory + MODTIME - Set file times to message dates + MONTHS - Full month names: EOL or ':' separated + MONTHSABR - Abbrieviated month names: EOL or ':' + separated + MULTIPG - Create multi-page indexes + NEXTPGLINK - Link to next page in main index + NEXTPGLINK - Inactive link to next page in main index + NOCONLEN - Ignore content-lengths + NODECODEHEADS - Leave message headers "as is" when read + (see note below) + NOFOLREFS - Do not print links to follow-ups & refs + NOMAIN - Do not create main index + NOMODTIME - Do not set file times to message dates + NOMULTIPG - Do not create multi-page indexes + PREVPGLINK - Link to previous page in main index + PREVPGLINKIA - Inactive link to previous page in main index + SUBJECTHEADER - Markup for subject header in converted mail + TIDXPREFIX - Prefix for multi-page thread index filenames + TSUBLISTBEG - List begin in sub-thread + TSUBLISTEND - List end in sub-thread + TSUBJECTBEG - Begin markup for subject-based sub-thread + TSUBJECTEND - End markup for subject-based sub-thread + TSINGLETXT - Markup for mesg not part of a thread + TTOPBEGIN - Begin for top of a thread + TTOPEND - End for a thread + TLINONE - Markup for missing message in a thread + TLIEND - Thread idx list item end + TNEXTBUTTON - Thread next button template + TNEXTBUTTONIA - Inactive thread next button template + TNEXTLINK - Thread next link template + TNEXTLINKIA - Inactive thread next link template + TNEXTPGLINK - Link to next page in thread index + TNEXTPGLINKIA - Inactive link to next page in thread index + TPREVBUTTON - Thread previous button template + TPREVBUTTONIA - Inactive thread previous button template + TPREVLINK - Thread previous link template + TPREVLINKIA - Inactive thread previous link template + TPREVPGLINK - Link to prev page in thread index + TPREVPGLINKIA - Inactive link to prev page in thread index + WEEKDAYS - Full weekday names: EOL or ':' separated + WEEKDAYSABR - Abbrieviated weekday names: EOL or ':' + separated + + + NOTE + 1522 processing is done when creating HTML output and + the (relevant) data stored in the database stays in + encoded form. The DECODEHEADS resource can be set + to decode decode-only charsets when message headers + are read. Hence, the decode-only charsets will be + stored in decoded form. Regular 1522 processing is + still done to still-encoded data when generating output. + The default is NODECODEHEADS. + + o List of removed resources: + + NOTSUBSORT, TSUBSORT + + o New resource variables: + (NOTE: Some variables are only valid in certain contexts) + + $FIRSTPG$ - Filename of first page of main index + $IDXPREFIX$ - Prefix to main index pages' filenames + $LASTPG$ - Filename of last page of main index + $NEXTPG$ - Filename of next main index page + $NEXTPGLINK$ - Link to next page of main index + $NUMOFPAGES$ - Total number of pages in index + $PAGENUM$ - Current page number of index + $PREVPG$ - Filename of previous main index page + $PREVPGLINK$ - Link to previous page of main index + $TFIRSTPG$ - Filename of first page of thread index + $TIDXPREFIX$ - Prefix to thread index pages' filenames + $TLASTPG$ - Filename of last page of thread index + $TNEXTBUTTON$ - Button for next mesg in thread + $TNEXTFROM$ - From of next mesg in thread + $TNEXTFROMADDR$ - From address of next mesg in thread + $TNEXTFROMNAME$ - From name of next mesg in thread + $TNEXTLINK$ - Link for next mesg in thread + $TNEXTMSG$ - Next mesg filename in thread + $TNEXTMSGNUM$ - Next mesg number in thread + $TNEXTPG$ - Filename of next thread index page + $TNEXTPGLINK$ - Link to next page of thread index + $TNEXTSUBJECT$ - Next mesg subject in thread + $TPREVBUTTON$ - Button for prev mesg in thread + $TPREVFROM$ - From of previous mesg in thread + $TPREVFROMADDR$ - From address of previous mesg in thread + $TPREVFROMNAME$ - From name of previous mesg in thread + $TPREVLINK$ - Link for prev mesg in thread + $TPREVMSG$ - Previous mesg filename in thread + $TPREVMSGNUM$ - Previous mesg number in thread + $TPREVPG$ - Filename of previous thread index page + $TPREVPGLINK$ - Link to previous page of thread index + $TPREVSUBJECT$ - Previous mesg subject in thread + + o Removed resources: + + NOTSUBSORT, TSUBSORT + + o Some changes to default resource settings. + + o Reorganized code. Some new libraries have been created + to help in maintenance. + + o Source code has been put under SCCS revision control. + + +======================================================================= +07/12/96 (1.2.3) + + o Extracted initialization of data structures into mhinit.pl. + The file is just required from the main source. + + o Use q{} instead of qq{} when trying to read database file. + Should fix require problem under MS-DOS. + + o Added comments at beginning + of messages. May aid in database recovery techniques. + + o ';'s are now deleted in filenames in mhexternal.pl + (applicable only when "usename" option specified) + + o Added recognition of '/' when converted e-mail addresses + to mailto links in message headers. + + o Simple fix to mhtxt2022.pl for execution under Perl 5. + + +======================================================================= +04/18/96 (1.2.2) + + o Increased the speed performance of base64 decoding. Speed + increase is much greater under Perl 4 than Perl 5. + + o Added -time option to print out total CPU execution time. + Mainly used for debugging reasons (like checking on + base64 decoding times). Time information is sent to + standard error. + + o Added M2H_LOCKDELAY envariable and -lockdelay option. + Either can be used to adjust the sleep time between + attempts to lock the archive. + + o Added -force option to override a lock on an archive if + attempts to lock fail. + + o Added image/x-bmp and image/x-pcx to the default supported + MIME types. + + o Ignore "Sv:" at the beginning of subjects when sorting by + subject. "Sv:" is Danish for "Re:". + + o Fixed bug in mhutil.pl where TIDXPGEND actually set + TIDXPGBEG. + + o Dynamically define exclude_field routine after reading + user options. exclude_field is utilized when formatting + a message header in HTML. Defining the routine at run-time + helps reduce the regular expression overhead the old version + of the routine entailed. There should be an increase in + overall execution time. + + +======================================================================= +03/22/96 (1.2.1) + + o Added support for x-uuencode content-transfer-encoding. + + o Added -locktries command-line option. + + o Added the resource variable $OUTDIR$. + + o mhexternal.pl filter will use the name parameter string + on the content-type field as the anchor text to the file + if there is no content-description. + + o application/x-patch is recognized and processed by the + text/plain filter (mhtxtplain.pl). + + o Fixed bug in install.me and osinit.pl where setting + $'PROG caused perl to terminate if $'DIRSEP was a backslash + (occured under MS-DOS usage). + + o Fixed bug in install.me in the create_dir routine. + If $DIRSEP was a backslash, the regular expression setting + @a would cause perl to abort with an error. + + o Fixed database bug where the MIMEARGS resource setting + was not being stored. + + o Fixed index listing bug where a reverse listing was not + correct if an index size was specified less than the + current size of the archive. + + +======================================================================= +03/01/96 (1.2.0) + + o Rewrote message parser routine so it will work under Perl 5 + for multipart messages. The rewrite also allows some + additional features that are mentioned below. + + o The -mbox and -mh options are no longer required. MHonArc + will automatically determine which mode to operate in + based upon the file arguments. Hence, one can specify + MH folders and mailbox files on the same command-line. + Both options are ignored if specified. + + o An HTML index of an archive contents can be generated to + standard output (-genidx). + + o Message header lines not conforming to RFC 822 are ignored. + (Eg: Those pesky "From " lines should not show up anymore -- + please do not confuse this with the regular "From:" lines; + note the colon vs the space). + + o New resources: + + BOTLINKS - May be used to completely customize + the links at the bottom of messages. + IDXPGBEGIN - Opening markup for main index page. + Allows one to redefine opening HTML + element, HEAD element, TITLE element, + opening BODY element, etc. + IDXPGEND - Closing markup for main index page. + IDXSIZE - Set the maximum number of messages + listed in index. This is different + in MAXSIZE where MAXSIZE will remove + older messages when the MAXSIZE limit + is reached in the archive. + MIMEARGS - Define arguments to filters + MSGPGBEGIN - Opening markup for message pages. + Allows one to redefine opening HTML + element, HEAD element, TITLE element, + opening BODY element, etc. + MSGPGEND - Closing markup for message pages. + NEXTBUTTON - Defines the 'Next' button. + NEXTBUTTONIA - Defines the 'Next' button when it is + inactive. + NEXTLINK - Defines the 'Next' link. + NEXTLINKIA - Defines the 'Next' link when it is + inactive. + NOTSUBSORT - Do not sort threads by subject. + OTHERINDEXES - List other resource files defining + other indexes to create when creating, + or updating, an archive. + PREVBUTTON - Defines the 'Prev' button. + PREVBUTTONIA - Defines the 'Prev' button when it is + inactive. + PREVLINK - Defines the 'Prev' link. + PREVLINKIA - Defines the 'Prev' link when it is + inactive. + TIDXPGBEGIN - Opening markup for thread index page. + Allows one to redefine opening HTML + element, HEAD element, TITLE element, + opening BODY element, etc. + TIDXPGEND - Closing markup for thread index page. + TOPLINKS - May be used to completely customize + the buttons at the top of messages. + TSUBSORT - Sort threads listed by subject. + + o Removed resources: + + INDEXBL, INDEXFL, MBOX, MH, NEXTBL, NEXTFL, PREVBL, + PREVFL, TINDEXBL, TINDEXFL + + Resource were removed because they were no longer applicable + and/or have been superceded by other resources. MHonArc + will still honor old resource settings (where applicable) of + older archives and incorporate them into the new resource + settings. + + o When specifying the resource file, mhonarc will now do + the following to determine its location: + + 1. If its an absolute pathname, mhonarc uses it. + 2. If it is a relative pathname, mhonarc checks for + it relative to the current working directory. + 3. Otherwise, mhonarc checks for it relative to + location of the archive as specified by outdir. + + This resolution will allow you to place resource files with + the archive if desired (can be useful when using the + OTHERINDEXES resource element). + + o Because of the new resources available, many
's are no + longer hard-coded and are controllable by resources.
's + are still used in message pages to separate message data + from mhonarc data. + + o Added resource variables: + (NOTE: Some variables are only valid in certain contexts) + + $DDMMYY$ - Date of message in dd/mm/yy format + $IDXSIZE$ - Max size of index list + $MMDDYY$ - Date of message in mm/dd/yy format + $MSGID$ - Message id + $NEXTBUTTON$ - Next button markup + $NEXTFROM$ - From field of next listed message + $NEXTFROMADDR$ - From e-mail address of next listed message + $NEXTFROMNAME$ - From name of next listed message + $NEXTLINK$ - Next link markup + $NEXTMSGNUM$ - Number of next listed message + $NEXTSUBJECT$ - Subject text of next listed message + $NUMOFIDXMSG$ - Number of messages in index list + $PREVBUTTON$ - Previous button markup + $PREVFROM$ - From field of previous listed message + $PREVFROMADDR$ - From e-mail address of prev listed message + $PREVFROMNAME$ - From name of previous listed message + $PREVLINK$ - Previous link markup + $PREVMSGNUM$ - Number of previous message + $PREVSUBJECT$ - Subject text of previous listed message + $YYMMDD$ - Date of message in yy/mm/dd format + + o Can specify a 'U' with variable length specifier to denote + replacement string is to be used in a URL. Examples: + + $SUBJECTNA:40U$ + $MSGID:U$ + + The 'U' causes the replace text to have special characters + escaped as denoted by the URL spec. NOTE: Specify ":U" + should NOT be used in the MAILTOURL resource; the variables + will automatically be expanded according to the URL spec. + Specifyind ":U" or a length specifier in the MAILTOURL + resource will prevent mhonarc from detecting the variable. + + o New command-line options: + + -genidx - Generate HTML index of archive contents + to stdout. + -idxsize - Maximum number of messages shown in indexes + -notsubsort - Do not sort threads listed by subject. + -savemem - Write message data while processing + -tsubsort - Sort threads listed by subject. + + o The library mhtxt2022.pl has been added that provides + a filter to process ISO-2022 (Japanese) encoded mail messages. + See mhtxt2022.pl on how to hook it in. + + o The mhexternal.pl filter by default ignores any filename + specification in the message for creating derived files. + This avoids name conflicts and security problems. + The "usename" filter option may be used to override this. + + o Mime filters are now called with two additional arguments: + + $converted_data = &function( + $header, *parsed_header_assoc_array, + *message_data, $decoded_flag, + $optional_filter_arguments); + + The $decoded_flag is set to 1 if the *message_data has been + decoded. $optional_filter_arguments contains an optional + argument string as determined by the filter. + + o Mime filters can now be registered for multipart types + and message types. This allows one to override mhonarc's + conversion of these types, and completely replace mhonarc's + message->HTML conversion process. + + o Mime filters should now use $'FieldSep instead of $'X for + accessing parsed message headers. + + o Mime filters can be registered for a base type. Ie. + It is no longer required to explicitly list each possible + subtype if a single filter is to be used for them all. + Example: + + + image/*:myfilter'imagefilter:myfilter.pl + + + Registers "myfilter'filter" for all image data types, + regardless of subtype. However, if an explicit entry + exists for a subtype, then that filter is called. + Example: + + + image/*:myfilter'imagefilter:myfilter.pl + image/gif:myfilter'giffilter:myfilter.pl + + + "myfilter'giffilter" is called for all image/gif data. + "myfilter'imagefilter" is called for all other image data. + + o A new resource, MIMEARGS, may be used to pass optional arguments + to filters to control their behavior. The format of the + argument string is controlled by the various filters. The + arguments can be specified by a specific content-type, or + for the filter routine in general. A content-type argument + will be used over any arguments specified for a filter. + + Example usage: + + + image/gif:inline usename + m2h_external'filter:usename + + + See the documentation for possible arguments to filters. + + o Installation program can now be invoked in batch mode. + + o Thread index properly includes docurl as main index. + -nodocurl will prevent the inclusion as with the main index. + + o Fixed bug in mhtxthtml.pl on properly propogating a base + URL to relative URLs starting with a "/". + + o Fixed bug where single quotes, and backslashed in keys of + associative arrays in the database file were not getting + escaped. + + o Fixed bug where spaces and special characters were not + properly escaped in URL strings: spaces were left as-is, + and special characters were deleted. + + o Removed illegal invocation choices in the Synopsis of the + documentation. + + +======================================================================= +04/24/95 (1.1.1) + + o Fixed bug in -scan output where month in date was off by + one. + + +======================================================================= +04/21/95 (1.1.0) + + o Made modifications to make MHonArc suitable to run + under MS-DOS without modification. MHonArc will + automatically detect if it is running under Unix or MS-DOS. + + o Added support for a thread index. MHonArc will create a + complimentary index to the main index showing message + threads. + + o Archive messages can be deleted. + + o A listing to stdout of an archives contents can be + generated. + + o Maximum number of messages for an archive can be set. + Older messages (based on sort method) are removed + automatically during add operations. + + o MHonArc will now recognize if you try to add in a message + that already exists in an archive. + + o The -editdx option will now also cause a updating of all + mail messages. Guarantees resource changes to affect all + messages. + + o Added the following resource file elements: + + MSGFOOT -- Footer text for converted messages + MSGHEAD -- Header text for converted messages + NODOC -- Do not put link to documentation + NOTHREAD -- Do not create thread index + TFOOT -- Text at bottom of thread index page + THEAD -- Text at top of thread index page + THREAD -- Create thread index + TLEVELS -- Depth of thread listing + TLITXT -- Template text for entry in thread + index + TIDXFNAME -- Thread index filename + TINDEXBL -- Top button label in messages to + thread index + TINDEXFL -- Verbose label in message to thread + index + TTITLE -- Title of thread index page + + o Added the following command-line options: + + -maxsize -- Maxinum # messages in an archive + -nodoc -- Do not put link to documentation + -nothread -- Do not create thread index + -rmm -- Remove messages from an archive + -scan -- Listing of archive to stdout + -thread -- Create thread index + -tidxfname -- Thread index filename + -tlevels -- Depth of thread listing + -ttitle -- Title of thread index page + + o Added the following environment variables: + + M2H_MAXSIZE -- Maxinum # messages in an archive + M2H_THREAD -- If non-zero, create thread index + M2H_TIDXFNAME -- Thread index filename + M2H_TLEVELS -- Depth of thread listing + M2H_TTITLE -- Title of thread index page + + o Added the following variables for template resources + (applicability of variables vary depending on the resource): + + $DOCURL$ -- URL to documentation + $IDXFNAME$ -- Main index page filename + $IDXTITLE$ -- Main index page title + $NEXTMSG$ -- Next message filename + $PREVMSG$ -- Previous message filename + $PROG$ -- Program name + $TIDXFNAME$ -- Thread index page filename + $TIDXTITLE$ -- Thread index page title + $VERSION$ -- Version number of the program + + o Added $FROM$, $MSGID$, and $SUBJECT$ variables to be used + in the MAILTOURL resource. + + o The string `$$' in template resources will produce a `$' in + the output. + + o Fixed problem with messages (with follow-ups) getting + unnecessarily updated when messages are added to an archive. + + o Only a CR/LF, or LF, pair will terminate a message head. + Before, MHonArc was terminating message heads when + encountering an empty line or a line that only contained + whitespace (which was incorrect behavior). + + o Fixed bug in mhexternal.pl dealing with the `name' parameter + in the content-type field. Surrounding "s or 's were not + being deleted causing filenames with quotes to be written. + + o mhexternal.pl: The head of a pathname in the `name' + parameter in the content-type field is stripped off before + writing the external file. I.e. Only the base filename is + used. + + o Only one
after the H1 subject in messages will appear + if no message header fields are printed. + + o Added recognition of the following content-types in + mhexternal.pl: + + application/mac-binhex40 + + o Added a extras/ directory containing useful programs for + MHonArc. See README in the directory for information on + the programs contained in there. + + o To support -rmm, MIME filters now return an array. The + first array value is the HTML for the message, and any other + array values are filenames of files generated by the + filter. This allows MHonArc to know of any extra files that + must be deleted when a message is removed. + + o Some routines from the main mhonarc source file have been + moved into a separate librarys: readmail.pl, mhdb.pl, + mhutil.pl + + o The default URL to the documentation is now, + + http://www.oac.uci.edu/indiv/ehood/mhonarc.html + + The old URL, + + http://www.oac.uci.edu/indiv/ehood/mhonarc.doc.html + + is still valid. + + o There's probably other stuff, but I cannot remember. + + +======================================================================= +10/01/94 (1.0.0) + + o First release -- See RELNOTES about compatibility issues + with mail2html. + + +======================================================================= +####################################################################### +======================================================================= +Earl Hood, ehood@medusa.acs.uci.edu +@(#) CHANGES 97/05/22 19:01:09 @(#) diff --git a/COPYING b/COPYING index 9ed3415..b9339b9 100644 --- a/COPYING +++ b/COPYING @@ -1,339 +1,346 @@ - GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc. - 675 Mass Ave, Cambridge, MA 02139, USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Library General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - - Appendix: How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) 19yy - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - - Gnomovision version 69, Copyright (C) 19yy name of author - Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the program - `Gnomovision' (which makes passes at compilers) written by James Hacker. - - , 1 April 1989 - Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Library General -Public License instead of this License. +GNU General Public License + +---------------------------------------------------------------------------- + +Table of Contents + + * GNU GENERAL PUBLIC LICENSE + o Preamble + o TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + o How to Apply These Terms to Your New Programs + +---------------------------------------------------------------------------- + +GNU GENERAL PUBLIC LICENSE + +Version 2, June 1991 + +Copyright (C) 1989, 1991 Free Software Foundation, Inc. +59 Temple Place - Suite 330, Boston, MA 02111-1307, USA + +Everyone is permitted to copy and distribute verbatim copies +of this license document, but changing it is not allowed. + +Preamble + +The licenses for most software are designed to take away your freedom to +share and change it. By contrast, the GNU General Public License is intended +to guarantee your freedom to share and change free software--to make sure +the software is free for all its users. This General Public License applies +to most of the Free Software Foundation's software and to any other program +whose authors commit to using it. (Some other Free Software Foundation +software is covered by the GNU Library General Public License instead.) You +can apply it to your programs, too. + +When we speak of free software, we are referring to freedom, not price. Our +General Public Licenses are designed to make sure that you have the freedom +to distribute copies of free software (and charge for this service if you +wish), that you receive source code or can get it if you want it, that you +can change the software or use pieces of it in new free programs; and that +you know you can do these things. + +To protect your rights, we need to make restrictions that forbid anyone to +deny you these rights or to ask you to surrender the rights. These +restrictions translate to certain responsibilities for you if you distribute +copies of the software, or if you modify it. + +For example, if you distribute copies of such a program, whether gratis or +for a fee, you must give the recipients all the rights that you have. You +must make sure that they, too, receive or can get the source code. And you +must show them these terms so they know their rights. + +We protect your rights with two steps: (1) copyright the software, and (2) +offer you this license which gives you legal permission to copy, distribute +and/or modify the software. + +Also, for each author's protection and ours, we want to make certain that +everyone understands that there is no warranty for this free software. If +the software is modified by someone else and passed on, we want its +recipients to know that what they have is not the original, so that any +problems introduced by others will not reflect on the original authors' +reputations. + +Finally, any free program is threatened constantly by software patents. We +wish to avoid the danger that redistributors of a free program will +individually obtain patent licenses, in effect making the program +proprietary. To prevent this, we have made it clear that any patent must be +licensed for everyone's free use or not licensed at all. + +The precise terms and conditions for copying, distribution and modification +follow. + +TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + +0. This License applies to any program or other work which contains a notice +placed by the copyright holder saying it may be distributed under the terms +of this General Public License. The "Program", below, refers to any such +program or work, and a "work based on the Program" means either the Program +or any derivative work under copyright law: that is to say, a work +containing the Program or a portion of it, either verbatim or with +modifications and/or translated into another language. (Hereinafter, +translation is included without limitation in the term "modification".) Each +licensee is addressed as "you". + +Activities other than copying, distribution and modification are not covered +by this License; they are outside its scope. The act of running the Program +is not restricted, and the output from the Program is covered only if its +contents constitute a work based on the Program (independent of having been +made by running the Program). Whether that is true depends on what the +Program does. + +1. You may copy and distribute verbatim copies of the Program's source code +as you receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice and +disclaimer of warranty; keep intact all the notices that refer to this +License and to the absence of any warranty; and give any other recipients of +the Program a copy of this License along with the Program. + +You may charge a fee for the physical act of transferring a copy, and you +may at your option offer warranty protection in exchange for a fee. + +2. You may modify your copy or copies of the Program or any portion of it, +thus forming a work based on the Program, and copy and distribute such +modifications or work under the terms of Section 1 above, provided that you +also meet all of these conditions: + + * a) You must cause the modified files to carry prominent notices stating + that you changed the files and the date of any change. + + * b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any part + thereof, to be licensed as a whole at no charge to all third parties + under the terms of this License. + + * c) If the modified program normally reads commands interactively when + run, you must cause it, when started running for such interactive use + in the most ordinary way, to print or display an announcement including + an appropriate copyright notice and a notice that there is no warranty + (or else, saying that you provide a warranty) and that users may + redistribute the program under these conditions, and telling the user + how to view a copy of this License. (Exception: if the Program itself + is interactive but does not normally print such an announcement, your + work based on the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If identifiable +sections of that work are not derived from the Program, and can be +reasonably considered independent and separate works in themselves, then +this License, and its terms, do not apply to those sections when you +distribute them as separate works. But when you distribute the same sections +as part of a whole which is a work based on the Program, the distribution of +the whole must be on the terms of this License, whose permissions for other +licensees extend to the entire whole, and thus to each and every part +regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest your +rights to work written entirely by you; rather, the intent is to exercise +the right to control the distribution of derivative or collective works +based on the Program. + +In addition, mere aggregation of another work not based on the Program with +the Program (or with a work based on the Program) on a volume of a storage +or distribution medium does not bring the other work under the scope of this +License. + +3. You may copy and distribute the Program (or a work based on it, under +Section 2) in object code or executable form under the terms of Sections 1 +and 2 above provided that you also do one of the following: + + * a) Accompany it with the complete corresponding machine-readable source + code, which must be distributed under the terms of Sections 1 and 2 + above on a medium customarily used for software interchange; or, + + * b) Accompany it with a written offer, valid for at least three years, + to give any third party, for a charge no more than your cost of + physically performing source distribution, a complete machine-readable + copy of the corresponding source code, to be distributed under the + terms of Sections 1 and 2 above on a medium customarily used for + software interchange; or, + + * c) Accompany it with the information you received as to the offer to + distribute corresponding source code. (This alternative is allowed only + for noncommercial distribution and only if you received the program in + object code or executable form with such an offer, in accord with + Subsection b above.) + +The source code for a work means the preferred form of the work for making +modifications to it. For an executable work, complete source code means all +the source code for all modules it contains, plus any associated interface +definition files, plus the scripts used to control compilation and +installation of the executable. However, as a special exception, the source +code distributed need not include anything that is normally distributed (in +either source or binary form) with the major components (compiler, kernel, +and so on) of the operating system on which the executable runs, unless that +component itself accompanies the executable. + +If distribution of executable or object code is made by offering access to +copy from a designated place, then offering equivalent access to copy the +source code from the same place counts as distribution of the source code, +even though third parties are not compelled to copy the source along with +the object code. + +4. You may not copy, modify, sublicense, or distribute the Program except as +expressly provided under this License. Any attempt otherwise to copy, +modify, sublicense or distribute the Program is void, and will automatically +terminate your rights under this License. However, parties who have received +copies, or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + +5. You are not required to accept this License, since you have not signed +it. However, nothing else grants you permission to modify or distribute the +Program or its derivative works. These actions are prohibited by law if you +do not accept this License. Therefore, by modifying or distributing the +Program (or any work based on the Program), you indicate your acceptance of +this License to do so, and all its terms and conditions for copying, +distributing or modifying the Program or works based on it. + +6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the original +licensor to copy, distribute or modify the Program subject to these terms +and conditions. You may not impose any further restrictions on the +recipients' exercise of the rights granted herein. You are not responsible +for enforcing compliance by third parties to this License. + +7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot distribute so +as to satisfy simultaneously your obligations under this License and any +other pertinent obligations, then as a consequence you may not distribute +the Program at all. For example, if a patent license would not permit +royalty-free redistribution of the Program by all those who receive copies +directly or indirectly through you, then the only way you could satisfy both +it and this License would be to refrain entirely from distribution of the +Program. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply and +the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any patents +or other property right claims or to contest validity of any such claims; +this section has the sole purpose of protecting the integrity of the free +software distribution system, which is implemented by public license +practices. Many people have made generous contributions to the wide range of +software distributed through that system in reliance on consistent +application of that system; it is up to the author/donor to decide if he or +she is willing to distribute software through any other system and a +licensee cannot impose that choice. + +This section is intended to make thoroughly clear what is believed to be a +consequence of the rest of this License. + +8. If the distribution and/or use of the Program is restricted in certain +countries either by patents or by copyrighted interfaces, the original +copyright holder who places the Program under this License may add an +explicit geographical distribution limitation excluding those countries, so +that distribution is permitted only in or among countries not thus excluded. +In such case, this License incorporates the limitation as if written in the +body of this License. + +9. The Free Software Foundation may publish revised and/or new versions of +the General Public License from time to time. Such new versions will be +similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + +10. If you wish to incorporate parts of the Program into other free programs +whose distribution conditions are different, write to the author to ask for +permission. For software which is copyrighted by the Free Software +Foundation, write to the Free Software Foundation; we sometimes make +exceptions for this. Our decision will be guided by the two goals of +preserving the free status of all derivatives of our free software and of +promoting the sharing and reuse of software generally. + +NO WARRANTY + +11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR +THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO +THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM +PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR +CORRECTION. + +12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO +LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR +THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + +END OF TERMS AND CONDITIONS + +How to Apply These Terms to Your New Programs + +If you develop a new program, and you want it to be of the greatest possible +use to the public, the best way to achieve this is to make it free software +which everyone can redistribute and change under these terms. + +To do so, attach the following notices to the program. It is safest to +attach them to the start of each source file to most effectively convey the +exclusion of warranty; and each file should have at least the "copyright" +line and a pointer to where the full notice is found. + +one line to give the program's name and an idea of what it does. +Copyright (C) 19yy name of author + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this when +it starts in an interactive mode: + +Gnomovision version 69, Copyright (C) 19yy name of author +Gnomovision comes with ABSOLUTELY NO WARRANTY; for details +type `show w'. This is free software, and you are welcome +to redistribute it under certain conditions; type `show c' +for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may be +called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + +Yoyodyne, Inc., hereby disclaims all copyright +interest in the program `Gnomovision' +(which makes passes at compilers) written +by James Hacker. + +signature of Ty Coon, 1 April 1989 +Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General Public +License instead of this License. diff --git a/INSTALL b/INSTALL new file mode 100644 index 0000000..0ee51c8 --- /dev/null +++ b/INSTALL @@ -0,0 +1,59 @@ +INSTALL for MHonArc + + http://www.oac.uci.edu/indiv/ehood/mhonarc.html + +--------------------------------------------------------------------------- + + NOTE + Installation has changed slightly from 1.x releases. Please + read the following instructions if you are familiar with + the 1.x installation process. + +This document gives the basic method for installing MHonArc on a Unix or +MS-DOS/Windows system. + +Instructions + + Interactive Installing: + + Run the following command: + + perl install.me + + The installation program will ask you a series of questions on + where the Perl executable is and where to put MHonArc files. + Just hit to accept the default values listed in ()'s. + + Batch Install: + + 1. Edit the file 'install.cfg'. Knowledge of Perl is helpful. + 2. Run the following command: + + perl install.me batch + + The installation program will output information on what + is being installed and where it is being installed. + +Notes on Installation Program + + o The '#!' line in the installed mhonarc program is set to + point to the Perl executable specified in the installation + process (this has no meaning under MS-DOS). + + o The installed mhonarc program has code added so it will find + its default libraries specified in the installation program. + I.e. The install lib directory is added to mhonarc's search + path so it will find its libraries. + + o If you specify paths that do not exist, the install.me + program will create the path ONLY if running in interactive + mode. If running in batch mode, you must check that all paths + specified exist. + + o MSDOS/Windows users: You many need to create a batch file + for easy invocation of MHonArc. An example batch file + exists in the bat/ directory of the distribution. + +--------------------------------------------------------------------------- +Copyright (C) 1997, Earl Hood, ehood@medusa.acs.uci.edu +@(#) INSTALL 97/05/15 16:59:14 @(#) diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..2779d12 --- /dev/null +++ b/Makefile @@ -0,0 +1,29 @@ +##---------------------------------------------------------------------------## +## @(#) Makefile 1.5 97/05/15 16:59:40 @(#) +##---------------------------------------------------------------------------## + +CHMOD = /bin/chmod +RM = /bin/rm +PRGS = mhonarc +TXTFILES = ACKNOWLG CHANGES COPYING README RELNOTES INSTALL BUGS +DOSIFY = dosify +PERL = perl +INSTALLPRG = install.me +INSTALLCFG = install.cfg + +default: + $(CHMOD) a+x $(PRGS) + $(CHMOD) -R a+r,a+X . + $(DOSIFY) $(TXTFILES) + +install: + $(PERL) $(INSTALLPRG) + +install-batch: + $(PERL) $(INSTALLPRG) batch + +test: + @echo "No tests" + +clean: + @echo "Nothing to clean" diff --git a/README b/README index df32d01..9522eb9 100644 --- a/README +++ b/README @@ -22,22 +22,15 @@ # # ############################################################################## -README for MHonArc -v1.2.3 - - - --------------------------------------------------------------------------- -Table of Contents: - CONTENTS - DOCUMENTATION - INSTALLATION - MAILING LIST - BUGS/COMMENTS/SUGGESTIONS? + README for MHonArc + v2.0.1 + + http://www.oac.uci.edu/indiv/ehood/mhonarc.html --------------------------------------------------------------------------- MHonArc -- Internet mail-to-HTML converter - Copyright (C) 1995,1996 Earl Hood, ehood@isogen.com + Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -49,152 +42,112 @@ Table of Contents: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + You should have received a copy of the GNU General Public + License along with this program; if not, write to the Free + Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, + MA 02111-1307, USA. --------------------------------------------------------------------------- CONTENTS -ACKNOWLG Thanks to people -CHANGES Revision history of MHonArc -COPYING GNU General Public License -README The file you are reading -RELNOTES Release notes for MHonArc (please read) -bat/ Batch files for MS-DOS users -doc/ Documentation for MHonArc -examples/ Example resource files for MHonArc -extras/ Extra programs for use with MHonArc (See extras/README) -install.cfg Base installation configuration file -install.me Installation program for MHonArc -lib/ Libraries/MIME filters used by MHonArc -logo/ Gifs of the MHonArc logo -mhonarc* The MHonArc program - ---------------------------------------------------------------------------- -DOCUMENTATION - -Documentation for MHonArc is located in the doc/ directory. - -html: - The main documentation for MHonArc is in multiple HTML files. Load - mhonarc.html in the doc/ directory into your Web browser to get - started. The HTML is generated from the Frame source via - MifMucker, - . - -postscript: - The postscript file, mhonarc.ps, is available if a hardcopy version - of the documentation is required. Since the cross-references used - are designed for HTML reading (ie they get converted into - hyperlinks), they may not be as useful for hardcopy reading. - The postscript is generated from the Frame source. - -ascii: - A plain text version of the documentation is in the single file - mhonarc.txt. This file is created by converting the HTML files - into ascii. See the Makefile in doc/ for how the conversion is - done. - -manpage: - For Unix users, there is a manpage in doc/ called mhonarc.1. It - is not very fancy. It is automatically generated like the - ascii version. The manpage does not follow the standard manpage - style and is not intended to be printed via troff. - -The installation process does not deal with the manpage or postscript -file. If you want to install them, you must do it manually. The -installation process does allow you to install the HTML and ASCII -documentation in a location of your choice. +ACKNOWLG Thanks to people +BUGS Bug list +CHANGES Revision history of MHonArc +COPYING GNU General Public License +INSTALL Instructions on how to install MHonArc +README The file you are reading +RELNOTES Release notes for MHonArc (please read) +bat/ Batch files for MS-DOS users +doc/ Documentation for MHonArc +examples/ Example resource files for MHonArc +extras/ Extra programs for use with MHonArc (See extras/README) +faq/ FAQ for MHonArc +install.cfg Base installation configuration file +install.me Installation program for MHonArc +lib/ Libraries/MIME filters used by MHonArc +logo/ Gifs of the MHonArc logo +mhonarc* The MHonArc program --------------------------------------------------------------------------- INSTALLATION -This section gives the basic method for installing MHonArc on a Unix or -MS-DOS/Windows system. The documentation (doc/install.html) contains -an installation section with more detailed information. You can also -read the detailed instructions at - - -Brief Instructions - - Interactive Installing: - - Run the following command: - - perl install.me - - The installation program will ask you a series of questions on - where the Perl executable is and where to put MHonArc files. - Just hit to accept the default values listed in ()'s. + Read the file INSTALL for instructions on how to install MHonArc. - Batch Install: - - 1. Edit the file 'install.cfg'. - 2. Run the following command: - - perl install.me install.cfg - - The installation program will output information on what - is being installed and where it is being installed. - -Notes on Installation Program - - o The '#!' line in the installed mhonarc program is set to - point to the Perl executable specified in the installation - process (this has no meaning under MS-DOS). +--------------------------------------------------------------------------- +DOCUMENTATION - o The installed mhonarc program has code added so it will find - its default libraries specified in the installation program. - I.e. The install lib directory is added to mhonarc's search - path so it will find its libraries. + Documentation for MHonArc is located in the doc/ directory. + The main documentation for MHonArc is in multiple HTML files. + Load mhonarc.html in the doc/ directory into your Web browser to + get started. - o If you specify paths that do not exist, the install.me - program will create the path ONLY if running in interactive - more. If using a configuration file (eg: install.cfg) you - must check that all paths specified exist. + Filenames of the documentation do NOT follow the 8.3 convention. + Therefore, you will need a filesystem that supports long names + to read the documentation locally. -Bugs in Installation Program + Some tables are used in the documentation. Therefore, having + a table-capable viewer is beneficial. If your viewer does not + recognize tables, the documentation should still be usable. - o In interactive mode, if you change a path after confirmation, - the old specified path will still exist, even if install.me - created it for you. Hence, the author recommends batch install. + Also provided is a version of the MHonArc FAQ in the faq/ + directory. The FAQ is also in HTML. Load faq.html into your + Web browser to read the FAQ. --------------------------------------------------------------------------- MAILING LIST - A MHonArc mailing list exists to provide a general discussion forum - for users and developers. To subscribe to the mailing list, send - mail to mhonarc-request@rosat.mpe-garching.mpg.de with the single - word "subscribe" (without the quotes) as the message body. + A MHonArc mailing list exists to provide a general discussion + forum for users and developers. The list is the main source for + the latest news about MHonArc. + + To subscribe to the mailing list, send mail to + mhonarc-request@rosat.mpe-garching.mpg.de with the single word + "subscribe" (without the quotes) as the message body. Mail sent to mhonarc@rosat.mpe-garching.mpg.de will be distributed to all subscribers. The WWW archive of the mailing list is located at - + (http://www.rosat.mpe-garching.mpg.de/mailing-lists/mhonarc/) + and is searchable via a Glimpse search engine. --------------------------------------------------------------------------- BUGS/COMMENTS/SUGGESTIONS? If you have any bugs/comments/suggestions about MHonArc, you may - send mail to the proper person(s) listed in the Contacts section of - the documentation, or (the prefered method) you may send mail to - the MHonArc mailing list, mhonarc@rosat.mpe-garching.mpg.de. + send mail to the MHonArc mailing list, + mhonarc@rosat.mpe-garching.mpg.de. + + NOTE: The author of MHonArc *is* subscribed to the list. If it is a bug you are reporting, please include the following in your message: o Version of Perl (can be retrievied by "perl -v"). - o Version of the program in question. + o Version of the program (can be retrievied by "mhonarc -b"). + o The operating system you are using (on Unix the output + of "uname -a" is useful). o The exact command-line used to invoke the program. o Error/diagnostic messages from the program. - o Any other information that might prove useful. + o Any other information that might prove useful (eg. input + files, resource files, environment settings, etc. Before sending e-mail, make sure the documentation does not already have an answer to your question/problem. - The latest information on MHonArc may be obtained at - +--------------------------------------------------------------------------- +USING/COPYING + + MHonArc is free to use, but feel free to send the author a donation + if you feel guilty on using a program that that cost you nothing, + but some poor soul sweated over. The author is more than happy to + provide address information to prospective donors inorder to ease + their conscience. Plus, requests from donars are more likely to + get more timely responses ;-) + + MHonArc is distributed under the GNU General Public License. + The rules for using and copying MHonArc are explained in the + file COPYING. --------------------------------------------------------------------------- -Earl Hood, ehood@isogen.com +Copyright (C) 1997, Earl Hood, ehood@medusa.acs.uci.edu +@(#) README 97/05/23 11:15:18 @(#) diff --git a/RELNOTES b/RELNOTES index b7d505c..bf72cee 100644 --- a/RELNOTES +++ b/RELNOTES @@ -1,172 +1,38 @@ -Release Notes for MHonArc - - - ---------------------------------------------------------------------------- - MHonArc -- Internet mail-to-HTML converter - Copyright (C) 1995,1996 Earl Hood, ehood@isogen.com - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ---------------------------------------------------------------------------- - -Version 1.2.3 -------------- - -This version is a minor enhancement, bug fix release. See the CHANGES -files for what was added and fixed. - -No modifications were made that require changes to the documentation -from v1.2.2. The documentation has been left untouched. - ---------------------------------------------------------------------------- - The following are release notes from previous versions of MHonArc. ---------------------------------------------------------------------------- - -Version 1.2.2 -------------- - -This version is a minor enhancement, bug fix release. See the CHANGES -files for what was added and fixed. - ---------------------------------------------------------------------------- - -Version 1.2.1 -------------- - -This version is a minor enhancement, bug fix release. See the CHANGES -files for what was added and fixed. - - -Version 1.2.0 -------------- - -The CHANGES file contains information on the changes that may affect -1.1.0 archives. Please read it. - - -Version 1.1.0 -------------- - -Database file: - 1.1.0 is able to handle 1.0.x database files. Only additions - have been made between 1.0.x and 1.1.0. - -Threading: - - o If you have a 1.0 archive, you can generate a thread index - for it with the following: - - mhonarc -thread -editidx ... - - NOTE: You will also need to (re)specify the LISTBEGIN - resource so a link to the thread index exists on the main - index page. See the section on _Index Page Customization_ - in the documentation for more information. - - o You can prevent the creation of the thread index by the - following: - - * Set the M2H_THREAD environment variable to 0. - * Specify the NOTHREAD resource file element. - * Use the -nothread option. - - o Remember, the thread index does not replace the main index. - It compliments the main index. If using a custom layout, - resource variables are available to link between the 2 - indexes. - - -The following note is only relevant if you have developed your own -MIME filters for use in MHonArc: - - o MHonArc now treats the return value from MIME filters as - an array. The first value of the array is treated as the - HTML text to use in the message. All other array values are - treated as names of files that the filter may have generated - (eg. mhexternal.pl). MHonArc stores the filenames in the - database. Therefore, MHonArc can delete any extra files - associated with a message if the message is removed via the - -rmm option. - - -Version 1.0.0 -------------- -* (See also Beta User Notes below if you were a user of 1.0.0 beta) - -The release notes for version 1.0.0 of MHonArc address compatiblity -issues with the mail2html 3.1.x program. - - o The database file is compatible with mail2html database - files, however the icon support feature will not work - properly. Recreate the archive with MHonArc if icon usage - is desired. - - o The database filename has been renamed to ".mhonarc.db". - HOWEVER, MHonArc will use the ".mail2html.db" file when - adding to archives created with mail2html. - - o Many of the index page resource settings have been eliminated, - like DATE and SUBONLY. The same effects can be obtained by - using the LITEMPLATE resource element. - - o The STAMP resource has been eliminated since the same effect - can be achieve with the LISTBEGIN or LISTEND resource elements. - - o The USERSUBS resource element has been eliminated. You can - achieve the same results by writing your own MIME filter, or - modifying the existing ones. - - -1.0.0 Beta User Notes ---------------------- - - o The number of library files have been reduced (beta 8). The - library 'mhexternal.pl' is a merging of the application, - audio, image, and video libraries. mhexternal.pl covers all - the content-types in the old filters, plus much more. The - library is designed to be a catch-all library for - content-types that get filtered to external files. - - **IMPORTANT NOTE: Because of the change in libraries, any - archive database files created with beta version less than 8 - will cause MHonArc to abort abnormally: i.e. Perl aborts - because it cannot require the libraries specified in the - database file. You can utilize the file deffilters.rc in - the examples directory, with the -rcfile option, to update - the database when adding new mail. - - o The PERLINC resource element is recognized (beta 8). The - docs used PERLINC, but the code used PERLLIB. Also, the - paths specified in the PERLINC resource element are saved - to the database. - - o The default filter libraries' filenames have been renamed to - 14 characters, or less (beta 5). This is to avoid conflicts - with older Unix file systems with filename limits. See - **IMPORTANT NOTE above about the effects of library filename - changes. - - o The default filters had a bug fixed in them (beta 5). - Content-Description text is now properly "htmlized". - - o The $CURDATE$ variable went away for the LISTBEGIN or - LISTEND resource elements (beta 3). Use $GMTDATE$ to get - the current date based off GMT time, and use $LOCALDATE$ to - get the local date and time for your timezone. $CURDATE$ - used to give only the GMT date and time. - - ---------------------------------------------------------------------------- -Earl Hood, ehood@isogen.com +Release Notes for MHonArc + + http://www.oac.uci.edu/indiv/ehood/mhonarc.html + +Also read the CHANGES document for changes they may affect +you if you are a user of an earlier version of MHonArc. + +=========================================================================== + +Version 2.0.1 + + See the BUGS file for an important bug fix related to + empty database entries. + +--------------------------------------------------------------------------- + +Version 2.0.0 + + o The installation process has changed slightly. Please + read the installation instructions in the README + carefully. + + o Documentation is now provided only in HTML. + + o There are some changes to how data is stored in the + database file from v1.x. If MHonArc v2.0 reads a 1.x + archive, it will automatically convert the 1.x data into + 2.0 data. All existing resource settings will be preserved. + + NOTE + Once an archive has been processed by v2.0, the + database may no longer be utilized by v1.x. If + v1.x is used later to process the archive, + unpredictable results will occur. + + +=========================================================================== +97/05/22 19:01:12 diff --git a/bat/README b/bat/README index e8944d7..2e574b0 100644 --- a/bat/README +++ b/bat/README @@ -13,7 +13,7 @@ NOTES The batch files are for your use if you are running MHonArc under MS-DOS. Edit the paths in the files to reflect where you have installed MHonArc via the install.me program. Then copy the batch -files to a location in your executable searc path. +files to a location in your executable search path. --------------------------------------------------------------------------- -Earl Hood, ehood@convex.com +Copyright (C) 1997, Earl Hood, ehood@medusa.acs.uci.edu diff --git a/doc/Makefile b/doc/Makefile deleted file mode 100644 index d8cf761..0000000 --- a/doc/Makefile +++ /dev/null @@ -1,32 +0,0 @@ -HTMLDOCS = \ - mhonarc.html \ - intro.html \ - install.html \ - qstart.html \ - overview.html \ - rcfile.html \ - adding.html \ - removing.html \ - indexpg.html \ - message.html \ - mime.html \ - details.html \ - diagnos.html \ - glossary.html \ - contacts.html - -TMPFILE = ,mhonarc -TEXTDOC = mhonarc.txt -MANPAGE = mhonarc.1 - -$(TEXTDOC): $(HTMLDOCS) mktxt - /bin/rm -f $(TMPFILE) $(TEXTDOC) $(MANPAGE) - @for i in $(HTMLDOCS) ;\ - do \ - echo $$i ;\ - lynx -dump -nolist $$i >> $(TMPFILE) ;\ - done - perl mktxt < $(TMPFILE) - /bin/rm -f $(TMPFILE) - chmod 644 $(TEXTDOC) $(MANPAGE) - diff --git a/doc/adding.html b/doc/adding.html deleted file mode 100644 index 8b2aad8..0000000 --- a/doc/adding.html +++ /dev/null @@ -1,138 +0,0 @@ - - - -MHonArc v1.2.2 -- Adding Messages - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
- -

Adding Messages -

- -

Adding messages to an archive is done via the -add option. If no mailbox/folder -arguments are given, MHonArc assumes that a single message is being added to -the archive via standard input. Otherwise, MHonArc adds the messages contained -in the mail folders specified. -

-
-
NOTE - -

MHonArc will skip any messages that already exist in an archive. If a -message to be added has a message-ID that equals a message-ID of an -archived message, the message is skipped. -

-
-

Examples -

- -

Adding a mail folder -

- -

Here is example session adding an mail folder to an existing archive: -

-
% mhonarc -add test/www
-Requiring MIME filter libraries ...
-        mhexternal.pl
-        mhtxthtml.pl
-        mhtxtplain.pl
-        mhtxtsetext.pl
-Adding messages to ./maillist.html
-Reading test/www/ ........................................
-Writing HTML ...
-49 messages
-
-
- -

.forward -

- -

MHonArc can be used to add new messages as they are received by using the -".forward" file in your home directory. Here is how I would set up my -.forward file to invoke MHonArc on incoming mail: -

-
\ehood, "|/mnt/ehood/bin/webnewmail #ehood"
-
-
- -
-
NOTE on .forward entry: - -

The "\ehood" tells sendmail to still deposit the incoming message to my -mail spool file. The "#ehood" Bourne shell comment is needed to insure -the command is unique from another user. Otherwise, sendmail may not -invoke the program for you or the other user. -

-

"webnewmail" is a Perl program that calls MHonArc with the appropriate -arguments. A wrapper program is used instead of calling MHonArc directly to -keep the .forward file simple. Here is the code to the webnewmail program: -

-
#!/usr/local/bin/perl
-
-$cmd = "/mnt/ehood/bin/mhonarc -add -quiet " .
- "-outdir /mnt/ehood/public_html/newmail";
-open(M2H, "|$cmd");
-print M2H <STDIN>;
-close(M2H);
-
-
- -

The webnewmail can be modified to check the mail header before calling -MHonArc to perform selective archiving of messages. For example, webnewmail -can check the To: field and only archive messages that come from a specific -mailing list. -

-

Cron -

- -

This example uses cron(1) to update some mail archives from MH mail folders. -

-

The following entry is in my crontab file: -

-
0 0 * * * webmail
-
-
- -

webmail is a script executed every night that calls MHonArc to perform the -update: -

-
#! /bin/csh -f
-
-umask 022
-setenv M2H_RCFILE $HOME/.mhonarc.rc
-## WWW messages
-mhonarc -add \
-          -outdir $HOME/public_html/doc/wwwmail \
-          $HOME/mail/www
-folder +www >& /dev/null
-refile first-last +www.ar >& /dev/null    # Archive original messages
-
-## Tools messages
-mhonarc -add \
-          -outdir $HOME/public_html/doc/toolsmail \
-          $HOME/mail/tools $HOME/mail/dtd
-folder +tools >& /dev/null
-refile first-last +tools.ar >& /dev/null  # Archive original messages
-folder +dtd >& /dev/null
-refile first-last +dtd.ar >& /dev/null    # Archive original messages
-
-folder +inbox >& /dev/null                # Set current folder to inbox
-
-
-
- -

To avoid mail everynight from cron due to output from MHonArc, the -quiet -option can be used for each call to MHonArc, or use the following line in your -crontab file: -

-
0 0 * * * webmail > /dev/null
-
- -

Standard error is not redirected to /dev/null so mail is still received if errors -occured during MHonArc execution. -

- -
-[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/bugs.html b/doc/bugs.html new file mode 100644 index 0000000..2e04fc3 --- /dev/null +++ b/doc/bugs.html @@ -0,0 +1,659 @@ + + + + +MHonArc -- Bugs + + + + +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+ +
+ +

Bugs

+ +

The following gives a list of bugs reported against +MHonArc. Each bug listing shows the version the +bug was reported against, a decription of the problem, +and if applicable, a solution and version of MHonArc +the bug was fixed. +

+ +

Bug List

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Version2.0.0
ProblemBogus empty entry shows up in the database. Bogus entry appears if a duplicate message is detected. + Potential visible problems of bogus entry are: mailto + links in headers corrupted; a blank listing in the + index. Maybe other potential problems. +
SolutionThere is a be a bug in some versions of Perl where a hash key gets added invalidly. The section of code that + this occurs has been modified to avoid the problem. + For existing databases with a bogus empty entry, + MHonArc now removes any empty key entries. + However, it is recommed to rebuild the archive. +
Fixed2.0.1

Version2.0.0
ProblemIndex pages are not properly updated if zero messages are in the archive (like through the -rmm option). + Even -editidx cannot cause a proper update. +
SolutionPage count was set to zero when no messages exist. This caused problems in conditional checks in the write index + routines. To fix, page count is forced to 1 if their + are no messages. +
Fixed2.0.1

Version2.0.0 beta 3
ProblemIndex pages with last page links are not updated when a new page is added. +
SolutionAll index pages are regenerated if a new page is added. +
Fixed2.0.0

Version2.0.0 beta 3
Problem"-idxsize 0" does not give unlimited page size.
SolutionProblem fixed and now works as documented.
Fixed2.0.0

Version2.0.0 beta 3
Problem"-maxsize 0" does not reset archive with unlimited messages allowed. +
SolutionProblem fixed and now works as documented.
Fixed2.0.0

Version2.0.0 beta 3
ProblemNon-ASCII text encodings (=?ISO-..?...) are not properly decoded when EDITIDX is set. +
SolutionThe charset filter libraries are now loaded for EDITIDX. +
Fixed2.0.0

Version2.0.0 beta 3
ProblemMODTIME resource setting not remembered across archive updates. +
SolutionMODTIME resource is now properly stored in the database. +
Fixed2.0.0

Version2.0.0 beta 3
ProblemSpecifying -rmm and -single caused confusion on what MHonArc does. +
SolutionThe case is properly handled, with -rmm taking precedence. +
Fixed2.0.0

Version2.0.0 beta 3
Problem4 digit year not checked before 2 digit year when parsing dates. +
SolutionFixed.
Fixed2.0.0

Version2.0.0 beta 3
ProblemSome index pages in multipage indexes not updated when messages expire. +
SolutionFixed; all pages are regenerated when a message expires. +
Fixed2.0.0

Version2.0.0 beta 3
ProblemSetting MONTHS and MONTHSABR had no effect.
SolutionFixed.
Fixed2.0.0

Version2.0.0 beta 3
Problem$TNEXTFROM$ actually gave the value of $NEXTFROM$.
SolutionFixed.
Fixed2.0.0

Version2.0.0 beta 3
ProblemNumerical timezone offsets not handled properly when the offset contained non-zero minutes. This + caused message to be sorted wrong by date. +
SolutionFixed.
Fixed2.0.0

Version2.0.0 beta 3
ProblemSome characters were not properly escaped when specifying the "in URL" modifier to a resource + variable. +
SolutionFixed.
Fixed2.0.0

Version2.0.0 beta 3
ProblemThread (formatting) information lost when a thread is split across multiple pages. +
SolutionFixed. New resources (TCONTBEGIN, TCONTEND, TINDENTBEGIN, TINDENTEND) exist to preserve + formatting of threads across pages. +
Fixed2.0.0

Version2.0.0 beta 3
ProblemIf specifying the REVERSE resource, the next/prev links in messages do not point to the proper + message as one may expect. +
SolutionThis should be fixed by the new behavior of $NEXT...$ and $PREV...$ resource variables. +
Fixed2.0.0

Version2.0.0 beta 2
ProblemPerl aborts with message "Undefined subroutine &main::output_db called ..." when the GENIDX resource + is set. +
SolutionFixed. The output_db function is not applicable when GENIDX is active. +
Fixed2.0.0 beta 3

Version2.0.0 beta 2
ProblemDuplicate resource filenames are not removed from the OTHERINDEXES resource. This caused duplicate work + to be performed. +
SolutionFixed. Any duplicate filenames are removed before applying the OTHERINDEXES resource. +
Fixed2.0.0 beta 3

Version2.0.0 beta 2
ProblemIndexes created via the OTHERINDEXES resource contain no messages. +
SolutionFixed.
Fixed2.0.0 beta 3

Version2.0.0 beta 2
ProblemThe markup defined by TSUBLISTEND may appear when there is no corresponding TSUBLISTBEG. +
SolutionFixed.
Fixed2.0.0 beta 3

Version2.0.0 beta 1
ProblemA multipart boundary specified with a capital boundary parameter, and not in quotes, was not recognized. +
SolutionFixed
Fixed2.0.0 beta 2

Version1.2.3
ProblemGeneration of links of message-ids when editting messages w/o consideration that the message-ids + may already be linked. This caused nested anchor + markup. +
SolutionFixed. Only new message-ids are checked for.
Fixed2.0.0 beta 1

Version1.2.2
ProblemThe ';' character may appear in derived files if the "usename" option is set for the mhexternal.pl filter. +
SolutionFixed.
Fixed1.2.3

Version1.2.2
ProblemThe '/' character is not properly recognized in e-mail addresses when e-mail addressess are being converted + to mailto links in message headers. +
SolutionFixed.
Fixed1.2.3

Version1.2.2
ProblemDatabase read failures occur in add operations on MS-DOS systems. +
SolutionFixed (?)
Fixed1.2.3

Version1.2.1
ProblemThe TIDXPGEND resource actually sets the value of the TIDXPGBEG resource. +
SolutionFixed.
Fixed1.2.2

Version1.2.0
ProblemMHonArc will abort execution under MS-DOS due to regular expression error. +
SolutionFixed.
Fixed1.2.1

Version1.2.0
Probleminstall.me will abort execution under MS-DOS due to regular expression error. +
SolutionFixed.
Fixed1.2.1

Version1.2.0
ProblemA reverse index listing is incorrect if the index size is less than the archive size. +
SolutionFixed.
Fixed1.2.1
+ + +
+ +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+ + + +
+
+97/05/22 20:02:37
+ +MHonArc
+Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
+
+ + + diff --git a/doc/contacts.html b/doc/contacts.html index 09c1fac..7bca7a5 100644 --- a/doc/contacts.html +++ b/doc/contacts.html @@ -1,68 +1,106 @@ + -MHonArc v1.2.2 -- Contacts +MHonArc -- Contacts -[Previous][Contents][FAQ][Bugs][Home] -
-

Contacts -

+ +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+
-

Mailing List -

-

A mailing list, mhonarc@rosat.mpe-garching.mpg.de, is available to provide a -discussion forum on the usage and development of MHonArc. Appropriate topics -for the list include: usage questions, bug reports, behavioral enhancements, -documentation bugs, and general help. -

-

To subscribe to the mailing list, send mail to -mhonarc-request@rosat.mpe-garching.mpg.de with the command, -

-
subscribe
+

Contacts

+ +
+

Mailing List

+ +

A mailing list, mhonarc@rosat.mpe-garching.mpg.de, is available to +provide a discussion forum on the usage and development of +MHonArc. Appropriate topics for the list include: usage +questions, bug reports, behavioral enhancements, documentation bugs, +and general help.

+ +

To subscribe to the mailing list, send mail to mhonarc-request@rosat.mpe-garching.mpg.de with the command,

+
+subscribe
 

as the message body.

-

If you send mail mhonarc@rosat.mpe-garching.mpg.de, your message will be -distributed to all subscribers on the list. -

-

The mailing list is archived by Majordomo. You can also use the WWW to access -the archive (with full text search using glimpse) at -<URL:http://www.rosat.mpe-garching.mpg.de/mailing-lists/mhonarc/> + +

If you send mail mhonarc@rosat.mpe-garching.mpg.de, your message will be +distributed to all subscribers on the list.

+ +

The mailing list is archived by Majordomo. You +can also use the WWW to access the archive (with +full text search using glimpse) at <URL:http://www.rosat.mpe-garching.mpg.de/mailing-lists/mhonarc/>

-
-

People -

+ +
+

People

+ +

The people listed here are those responsible for development +and support of MHonArc.

Earl Hood
-ehood@isogen.com - -

Main developer of MHonArc. Contact for bug reports, behavioral -enhancements, documentation bugs, and Unix usage issues. +ehood@medusa.acs.uci.edu +

Creator and developer of MHonArc. Also author +of the documention, for what it is worth.

+
Steve Pacenka
sp17@cornell.edu - -

Contributing developer. Worked on isolating code that would conflict -with MS-DOS. Contact for MS-DOS installation problems or MS-DOS -usage issues. +

Contributer: Helped in making MHonArc run under MS-DOS/Windows +environments.

+
Achim Bohnet
-ach@rosat.mpe-garching.mpg.de +ach@rosat.mpe-garching.mpg.de +

Administrator, and maintainer, of the +MHonArc mailing list.

-

Contributing developer. Administrator, and maintainer, of the MHonArc -mailing list. -

+
+
MHonArc users
+mhonarc@rosat.mpe-garching.mpg.de +

Everyone who helps answer questions and make comments +to improve the quality of MHonArc. +

+

-[Previous][Contents][FAQ][Bugs][Home] + +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+ + +
+
+97/05/15 16:53:45
+ +MHonArc
+Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
+
+ diff --git a/doc/details.html b/doc/details.html deleted file mode 100644 index 44ee035..0000000 --- a/doc/details.html +++ /dev/null @@ -1,185 +0,0 @@ - - - -MHonArc v1.2.2 -- Gory Details - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
- -

Gory Details -

- -

This sections explain in detail how MHonArc functions. Knowing the material -covered in this section may help you when trouble shooting. -

-
-

OS Detection -

- -

MHonArc will automatically detect which operating system it is running under. If -the following list of conditions are true, MHonArc assumes it is running under -MS-DOS: -

-
    -
  • The COMSPEC environment variable is defined. -
  • The value of the COMSPEC environment variable is a legal MS-DOS -pathname. -
  • The value of the COMSPEC environment variable is an executable file. -

-

If any of the above conditions is false, MHonArc assumes it is running under Unix. -

-
-
NOTE - -

The previous conditions are used since the conditions will exist if Perl has -been installed on an MS-DOS machine. None of the above conditions exist -when Perl is installed on a Unix system. -

-
-

Processing Steps -

- -

This section describes the steps MHonArc performs when creating/editting an -archive. Anytime messages are added or deleted or the index page layout is -changed, MHonArc will perform the following steps. -

-
    -
  • Creates a lock file. This insures only one MHonArc process is updating the -archive at any given moment. See Archive Integrity for more information. -

  • Reads the database file. The name, and location, of the database file can be -explicitly specified via the M2H_DBFILE and M2H_OUTDIR environment -variables or the command-line options -dbfile and -outdir. -Otherwise, the current working directory is used. -

    NOTE: The database file must be in the same location as the archive since the -M2H_OUTDIR variable and -outdir option also specify the location of the -archive. -

    The database file contains data to update any mail threads and the -resource settings when MHonArc was last invoked. This allows new -messages to contain the same formatting/resource specifications as -existing messages in the archive without having to re-specify the resources -each time new messages are added. Resources defined in the database file -override the environment variables. -

    NOTE: If no database file is found, MHonArc will create a new archive. -

  • Read the MHonArc resource file, if specified. The resource file will override -any settings contained in the database file. -

  • Read the settings specified on the command-line. Command-line options -override any settings in the database and/or resource file. -

  • Update archive. -

  • Rewrites the index pages to reflect the update. -

  • Writes a new database file containing the new state of the archive and all -(new) resource settings. -

-

Normally, knowing all the previous steps is unnecessary. However, it may be -useful to be aware of them if unexpected behavior, or errors, occur. -

-
-

Archive Integrity -

- -

MHonArc applies safeguards to try to insure that a mail archive does not get -corrupted due to exceptional circumstances. MHonArc does the following to insure -a mail archive does not get corrupted: -

-
    -
  • MHonArc creates a lock file, ".mhonarc.lck", when creating/updating -an archive. The lock file insures that only one MHonArc process is -modifying an archive at any given moment. The -locktries -command-line option, or the M2H_LOCKTRIES environment variable, -allows you to control how long a given MHonArc process will wait if an -archive is currently locked. If MHonArc can not lock the archive after the -specified number of tries, MHonArc will exit, unless the -force option is -specified. -

  • MHonArc will ignore the following signals once messages are actually -being written to disk: SIGABRT, SIGHUP, SIGINT, SIGQUIT, SIGPIPE, -SIGTERM. Possible archive corruption can still occur if a SIGKILL signal -is received since SIGKILLs are uncatchable. A SIGKILL will also prevent -MHonArc from deleting the lock file. -

-
-

File Formats -

- -

Database File -

- -

The MHonArc database file is actual Perl code. MHonArc requires it like any other -Perl library to load in the contents of the database. -

-
-
CAUTION - -

You should never modify the database file by hand. Changing the file by -hand could cause future incorrect/unpredictable behavior when -processing the archive. -

-

Index and Message Files -

- -

The indexes and message files are legal HTML documents. However, manual -editting of the documents is discouraged. The documents contain special comment -declarations. The comment declarations act as markers which allow MHonArc to -correctly edit the documents when needed. -

-

The comment declarations look like the following: -

-
<!--X-Body-Begin-->
-<!--X-User-Header-->
-<!--X-User-Header-End-->
-<!--X-TopPNI-->
-...
-
-
- -

Derived Files -

- -

Derived files are files that are generated by the MIME filters. These files are created -when the data being processed in messages cannot be converted to HTML (eg. -images, postscript, video, binaries). The format of these files depend on the -content-type of the data. -

-
-

Notes -

- -
    -
  • Here is the explicit order of decreasing precedence when setting -resources/options: -

      -
    • command-line options (highest precedence) -
    • resource file -
    • database file -
    • environment variables (lowest precedence) -

    -
  • Mail thread detection is dependent upon the mail messages containing the -message id(s) of referenced messages. Most mailers reply function will -automatically include the message id of the message being replied to. -

  • All mail message being converted into HTML are stored in memory before -they are written to disk. This can eat up much memory if many mail -messages are being converted. If you are processing multiple -mailboxes/folders and worried about memory, you can try the following: -

      -
    • Invoke MHonArc on each one separately using the -add option. -
    • Or, invoke MHonArc with the -savemem option. -

    -
  • The database file, and the index pages, are completely rewritten evertime -new messages are added. This may cause slight slow-downs when -archives become very large. -

  • When reading MH mail folders, mail message are assumed to have -numeric filenames. -

  • When sorting by date, MHonArc tries to use the date listed in the first -Received field of the message. If no Received field exists, than the Date field -is used. -

  • No distinction is made, in the output, on which messages came from -which mail folder if multiple mail folders are processed. -

  • MHonArc can probably be modified to handle other types of mailers -(which has been done since the original version only supported MH mail -folders). The MSGSEP resource gives flexibility in processing Unix style -mailbox files. -

- -
-[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/diagnos.html b/doc/diagnos.html index b1d7a80..5853032 100644 --- a/doc/diagnos.html +++ b/doc/diagnos.html @@ -1,231 +1,240 @@ - -MHonArc v1.2.2 -- Diagnostics - +MHonArc -- Diagnostics + -[Previous][Next][Contents][FAQ][Bugs][Home] -
-

Diagnostics -

+ +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+ -

Three types of messages exist in MHonArc: Informative messages, Warnings, and -Errors. Informative messages give you the current status of MHonArc's execution. -Warnings signify undesired conditions, but are not critical in MHonArc's exection. -Errors signify critical conditions that inhibit MHonArc from finishing its task. -

-

Another set of messages exists that are generated from the Perl interpreter itself. -MHonArc tries its best to catch any conditions that may cause Perl to abnormally -abort, but conditions may arise where this is not possible. -

-

This section describes the various diagnostics MHonArc may produce and -messages Perl may produce. -


-

Informative messages -

-

Informative messages may be suppressed via the -quiet command-line option. -Only the more important Informative messages are listed here. -

-

Could not process message with given Content-Type: ... -

+

Diagnostics

-

MHonArc will output this statement in filtered mail messages for content-types it -is unable to process. See Default Filters in MIME for content-types that MHonArc -supports by default. See Writing Filters for adding new filters into MHonArc. -

-

This is the only Informative message that does not go to standard output, but into -the actual filtered mail message. -

-

No new messages -

+

Three types of messages exist in MHonArc: +Informative messages, Warnings, and +Errors. Informative messages give you the +current status of MHonArc's execution. Warnings +signify undesired conditions, but are not critical in +MHonArc's exection. Errors signify critical +conditions that inhibit MHonArc from finishing its task.

-

No mail messages exist when performing an add operation to an archive. This can -occur if an empty MH mail folder, or empty mailbox file, is passed to MHonArc. -

-

Requiring MIME filter libraries ... -

+

Another set of messages exists that are generated from the Perl +interpreter itself. MHonArc tries its best to catch any +conditions that may cause Perl to abnormally abort, but conditions +may arise where this is not possible.

This section describes +the various diagnostics MHonArc may produce and messages +Perl may produce.

-

Indicates MHonArc is loading external libraries for filtering mail messages. -MHonArc will output each library it loads. See MIME for more information of filter -libraries. -

-

Trying to lock mail archive ... -

+
+

Informative messages

-

The statement means that a lock file is in place for the archive you are trying to -update. Normally, an existing lock file implies that another MHonArc process is -currently using the archive, and other MHonArc processes will wait awhile to see -if the archive will be unlocked. -

-

However, there are times when a lock file exists, but no MHonArc process is -modifying the archive. This can occur if MHonArc is abnormally terminated. If you -know that no other MHonArc process is editting the archive you are try to modify, -then manually remove the lock file or use the -force option. -

-

See Archive Integrity for more information. -

-
-

Warnings -

+

Informative messages may be suppressed via the +QUIET resource. +Only the more important Informative messages are listed here.

-

Warning messages denote some undesired event occurred, but the event is not -severe enough to cause program termination. -

-

Warning: Could not find date for message -

+

No new messages

-

MHonArc was unable to find a received/sent date for a mail message. With respect -to other mail messages, a message with no received/sent date is first in -chronological order. -

-

Warning: Database (<dbversion>) != program (<prgversion>) version -

- -

Indicates that the version of MHonArc updating an archive is different from the -version of MHonArc that created the database file. Problems can arise if the -database file changes in format from different version of MHonArc. See the release -notes of the MHonArc distribution if changes in the databse format has effects on -older archives. +

No new mail messages exist when performing an add operation to an +archive. This can occur if an empty MH mail folder, or empty +mailbox file, is passed to MHonArci; or the folder +contains messages already in the archive.

-

Warning: Unable to create <outdir>/<dbfile> -

-

Indicates MHonArc was unable to create the database file <dbfile> for the mail -archive created/modified in <outdir>. This message can occur if <outdir> -permissions changed during MHonArc execution, the existing <dbfile> is read-only, -or the file system is full. -

-

This message can be severe because no future add operations can be performed to -the archive. -

-

Warning: Unable to open footer: <footer> -

+

Requiring MIME filter libraries ...

-

MHonArc was unable to open the footer file, <footer>, for inclusion into the index -page. Make sure <footer> exists, and is readable by you. -

-

Warning: Unable to open header: <header> -

+

Indicates MHonArc is loading external libraries for +filtering mail messages. MHonArc will output each library +it loads. See MIMEFILTERS for more +information of filter libraries.

-

MHonArc was unable to open the header file, <header>, for inclusion into the index -page. Make sure <header> exists, and is readable by you. -

-

Warning: Unable to open <folder> -

+

Trying to lock mail archive ...

-

MHonArc was unable to open the specified mail <folder> for reading. Make sure -<folder> exists and is readable (and executable if a directory) by you. -

-

Warning: Unable to open message: <folder>/<message> -

+

The statement means that a lock file is in place for the archive +you are trying to update. Normally, an existing lock file implies +that another MHonArc process is currently using the archive, +and other MHonArc processes will wait awhile to see if the +archive will be unlocked.

-

MHonArc was unable to open the specified MH mail message <folder>/<message> -for reading. Make sure <folder>/<message> exists and is readable by you. -

-

Warning: Unable to open resource file: <file> -

+

However, there are times when a lock file exists, but no +MHonArc process is modifying the archive. This can occur +if MHonArc is abnormally terminated. If you know that no +other MHonArc process is editting the archive you are +try to modify, then manually remove the lock file or use the +FORCE resource.

-

MHonArc was unable to open the resource file, <file>, for reading. Make sure <file> -exists, and is readable by you. -

-

Warning: Undefined time zone: "<timezone>" -

+
+

Warnings

-

MHonArc has found an unrecognized timezone acronym, <timezone>, in a mail -message. You can tell MHonArc about other timezone acronyms, and their hour -offset to UTC, by using the TIMEZONES resource element of the Resource File. -

-

The timezone UTC (or GMT) is used for an undefined timezone acronym -

-
-

Errors -

+

Warning messages denote some undesired event occurred, but the +event is not severe enough to cause program termination.

-

Errors denote conditions that cause MHonArc to abort execution. -

-

Some error conditions may cause the MHonArc archive to become corrupted. If the -error occurs when MHonArc is writing files, you may have to recreate the archive -from the original messages. -

-

ERROR: Database read error of <dbfile> -

+

Warning: Could not find date for message

-

An error occured when trying to read an archive's database. The error can occur if -the database file is not readable or the file got corrupted. +

MHonArc was unable to find a date for a +mail message, or could not parse the date if the date is not +in a common format. The message is given the current date +if no date is found.

-

ERROR: Unable to create <file> -

-

MHonArc was unable to create <file>. This message can occur if the directory being -written to is not writable, a read-only file with the same name exists, or the file -system is full. -

-

ERROR: Unable to create <lockfile> after <#> tries -

+

Warning: Database (dbversion) +!= program (prgversion) version

-

The statement means that a lock file is in place for the archive you are trying to -update. -

-

Sometimes a lock file exists, but no MHonArc process is modifying the archive. This -can occur if MHonArc is abnormally terminated. If you know that no other -MHonArc process is editting the archive you are try to modify, then manually -remove the lock file or use the -force option. -

-

ERROR: Unable to open <file> -

+

Indicates that the version of MHonArc updating an archive +is different from the version of MHonArc that created the +database file. Problems can arise if the database file changes in +format from different version of MHonArc. See the release +notes of the MHonArc distribution if changes in the databse +format will effect older archives.

-

MHonArc was unable to open <file> for reading. Make sure <file> exists, and is -readable by you. -

-

ERROR: Unable to require newgetopt.pl -

+

Warning: Unable to create outdir/dbfile

-

The newgetopt.pl library is needed for MHonArc to parse the command-line. -newgetopt.pl is part of the standard Perl distribution. Make sure Perl has been -correctly installed at your site. -

-

ERROR: Unable to require timelocal.pl -

+

Indicates MHonArc was unable to create the +database file dbfile for the mail archive +created/modified in outdir. This message can occur if +outdir permissions changed during MHonArc +execution, the existing dbfile is read-only, or the +file system is full.

-

The timelocal.pl library is needed for MHonArc to process dates in messages. -timelocal.pl is part of the standard Perl distribution. Make sure Perl has been -correctly installed at your site. -

-

ERROR: Unable to require <file> -

+

This warning can be severe because no future add operations can +be performed to the archive.

-

This message signifies MHonArc was unable to require the library <file>. Make sure -you properly installed MHonArc via the installation program. If <file> is your own -custom filter, make sure you properly registered it in the Resource File. See also -Specifying Filters and the PERLINC resource element. +

Warning: Unable to open footer: footer

+ +

MHonArc was unable to open the footer file, +footer, for inclusion into the index page. Make sure +footer exists, and is readable by you.

+ +

Warning: Unable to open header: header +

+ +

MHonArc was unable to open the header file, +header, for inclusion into the index page. Make sure +header exists, and is readable by you.

+ +

Warning: Unable to open folder

+ +

MHonArc was unable to open the specified mail +folder for reading. Make sure folder +exists and is readable (and executable if a directory) by you.

+ +

Warning: Unable to open message: folder/message +

+ +

MHonArc was unable to open the specified MH +mail message folder/message for reading. Make sure +folder/message exists and is readable by you.

+ +

Warning: Unable to open resource file: file +

+ +

MHonArc was unable to open the resource file, +file, for reading. Make sure file exists, and +is readable by you.

+ +

Warning: Undefined time zone: "timezone" +

+ +

MHonArc has found an unrecognized timezone +acronym, timezone, in a mail +message. You can tell MHonArc about other timezone +acronyms, and their hour offset to UTC, by using the TIMEZONES resource

-
-

Perl Messages -

-

Generally, if execution is aborted and the following error messages appear, then -you will have to manually delete the lock file since MHonArc will not have the -chance to delete the file. +

The timezone UTC (or GMT) is used for an undefined timezone acronyms.

-

Can't locate <file> in @INC at <file> line <number>. -

-

A library that MHonArc tried to load was not found in the Perl include search -paths. This error usually implies that MHonArc was not installed correctly. Make -sure that MHonArc was installed via the install.me program that is provided in -the MHonArc distribution. +


+

Errors

+ +

Errors denote conditions that cause MHonArc to abort +execution.

+ +

Some error conditions may cause the MHonArc archive to +become corrupted. If the error occurs when MHonArc is writing +files, you may have to recreate the archive from the original messages.

-

<file> did not return a true value at <file> line <number>. -

-

If you are using your own MIME filters with MHonArc, make sure the library files -return 1. +

ERROR: Database read error of dbfile

+ +

An error occured when trying to read an archive's database. The +error can occur if the database file is not readable or the file +got corrupted.

+ +

ERROR: Unable to create file

+ +

MHonArc was unable to create file. This +message can occur if the directory being written to is not writable, a +read-only file with the same name exists, or the file system is full.

+

ERROR: Unable to create lockfile after # tries +

+ +

The statement means that a lock file is in place for the archive +you are trying to update.

+ +

Sometimes a lock file exists, but no MHonArc +process is modifying the archive. This can occur if +MHonArc is abnormally terminated. If you know that no +other MHonArc process is editting the archive you are +try to modify, then manually remove the lock file or use the FORCE resource.

+ +

ERROR: Unable to open file

+ +

MHonArc was unable to open file for reading. Make +sure file exists, and is readable by you.

+ +

ERROR: Unable to require perl-library

+ +

Make sure you properly installed MHonArc. Also +make sure Perl is installed properly if the library is a standard +Perl library. +

+ +
+

Perl Messages

+ +

Generally, if execution is aborted and the following error messages +appear, then you will have to manually delete the lock file since +MHonArc will not have the chance to delete the file.

+ +

Can't locate file in @INC at file line number. +

+ +

A library that MHonArc tried to load was not found +in the Perl include search paths. This error usually implies +that MHonArc was not installed correctly. Make sure that +MHonArc was installed via the install.me program +that is provided in the MHonArc distribution.

+ +

file did not return a true value at file line number.

+ +

If you are using your own MIME filters with MHonArc, make +sure the library files return 1.

+ +
+ +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+ +
-[Previous][Next][Contents][FAQ][Bugs][Home] +
+97/05/15 16:48:57
+ +MHonArc
+Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
+
+ diff --git a/doc/glossary.html b/doc/glossary.html deleted file mode 100644 index 6b081cf..0000000 --- a/doc/glossary.html +++ /dev/null @@ -1,48 +0,0 @@ - - - -MHonArc v1.2.2 -- Glossary - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
- -

Glossary -

- -
-
HTML - -

Hypertext Markup Language. HTML is the main document markup -language for the World Wide Web. -

-
-
MIME - -

Multipurpose Internet Mail Extensions. MIME allows the transmission of -non-ASCII data, and mixed content data, in electronic mail messages. -

-
-
MH - -

Message Handler. MH is a free message handling system initially -developed by the RAND Corporation, with subsequent development done -at the University of Califonia: Irvine. -

-
-
Perl - -

Practical Extraction and Report Language. Perl is an interpreted -programming language suited for processing text and generating reports. -

-
-
SGML - -

Standard Generalized Markup Language. SGML is a language for -document representation. -

- -
-[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/indexpg.html b/doc/indexpg.html deleted file mode 100644 index c344dfe..0000000 --- a/doc/indexpg.html +++ /dev/null @@ -1,422 +0,0 @@ - - - -MHonArc v1.2.2 -- Index Page Customization - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
- -

Index Page Customization -

- -

MHonArc creates an index page with links to all mail messages filtered (unless -processing a single message with the -single option). MHonArc allows you to -have complete customization over the appearance of the index page by setting -various resource either through environment variables, command-line options, or -the resource file. -

-
-

Filename -

- -

By default, the filename of the index page is "maillist.html". However, a -different name may be specified with the M2H_IDXFNAME environment variable, -the IDXFNAME resource element, or the -idxfname command-line option. -

-
-

Beginning Markup -

- -

MHonArc allows you to completely override the begining markup of the index -page. I.e. You can control the opening <HTML> tag, the HEAD element contents, -the opening <BODY> tag, etc. Therefore, if you are not satisfied with the default -behavior of how the TITLE resource is used, or have other needs that require -control on the beginning markup, you can set the IDXPGBEGIN resource file -element. -

-

IDXPGBEGIN -

- -

The best way to show how the IDXPGBEGIN works, the following represents the -default setting MHonArc uses: -

-
<IDXPGBEGIN>
-<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
-<HTML>
-<HEAD>
-<TITLE>$IDXTITLE$</TITLE>
-</HEAD>
-<BODY>
-<H1>$IDXTITLE$</H1>
-</IDXPGBEGIN>
-
-
- -
-
NOTE - -

Technically, setting the TITLE resource, via the M2H_TITLE environment -variable, the TITLE resource element, or the -title command-line -option, sets the $IDXTITLE$ resource file variable. -

-

The resource variables allowed in the IDXPGBEGIN element are the following: -

-
    -
  • $DOCURL$ -- URL to documentation -
  • $GMTDATE$ -- Current GMT date. -
  • $IDXFNAME$ -- Filename of main index page. -
  • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
  • $IDXTITLE$ -- The title of the index page. -
  • $LOCALDATE$ -- Current local date. -
  • $NUMOFIDXMSG$ -- Number of message listed. -
  • $NUMOFMSG$ -- Number of messages in the archive. -
  • $OUTDIR$ -- Pathname of archive. -
  • $PROG$ -- Program name. -
  • $TIDXFNAME$ -- Filename of thread index page. -
  • $TIDXTITLE$ -- Title of thread index page. -
  • $VERSION$ -- Program version. -
-

See Resource Variables for more information on the usage of variables. -

-
-

End Markup -

- -

Since MHonArc allows you to control the beginning markup, it makes sense for it -to allow you to control the ending markup. -

-

IDXPGEND -

- -

The IDXPGEND resource element may be used to define the ending markup of the -index page. The default value is the following: -

-
<IDXPGEND>
-</BODY>
-</HTML>
-</IDXPGEND>
-
-
- -

The resource variables allowed are the same as for IDXPGBEGIN. -

-
-

Include Files -

- -

MHonArc allows you to include the contents of files into the index page via the -header and footer resources. -

-
-
NOTE - -

The use of include files is discouraged since the LISTBEGIN and LISTEND -resources can be used to achieve the same results. Also, the support for the -include resource may be removed in future releases. -

-

The header file is specified via the M2H_HEADER environment variable, the -HEADER resource element, or the -header command-line option. The contents of -the header file are inserted above the message listing, and right after the H1 title -element. -

-
-
NOTE - -

Filename should not contain the <HTML>, <HEAD>, and <BODY> tags; these -tags are automatically provided by MHonArc, or defined by the -IDXPGBEGIN resource file element. -

-

The footer file is specified via the M2H_FOOTER environment variable, the FOOTER -resource element, or the -footer command-line option. The contents of the footer -file are inserted after the message listing. -

-
-
NOTE - -

Filename should not contain the </BODY>, and </HTML> tags; these tags -are automatically provided by MHonArc, or defined by the IDXPGEND -resource file element. -

-

The header and footer files allow you to incorporate search-forms, hyperlinks to -other pages, or any other HTML markup you like. -

-

It is only necessary to specify the header and/or footer files the first time you create -an archive. The contents included from the header and/or footer files are -preserved in any subsequent additions to the archive. Only respecify the header -and/or footer files if you need to make changes to the header/footer contents. -

-
-

Listing Layout -

- -

MHonArc lists messages in the order specified by the various sort options. -However, you have complete control on how the message listing are formatted via -the LISTBEGIN, LITEMPLATE, and LISTEND resource elements in the Resource -File. These elements allow you to specify the HTML markup to use in the index -page. -

-

LISTBEGIN -

- -

The LISTBEGIN resource element specifies the text to begin the message list. The -text can be any valid HTML markup. Plus, MHonArc defines the following -variables you may use which get expanded at run-time: -

-
    -
  • $DOCURL$ -- URL to documentation -
  • $GMTDATE$ -- Current GMT date. -
  • $IDXFNAME$ -- Filename of main index page. -
  • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
  • $IDXTITLE$ -- The title of the index page. -
  • $LOCALDATE$ -- Current local date. -
  • $NUMOFIDXMSG$ -- Number of message listed. -
  • $NUMOFMSG$ -- Number of messages in the archive. -
  • $OUTDIR$ -- Pathname of archive. -
  • $PROG$ -- Program name. -
  • $TIDXFNAME$ -- Filename of thread index page. -
  • $TIDXTITLE$ -- Title of thread index page. -
  • $VERSION$ -- Program version. -
-

MHonArc's LISTBEGIN default value is the following: -

-
<LISTBEGIN>
-<UL>
-<LI><A HREF="$TIDXFNAME$">Thread Index</A></LI>
-</UL>
-<HR>
-<UL>
-</LISTBEGIN>
-
-
- -

If the NOTHREAD resource is set, the following is the default value: -

-
<LISTBEGIN>
-<HR>
-<UL>
-</LISTBEGIN>
-
-
- -

LITEMPLATE -

- -

The LITEMPLATE resoure element defines the HTML text to represent each -message list item. You may use the following variables which are expanded at -runtime: -

-
    -
  • $A_ATTR$ -- The NAME and HREF attributes to use in an anchor to link to -the archived message. The NAME attribute links the messages to the index -page. -
  • $A_HREF$ -- The HREF attribute to use in an anchor to link to the archived -message. -
  • $A_NAME$ -- The NAME attributes to use in an anchor for messages to link -to the index page. -
  • $DATE$ -- The date of the message. -
  • $DDMMYY$ -- Message date in dd/mm/yy format. -
  • $ICON$ -- The context-type sensistive icon. See Icons for information. -
  • $ICONURL$ -- The URL to the context-type sensistive icon. See Icons for -information. -
  • $MMDDYY$ -- Message date in mm/dd/yy format. -
  • $NUMFOLUP$ -- Number of follow-ups for the given message. -
  • $FROM$ -- The complete text in the From: field of the message. -
  • $FROMADDR$ -- The e-mail address in the From: field of the message. -
  • $FROMNAME$ -- The English name of the person in the From: field of the -message. If no English name is found, the username specified in the e-mail -address is used. -
  • $MSGNUM$ -- The message numbers assigned to the message by MHonArc. -
  • $ORDNUM$ -- The current listing number of the message. -
  • $SUBJECT$ -- The subject text of the message wrapped in an anchor -element that hyperlinks to the message. -
  • $SUBJECTNA$ -- The subject text of the message without the anchor -element. -
  • $YYMMDD$ -- Message date in yy/mm/dd format. -
-

-

-
-
NOTE - -

Do not specify $A_ATTR$, $A_NAME, and $SUBJECT$ together in the -LITEMPLATE element. Since all of these variables contain the NAME -atrribute. Invalid HTML will be created since multiple anchors will have -the same NAME identifier. -

-

LITEMPLATE's default value is the following: -

-
<LITEMPLATE> 
-<LI><STRONG>$SUBJECT$</STRONG> 
-<UL><LI><EM>From</EM>: $FROM$</LI></UL> 
-</LI> 
-</LITEMPLATE> 
-
-
- -

LISTEND -

- -

The LISTEND resource element specifies the text to use to end the message list. The -text can be any valid HTML markup. LISTEND may contain the same variables as -LISTBEGIN. -

-

LISTEND's default value is the following: -

-
<LISTEND> 
-</UL> 
-</LISTEND> 
-
-
- -
-

Icons -

- -

MHonArc supports the ability to insert icons in the index page for each message -based on the message's content-type. For example: You can have text/plain -messages use a different icon than text/html messages. -

-

Defining Icons -

- -

To specify the icons for MHonArc to use, you use the ICONS resource element in -the Resource File. The format of each line in the ICONS element is as follows: -

-

<content-type>:<URL for icon> -

-

<content-type> represents a MIME content-type. <URL for icon> is the URL to the -icon. The special content-type called "unknown" may be defined to specify the -icon to use for non-recognized content-types. If unknown is not defined, the -text/plain icon is used for unknown content types. -

-

Example -

- -
<ICONS>
-audio/basic:http://foo.org/gifs/gsound.gif
-image/gif:http://foo.org/gifs/gimage.gif
-image/jpeg:http://foo.org/gifs/gimage.gif
-image/tiff:http://foo.org/gifs/ggraphic.gif
-multipart/alternative:http://foo.org/gifs/gmulti.gif
-multipart/digest:http://foo.org/gifs/gtext.gif
-multipart/mixed:http://foo.org/gifs/gdoc2.gif
-multipart/parallel:http://foo.org/gifs/gdoc.gif
-text/richtext:http://foo.org/gifs/gdoc.gif
-text/html:http://foo.org/gifs/gdoc.gif
-text/plain:http://foo.org/gifs/gletter.gif
-unknown:http://foo.org/gifs/gunknown.gif
-video/mpeg:http://foo.org/gifs/gmovie.gif
-</ICONS>
-
-
- -

Using Icons -

- -

In order to incorporate icons into the index page, insert the $ICON$ variable into -the LITEMPLATE resource element. -

-

Example -

- -
<litemplate>
-$ICONURL$<strong>$SUBJECT:40$</strong>
-($NUMFOLUP$) <em>$FROMNAME$</em><br>
-</litemplate>
-
-
- -

The $ICON$ variable expands to the IMG HTML element with the appropriate -URL in the SRC attribute to the icon. The ALT attribute of the IMG element contains -the content-type of the message, surrounded by []'s, for use with text based -browsers. -

-

$ICONURL$ may also be used if you want redefine the format of the IMG element. -

-

Example -

- -
<litemplate>
-<img src="$ICONURL$" alt="* "><strong>$SUBJECT:40$</strong>
-($NUMFOLUP$) <em>$FROMNAME$</em><br>
-</litemplate>
-
-
- -

This example overrides what is normally used in the ALT attribute. -

-
-

Examples -

- -

Example 1 -

- -

It may be easier to see how the LISTBEGIN, LITEMPLATE, LISTEND resource -elements work when declared together: -

-
<!-- This represents the default values used by MHonArc -->
-<LISTBEGIN>
-<UL>
-<LI><A HREF="$TIDXFNAME$">Thread Index</A></LI>
-</UL>
-<HR>
-<UL>
-</LISTBEGIN>
-
-<LITEMPLATE> 
-<LI><STRONG>$SUBJECT$</STRONG> 
-<UL><LI><EM>From</EM>: $FROM$</LI></UL> 
-</LI> 
-</LITEMPLATE> 
-
-<LISTEND> 
-</UL> 
-</LISTEND> 
-
-
- -

Example 2 -

- -

Here's another example that changes the layout into a more compact listing, adds -Icons usage, and adds a time stamp information on when the index page was last -updated: -

-
<listbegin>
-<address>
-Last update: $CURDATE$<br>
-$NUMOFMSG$ messages<br>
-</address>
-<p>
-<UL>
-<LI><A HREF="$TIDXFNAME$">Thread Index</A></LI>
-</UL>
-<p>
-Messages listed in chronological order.  Listing format is the following:
-<blockquote>
-<img src="http://foo.org/gifs/gletter.gif" alt="* ">
-<strong>Subject</strong>
-(# of follow-ups)
-<em>From</em>.
-</blockquote>
-<p>
-<hr>
-</listbegin>
-
-<litemplate>
-<img src="$ICONURL$" alt="* "><strong>$SUBJECT:40$</strong>
-($NUMFOLUP$) <em>$FROMNAME$</em><br>
-</litemplate>
-
-<listend>
-</listend>
-
-
- - -
-[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/install.html b/doc/install.html deleted file mode 100644 index 37b9f1b..0000000 --- a/doc/install.html +++ /dev/null @@ -1,381 +0,0 @@ - - - -MHonArc v1.2.2 -- Installation - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
- -

Installation -

- -

This section instructs you on how to install and get MHonArc running on your -machine. The section covers Unix installation and MS-DOS/Windows installation. -

-
-
NOTE - -

For brevity, anything that applies to MS-DOS also applies to Windows. -

-
-

System Requirements -

- -

MHonArc is written in Perl 4. Therefore, you must have Perl 4 or 5 installed on your -system. If you do not know if Perl is installed on your system, ask your system -administrator. -

-

If Perl is not installed on your system, you can retrieve Perl at -<URL:http://www.cis.ufl.edu/perl/ftp.html>. I recommend version 4.0 -patchlevel 34, or later. MHonArc has not been tested on earlier versions. -

-
-
NOTE - -

MHonArc makes use of the Perl libraries newgetopt.pl and -timelocal.pl. These libraries are part of the normal Perl distribution. -

-
-

Extracting the Distribution File -

- -

Before extracting the distribution file, you may want copy the distribution file into -scratch directory, and work in there during installation. -

-

Tar/Gzip Distribution -

- -

You must have gzip and tar installed on your system. If gzip is not installed, you -may obtain gzip at <URL:ftp://prep.ai.mit.edu/pub/gnu>. Tar comes with all -Unix systems. However, MS-DOS users may have to obtain tar. -

-

To extract the file, type the following command at your shell's prompt: -

-
-
Unix - -

zcat MHonArc.tar.gz | tar xvof - -

-
-
MS-DOS - -

gunzip -dv MHonArc.tar.gz
-tar xvf MHonArc.tar -

-

A directory called "MHonArc" should be created. The directory contains all the -files need for installing MHonArc. -

-
-
NOTE - -

The actual name of the distribution file may differ from the example given. -

-

Zip Distribution -

- -

You must have pkzip or unzip installed on your system. -

-

To extract the file, type the following command at your shell's prompt: -

-

unzip mhonarc.zip
-

-OR
-
-pkunzip -d mhonarc.zip -

-
-
IMPORTANT - -

The directory structure of the zip file must be preserved during extraction -to insure proper installation. -

-

A directory called "MHonArc" should be created. The directory contains all the -files need for installing MHonArc. -

-
-
NOTE - -

The actual name of the distribution file may differ from the example given. -

-
-

Installing the Software -

- -

Once you have extracted the distribution file, change your current working -directory into the MHonArc directory created during the extraction of the -distribution file. -

-

Example: Assuming you are in the directory you extracted the distribution file in, -you can type the following on your command-line: -

-
-
Unix - -

cd MHonArc -

-
-
MS-DOS - -

cd MHONARC -

-

install.me -

- -

Contained in the MHonArc directory is a Perl program called "install.me". This -program will perform the tasks required to install MHonArc on you machine. The -install program is capable of running interactively, or in batch. -

-

Interactive Mode -

- -

To run install.me in interactive mode, type the following at your shell's -prompt: -

-

perl install.me -

-
-
NOTE - -

Make sure you are in the same directory as the install.me program. -

-

The program will then prompt you for the necessary information to install -MHonArc on your system. -

-

Here's an example (Unix) session: -

-
% perl install.me
-MHonArc Installation
-====================
-The installation process will ask you a series of questions on where
-the Perl executable is and where to put MHonArc files.  Just hit <CR>
-to accept the default values listed in ()'s.
-
-If directory path does not exist on your system, the installation
-program will create the path for you.
-
------------------------------------------------
-Note:  Make sure all pathnames are absolute.
------------------------------------------------
-
-Hit <CR> to continue ...
-Perl executable ("/usr/local/bin/perl")
--> /usr/bin/perl
-Location to install programs ("/usr/local/bin")
--> /mnt/ehood/bin
-Location to install libraries ("/usr/local/lib/MHonArc")
--> /mnt/ehood/lib/MHonArc
-Install documentation ("y")?  y
-Location to install docs ("/usr/local/lib/MHonArc/doc")
--> /mnt/ehood/lib/MHonArc/doc
-
-You've specified the following:
-        Perl location: /usr/bin/perl
-        Program directory: /mnt/ehood/bin
-        Library directory: /mnt/ehood/lib/MHonArc
-        Doc directory: /mnt/ehood/lib/MHonArc/doc
-Is this correct ("y")?  y
-Installing the following into /mnt/ehood/bin
-        mhonarc
-Installing the following into /mnt/ehood/lib/MHonArc
-        base64.pl
-        mhexternal.pl
-        mhtxthtml.pl
-        mhtxtplain.pl
-        mhtxtsetext.pl
-        qprint.pl
-        readmail.pl
-Installing the following into /mnt/ehood/lib/MHonArc/doc
-        mhonarc.txt
-        ...
-
-
- -

Batch Mode -

- -

To run install.me in batch mode, type the following at your shell's prompt: -

-

perl install.me install.cfg -

-
-
NOTE - -

Make sure you are in the same directory as the install.me program. -

-

The install.cfg contains the necessary information for intalling MHonArc on -your system. You will need to edit install.cfg to reflect your installation -requirements. -

-

Here is an example install.cfg: -

-
# Should executables be installed. 0 => NO, non-zero => YES.
-#
-$dobin = 1;
-
-# Should libraries be installed. 0 => NO, non-zero => YES.
-#
-$dolib = 1;
-
-# Should documentation be installed. 0 => NO, non-zero => YES.
-#
-$dodoc = 1;
-
-# Location for executable.  If using ms-dos, use something like
-# 'C:\\BIN'.
-#
-$bindir  = '/usr/local/bin';
-
-# Location for libraries.  If using ms-dos, use something like
-# 'C:\\LIB\\MHONARC'.
-#
-$libdir  = '/usr/local/lib/MHonArc';
-
-# Location for documents.  If using ms-dos, use something like
-# 'C:\\DOC\\MHONARC'.
-#
-$docdir  = '/usr/local/lib/MHonArc/doc';
-
-# Location of perl executable.  If using ms-dos, use something like
-# 'C:\\BIN\\PERL.EXE'.
-#
-$perlprg = '/usr/local/bin/perl';
-
-
-1; # DO NOT DELETE THIS LINE
-
-
- -

The file is Perl code, and therefore, must follow Perl syntax rules: -

-
    -
  • Anything following a `#' character is ignored. -
  • Strings values need to be enclosed in quotes. -
  • If you need to use a backslash in a string value, it must be escaped with a -backslash. Example: 'C:\\LIB\\MHONARC'. The same applies to the '$' -character. -
  • All statements must end with a semi-colon. -
  • The "1;" line must not be deleted. -
-
-
NOTE - -

You can verify the syntax of the configuration file by invoking "perl -c" -on the file. -

-

After you have successfully executed install.me, MHonArc is ready to use. -

-

MS-DOS Post install.me Note -

- -

If you would like the ability to run MHonArc like other programs, then create a -batch file that contains something like the following: -

-
@ECHO OFF
-C:\BIN\PERL.EXE C:\BIN\MHONARC %1 %2 %3 %4 %5 %6 %7 %8 %9
-
-
- -

Of course, you will need to change the paths to Perl and MHonArc to suit your -systems configuration. -

-

Sample batch files are available in the MHonArc distribution. -

-

Notes on install.me -

- -
    -
  • If you do not know the location of the Perl executable on your system, ask -your system administrator. -

  • All pathnames must be absolute. -

  • If a path does not exist that you specify, the path will be automatically -created if running in interactive mode. In batch mode, all paths specified -must already exist. -

  • During the installation process, the main MHonArc source file is modified -to be aware of the location of the Perl executable and MHonArc's library -files. If you ever need to install MHonArc in a different location, rerun the -install.me program. -

    NOTE: Location of the Perl exectuble is only relevant for Unix systems. -MS-DOS systems do not make use of the "#!" line in scripts. -

  • MHonArc requires the use of timelocal.pl and newgetopt.pl. These -libraries are part of the normal Perl distribution. -

-
-

Tested Environments -

- -

This section covers software environments MHonArc has worked successfully. -Feedback is welcome about other success, or failure, stories covering MHonArc -usage in other environments. -

-

Perl -

- -

MHonArc is known to work with the following version of Perl 4, or later: -

-

$RCSfile: perl.c,v $$Revision: 4.0.1.7 $$Date: 92/06/08 -14:50:39 $
-Patch level: 34
-

-

MHonArc is known also to work with Perl 5.001m and Perl 5.002 beta2. -

-
-
NOTE - -

The version numbers are based upon the Unix versions of Perl. DOS -version numbers may differ. -

-

Unix -

- -

Mail Software -

- -
    -
  • MH -
  • Elm, Mail, mail, and any other mail software that stores e-mail in UUCP -style mailbox format. UUCP format is where mail messages are separated -by a line beginning with "From " (I.e. the word "From" followed by a -space). You may need to utilize the MSGSEP resource if the message -separator is different from standard mailbox files (eg. MMDF format). -

-

News Software -

- -

Different news software store messages differently. Messages are either stored in a -format similiar to MH or similiar to a mailbox file: -

-
    -
  • MH style is where the messages are stored in a directory with each post a -separate file, and each file has a numeric filename. -

  • Mailbox style is where messages are stored in a single file. You may need -to utilize the MSGSEP resource if the message separator is different from -standard mailbox files. -

-

MS-DOS -

- -

Mail/News Software -

- -

MHonArc has been tested under MS-DOS with message files created by the -following mail and news programs: -

-
    -
  • Eudora -
  • WinVN -
  • Windows Trumpet -
  • NUPop -

-

It also works with individual RFC822 mail messages, but you must run MHonArc -without a batch file if you need to use redirection. For example: -

-

perl c:\bin\mhonarc <one.msg >one.htm
-perl c:\bin\mhonarc -add <one.msg

- -

- -
-[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/intro.html b/doc/intro.html index 2b62428..97aef02 100644 --- a/doc/intro.html +++ b/doc/intro.html @@ -1,77 +1,116 @@ + -MHonArc v1.2.2 -- Introduction +MHonArc -- Introduction -[Next][Contents][FAQ][Bugs][Home] + + +

+[Prev][Next][TOC][FAQ][Bugs][Home] +

+
-

Introduction -

+

Introduction

+ +

MHonArc is a Perl +program for converting e-mail messages as specified in RFC 822 and +the +MIME standard to HTML. +MHonArc can perform the following tasks:

-

MHonArc is a Perl program for converting e-mail messages as specified in RFC 822 -and RFC 1521 (MIME) to HTML. MHonArc can perform the following tasks: -

    -
  • Convert mh(1) mail folders or UUCP/Unix style mailboxes into an HTML -mail archive. -
  • Add or remove messages to an existing HTML mail archive generated by -MHonArc. -
  • Convert a single message to HTML. -

+
  • Convert MH +mail folders or UUCP/Unix style mailboxes into an HTML mail archive. +
  • Add or remove messages to an existing HTML mail archive generated +by MHonArc. +
  • Convert a single message to HTML. + +

    Along with these tasks, MHonArc provides the following:

    +
      -
    • A main customizable index page for mail messages archived. -
    • A customizable thread index page listing messages by thread. +
    • A main customizable index for mail messages archived. +
    • A customizable thread index listing messages by thread.
    • Control over message formatting.
    • The ability to hook in your own custom message filters.
    -
    -

    Why Use MHonArc? -

    + +
    +

    Why Use MHonArc?

    Here are some reasons for using MHonArc:

    +
      -
    • You want to keep organized archives of mail messages and/or news -articles for a World Wide Web (WWW) server; complete with live -hypertext pointers to their authors and to any url's mentioned. -
    • You would like to control the layout of mail/news archives to keep a -consistent style to your WWW pages. -
    • You have a WWW client, but no MIME mail reader. MHonArc will allow -you to read MIME messages that includes images, audio, video, etc via -your Web client. -
    • Muli-platform support: MS-DOS and Unix. -
    • You think the MHonArc logo is really cool, and it deserves to be used. + +
    • You want to keep organized archives +of mail messages and/or news articles for a World Wide +Web (WWW) server; complete with live hypertext pointers +to their authors and to any url's mentioned. + +
    • You would like to control the layout of mail/news archives to +keep a consistent style to your WWW pages. + +
    • You have MIME messages that you want to include in your archives. + +
    • You have a WWW client, but no MIME mail reader. MHonArc +will allow you to read MIME messages that includes images, audio, +video, etc via your Web client. + +
    • Muli-platform support: Unix and MSDOS/Windows (MacOS?) + +
    • You think the MHonArc logo is really cool, and it deserves +to be used. +
    • You like Perl, and you want to see what it can do. + +
    • You need a mail archiving utility that can work under Perl 4 +and 5. +
    • Just cuz.
    -
    -

    Supported Platforms -

    -

    MHonArc (version 1.1, or later) will run under Unix or MS-DOS operating systems -with Perl 4 or 5 installed. -

    -
    -

    Availability -

    +
    +

    Supported Platforms

    -

    The latest information on MHonArc, and its availability, may be obtained at -<URL:http://www.oac.uci.edu/indiv/ehood/mhonarc.html>. +

    MHonArc (version 1.1, or later) will run under Unix or +MSDOS/Windows operating systems with Perl 4 or 5 installed. Execution +under MacOS has not been verified.

    -
    -

    About the Documentation -

    -

    The documentation is oriented towards Unix users. However, the section on -Installation does conver MS-DOS installation instructions. Notes are made in the -documentation when something may differ due to the operating system. +


    +

    Availability

    + +

    The latest information on MHonArc, where to get more help, +and its availability, may be obtained at <URL:http://www.oac.uci.edu/indiv/ehood/mhonarc.html>.


    -[Next][Contents][FAQ][Bugs][Home] + +

    +[Prev][Next][TOC][FAQ][Bugs][Home] +

    + + + +
    +
    +97/05/15 16:48:58
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + diff --git a/doc/layout.html b/doc/layout.html new file mode 100644 index 0000000..7c5b44b --- /dev/null +++ b/doc/layout.html @@ -0,0 +1,186 @@ + + + +MHonArc -- Page Layout + + + + + +

    +[Prev][Next][TOC][FAQ][Bugs][Home] +

    + +
    + + +

    Page Layout

    + +

    The section describes the layout of the pages created by +MHonArc. Each page's layout is controlled by resources +(see MHonArc Resources). +To simplify the description of each type of page created +by MHonArc, the following notation is used: +

    + +
    +
    ( )
    +
    Parentheses denote a group of resources. +
    +
    ?
    +
    Denotes that preceding resource, or group, is +optional. +
    +
    *
    +
    Denotes that preceding resource, or group, can +occur zero or more times. +
    +
    +
    +
    Denotes that preceding resource, or group, can +occur one or more times. +
    +
    + + +
    +

    Main Index Page

    + +

    The main index is normally the default index of an +archive. The main index list messages by date, +subject, author, or message number. +Since date listing is the default, the +main index is commonly referred to as the date index. +

    + +

    Main index page resource layout

    + +
    +IDXPGBEGIN
    +    HEADER
    +	LISTBEGIN
    +	(AUTHORBEGIN |
    +	 DAYBEGIN |
    +	 SUBJECTBEGIN)?
    +	LITEMPLATE+
    +	(AUTHOREND |
    +	 DAYEND |
    +	 SUBJECTEND)?
    +         LISTEND
    +    FOOTER
    +    DOC
    +IDXPGEND
    +
    + +

    Main index pages also contain comment declarations. Some of the +comment declarations are vital markers to allow MHonArc +to properly edit the index during archive updates. +

    + + +
    +

    Thread Index Page

    + +

    The thread index list messages by thread. Threads +are based upon In-Reply-To and References fields of +messages and by same Subjects. +

    + +

    The layout of a thread index page is more complicated +than other pages since threads are more +complex than a regular date or subject listing. +Also, MHonArc tries to provide the greatest +flexibility for customizing thread listing layout. +

    + +

    Thread index page resource layout

    + +
    +TIDXPGBEGIN
    +    THEAD
    +	((TTOPBEGIN
    +	    TSUBLISTBEG
    +		((TLITXT
    +		    [possible subthread listing]
    +		  TLIEND)|
    +		(TLINONE
    +		    [possible subthread listing]
    +		 TLINONEEND))+
    +	    TSUBLISTEND
    +	    (TSUBJECTBEG
    +		((TLITXT
    +		    [possible subthread listing]
    +		  TLIEND)|
    +		(TLINONE
    +		    [possible subthread listing]
    +		 TLINONEEND))+
    +	     TSUBJECTEND)?
    +	  TTOPEND)
    +	 |
    +	 TSINGLETXT)* [message w/o references or follow-ups]
    +    TFOOT
    +    DOC
    +TIDXPGEND
    +
    + +

    If the previous is not confusing enough, there are four other resources +for controlling the thread index page layout: +TCONTBEGIN, +TCONTEND, +TINDENTBEGIN, +TINDENTEND. +If the multiple page resource is +set, it is possible that a thread can span more than one page. These +resources are used to restart a thread that has been clipped due to +a page boundary. +

    + + +
    +

    Message Page

    + +

    The message page contains a single message converted +to HTML and archive navigational links. +

    + +

    Message page resource layout

    + +
    +MSGPGBEGIN
    +    MSGHEAD
    +    TOPLINKS
    +    SUBJECTHEADER
    +    Converted message header
    +    HEADBODYSEP
    +    Converted message body
    +    FOLREFS
    +    BOTLINKS
    +    MSGFOOT
    +MSGPGEND
    +
    + +

    Message pages also contain comment declarations. Some of the +comment declarations are vital markers to allow MHonArc +to properly edit the message when needed during updates. +

    + +
    + +

    +[Prev][Next][TOC][FAQ][Bugs][Home] +

    + + + +
    +
    +97/05/15 17:14:33
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/message.html b/doc/message.html deleted file mode 100644 index 313d4d9..0000000 --- a/doc/message.html +++ /dev/null @@ -1,510 +0,0 @@ - - - -MHonArc v1.2.2 -- Message Customization - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
    - -

    Message Customization -

    - -

    This sections shows how to customize the appearance of messages when -converted to HTML. -

    -
    -

    Beginning Markup -

    - -

    MHonArc allows you to completely override the begining markup of the message -pages. I.e. You can control the opening <HTML> tag, the HEAD element contents, the -opening <BODY> tag, etc. Therefore, if you are not satisfied with the default -markup used, or have other needs that require control on the beginning markup, -you can set the MSGPGBEGIN resource file element. -

    -

    MSGPGBEGIN -

    - -

    The MSGPGBEGIN resource file element has the default value: -

    -
    <MSGPGBEGIN>
    -<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
    -<HTML>
    -<HEAD>
    -<TITLE>$SUBJECTNA:72$</TITLE>
    -<LINK REV="made" HREF="mailto:$FROMADDR$">
    -</HEAD>
    -<BODY>
    -</MSGPGBEGIN>
    -
    -
    - -

    The following variables may be used in the MSGPGBEGIN element: -

    -
      -
    • $DATE$ -- Message date. -
    • $DDMMYY$ -- Message date in dd/mm/yy format. -
    • $DOCURL$ -- URL to documentation. -
    • $FROM$ -- Contents of From field of message. -
    • $FROMADDR$ -- E-mail address contained in From field of message. -
    • $FROMNAME$ -- "English" name contained in From field of message. -
    • $GMTDATE$ -- Current GMT date. -
    • $IDXFNAME$ -- Filename of main index page. -
    • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
    • $IDXTITLE$ -- The title of the index page. -
    • $LOCALDATE$ -- Current local date. -
    • $MMDDYY$ -- Message date in mm/dd/yy format. -
    • $MSGID$ -- Message ID of message. -
    • $MSGNUM$ -- Number assigned to message by MHonArc. -
    • $NUMOFIDXMSG$ -- Number of message listed. -
    • $NUMOFMSG$ -- Number of messages in the archive. -
    • $OUTDIR$ -- Pathname of archive. -
    • $PROG$ -- Program name. -
    • $SUBJECTNA$ -- Message subject text. -
    • $TIDXFNAME$ -- Filename of thread index page. -
    • $TIDXTITLE$ -- Title of thread index page. -
    • $VERSION$ -- Program version. -
    • $YYMMDD$ -- Message date in yy/mm/dd format. -
    -
    -

    End Markup -

    - -

    The ending markup of messages can be controlled by the MSGPGEND resource file -element. -

    -

    MSGPGEND -

    - -

    The MSGPGEND resource element may be used to define the ending markup of the -message pages. The default value is the following: -

    -
    <MSGPGEND>
    -</BODY>
    -</HTML>
    -</MSGPGEND>
    -
    -
    - -

    The resource variables allowed are the same as for MSGPGBEGIN. -

    -
    -

    Header and Footer -

    - -

    The MSGHEAD resource represents HTML text that should be inserted at the very -beginning of each converted message. The MSGFOOT resource represents HTML -text that should be appended to the end of each converted message. The default -value for both resources is empty. The following variables may be used in the -MSGHEAD and MSGFOOT content: -

    -
      -
    • $DATE$ -- Message date. -
    • $DDMMYY$ -- Message date in dd/mm/yy format. -
    • $DOCURL$ -- URL to documentation. -
    • $FROM$ -- Contents of From field of message. -
    • $FROMADDR$ -- E-mail address contained in From field of message. -
    • $FROMNAME$ -- "English" name contained in From field of message. -
    • $GMTDATE$ -- Current GMT date. -
    • $IDXFNAME$ -- Filename of main index page. -
    • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
    • $IDXTITLE$ -- The title of the index page. -
    • $LOCALDATE$ -- Current local date. -
    • $MMDDYY$ -- Message date in mm/dd/yy format. -
    • $MSGID$ -- Message ID of message. -
    • $MSGNUM$ -- Number assigned to message by MHonArc. -
    • $OUTDIR$ -- Pathname of archive. -
    • $PROG$ -- Program name. -
    • $SUBJECTNA$ -- Message subject text. -
    • $TIDXFNAME$ -- Filename of thread index page. -
    • $TIDXTITLE$ -- Title of thread index page. -
    • $VERSION$ -- Program version. -
    • $YYMMDD$ -- Message date in yy/mm/dd format. -
    -
    -

    Navigational Links -

    - -

    MHonArc gives you the ability to control the layout of the navigational links for -each message page. Navigational links include links to previous and next -messages, link to main index, link to thread index, etc. The layout of the -navigational links are controlled by two resource file elements: TOPLINKS and -BOTLINKS. -

    -

    TOPLINKS -

    - -

    The TOPLINKS resource element defines the layout of the navigational links at the -top of each message page. The markup defined, will appear after the MSGHEAD -data and before the filtered message data. -

    -

    The default value for TOPLINKS is the following: -

    -
    <TOPLINKS>
    -<HR>
    -$PREVBUTTON$$NEXTBUTTON$<A HREF="$IDXFNAME$#$MSGNUM$">[Index]</A><A 
    -HREF="$TIDXFNAME$#$MSGNUM$">[Thread]</A>
    -</TOPLINKS>
    -
    - -
    -
    - -

    If no thread index is specified, then the thread link markup is removed. The -following variables are available: -

    -
      -
    • $DATE$ -- Message date. -
    • $DDMMYY$ -- Message date in dd/mm/yy format. -
    • $DOCURL$ -- URL to documentation. -
    • $FROM$ -- Contents of From field of message. -
    • $FROMADDR$ -- E-mail address contained in From field of message. -
    • $FROMNAME$ -- "English" name contained in From field of message. -
    • $GMTDATE$ -- Current GMT date. -
    • $IDXFNAME$ -- Filename of main index page. -
    • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
    • $IDXTITLE$ -- The title of the index page. -
    • $LOCALDATE$ -- Current local date. -
    • $MMDDYY$ -- Message date in mm/dd/yy format. -
    • $MSGID$ -- Message ID of message. -
    • $MSGNUM$ -- Number assigned to message by MHonArc. -
    • $NEXTBUTTON$ -- Next button markup. See Conditional Links for more -information. -
    • $NEXTFROM$ -- Contenst of From field of the next message according to -the list order of the main index. -
    • $NEXTFROMADDR$ -- E-mail address contained in From field of the next -message according to the list order of the main index. -
    • $NEXTFROMNAME$ -- English" name contained in From field of the next -message according to the list order of the main index. -
    • $NEXTLINK$ -- Next link markup. See Conditional Links for more -information. -
    • $NEXTMSG$ -- Filename of next message according to the list order of the -main index. -
    • $NEXTMSGNUM$ -- Number assigned to next message according to the list -order of the main index. -
    • $NEXTSUBJECT$ -- Subject of next message according to the list order of -the main index. -
    • $NUMOFIDXMSG$ -- Number of message listed. -
    • $NUMOFMSG$ -- Number of messages in the archive. -
    • $PREVBUTTON$ -- Previous button markup. See Conditional Links for -more information. -
    • $PREVFROM$ -- Contenst of From field of the previous message according -to the list order of the main index. -
    • $PREVFROMADDR$ -- E-mail address contained in From field of the -previous message according to the list order of the main index. -
    • $PREVFROMNAME$ -- English" name contained in From field of the -previous message according to the list order of the main index. -
    • $PREVLINK$ -- Previous link markup. See Conditional Links for more -information. -
    • $PREVMSG$ -- Filename of previous message according to the list order of -the main index. -
    • $PREVMSGNUM$ -- Number assigned to previous message according to the -list order of the main index. -
    • $PREVSUBJECT$ -- Subject of previous message according to the list order -of the main index. -
    • $PROG$ -- Program name. -
    • $SUBJECTNA$ -- Message subject text. -
    • $TIDXFNAME$ -- Filename of thread index page. -
    • $TIDXTITLE$ -- Title of thread index page. -
    • $VERSION$ -- Program version. -
    • $YYMMDD$ -- Message date in yy/mm/dd format. -
    -

    BOTLINKS -

    - -

    The BOTLINKS resource element defines the layout of the navigational links at the -bottom of each message page. The markup defined, will appear after the filtered -message data and any thread links, and before the MSGFOOT data. -

    -

    The default value for BOTLINKS is the following: -

    -
    <BOTLINKS>
    -<HR>
    -<UL>
    -$PREVLINK$
    -$NEXTLINK$
    -<LI>Index(es):
    -<UL>
    -<LI><A HREF="$IDXFNAME$#$MSGNUM$"><STRONG>Main</STRONG></A></LI>
    -<LI><A HREF="$TIDXFNAME$#$MSGNUM$"><STRONG>Thread</STRONG></A></LI>
    -</BOTLINKS>
    -
    - -
    -
    - -

    If no thread index is specified, then the thread link markup is removed. The -variables available for BOTLINKS are the same as for TOPLINKS. -

    -

    Conditional Links -

    - -

    Since the state of some navigational links can change due the position of the -message in the archive (eg. first and last messages), special resources exist that -allows you to control the markup of some of the links based upon if the link is valid -or not for a given message. -

    -

    The resource elements for defining the conditional links are the following: -PREVBUTTON, NEXTBUTTON, PREVLINK, and NEXTLINK, and their inactive -counterparts, PREVBUTTONIA, NEXTBUTTONIA, PREVLINKIA, and NEXTLINKIA. -The appropriate value of these elements (ie. if it is active, or inactive) are -represented by the $PREVBUTTON$, $NEXTBUTTON$, $PREVLINK$, and -$NEXTLINK$ resource file variables, respectively, which may be used in other -resource elements' contents (TOPLINKS and BOTLINKS in particular). -

    -

    The defaults values for each conditional link resource is as follows: -

    -

    PREVBUTTON -

    -
    <PREVBUTTON>
    -<A HREF="$PREVMSG$">[Prev]</A>
    -</PREVBUTTON>
    -
    -
    - -

    NEXTBUTTON -

    -
    <NEXTBUTTON>
    -<A HREF="$NEXTMSG$">[Next]</A>
    -</NEXTBUTTON>
    -
    -
    - -

    PREVLINK -

    -
    <PREVLINK>
    -<LI>Prev: <STRONG><A HREF="$PREVMSG$">$PREVSUBJECT$</A></STRONG></LI>
    -</PREVLINK>
    -
    -
    - -

    NEXTLINK -

    -
    <NEXTLINK>
    -<LI>Next: <STRONG><A HREF="$NEXTMSG$">$NEXTSUBJECT$</A></STRONG></LI>
    -</NEXTLINK>
    -
    -
    - -

    All the "IA" elements default to empty content. -

    -
    -
    NOTE - -

    The last newline for the PREVBUTTON, NEXTBUTTON, PREVBUTTONIA, -and NEXTBUTTONIA elements is ignored by MHonArc. This allows a -"tight" grouping of button links; ie. no space between buttons. If you -desire to have a newline in the content, just insert a trailing blank line at -the end of the element's content. -

    -

    You should note that there is a correlation between the value of the conditional -links elements and the contents of the TOPLINKS and BOTLINKS elements. -

    -

    The following variables may be used within the conditional link elements. -

    -
      -
    • $NEXTFROM$ -- Contenst of From field of the next message according to -the list order of the main index. -
    • $NEXTFROMADDR$ -- E-mail address contained in From field of the next -message according to the list order of the main index. -
    • $NEXTFROMNAME$ -- English" name contained in From field of the next -message according to the list order of the main index. -
    • $NEXTMSG$ -- Filename of next message according to the list order of the -main index. -
    • $NEXTMSGNUM$ -- Number assigned to next message according to the list -order of the main index. -
    • $NEXTSUBJECT$ -- Subject of next message according to the list order of -the main index. -
    • $PREVFROM$ -- Contenst of From field of the previous message according -to the list order of the main index. -
    • $PREVFROMADDR$ -- E-mail address contained in From field of the -previous message according to the list order of the main index. -
    • $PREVFROMNAME$ -- English" name contained in From field of the -previous message according to the list order of the main index. -
    • $PREVMSG$ -- Filename of previous message according to the list order of -the main index. -
    • $PREVMSGNUM$ -- Number assigned to previous message according to the -list order of the main index. -
    • $PREVSUBJECT$ -- Subject of previous message according to the list order -of the main index. -
    -

    -

    -
    -
    WARNING - -

    Never include conditional link variables ($PREVBUTTON$, -$NEXTBUTTON$, $PREVLINK$, and $NEXTLINK$) in conditional link -element content. This will cause an infinite loop during execution and will -eventually lead to a crash due to a lack of memory. -

    -
    -

    Message Layout -

    - -

    Defining the format for the actual mail message data is divided into two parts: the -message head and the message body. Customizing the message header markup is -described in this section, but due to the nature of how messages are processed, the -message body format is controlled by the various MIME filters directly (see the -section on MIME for further details). -

    -

    Excluding Fields -

    - -

    The EXCS resource allows you to specify what fields should be excluded in the -HTML output. -

    -

    EXCS -

    - -

    Each line of the EXCS element specifies a mail header field to exclude in the -converted HTML output. Each line is treated as a Perl regular expression (NOTE: -the regular expression is already anchored to the begining of the line). -

    -

    The default value for EXCS is the following: -

    -
    <EXCS>
    -content-
    -errors-to
    -forward
    -lines
    -message-id
    -mime-
    -nntp-
    -originator
    -path
    -precedence
    -received
    -replied
    -return-path
    -status
    -via
    -x-
    -</EXCS>
    -
    -
    - -

    Any fields you specify for the EXCS resource will augment the default list, unless -the "Override" attribute is specified. If "Override" is specified, the default list -is discarded along with any other lists specified from previous EXCS elements; and -only header fields specified in the EXCS element are excluded. -

    -

    Field Order -

    - -

    The FIELDORDER resource allows you to control the order the message header -fields appear in the HTML output. -

    -

    FIELDORDER -

    - -

    Each line of the FIELDORDER element is the exact case-insensitive name of a -message header field. The order the fields are listed is the order they will appear in -the filtered message. The special field value "-extra-" represents all fields not -explicitly specified in the FIELDORDER element and not excluded by the EXCS -element. Extra fields are listed in sorted order. -

    -

    The following represents the default value of the FIELDORDER resource: -

    -
    <FIELDORDER>
    -to
    -subject
    -from
    -date
    --extra-
    -</FIELDORDER>
    -
    -
    - -

    Field Formatting -

    - -

    The FIELDSTYLES and LABELSTYLES resources allow to control how each -message header field is formatted. -

    -

    FIELDSTYLES -

    - -

    Each line in the FIELDSTYLES element defines HTML elements to wrap around -the field text in mail headers (e.g. "To: field text", "From: field text"). The format -of each line is "field_name:html_element". This specifies to wrap -html_element around the text associated with field_name. If html_element -is empty, then the field text is not wrapped in any element. -

    -

    MHonArc defines a special field_name called "-default-". This is default -HTML element to wrap field text in if no explicit specific element is defined for the -label. -

    -

    field_name must be the exact name of a header field name, but character case is -ignored. -

    -

    The default value of FIELDSTYLES is the following: -

    -
    <FIELDSTYLES>
    --default-
    -</FIELDSTYLES>
    -
    -
    - -

    LABELSTYLES -

    - -

    Each line in the LABELSTYLES element defines HTML elements to wrap around -labels in mail headers (e.g. "To:", "From:"). The format of each line is -"field_name:html_element". This specifies to wrap html_element around -field_name. If html_element is empty, then the label is not wrapped in any -element. -

    -

    MHonArc defines a special field_name called "-default-". This is default -HTML element to wrap a label in if no explicit specific element is defined for the -label. -

    -

    field_name must be the exact name of a header field name, but character case is -ignored. -

    -

    The default value of LABELSTYLES is the following: -

    -
    <LABELSTYLES>
    --default-:em
    -</LABELSTYLES>
    -
    -
    - -
    -

    Other Resources -

    - -

    E-mail Links -

    - -

    MAILTOURL -

    - -

    URL to use for e-mail address hyperlinks in e-mail message header fields. The -following variables are defined for the MAILTOURL resource: -

    -
      -
    • $FROM$ -- Who the message is from. -
    • $MSGID$ -- Message ID of the message. -
    • $SUBJECT$ -- The subject of the message. -
    • $TO$ -- Destination e-mail address of link. -
    -

    MHonArc will use the following URL by default: "mailto:$TO$". -

    -
    -
    NOTE - -

    The MAILTOURL resource has different rules for variable expansion. If a -variable does not exactly match the set of variables available for the -MAILTOURL, the variable text will be taken literally as part of the element -content. Therefore, a single "$" can be used to represent a "$" character. -

    Also, variables in the MAILTOURL should NOT have ":NU" modifier. This -will prevent the variables from be recognized. MHonArc will -automatically treat the replacement value as a part of a URL string. -

    - -
    -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/mhonarc.1 b/doc/mhonarc.1 deleted file mode 100644 index 13e8f60..0000000 --- a/doc/mhonarc.1 +++ /dev/null @@ -1,3787 +0,0 @@ -.TH MHonArc 1 -.SH NAME -MHonArc \- Mail\-to\-HTML converter -.SH DESCRIPTION -.in 0 -.nf - - [INLINE] - - MHonArc - - An Internet mail\-to\-HTML converter. - - _________________________________________________________________ - -Table of Contents - - * Introduction - + Why Use MHonArc? - + Supported Platforms - + Availability - + About the Documentation - - * Installation - + System Requirements - + Extracting the Distribution File - + Installing the Software - + Tested Environments - - * Quick Start - + Converting MH mail folders or Mailbox files - + Adding Messages to an Archive - + Converting a single message - - * Overview - + Synopsis - + Options - + Environment - - * Resource File - + Resource Syntax - + Resource Elements - + Example Resource File - + Notes on Resource File - - * Adding Messages - + Examples - - * Removing Messages - + Message Numbers - + Scanning an Archive - - * Index Page Customization - + Filename - + Beginning Markup - + End Markup - + Include Files - + Listing Layout - + Icons - + Examples - - * Thread Index Customization - + Filename - + Beginning Markup - + End Markup - + Listing Layout - - * Message Customization - + Beginning Markup - + End Markup - + Header and Footer - + Navigational Links - + Message Layout - + Other Resources - - * MIME - + Default Filters - + Non\-MIME Messages - + Writing Filters - + Specifying Filters - - * Gory Details - + OS Detection - + Processing Steps - + Archive Integrity - + File Formats - + Notes - - * Diagnostics - + Informative messages - + Warnings - + Errors - + Perl Messages - - * Glossary - - * Contacts - + Mailing List - + People - - _________________________________________________________________ - - - Earl Hood - Isogen International Corp - 2200 North Lamar #230 - Dallas, TX 75202 - - Phone: (214) 953\-004 x127 - FAX: (214) 953\-3152 - - _________________________________________________________________ - - - - _________________________________________________________________ - - Introduction - - _MHonArc_ is a Perl program for converting e\-mail messages as - specified in RFC 822 and RFC 1521 (_MIME_) to HTML. _MHonArc_ can - perform the following tasks: - - * Convert mh(1) mail folders or UUCP/Unix style mailboxes into an - HTML mail archive. - * Add or remove messages to an existing HTML mail archive generated - by _MHonArc_. - * Convert a single message to HTML. - - Along with these tasks, _MHonArc_ provides the following: - - * A main customizable index page for mail messages archived. - * A customizable thread index page listing messages by thread. - * Control over message formatting. - * The ability to hook in your own custom message filters. - - _________________________________________________________________ - -Why Use MHonArc? - - Here are some reasons for using _MHonArc_: - - * You want to keep organized archives of mail messages and/or news - articles for a World Wide Web (_WWW_) server; complete with live - hypertext pointers to their authors and to any url's mentioned. - * You would like to control the layout of mail/news archives to keep - a consistent style to your WWW pages. - * You have a WWW client, but no MIME mail reader. _MHonArc_ will - allow you to read MIME messages that includes images, audio, - video, etc via your Web client. - * Muli\-platform support: MS\-DOS and Unix. - * You think the _MHonArc_ logo is really cool, and it deserves to be - used. - * You like Perl, and you want to see what it can do. - * Just cuz. - - _________________________________________________________________ - -Supported Platforms - - _MHonArc_ (version 1.1, or later) will run under Unix or MS\-DOS - operating systems with Perl 4 or 5 installed. - - _________________________________________________________________ - -Availability - - The latest information on _MHonArc_, and its availability, may be - obtained at . - - _________________________________________________________________ - -About the Documentation - - The documentation is oriented towards Unix users. However, the section - on Installation does conver MS\-DOS installation instructions. Notes - are made in the documentation when something may differ due to the - operating system. - - _________________________________________________________________ - - - _________________________________________________________________ - - Installation - - This section instructs you on how to install and get _MHonArc_ running - on your machine. The section covers _Unix_ installation and - _MS\-DOS/Windows_ installation. - - _NOTE_ - For brevity, anything that applies to MS\-DOS also applies to - Windows. - - _________________________________________________________________ - -System Requirements - - _MHonArc_ is written in Perl 4. Therefore, you must have Perl 4 or 5 - installed on your system. If you do not know if Perl is installed on - your system, ask your system administrator. - - If Perl is not installed on your system, you can retrieve Perl at - . I recommend version 4.0 - patchlevel 34, or later. _MHonArc_ has not been tested on earlier - versions. - - _NOTE_ - _MHonArc_ makes use of the Perl libraries newgetopt.pl and - timelocal.pl. These libraries are part of the normal Perl - distribution. - - _________________________________________________________________ - -Extracting the Distribution File - - Before extracting the distribution file, you may want copy the - distribution file into scratch directory, and work in there during - installation. - - Tar/Gzip Distribution - - You must have _gzip_ and _tar_ installed on your system. If _gzip_ is - not installed, you may obtain _gzip_ at - . _Tar_ comes with all Unix - systems. However, MS\-DOS users may have to obtain _tar_. - - To extract the file, type the following command at your shell's - prompt: - - _Unix_ - zcat MHonArc.tar.gz | tar xvof \- - - _MS\-DOS_ - gunzip \-dv MHonArc.tar.gz - tar xvf MHonArc.tar - - A directory called "MHonArc" should be created. The directory contains - all the files need for installing _MHonArc_. - - _NOTE_ - The actual name of the distribution file may differ from the - example given. - - Zip Distribution - - You must have _pkzip_ or _unzip_ installed on your system. - - To extract the file, type the following command at your shell's - prompt: - - unzip mhonarc.zip - - OR - - pkunzip \-d mhonarc.zip - - _IMPORTANT_ - The directory structure of the zip file must be preserved - during extraction to insure proper installation. - - A directory called "MHonArc" should be created. The directory contains - all the files need for installing _MHonArc_. - - _NOTE_ - The actual name of the distribution file may differ from the - example given. - - _________________________________________________________________ - -Installing the Software - - Once you have extracted the distribution file, change your current - working directory into the MHonArc directory created during the - extraction of the distribution file. - - _Example_: Assuming you are in the directory you extracted the - distribution file in, you can type the following on your command\-line: - - _Unix_ - cd MHonArc - - _MS\-DOS_ - cd MHONARC - - install.me - - Contained in the MHonArc directory is a Perl program called - "install.me". This program will perform the tasks required to install - _MHonArc_ on you machine. The install program is capable of running - interactively, or in batch. - - Interactive Mode - - To run install.me in interactive mode, type the following at your - shell's prompt: - - perl install.me - - _NOTE_ - Make sure you are in the same directory as the install.me - program. - - The program will then prompt you for the necessary information to - install _MHonArc_ on your system. - - Here's an example (Unix) session: - -% perl install.me -MHonArc Installation -==================== -The installation process will ask you a series of questions on where -the Perl executable is and where to put MHonArc files. Just hit -to accept the default values listed in ()'s. - -If directory path does not exist on your system, the installation -program will create the path for you. - -\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- -Note: Make sure all pathnames are absolute. -\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - -Hit to continue ... -Perl executable ("/usr/local/bin/perl") -\-> /usr/bin/perl -Location to install programs ("/usr/local/bin") -\-> /mnt/ehood/bin -Location to install libraries ("/usr/local/lib/MHonArc") -\-> /mnt/ehood/lib/MHonArc -Install documentation ("y")? y -Location to install docs ("/usr/local/lib/MHonArc/doc") -\-> /mnt/ehood/lib/MHonArc/doc - -You've specified the following: - Perl location: /usr/bin/perl - Program directory: /mnt/ehood/bin - Library directory: /mnt/ehood/lib/MHonArc - Doc directory: /mnt/ehood/lib/MHonArc/doc -Is this correct ("y")? y -Installing the following into /mnt/ehood/bin - mhonarc -Installing the following into /mnt/ehood/lib/MHonArc - base64.pl - mhexternal.pl - mhtxthtml.pl - mhtxtplain.pl - mhtxtsetext.pl - qprint.pl - readmail.pl -Installing the following into /mnt/ehood/lib/MHonArc/doc - mhonarc.txt - ... - - Batch Mode - - To run install.me in batch mode, type the following at your shell's - prompt: - - perl install.me install.cfg - - _NOTE_ - Make sure you are in the same directory as the install.me - program. - - The install.cfg contains the necessary information for intalling - _MHonArc_ on your system. You will need to edit install.cfg to reflect - your installation requirements. - - Here is an example install.cfg: - -# Should executables be installed. 0 => NO, non\-zero => YES. -# -$dobin = 1; - -# Should libraries be installed. 0 => NO, non\-zero => YES. -# -$dolib = 1; - -# Should documentation be installed. 0 => NO, non\-zero => YES. -# -$dodoc = 1; - -# Location for executable. If using ms\-dos, use something like -# 'C:\\\\BIN'. -# -$bindir = '/usr/local/bin'; - -# Location for libraries. If using ms\-dos, use something like -# 'C:\\\\LIB\\\\MHONARC'. -# -$libdir = '/usr/local/lib/MHonArc'; - -# Location for documents. If using ms\-dos, use something like -# 'C:\\\\DOC\\\\MHONARC'. -# -$docdir = '/usr/local/lib/MHonArc/doc'; - -# Location of perl executable. If using ms\-dos, use something like -# 'C:\\\\BIN\\\\PERL.EXE'. -# -$perlprg = '/usr/local/bin/perl'; - - -1; # DO NOT DELETE THIS LINE - - The file is Perl code, and therefore, must follow Perl syntax rules: - - * Anything following a `#' character is ignored. - * Strings values need to be enclosed in quotes. - * If you need to use a backslash in a string value, it must be - escaped with a backslash. Example: 'C:\\\\LIB\\\\MHONARC'. The same - applies to the '$' character. - * All statements must end with a semi\-colon. - * The "1;" line must not be deleted. - - _NOTE_ - You can verify the syntax of the configuration file by invoking - "perl \-c" on the file. - - After you have successfully executed install.me, _MHonArc_ is ready to - use. - - MS\-DOS Post install.me Note - - If you would like the ability to run _MHonArc_ like other programs, - then create a batch file that contains something like the following: - -@ECHO OFF -C:\\BIN\\PERL.EXE C:\\BIN\\MHONARC %1 %2 %3 %4 %5 %6 %7 %8 %9 - - Of course, you will need to change the paths to Perl and _MHonArc_ to - suit your systems configuration. - - Sample batch files are available in the _MHonArc_ distribution. - - Notes on install.me - - * If you do not know the location of the Perl executable on your - system, ask your system administrator. - * All pathnames must be absolute. - * If a path does not exist that you specify, the path will be - automatically created if running in interactive mode. In batch - mode, all paths specified must already exist. - * During the installation process, the main _MHonArc_ source file is - modified to be aware of the location of the Perl executable and - _MHonArc_'s library files. If you ever need to install _MHonArc_ - in a different location, rerun the install.me program. - _NOTE_: Location of the Perl exectuble is only relevant for Unix - systems. MS\-DOS systems do not make use of the "#!" line in - scripts. - * _MHonArc_ requires the use of timelocal.pl and newgetopt.pl. These - libraries are part of the normal Perl distribution. - - _________________________________________________________________ - -Tested Environments - - This section covers software environments _MHonArc_ has worked - successfully. Feedback is welcome about other success, or failure, - stories covering _MHonArc_ usage in other environments. - - Perl - - _MHonArc_ is known to work with the following version of Perl 4, or - later: - - $RCSfile: perl.c,v $$Revision: 4.0.1.7 $$Date: 92/06/08 14:50:39 $ - Patch level: 34 - - _MHonArc_ is known also to work with Perl 5.001m and Perl 5.002 beta2. - - _NOTE_ - The version numbers are based upon the Unix versions of Perl. - DOS version numbers may differ. - - Unix - - Mail Software - - * _MH_ - * _Elm_, _Mail_, _mail_, and any other mail software that stores - e\-mail in UUCP style mailbox format. UUCP format is where mail - messages are separated by a line beginning with "From " (I.e. the - word "From" followed by a space). You may need to utilize the - MSGSEP resource if the message separator is different from - standard mailbox files (eg. MMDF format). - - News Software - - Different news software store messages differently. Messages are - either stored in a format similiar to _MH_ or similiar to a mailbox - file: - - * _MH_ style is where the messages are stored in a directory with - each post a separate file, and each file has a numeric filename. - * Mailbox style is where messages are stored in a single file. You - may need to utilize the MSGSEP resource if the message separator - is different from standard mailbox files. - - MS\-DOS - - Mail/News Software - - _MHonArc_ has been tested under MS\-DOS with message files created by - the following mail and news programs: - - * _Eudora_ - * _WinVN_ - * _Windows Trumpet_ - * _NUPop_ - - It also works with individual RFC822 mail messages, but you must run - _MHonArc_ without a batch file if you need to use redirection. For - example: - - perl c:\\bin\\mhonarc one.htm - perl c:\\bin\\mhonarc \-add /inbox - - Where represents the path to the directory that contains the - mail folder _inbox_. If you are in the directory that contains inbox, - then you can leave out the "/". - - _MHonArc_ prints out messages showing its progress as your e\-mail is - processed. When _MHonArc_ finishes, the following files will be - created: - - * maillist.html: The main index file containing links to all mail - messages converted. Messages are listed with subjects and who the - messages are from. All messages are listed in sorted order by date - received/sent. - * threads.html: The file listing messages by thread. - * msg*.html: HTML versions of the mail messages, where * represents - a message number from 0 to the number of message processed minus - 1. - * .mhonarc.db (or MHONARC.DB under MS\-DOS): This database file is - needed inorder for _MHonArc_ to perform additions of new mail - messages to the archive. Information is stored to perform mail - threading updates when new messages are added, as well as any - resources set via Environment variables, Resource File, and/or - command\-line Options. - * _Other_: Depending on the content\-types of the e\-mail messages - converted, other files may be created for images, videos, - binaries, etc. See the section on MIME for more information. - - The format of each converted mail message is as follows: - - * A is inserted in the - HEAD element of HTML mail message file. This allows readers of the - message to send comments to the author of the mail message within - Web browsers that support such functionality (like _Lynx_). - * The title (i.e. TITLE element) contains the subject of the - message. - * Hyperlinks to the previous and next messages and the index pages - are located at the top of the message. - * Next, the subject appears in a H1 element. - * Next, follows the mail header with fields listed in a UL element - surrounded by HR's. - * Next, the actual body of the mail message. - * Next, links to any follow\-up, or referenced, messages. The - messages are listed by subject and who they are from. These links - allows you to easily follow mail threads. - * Last, are verbose links to the previous mail message, next mail - message, and index pages. - - The following is also done for each mail message processed: - - * Links are created in the "References" and "In\-Reply\-To" header - fields, and possibly the message body, if the destination - message\-ids are being processed. - * E\-mail addresses are converted to "mailto" hyperlinks in "To:", - "From:", "Cc:", and "Sender:" mail header fields. Currently, not - all Web browsers support the mailto URL. - * Newsgroups listed in a "Newsgroups:" mail header field are - converted to news hyperlinks. - - _MHonArc_ allows you to specify more than one mail folder to process - on the command\-line. - - _Example_ - % mhonarc /home/ehood/mail/inbox1 /home/ehood/mail/inbox2 ... - - All the files created will be put into the current working directory, - by default. You can control the destination of the output location by - using the \-outdir option. - - _Example_ - % mhonarc \-outdir /home/ehood/htmlarchive - /home/ehood/mail/inbox - - Here is a sample session converting a mail folder: - -% mhonarc ~/mail/inbox -Requiring MIME filter libraries ... - mhexternal.pl - mhtxthtml.pl - mhtxtplain.pl - mhtxtsetext.pl -Converting messages to ./maillist.html -Reading /mnt/ehood/mail/inbox .......... -Writing mail ... -Writing tmp/maillist.html ... -Writing tmp/threads.html ... -10 messages - - _________________________________________________________________ - -Adding Messages to an Archive - - If you have new messages you want to add to an existing archive, you - must utilizing the \-add command\-line option. With the \-add, you can do - the following: - - * Add a mail folder to an archive, or - * Add a single message to an archive. - - Adding a mail folder to an archive in the current working directory - can be done like the following: - - % mhonarc \-add /mailfolder - - If you are not in the same directory as the archive, then you can - specify the location of the archive to add to with the \-outdir option: - - % mhonarc \-add \-outdir /mailfolder - - _NOTE_ - _MHonArc_ will skip any messages that already exist in the - archive. Therefore, _MHonArc_ can be used to rescan the same - mail folder and only convert any new messages it finds. - - If no mail folder arguments are specified, then _MHonArc_ will attempt - to add a _single_ message read in from standard input. - - _Example_ - % mhonarc \-add < single.msg - - Or, from a pipe: - - % cat single.msg | mhonarc \-add - - See the section on Adding Messages for more information and examples - for adding messages to an archive. - - _________________________________________________________________ - -Converting a single message - - _MHonArc_ has the ability to process a single mail message independent - of creating, or modifying, and archive. To convert a single message to - HTML use the \-single command\-line option. The message to process can - be specified by a filename on the command\-line, or by reading the - message from standard input if no file is specified. The filtered - message is sent to standard output. All formatting options apply to - the single message as with messages being processed for an archive, - with the exception of formatting related specificly to archive - processing, like index links and mail thread links. - - Examples - - Input from standard input: - % mhonarc \-single < messagefile > file.html - - Filename on command\-line: - % mhonarc \-single messagefile > file.html - - _________________________________________________________________ - - - _________________________________________________________________ - - Overview - - This section gives an overview of _MHonArc_'s command\-line options and - environment variables. The _MHonArc_ resource file is covered in the - section Resource File. The resource file allows you to specify most of - the resources set by environment variables and command\-line options, - plus it give you the capability of completely customizing the HTML - output generated by _MHonArc_. - - _________________________________________________________________ - -Synopsis - - Invoke _MHonArc_ from your shell with the following syntax: - - % mhonarc [_options_] _mhfolder_... - % mhonarc [_options_] _mailbox_ ... - % mhonarc \-add [_options_] < _message_ - % mhonarc \-single [_options_] < _message_ > _message.html - _% mhonarc \-single [_options_] _message_ > _message.html - _% mhonarc \-rmm [_options_] _msg# _..._ - _ - _________________________________________________________________ - -Options - - The following options are available: - - \-add - - Add new messages to an existing archive. If no mail folder arguments - are given, _MHonArc_ assumes that a _single_ message is being added to - the archive via _standard input_. Otherwise, _MHonArc_ adds the - messages contained in the mail folders specified. - - \-dbfile name - - Use _name_ for the name of _MHonArc_ database file. The default is - ".mhonarc.db" (or "MHONARC.DB" under MS\-DOS). - - _NOTE_ - You should not override the default name unless absolutely - necessary, and you are confident about what you are doing. - - \-docurl url - - Use _url_ as the URL to _MHonArc_ documentation. The default is - "http://www.oac.uci.edu/indiv/ehood/mhonarc.html". - - \-editidx - - This option tells _MHonArc_ to rewrite the index page and re\-edit all - mail messages in the archive. This option is useful if you need to - change the layout of the index page and/or messages. - - \-footer filename - - Insert contents of filename at the bottom of the index page. See - Include Files in Index Page Customization for more information about - the footer file. - - \-force - - Override a lock on an archive if attempts to lock fail. I.e. After - trying unsuccessfully to lock an archive, _MHonArc_ will still perform - the actions requested. - - This option is useful to help dealing with locks that are no longer - valid (i.e. _stale locks_). A stale lock can exist if the _MHonArc_ - process that created the lock abnormally terminated and could not - perform the proper cleanup procedures. - - \-genidx - - Output an index page to standard output based upon the contents of an - archive, and utilizing any extra formatting options specified. - - \-header filename - - Insert contents of _filename_ at the beginning of the index page. See - Include Files in Index Page Customization for more information about - the header file. - - \-help - - Print out a help message about _MHonArc_. - - \-idxfname name - - Sets the name of the main index file to _name_. The default is - "maillist.html". - - \-idxsize # - - Set the maximum number of messages listed in the indexes. - - \-lockdelay # - - The sleep time, in seconds, between attempts to lock the archive. The - default value is 3. - - \-locktries # - - Set the number of time _MHonArc_ tries to lock a mail archive before - processing new messages. The default value is 10. _MHonArc_ waits - approximately 3 seconds before each try. - - See Archive Integrity for more information on the \-locktries options. - - \-mailtourl url - - Use _url_ for e\-mail address hyperlinks in mail message headers. The - url can contain the following _variables_ that get expanded during - run\-time: - - $FROM$ - Who the message is from. - - $MSGID$ - Message ID of the message. - - $SUBJECT$ - The subject of the message. - - $TO$ - Destination e\-mail address of link. - - The default URL is "mailto:$TO$" - - The \-mailtourl option has no effect if the \-nomailto option is - specified. - - \-maxsize # - - Set the maxinum number of messages allowed in the archive to _#_. If - messages are added to the archive which would cause the total number - of messages to exceed _#_, older messages (based on sort method) are - removed automatically. - - \-msgsep expression - - Use the _expression_ as the Perl regular expression that signifies the - message separator in Unix mailbox files. The default expression is - "^From " (minus the quotes). - - _NOTE_ - There is a space character after the From. - - \-nodoc - - Do not print link to documentation at end of index page. - - \-nomailto - - Do not convert e\-mail addresses in mail headers to mailto hyperlinks. - - \-nonews - - Do not convert newsgroups in the Newsgroups: mail header field to news - hyperlinks. - - \-noreverse - - Do not perform a reverse listing of the mail messages in the index - page. - - \-nosort - - Do not sort messages by date. Messages will be in the order they - appear in the mailboxes/folders. By default, _MHonArc_ sorts messages - by date sent/received. - - \-nosort takes precedence over the \-sort option. - - \-nothread - - Do not create a thread index page. - - \-notsubsort - - Do not sort threads by subject on thread index page. - - \-notreverse - - List threads in the thread index with oldest thread first. - - \-outdir path - - Set destination/location of the HTML mail archive to _path_. By - default, the current working directory is used. - - \-quiet - - Suppress processing messages when _MHonArc_ is running. - - \-rcfile file - - Use file as the resource file for _MHonArc_. _MHonArc_ does the - following to determine the location of file: - - 1. If its an absolute pathname, use it. - 2. If it is a relative pathname, check for it relative to the current - working directory. - 3. Otherwise, check for it relative to the location of the archive. - - See Resource File for more information. There is no default resource - file. - - \-reverse - - List messages in reverse order of the sorting option specified. For - example, if date sorting is specified, \-reverse will cause messages to - be listed in _reverse_ chronological order. - - \-rmm - - All non\-option command\-line arguments are treated as messages to - remove from the archive. Messages to remove are denoted by their - message numbers. - - \-savemem - - Normally, all messages are stored in memory and then written in one - shot. This option causes _MHonArc_ to write the message data as it is - processesd. This option will cause a slow down in execution time as - more disk I/O required, but it may allow large amounts of data to be - processed in a single process if memory is limited. - - _NOTE_ - The reason more disk I/O is required is that when the message - data is first written, all the archive navigational link - information is non\-existant. The information required to - correctly generate the navigational link information will not - exist until all messages are processed. Therefore, each new - message file must be reopened to add in the navigational link - information after all messages are processed. - - \-scan - - List contents of archive to standard output. - - \-single - - Convert a single mail message to HTML. The message can be specified by - a filename on the command\-line, or read from standard input if no file - is given. The filtered message is sent to standard output. - - The \-single option is useful tp convert individual messages to HTML - not related to a specific mail archive. Any option related to how - message formatting can be used with the \-single option. - - The \-single takes precedence over the \-add option. - - \-sort - - Perform chronological date sorting. This is the default. - - \-subsort - - Sort messages by subject. Subject sorting is case\-insensitive, and - begining "Re:", "A", "An", and "The" words are ignored. - - \-tidxfname name - - Sets the name of the thread index file to _name_. The default is - "threads.html". - - \-time - - Print out total CPU execution time taken when processing messages. - Time information is written to standard error. - - \-title string - - Set the title of the main index page to _string_. The default is - "_Mail Index_". - - \-thread - - Create a thread index page. This is the default. - - \-tlevels - - Set the maximum number of nested lists for the thread index page. The - default is 3. - - \-treverse - - List threads in the thread index with newest thread first. - - \-tsubsort - - List threads in the thread index by subject. - - \-ttitle string - - Set the title of the thread index page to _string_. The default is - "_Mail Thread Index_". - - \-umask umask - - Set the umask of the _MHonArc_ process to _umask_. The value is - treated as an octal number. - - NOTE - - The \-no* options always take precedence over their counterparts. For - example, if \-noreverse and \-reverse are both specified on the - command\-line, the \-noreverse will be applied. - - _________________________________________________________________ - -Environment - - _MHonArc_ supports the use of environment variables. The environment - variables allow you to set default options everytime you invoke - _MHonArc_. The following environment variables may be used: - - M2H_DBFILE - - Sets the name of _MHonArc_ database file. The default is ".mhonarc.db" - (or "MHONARC.DB" under MS\-DOS). - - _NOTE_ - You should not override the default name unless absolutely - necessary, and you are confident about what you are doing. - - M2H_DOCURL - - Set the URL used to point to _MHonArc_ documentation. The default is, - "http://www.oac.uci.edu/indiv/ehood/mhonarc.html". - - M2H_FOOTER - - Set the HTML footer file to insert at the bottom of the index page. No - default footer file is defined. See Include Files in Index Page - Customization for more information about the footer file. - - M2H_HEADER - - Set the HTML header file to insert at the top of the index page. No - default header file is defined. See Include Files in Index Page - Customization for more information about the header file. - - M2H_IDXFNAME - - Set the name of the index file. The default is, "maillist.html". - - M2H_IDXSIZE - - Sets the maximum number of messages listed in the indexes. - - M2H_LOCKFILE - - The sleep time, in seconds, between attempts to lock the archive. The - default value is 3. - - M2H_LOCKFILE - - Set the name of the lock file. The default name use is ".mhonarc.lck" - (or "MHONARC.LCK" under MS\-DOS). - - _NOTE_ - You should not change the default unless absolutely necessary. - - See Archive Integrity for more information about the lock file. - - M2H_LOCKTRIES - - Set the number of time _MHonArc_ tries to lock a mail archive before - processing new messages. The default value is 10. _MHonArc_ waits - approximately 3 seconds before each try. - - See Archive Integrity for more information on the M2H_LOCKTRIES - environment variable. - - M2H_MAILTOURL - - Sets the URL for e\-mail address hyperlinks in mail message headers. - The URL can contain the following _variables_ that get expanded during - run\-time: - - $FROM$ - Who the message is from. - - $MSGID$ - Message ID of the message. - - $SUBJECT$ - The subject of the message. - - $TO$ - Destination e\-mail address of link. - - The default URL is "mailto:$TO$" - - M2H_MAXSIZE - - Sets the maximum number of messages that an archive will contain. If - messages are added to the archive which would cause the total number - of messages to exceed M2H_MAXSIZE, older messages (based on sort - method) are removed automatically. - - M2H_OUTDIR - - Sets the destination/location of the HTML mail archive. The default is - the current working directory. - - M2H_RCFILE - - Specifies the Resource File for _MHonArc_. No default resource file is - defined. - - M2H_THREAD - - Flag to determine if _MHonArc_ generates a thread index. If set to - zero, the thread index will not be created. The default behavior is to - create a thread index. - - M2H_TIDXFNAME - - Sets the name of the thread index file. The default is "threads.html". - - M2H_TITLE - - Sets the default title of the index page. The default is "_Main - Index_". - - M2H_TLEVELS - - Sets the maximum number of nested lists for the thread index page. The - default is 3. - - M2H_TTITLE - - Sets the title of the thread index page. The default is "_Mail Thread - Index_". - - NOTE - - Environment variables may be overriden by the Resource File or - command\-line Options. - - _________________________________________________________________ - - - _________________________________________________________________ - - Resource File - - _MHonArc_ supports the ability to read in a resource file to control - the behavior of _MHonArc_. The resource file allows you to specify - most of the resources set by environment variables and command\-line - options, and it allows you to specify other resources to control - _MHonArc_'s behavior. - - The resource file is specified by the M2H_RCFILE environment variable - or the \-rcfile command\-line option. The command\-line option overrides - the environment variable if both are defined. - - _NOTE_ - _MHonArc_ will store the information specified in the resource - file in the database for the archive. Therefore, it is - unnecessary to respecify the resource file duing archive - updates unless changes are required from the current settings. - - _________________________________________________________________ - -Resource Syntax - - Resources are set in the file by using _elements_ similiar in style to - HTML/SGML markup. However, _MHonArc_ uses simpler parsing rules for - the resource file than standard SGML: - - * Any line that is not a recognized element open tag, _and_ the line - is not contained within an element, is ignored. This implies that - regular text can be put anywhere _outside_ of recognized elements - for commenting purposes. - _NOTE_: You should use SGML comment declarations () - when commenting a resource file. This will eliminate possible - conflict with later versions of _MHonArc_ if more stricter parsing - rules are adopted. - * The opening tag of an element must occur by itself on a single - line. Whitespace is allowed before the the open tag. - * No comments are allowed inside elements because the text will be - treated as element content. - * Each element must be closed with a tag on its own - line unless _explicitly_ stated otherwise in the Resource Elements - section. Whitespace is allowed before the close tag. - * Some elements can take an optional attribute called "Override". - This tells _MHonArc_ that the contents of the element will - completely override the default behavior of _MHonArc_, and - previous instances of the element. _Example_: "". - If "Override" is not specified, then the contents of the element - augment the current setting. - * Element names are case\-insensitive. - * Elements can occur in any order in the resource file. - - Resource Variables - - Some resource element contents may contain variables. Variables get - expanded to strings at run\-time. - - _NOTE_ - Variable expansion will only take place in resource elements - that are intended to have variables as part of their content. - If an element is not meant to have variables, the variable text - will be taken literally as part of the element content. - - The syntax of the _variables_ to use in resource elements is as - follows: - - $_VARIABLE_[:[_N_][U]]$ - - The items in []'s are optional. Definition of each part: - - $ - The $ character represents the beginning, and ending, of the - variable. - - _VARIABLE_ - This is the the actual name of the variable. All variable names - must be uppercase. - - :[_N_][U] (_optional_) - This defines a maximum length of the replacement string for the - variable. The option "U" denotes that the replacement string - should be treated as part of a URL string. This can be useful - when the variable may contain special characters, and the - variable is used withing a URL. - - _No_ whitespace is allowed between the opening $ and closing $. If an - unrecognized variable is encountered, it gets replaced with an empty - string. If a literal "$" is needed, use "$$". - - _SPECIAL NOTE_ - The MAILTOURL resource has different rules for variable - expansion. If a variable does not exactly match the set of - variables available for the MAILTOURL, the variable text will - be taken literally as part of the element content. Therefore, a - single "$" can be used to represent a "$" character. - - Also, variables in the MAILTOURL should _NOT_ have ":NU" - modifier. This will prevent the variables from be recognized. - _MHonArc_ will automatically treat the replacement value as a - part of a URL string. - - Here are some examples of legal variable usage: - - * $SUBJECT$ - * $FROMNAME$ - * $SUBJECT:50$ - * $SUBJECTNA:60U$ - * $FROMADDR:U$ - - Each resource element will define what variables are defined for it. - - _________________________________________________________________ - -Resource Elements - - The following are complete listings of all the resource elements - defined by _MHonArc_. Many element descriptions will reference to - other sections of the documentation on the exact usage of the element. - - Empty Elements - - The following list of elements contain no textual content. Therefore, - no end tag is required: - - NODOC - - Do not put link to documentation on main index page. - - NOMAILTO - - Do not convert e\-mail addresses in mail headers to mailto hyperlinks. - - NONEWS - - Do not convert newsgroups in the Newsgroups: mail header field to news - hyperlinks. - - NOREVERSE - - Do not perform a reverse listing of the mail messages in the main - index page. - - NOSORT - - List messages in the index page in the order they are processed. - - NOTHREAD - - Do not create thread index. - - NOTREVERSE - - List threads in the thread index with oldest thread first. - - NOTSUBSORT - - Do not sort thread by subject in thread index page. - - REVERSE - - List messages in reverse listing order for the main index page. - - SORT - - List messages in the index page in chronological order. - - SUBSORT - - Sort messages by subject. Subject sorting is case\-insensitive, and - begining "Re:", "A", "An", and "The" words are ignored. - - THREAD - - Create thread index. This is the default. - - TREVERSE - - List threads in the thread index with newest thread first. - - TSUBSORT - - Sort thread by subject in thread index page. - - Non\-Empty Elements - - The following list of elements contain textual content, therefore, - each element must be _explicitly_ closed with an element end tag - (examples are given in Example Resource File): - - BOTLINKS - - Markup for defining the various hyperlinks at the bottom of converted - messages. See Navigational Links of Message Customization for usage of - this element. - - DBFILE - - Use _name_ for the name of _MHonArc_ database file. The default is - ".mhonarc.db" (or "MHONARC.DB" under MS\-DOS). - - _NOTE_ - You should not override the default name unless absolutely - necessary, and you are confident about what you are doing. - - DOCURL - - URL to _MHonArc_ documentation. The default is - "http://www.oac.uci.edu/indiv/ehood/mhonarc.html". - - EXCS - - Set of message header fields to exclude from messages. See Excluding - Fields of Message Customization for usage of this element. - - FIELDORDER - - The order the message header fields appear in messages. See Field - Order of Message Customization for usage of this element. - - FIELDSTYLES - - The format specification for message header field values. See Field - Formatting of Message Customization for usage of this element. - - FOOTER - - File to include at the end of the index page. See Include Files in - Index Page Customization for more information about the footer file. - - HEADER - - File to include at the beginning of the index page. See Include Files - in Index Page Customization for more information about the header - file. - - ICONS - - The ICONS element is used to specify the icons that represent the - different content\-types of messages. See Icons in Index Page - Customization for usage of this element. - - IDXFNAME - - The name of the index file. The default is "maillist.html". - - LABELSTYLES - - The format specification for message header field labels. See Field - Formatting in Message Customization for usage of this element. - - LISTBEGIN - - Markup for beginning the main index list. See Listing Layout in Index - Page Customization for usage of this element. - - LITEMPLATE - - Markup for an entry in the main index list. See Listing Layout in - Index Page Customization for usage of this element. - - LISTEND - - Markup for terminating the main index list. See Listing Layout in - Index Page Customization for usage of this element. - - MAILTOURL - - Url to use for e\-mail hyperlinks. See E\-mail Links in Message - Customization for usage of this element. - - MIMEARGS - - Arguments to MIME filters. See Specifying Filters in MIME for usage of - this element. - - MIMEFILTERS - - Routines for filtering messages. See Specifying Filters in MIME for - usage of this element. - - MSGFOOT - - Footer text for converted messages. See Header and Footer in Message - Customization for usage of this element. - - MSGHEAD - - Header text for converted messages. See Header and Footer in Message - Customization for usage of this element. - - MSGSEP - - Perl regular expression that represents the message separator for - mailbox files. The default expression is "^From ". - - OTHERINDEXES - - List of resource files (one per line) defining other index pages to - generate when creating, or updating, an archive. - - _CAUTION_ - It is very important that each resource file specified defines - the IDXFNAME (or the TIDXFNAME _and_ THREAD elements for a - thread index) to prevent overwriting of the default index - pages. - - _MHonArc_ will only store the name of the resource files listed in the - database. Therefore, for any subsequent updates the archive, the extra - index resource files must exist inorder to generate the extra index - pages. - - _NOTE_ - Since _MHonArc_ will look in the archive location for resource - files specified with relative pathnames, you can keep the other - index resource files in the same location as the archive, and - just specify the filenames for the OTHERINDEXES element in the - main resource file. - - When create resource files for extra indexes, make sure to explicitly - set all resources desired since some resource settings may no longer - be set to the defaults due to database settings, or from a previously - read resource file. Ie. _MHonArc_ does not reset to the default - settings when reading in the other resource files. - - PERLINC - - Each line represents a path to search when requiring MIME filters. See - Specifying Filters in MIME for the use of this element. - - TFOOT - - Markup that appears after the thread index listing. See Listing Layout - in Thread Index Customization for usage of this element. - - THEAD - - Markup that appears before the thread index listing. See Listing - Layout in Thread Index Customization for usage of this element. - - TIDXFNAME - - The name of the thread index file. The default is "threads.html". - - TIMEZONES - - Each line of the TIMEZONES element defines a timezone acronym and its - hour offset from UTC/GMT (_Universal Coordinate Time_). The format of - each line is "timezone_acronym:hour_offset". Examples of timezone - acronyms are: UTC, PDT, EST. The hour offset is should be positive for - timezones West of UTC, and negative for time zones East of UTC. - - _MHonArc_ has a default list of timezone acronyms defined with hour - offsets. Therefore, the list given in the resource file will augment - the default list, unless the "Override" attribute is specified. If - "Override" is specified, the default list, along with any other lists - specified in previous TIMEZONES elements, are discarded, and only the - timezone acronyms specified in the TIMEZONES element will be used. - - The following is the default value for TIMEZONES: - - -UTC:0 -GMT:0 -AST:4 -ADT:3 -EST:5 -EDT:4 -CST:6 -CDT:5 -MST:7 -MDT:6 -PST:8 -PDT:7 - - - Most of the time, the date used by _MHonArc_ uses a hour offset - instead of a timezone acronym. However, mail messages may contain - timezone acronyms in received/sent dates and _MHonArc_ must be told - what the hour offset from UTC the timezone acronym represents in order - to properly sort messages by date. - - TITLE - - Title for the main index page. The default is "_Mail Index_". - - TLEVELS - - The maximum number of nested lists for the thread index. The default - is 3. - - TLITXT - - Markup for an entry in the thread index list. See Listing Layout in - Thread Index Customization for usage of this element. - - TOPLINKS - - Markup for defining the various hyperlinks at the top of converted - messages. See Navigational Links in Message Customization for usage of - this element. - - TTITLE - - Title for the thread index page. The default is "_Mail Thread Index_". - - UMASK - - Sets the umask for the _MHonArc_ process. The value is treated as an - octal number. The resource is only applicable on Unix systems. - - _________________________________________________________________ - -Example Resource File - - - - -MHonArc test - - - -MHonArc test - - - - - - -
    -Last updated: $LOCALDATE$
    -$NUMOFMSG$ messages in chronological order
    -
    - -

    -Listing format is the following: -

    -

    • -Subject -(# of follow\-ups) -From
      -
    -

    -


    -
      - - - - - -
    • -$SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
      - - - -
    -

    -


    - -Home - -

    - - - - -

    -Thread index
    -Last updated: $LOCALDATE$
    -$NUMOFMSG$ messages
    -
    - -
    - - - - -apparently -errors\-to -followup -forward -lines -message\-id -mime\- -nntp\- -originator -path -precedence -received -replied -return\-path -status -via -x\- - - - -\-default\- -subject:strong -from:strong -to:strong - - - -\-default\- -subject:strong -from:strong -to:strong -keywords:em -newsgroups:strong - - - -
    -MHonArc test archive -
    -
    - - - -Home | -Main Index | -Thread Index - - - - - -application/octet\-stream:http://foo.org/icons/binary.xbm -application/postscript:http://foo.org/icons/postscript.xbm -audio/basic:http://foo.org/icons/sound.xbm -image/gif:http://foo.org/icons/image.xbm -image/jpeg:http://foo.org/icons/image.xbm -image/tiff:http://foo.org/icons/image.xbm -multipart/alternative:http://foo.org/icons/alternative.xbm -multipart/digest:http://foo.org/icons/text.xbm -multipart/mixed:http://foo.org/icons/mixed.xbm -multipart/parallel:http://foo.org/icons/mixed.xbm -text/richtext:http://foo.org/icons/mixed.xbm -text/html:http://foo.org/icons/mixed.xbm -text/plain:http://foo.org/icons/text.xbm -unknown:http://foo.org/icons/unknown.doc.xbm -video/mpeg:http://foo.org/icons/movie.xbm -video/quicktime:http://foo.org/icons/movie.xbm - - - _________________________________________________________________ - -Notes on Resource File - - * Elements can be duplicated. The following elements augment - previous instances of themselves: - + EXCS (can specify Override attribute) - + FIELDSTYLES - + ICONS (can specify Override attribute) - + LABELSTYLES - + MIMEFILTERS (can specify Override attribute) - + PERLINC (can specify Override attribute) - + TIMEZONES (can specify Override attribute) - The Override attribute will discard previous settings of the - element. - * If duplicate instances of other elements exist, the last instance - takes precedence. - * If an element only accepts a single line of content, then the last - line is used for the element's content. - * If elements have conflicting resource settings (eg. NOSORT and - SORT), the last element defined takes precedence. - * Resource file settings override environment variables. - * Command\-line options override any settings in the resource file. - * If you want to do an exact match of a field in the EXCS element, - append a '$' after the field name. - - _________________________________________________________________ - - - _________________________________________________________________ - - Adding Messages - - Adding messages to an archive is done via the \-add option. If no - mailbox/folder arguments are given, _MHonArc_ assumes that a _single_ - message is being added to the archive via _standard input_. Otherwise, - _MHonArc_ adds the messages contained in the mail folders specified. - - _NOTE_ - _MHonArc_ will skip any messages that already exist in an - archive. If a message to be added has a message\-ID that equals - a message\-ID of an archived message, the message is skipped. - - _________________________________________________________________ - -Examples - - Adding a mail folder - - Here is example session adding an mail folder to an existing archive: - -% mhonarc \-add test/www -Requiring MIME filter libraries ... - mhexternal.pl - mhtxthtml.pl - mhtxtplain.pl - mhtxtsetext.pl -Adding messages to ./maillist.html -Reading test/www/ ........................................ -Writing HTML ... -49 messages - - .forward - - _MHonArc_ can be used to add new messages as they are received by - using the ".forward" file in your home directory. Here is how I would - set up my .forward file to invoke _MHonArc_ on incoming mail: - -\\ehood, "|/mnt/ehood/bin/webnewmail #ehood" - - _NOTE_ on .forward entry: - The "\\ehood" tells sendmail to still deposit the incoming - message to my mail spool file. The "#ehood" Bourne shell - comment is needed to insure the command is unique from another - user. Otherwise, sendmail may not invoke the program for you or - the other user. - - "webnewmail" is a Perl program that calls _MHonArc_ with the - appropriate arguments. A wrapper program is used instead of calling - _MHonArc_ directly to keep the .forward file simple. Here is the code - to the webnewmail program: - -#!/usr/local/bin/perl - -$cmd = "/mnt/ehood/bin/mhonarc \-add \-quiet " . - "\-outdir /mnt/ehood/public_html/newmail"; -open(M2H, "|$cmd"); -print M2H ; -close(M2H); - - The webnewmail can be modified to check the mail header before calling - _MHonArc_ to perform selective archiving of messages. For example, - webnewmail can check the To: field and only archive messages that come - from a specific mailing list. - - Cron - - This example uses cron(1) to update some mail archives from MH mail - folders. - - The following entry is in my crontab file: - -0 0 * * * webmail - - webmail is a script executed every night that calls _MHonArc_ to - perform the update: - -#! /bin/csh \-f - -umask 022 -setenv M2H_RCFILE $HOME/.mhonarc.rc -## WWW messages -mhonarc \-add \\ - \-outdir $HOME/public_html/doc/wwwmail \\ - $HOME/mail/www -folder +www >& /dev/null -refile first\-last +www.ar >& /dev/null # Archive original messages - -## Tools messages -mhonarc \-add \\ - \-outdir $HOME/public_html/doc/toolsmail \\ - $HOME/mail/tools $HOME/mail/dtd -folder +tools >& /dev/null -refile first\-last +tools.ar >& /dev/null # Archive original messages -folder +dtd >& /dev/null -refile first\-last +dtd.ar >& /dev/null # Archive original messages - -folder +inbox >& /dev/null # Set current folder to inbox - - - To avoid mail everynight from cron due to output from _MHonArc_, the - \-quiet option can be used for each call to _MHonArc_, or use the - following line in your crontab file: - -0 0 * * * webmail > /dev/null - - Standard error is not redirected to /dev/null so mail is still - received if errors occured during _MHonArc_ execution. - - _________________________________________________________________ - - - _________________________________________________________________ - - Removing Messages - - Removing messages from an archive is done via the \-rmm option. - Messages to be deleted are designated by message numbers on the - command\-line. - - _Example_ - -% mhonarc \-rmm 24 28 39 48 -Removing messages from ./maillist.html ... - Removing message 24 - Removing message 28 - Removing message 39 - Removing message 48 - -Writing mail ... -Writing tmp/maillist.html ... -Writing tmp/threads.html ... -45 messages - - _________________________________________________________________ - -Message Numbers - - Normally, you will never have to worry about message numbers unless - you want to remove messages from an archive. Therefore, you will need - to know how _MHonArc_ assigns message numbers when processing - messages. - - When a message is processed, the smallest available number is assigned - to it, starting with 0. The number assigned to a message becomes part - of the filename for the HTML version of the message (eg. - msg00042.html). - - To avoid message number conflicts, _MHonArc_ determines the smallest - available number by finding the largest assigned number and adding one - to it. - - _________________________________________________________________ - -Scanning an Archive - - You will quickly find out that finding the message numbers for a - messages you want to remove can be a cumbersome task if all you have - to work with are the message filenames. To ease this task, _MHonArc_ - gives you the ability to scan an archives contents via the \-scan - command\-line option. - - Example - -% mhonarc \-scan -100 messages in .: - -Msg # YY/MM/DD From Subject -\-\-\-\-\- \-\-\-\-\-\-\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - 513 95/02/09 Rick Silterra EDComment(sic) - 517 95/02/09 Earl Hood Re: DTD2HTML - 512 95/02/09 Earl Hood Re: edc2html - 516 95/02/09 John Barnum Re: DTD2HTML - 515 95/02/09 Earl Hood Re: DTD2HTML - 511 95/02/09 Rick Silterra edc2html - 514 95/02/08 John Barnum DTD2HTML - 510 95/02/06 jflores mhonarc_diagnostics.doc.html - 509 95/02/06 web Dr.Web: Status Review + Thank You - 508 95/02/05 Earl Hood Re: sgml to html converters - 507 95/02/03 Aileen Barry sgml to html converters - 506 95/01/28 Earl Hood Re: MHonarc: Deleting Messages from an archiv - 505 95/01/28 Floyd Moore MHonarc: Deleting Messages from an archive - 504 95/01/25 Earl Hood Re: MHonArc - 503 95/01/25 Earl Hood Re: MHonArc -... - - The messages are listed in the same order as they are listed in the - archive's index page. You will notice that the list order does not - necessarily correspond with message number order. If you always want - the messages listed in message number order when scanning, use the - following: - -% mhonarc \-scan \-nosort \-noreverse -82 messages in .: - -Msg # YY/MM/DD From Subject -\-\-\-\-\- \-\-\-\-\-\-\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - 0 94/05/09 Michael O´Sulli Re: Finger within an html - 1 94/04/31 John M. Troyer Re: TROFF to HTML Converters - 2 94/05/04 John D. Kilburg ANNOUNCE: Chimera 1.53 - 3 94/05/17 Stephen Billing Re: government www? - 4 94/05/21 C. Emory Tate Re: government www? - 5 94/05/24 Daniel W. Conno Re: Comments on HTML 2.0 document/DTD - 6 94/05/24 Dan Connolly Re: Validating HTML documents: - 7 94/05/25 Henrik Frystyk CERN Common World\-Wide Web Library 2.16pre2 A - 8 94/06/04 Denesh Bhabuta Re: Atari on www (revisited) - 9 94/06/07 Dale Newfield ANNOUNCE: Come explore The Edge \- SIGGRAPH 94 - 10 94/06/11 Roy T. Fielding Announcing libwww\-perl 0.12 -... - - _________________________________________________________________ - - - _________________________________________________________________ - - Index Page Customization - - _MHonArc_ creates an index page with links to all mail messages - filtered (unless processing a single message with the \-single option). - _MHonArc_ allows you to have complete customization over the - appearance of the index page by setting various resource either - through environment variables, command\-line options, or the resource - file. - - _________________________________________________________________ - -Filename - - By default, the filename of the index page is "maillist.html". - However, a different name may be specified with the M2H_IDXFNAME - environment variable, the IDXFNAME resource element, or the \-idxfname - command\-line option. - - _________________________________________________________________ - -Beginning Markup - - _MHonArc_ allows you to completely override the begining markup of the - index page. I.e. You can control the opening tag, the HEAD - element contents, the opening tag, etc. Therefore, if you are - not satisfied with the default behavior of how the TITLE resource is - used, or have other needs that require control on the beginning - markup, you can set the IDXPGBEGIN resource file element. - - IDXPGBEGIN - - The best way to show how the IDXPGBEGIN works, the following - represents the default setting _MHonArc_ uses: - - - - - -$IDXTITLE$ - - -

    $IDXTITLE$

    -
    - - _NOTE_ - Technically, setting the TITLE resource, via the M2H_TITLE - environment variable, the TITLE resource element, or the \-title - command\-line option, sets the $IDXTITLE$ resource file - variable. - - The resource variables allowed in the IDXPGBEGIN element are the - following: - - * $DOCURL$ \-\- URL to documentation - * $GMTDATE$ \-\- Current GMT date. - * $IDXFNAME$ \-\- Filename of main index page. - * $IDXSIZE$ \-\- Max number of messages that may be listed in the - index. - * $IDXTITLE$ \-\- The title of the index page. - * $LOCALDATE$ \-\- Current local date. - * $NUMOFIDXMSG$ \-\- Number of message listed. - * $NUMOFMSG$ \-\- Number of messages in the archive. - * $OUTDIR$ \-\- Pathname of archive. - * $PROG$ \-\- Program name. - * $TIDXFNAME$ \-\- Filename of thread index page. - * $TIDXTITLE$ \-\- Title of thread index page. - * $VERSION$ \-\- Program version. - - See Resource Variables for more information on the usage of variables. - - _________________________________________________________________ - -End Markup - - Since _MHonArc_ allows you to control the beginning markup, it makes - sense for it to allow you to control the ending markup. - - IDXPGEND - - The IDXPGEND resource element may be used to define the ending markup - of the index page. The default value is the following: - - - - - - - The resource variables allowed are the same as for IDXPGBEGIN. - - _________________________________________________________________ - -Include Files - - _MHonArc_ allows you to include the contents of files into the index - page via the header and footer resources. - - _NOTE_ - The use of include files is discouraged since the LISTBEGIN and - LISTEND resources can be used to achieve the same results. - Also, the support for the include resource may be removed in - future releases. - - The header file is specified via the M2H_HEADER environment variable, - the HEADER resource element, or the \-header command\-line option. The - contents of the header file are inserted above the message listing, - and right after the H1 title element. - - _NOTE_ - Filename should not contain the , , and - tags; these tags are automatically provided by _MHonArc_, or - defined by the IDXPGBEGIN resource file element. - - The footer file is specified via the M2H_FOOTER environment variable, - the FOOTER resource element, or the \-footer command\-line option. The - contents of the footer file are inserted after the message listing. - - _NOTE_ - Filename should not contain the , and tags; - these tags are automatically provided by _MHonArc_, or defined - by the IDXPGEND resource file element. - - The header and footer files allow you to incorporate search\-forms, - hyperlinks to other pages, or any other HTML markup you like. - - It is only necessary to specify the header and/or footer files the - first time you create an archive. The contents included from the - header and/or footer files are preserved in any subsequent additions - to the archive. Only respecify the header and/or footer files if you - need to make changes to the header/footer contents. - - _________________________________________________________________ - -Listing Layout - - _MHonArc_ lists messages in the order specified by the various sort - options. However, you have complete control on how the message listing - are formatted via the LISTBEGIN, LITEMPLATE, and LISTEND resource - elements in the Resource File. These elements allow you to specify the - HTML markup to use in the index page. - - LISTBEGIN - - The LISTBEGIN resource element specifies the text to begin the message - list. The text can be any valid HTML markup. Plus, _MHonArc_ defines - the following variables you may use which get expanded at run\-time: - - * $DOCURL$ \-\- URL to documentation - * $GMTDATE$ \-\- Current GMT date. - * $IDXFNAME$ \-\- Filename of main index page. - * $IDXSIZE$ \-\- Max number of messages that may be listed in the - index. - * $IDXTITLE$ \-\- The title of the index page. - * $LOCALDATE$ \-\- Current local date. - * $NUMOFIDXMSG$ \-\- Number of message listed. - * $NUMOFMSG$ \-\- Number of messages in the archive. - * $OUTDIR$ \-\- Pathname of archive. - * $PROG$ \-\- Program name. - * $TIDXFNAME$ \-\- Filename of thread index page. - * $TIDXTITLE$ \-\- Title of thread index page. - * $VERSION$ \-\- Program version. - - _MHonArc_'s LISTBEGIN default value is the following: - - - -
    -
      - - - If the NOTHREAD resource is set, the following is the default value: - - -
      -
        - - - LITEMPLATE - - The LITEMPLATE resoure element defines the HTML text to represent each - message list item. You may use the following variables which are - expanded at runtime: - - * $A_ATTR$ \-\- The NAME and HREF attributes to use in an anchor to - link to the archived message. The NAME attribute links the - messages to the index page. - * $A_HREF$ \-\- The HREF attribute to use in an anchor to link to the - archived message. - * $A_NAME$ \-\- The NAME attributes to use in an anchor for messages - to link to the index page. - * $DATE$ \-\- The date of the message. - * $DDMMYY$ \-\- Message date in dd/mm/yy format. - * $ICON$ \-\- The context\-type sensistive icon. See Icons for - information. - * $ICONURL$ \-\- The URL to the context\-type sensistive icon. See - Icons for information. - * $MMDDYY$ \-\- Message date in mm/dd/yy format. - * $NUMFOLUP$ \-\- Number of follow\-ups for the given message. - * $FROM$ \-\- The complete text in the From: field of the message. - * $FROMADDR$ \-\- The e\-mail address in the From: field of the - message. - * $FROMNAME$ \-\- The English name of the person in the From: field of - the message. If no English name is found, the username specified - in the e\-mail address is used. - * $MSGNUM$ \-\- The message numbers assigned to the message by - _MHonArc_. - * $ORDNUM$ \-\- The current listing number of the message. - * $SUBJECT$ \-\- The subject text of the message wrapped in an anchor - element that hyperlinks to the message. - * $SUBJECTNA$ \-\- The subject text of the message without the anchor - element. - * $YYMMDD$ \-\- Message date in yy/mm/dd format. - - _NOTE_ - Do not specify $A_ATTR$, $A_NAME, and $SUBJECT$ together in the - LITEMPLATE element. Since all of these variables contain the - NAME atrribute. Invalid HTML will be created since multiple - anchors will have the same NAME identifier. - - LITEMPLATE's default value is the following: - - -
      • $SUBJECT$ -
        • From: $FROM$
        -
      • -
        - - LISTEND - - The LISTEND resource element specifies the text to use to end the - message list. The text can be any valid HTML markup. LISTEND may - contain the same variables as LISTBEGIN. - - LISTEND's default value is the following: - - -
      - - - _________________________________________________________________ - -Icons - - _MHonArc_ supports the ability to insert icons in the index page for - each message based on the message's content\-type. For example: You can - have text/plain messages use a different icon than text/html messages. - - Defining Icons - - To specify the icons for _MHonArc_ to use, you use the ICONS resource - element in the Resource File. The format of each line in the ICONS - element is as follows: - - __:__ - - __ represents a MIME content\-type. __ is - the URL to the icon. The special content\-type called "unknown" may be - defined to specify the icon to use for non\-recognized content\-types. - If unknown is not defined, the text/plain icon is used for unknown - content types. - - Example - - -audio/basic:http://foo.org/gifs/gsound.gif -image/gif:http://foo.org/gifs/gimage.gif -image/jpeg:http://foo.org/gifs/gimage.gif -image/tiff:http://foo.org/gifs/ggraphic.gif -multipart/alternative:http://foo.org/gifs/gmulti.gif -multipart/digest:http://foo.org/gifs/gtext.gif -multipart/mixed:http://foo.org/gifs/gdoc2.gif -multipart/parallel:http://foo.org/gifs/gdoc.gif -text/richtext:http://foo.org/gifs/gdoc.gif -text/html:http://foo.org/gifs/gdoc.gif -text/plain:http://foo.org/gifs/gletter.gif -unknown:http://foo.org/gifs/gunknown.gif -video/mpeg:http://foo.org/gifs/gmovie.gif - - - Using Icons - - In order to incorporate icons into the index page, insert the $ICON$ - variable into the LITEMPLATE resource element. - - Example - - -$ICONURL$$SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
      -
      - - The $ICON$ variable expands to the IMG HTML element with the - appropriate URL in the SRC attribute to the icon. The ALT attribute of - the IMG element contains the content\-type of the message, surrounded - by []'s, for use with text based browsers. - - $ICONURL$ may also be used if you want redefine the format of the IMG - element. - - Example - - -* $SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
      -
      - - This example overrides what is normally used in the ALT attribute. - - _________________________________________________________________ - -Examples - - Example 1 - - It may be easier to see how the LISTBEGIN, LITEMPLATE, LISTEND - resource elements work when declared together: - - - - -
      -
        - - - -
      • $SUBJECT$ -
        • From: $FROM$
        -
      • -
        - - -
      - - - Example 2 - - Here's another example that changes the layout into a more compact - listing, adds Icons usage, and adds a time stamp information on when - the index page was last updated: - - -
      -Last update: $CURDATE$
      -$NUMOFMSG$ messages
      -
      -

      -

      -

      -Messages listed in chronological order. Listing format is the following: -

      -* -Subject -(# of follow\-ups) -From. -
      -

      -


      -
      - - -* $SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
      -
      - - - - - _________________________________________________________________ - - - _________________________________________________________________ - - Message Customization - - This sections shows how to customize the appearance of messages when - converted to HTML. - - _________________________________________________________________ - -Beginning Markup - - _MHonArc_ allows you to completely override the begining markup of the - message pages. I.e. You can control the opening tag, the HEAD - element contents, the opening tag, etc. Therefore, if you are - not satisfied with the default markup used, or have other needs that - require control on the beginning markup, you can set the MSGPGBEGIN - resource file element. - - MSGPGBEGIN - - The MSGPGBEGIN resource file element has the default value: - - - - - -$SUBJECTNA:72$ - - - - - - The following variables may be used in the MSGPGBEGIN element: - - * $DATE$ \-\- Message date. - * $DDMMYY$ \-\- Message date in dd/mm/yy format. - * $DOCURL$ \-\- URL to documentation. - * $FROM$ \-\- Contents of From field of message. - * $FROMADDR$ \-\- E\-mail address contained in From field of message. - * $FROMNAME$ \-\- "English" name contained in From field of message. - * $GMTDATE$ \-\- Current GMT date. - * $IDXFNAME$ \-\- Filename of main index page. - * $IDXSIZE$ \-\- Max number of messages that may be listed in the - index. - * $IDXTITLE$ \-\- The title of the index page. - * $LOCALDATE$ \-\- Current local date. - * $MMDDYY$ \-\- Message date in mm/dd/yy format. - * $MSGID$ \-\- Message ID of message. - * $MSGNUM$ \-\- Number assigned to message by _MHonArc_. - * $NUMOFIDXMSG$ \-\- Number of message listed. - * $NUMOFMSG$ \-\- Number of messages in the archive. - * $OUTDIR$ \-\- Pathname of archive. - * $PROG$ \-\- Program name. - * $SUBJECTNA$ \-\- Message subject text. - * $TIDXFNAME$ \-\- Filename of thread index page. - * $TIDXTITLE$ \-\- Title of thread index page. - * $VERSION$ \-\- Program version. - * $YYMMDD$ \-\- Message date in yy/mm/dd format. - - _________________________________________________________________ - -End Markup - - The ending markup of messages can be controlled by the MSGPGEND - resource file element. - - MSGPGEND - - The MSGPGEND resource element may be used to define the ending markup - of the message pages. The default value is the following: - - - - - - - The resource variables allowed are the same as for MSGPGBEGIN. - - _________________________________________________________________ - -Header and Footer - - The MSGHEAD resource represents HTML text that should be inserted at - the very beginning of each converted message. The MSGFOOT resource - represents HTML text that should be appended to the end of each - converted message. The default value for both resources is empty. The - following variables may be used in the MSGHEAD and MSGFOOT content: - - * $DATE$ \-\- Message date. - * $DDMMYY$ \-\- Message date in dd/mm/yy format. - * $DOCURL$ \-\- URL to documentation. - * $FROM$ \-\- Contents of From field of message. - * $FROMADDR$ \-\- E\-mail address contained in From field of message. - * $FROMNAME$ \-\- "English" name contained in From field of message. - * $GMTDATE$ \-\- Current GMT date. - * $IDXFNAME$ \-\- Filename of main index page. - * $IDXSIZE$ \-\- Max number of messages that may be listed in the - index. - * $IDXTITLE$ \-\- The title of the index page. - * $LOCALDATE$ \-\- Current local date. - * $MMDDYY$ \-\- Message date in mm/dd/yy format. - * $MSGID$ \-\- Message ID of message. - * $MSGNUM$ \-\- Number assigned to message by _MHonArc_. - * $OUTDIR$ \-\- Pathname of archive. - * $PROG$ \-\- Program name. - * $SUBJECTNA$ \-\- Message subject text. - * $TIDXFNAME$ \-\- Filename of thread index page. - * $TIDXTITLE$ \-\- Title of thread index page. - * $VERSION$ \-\- Program version. - * $YYMMDD$ \-\- Message date in yy/mm/dd format. - - _________________________________________________________________ - -Navigational Links - - _MHonArc_ gives you the ability to control the layout of the - navigational links for each message page. Navigational links include - links to previous and next messages, link to main index, link to - thread index, etc. The layout of the navigational links are controlled - by two resource file elements: TOPLINKS and BOTLINKS. - - TOPLINKS - - The TOPLINKS resource element defines the layout of the navigational - links at the top of each message page. The markup defined, will appear - after the MSGHEAD data and before the filtered message data. - - The default value for TOPLINKS is the following: - - -
      -$PREVBUTTON$$NEXTBUTTON$[Index][Thread] -
      - - If no thread index is specified, then the thread link markup is - removed. The following variables are available: - - * $DATE$ \-\- Message date. - * $DDMMYY$ \-\- Message date in dd/mm/yy format. - * $DOCURL$ \-\- URL to documentation. - * $FROM$ \-\- Contents of From field of message. - * $FROMADDR$ \-\- E\-mail address contained in From field of message. - * $FROMNAME$ \-\- "English" name contained in From field of message. - * $GMTDATE$ \-\- Current GMT date. - * $IDXFNAME$ \-\- Filename of main index page. - * $IDXSIZE$ \-\- Max number of messages that may be listed in the - index. - * $IDXTITLE$ \-\- The title of the index page. - * $LOCALDATE$ \-\- Current local date. - * $MMDDYY$ \-\- Message date in mm/dd/yy format. - * $MSGID$ \-\- Message ID of message. - * $MSGNUM$ \-\- Number assigned to message by _MHonArc_. - * $NEXTBUTTON$ \-\- Next button markup. See Conditional Links for more - information. - * $NEXTFROM$ \-\- Contenst of From field of the next message according - to the list order of the main index. - * $NEXTFROMADDR$ \-\- E\-mail address contained in From field of the - next message according to the list order of the main index. - * $NEXTFROMNAME$ \-\- English" name contained in From field of the - next message according to the list order of the main index. - * $NEXTLINK$ \-\- Next link markup. See Conditional Links for more - information. - * $NEXTMSG$ \-\- Filename of next message according to the list order - of the main index. - * $NEXTMSGNUM$ \-\- Number assigned to next message according to the - list order of the main index. - * $NEXTSUBJECT$ \-\- Subject of next message according to the list - order of the main index. - * $NUMOFIDXMSG$ \-\- Number of message listed. - * $NUMOFMSG$ \-\- Number of messages in the archive. - * $PREVBUTTON$ \-\- Previous button markup. See Conditional Links for - more information. - * $PREVFROM$ \-\- Contenst of From field of the previous message - according to the list order of the main index. - * $PREVFROMADDR$ \-\- E\-mail address contained in From field of the - previous message according to the list order of the main index. - * $PREVFROMNAME$ \-\- English" name contained in From field of the - previous message according to the list order of the main index. - * $PREVLINK$ \-\- Previous link markup. See Conditional Links for more - information. - * $PREVMSG$ \-\- Filename of previous message according to the list - order of the main index. - * $PREVMSGNUM$ \-\- Number assigned to previous message according to - the list order of the main index. - * $PREVSUBJECT$ \-\- Subject of previous message according to the list - order of the main index. - * $PROG$ \-\- Program name. - * $SUBJECTNA$ \-\- Message subject text. - * $TIDXFNAME$ \-\- Filename of thread index page. - * $TIDXTITLE$ \-\- Title of thread index page. - * $VERSION$ \-\- Program version. - * $YYMMDD$ \-\- Message date in yy/mm/dd format. - - BOTLINKS - - The BOTLINKS resource element defines the layout of the navigational - links at the bottom of each message page. The markup defined, will - appear after the filtered message data and any thread links, and - before the MSGFOOT data. - - The default value for BOTLINKS is the following: - - -
      -
        -$PREVLINK$ -$NEXTLINK$ -
      • Index(es): -
          -
        • Main
        • -
        • Thread
        • - - - If no thread index is specified, then the thread link markup is - removed. The variables available for BOTLINKS are the same as for - TOPLINKS. - - Conditional Links - - Since the state of some navigational links can change due the position - of the message in the archive (eg. first and last messages), special - resources exist that allows you to control the markup of some of the - links based upon if the link is valid or not for a given message. - - The resource elements for defining the conditional links are the - following: PREVBUTTON, NEXTBUTTON, PREVLINK, and NEXTLINK, and their - inactive counterparts, PREVBUTTONIA, NEXTBUTTONIA, PREVLINKIA, and - NEXTLINKIA. The appropriate value of these elements (ie. if it is - active, or inactive) are represented by the $PREVBUTTON$, - $NEXTBUTTON$, $PREVLINK$, and $NEXTLINK$ resource file variables, - respectively, which may be used in other resource elements' contents - (TOPLINKS and BOTLINKS in particular). - - The defaults values for each conditional link resource is as follows: - - PREVBUTTON - - -[Prev] - - - NEXTBUTTON - - -[Next] - - - PREVLINK - - -
        • Prev: $PREVSUBJECT$
        • -
          - - NEXTLINK - - -
        • Next: $NEXTSUBJECT$
        • -
          - - All the "IA" elements default to empty content. - - _NOTE_ - The last newline for the PREVBUTTON, NEXTBUTTON, PREVBUTTONIA, - and NEXTBUTTONIA elements is ignored by _MHonArc_. This allows - a "tight" grouping of button links; ie. no space between - buttons. If you desire to have a newline in the content, just - insert a trailing blank line at the end of the element's - content. - - You should note that there is a correlation between the value of the - conditional links elements and the contents of the TOPLINKS and - BOTLINKS elements. - - The following variables may be used within the conditional link - elements. - - * $NEXTFROM$ \-\- Contenst of From field of the next message according - to the list order of the main index. - * $NEXTFROMADDR$ \-\- E\-mail address contained in From field of the - next message according to the list order of the main index. - * $NEXTFROMNAME$ \-\- English" name contained in From field of the - next message according to the list order of the main index. - * $NEXTMSG$ \-\- Filename of next message according to the list order - of the main index. - * $NEXTMSGNUM$ \-\- Number assigned to next message according to the - list order of the main index. - * $NEXTSUBJECT$ \-\- Subject of next message according to the list - order of the main index. - * $PREVFROM$ \-\- Contenst of From field of the previous message - according to the list order of the main index. - * $PREVFROMADDR$ \-\- E\-mail address contained in From field of the - previous message according to the list order of the main index. - * $PREVFROMNAME$ \-\- English" name contained in From field of the - previous message according to the list order of the main index. - * $PREVMSG$ \-\- Filename of previous message according to the list - order of the main index. - * $PREVMSGNUM$ \-\- Number assigned to previous message according to - the list order of the main index. - * $PREVSUBJECT$ \-\- Subject of previous message according to the list - order of the main index. - - _WARNING_ - Never include conditional link variables ($PREVBUTTON$, - $NEXTBUTTON$, $PREVLINK$, and $NEXTLINK$) in conditional link - element content. This will cause an infinite loop during - execution and will eventually lead to a crash due to a lack of - memory. - - _________________________________________________________________ - -Message Layout - - Defining the format for the actual mail message data is divided into - two parts: the message head and the message body. Customizing the - message header markup is described in this section, but due to the - nature of how messages are processed, the message body format is - controlled by the various MIME filters directly (see the section on - MIME for further details). - - Excluding Fields - - The EXCS resource allows you to specify what fields should be excluded - in the HTML output. - - EXCS - - Each line of the EXCS element specifies a mail header field to exclude - in the converted HTML output. Each line is treated as a Perl regular - expression (_NOTE_: _the regular expression is already anchored to the - begining of the line_). - - The default value for EXCS is the following: - - -content\- -errors\-to -forward -lines -message\-id -mime\- -nntp\- -originator -path -precedence -received -replied -return\-path -status -via -x\- - - - Any fields you specify for the EXCS resource will augment the default - list, unless the "Override" attribute is specified. If "Override" is - specified, the default list is discarded along with any other lists - specified from previous EXCS elements; and only header fields - specified in the EXCS element are excluded. - - Field Order - - The FIELDORDER resource allows you to control the order the message - header fields appear in the HTML output. - - FIELDORDER - - Each line of the FIELDORDER element is the exact case\-insensitive name - of a message header field. The order the fields are listed is the - order they will appear in the filtered message. The special field - value "\-extra\-" represents all fields not explicitly specified in the - FIELDORDER element and not excluded by the EXCS element. Extra fields - are listed in sorted order. - - The following represents the default value of the FIELDORDER resource: - - -to -subject -from -date -\-extra\- - - - Field Formatting - - The FIELDSTYLES and LABELSTYLES resources allow to control how each - message header field is formatted. - - FIELDSTYLES - - Each line in the FIELDSTYLES element defines HTML elements to wrap - around the field text in mail headers (e.g. "To: field text", "From: - field text"). The format of each line is "field_name:html_element". - This specifies to wrap html_element around the text associated with - field_name. If html_element is empty, then the field text is not - wrapped in any element. - - _MHonArc_ defines a special field_name called "\-default\-". This is - default HTML element to wrap field text in if no explicit specific - element is defined for the label. - - field_name must be the exact name of a header field name, but - character case is ignored. - - The default value of FIELDSTYLES is the following: - - -\-default\- - - - LABELSTYLES - - Each line in the LABELSTYLES element defines HTML elements to wrap - around labels in mail headers (e.g. "To:", "From:"). The format of - each line is "field_name:html_element". This specifies to wrap - html_element around field_name. If html_element is empty, then the - label is not wrapped in any element. - - _MHonArc_ defines a special field_name called "\-default\-". This is - default HTML element to wrap a label in if no explicit specific - element is defined for the label. - - field_name must be the exact name of a header field name, but - character case is ignored. - - The default value of LABELSTYLES is the following: - - -\-default\-:em - - - _________________________________________________________________ - -Other Resources - - E\-mail Links - - MAILTOURL - - URL to use for e\-mail address hyperlinks in e\-mail message header - fields. The following variables are defined for the MAILTOURL - resource: - - * $FROM$ \-\- Who the message is from. - * $MSGID$ \-\- Message ID of the message. - * $SUBJECT$ \-\- The subject of the message. - * $TO$ \-\- Destination e\-mail address of link. - - _MHonArc_ will use the following URL by default: "mailto:$TO$". - - _NOTE_ - The MAILTOURL resource has different rules for variable - expansion. If a variable does not exactly match the set of - variables available for the MAILTOURL, the variable text will - be taken literally as part of the element content. Therefore, a - single "$" can be used to represent a "$" character. - - Also, variables in the MAILTOURL should _NOT_ have ":NU" - modifier. This will prevent the variables from be recognized. - _MHonArc_ will automatically treat the replacement value as a - part of a URL string. - - _________________________________________________________________ - - - _________________________________________________________________ - - MIME - - _MHonArc_ has support for e\-mail messages with _Multipurpose Internet - Mail Extensions_ (MIME) as defined in RFC 1521. _MHonArc_ handles the - filtering of the various content\-types used in MIME in a modular - fashion. Since new content\-types are occasionally defined for MIME, - this modularity allows users to add new filters to accomodate new - content\-types. Also, filters can be hooked in to override _MHonArc's_ - default filters, or provide _MHonArc_ with the ability to process - existing content\-types that it cannot handle currently. - - _________________________________________________________________ - -Default Filters - - The default filters provided by _MHonArc_ supports the following MIME - content\-types, which may be overriden by user\-defined filters: - - * application/* - * audio/* - * image/* - * message/news - * message/partial - * message/rfc822 - * multipart/alternative - * multipart/digest - * multipart/mixed - * multipart/parallel - * text/html - * text/plain - * text/setext - * video/* - - For more information on how to write your filters, or replace existing - filters, see Writing Filters. - - The next sections describes how _MHonArc_ processes the content\-types - listed above. - - application/* - - _MHonArc_ extracts the data into a separate file and puts a hyperlink - to the file into the HTMLized message. - - By default, _MHonArc_ ignores any filename specification (the "_name_" - attribute as defined in the Content\-Type header field) given in the - message when writing the data to disk. _MHonArc_ generates a unique - filename with an extenstion based upon sub\-type. - - If you want _MHonArc_ to use the filename, then you can use the - MIMEARGS resource and specify an argument string of "usename". - - Example: - - -application/postscript:usename - - - If you want _MHonArc_ to use specified filename for all application - types, then use the following: - - -application/*:usename - - - _CAUTION_ - The use of "usename" is discouraged since it can lead to - filename conflicts and security problems. - - Here is the current list of _application_ sub\-types (with their - filename extensions) supported by _MHonArc_: - - * mac\-binhex40 (hqx) - * octet\-stream (bin) - * oda (oda) - * pdf (pdf) - * postscript (ps) - * rtf (rtf) - * x\-bcpio (bcpio) - * x\-cpio (cpio) - * x\-csh (csh) - * x\-dvi (dvi) - * x\-gtar (gtar) - * x\-hdf (hdf) - * x\-latex (latex) - * x\-mif (mif) - * x\-netcdf (cdf) - * x\-patch (_no extension_; processed by the text/plain filter) - * x\-sh (sh) - * x\-shar (shar) - * x\-sv4cpio (sv4cpio) - * x\-sv4crc (sv4crc) - * x\-tar (tar) - * x\-tcl (tcl) - * x\-tex (tex) - * x\-texinfo (texinfo) - * x\-troff (roff) - * x\-troff\-man (man) - * x\-troff\-me (me) - * x\-troff\-ms (ms) - * x\-ustar (ustar) - * x\-wais\-source (src) - * zip (zip) - - audio/* - - _MHonArc_ extracts the data into a separate file and puts a hyperlink - to the file into the HTMLized message. The name of the file created - follows the same guidelines mentioned under application/*. - - Here is the current list of _audio_ sub\-types (with their filename - extensions) supported by _MHonArc_: - - * basic (snd) - * x\-aiff (aif) - * x\-wav (wav) - - image/* - - _MHonArc_ will extract the data into a separate file and puts a - hyperlink to the file into the HTMLized message. The name of the file - created follows the same guidelines mentioned under application/*. In - addition to the filename specification mentioned under application/*, - an "inline" argument may be declared to instruct _MHonArc_ to inline - the image in the generated HTML. - - Example: - - -image/gif:inline - - - The following examples says to inline XBM images and use the name - attribute as the filename if defined: - - -image/x\-xbm:inline usename - - - The following represents the default argument settings used by - _MHonArc_: - - -image/gif:inline -image/x\-xbitmap:inline -image/x\-xbm:inline - - - Here is the current list of _image_ sub\-types (with their filename - extensions) supported by _MHonArc_: - - * gif (gif) - * ief (ief) - * jpeg (jpg) - * tiff (tif) - * x\-bmp (bmp) - * x\-cmu\-raster (ras) - * x\-pcx (pcx) - * x\-pict (pict) - * x\-portable\-anymap (pnm) - * x\-pnm (pnm) - * x\-portable\-bitmap (pbm) - * x\-pbm (pbm) - * x\-portable\-graymap (pgm) - * x\-pgm (pgm) - * x\-portable\-pixmap (ppm) - * x\-ppm (ppm) - * x\-rgb (rgb) - * x\-xbitmap (xbm) - * x\-xbm (xbm) - * x\-xpixmap (xpm) - * x\-xpm (xpm) - * x\-xwindowdump (xwd) - * x\-xwd (xwd) - - If the image is a GIF or XBM (X bitmap), the HTML IMG element will be - used to in\-line the image into the HTMLized message. - - message/news - - _message/news_ signifies an included (MIME) USENET news message. The - data associated with a _message/news_ part is processed by _MHonArc_ - in the same manner as a regular mail message. - - message/partial - - _message/partial_ signifies that the content is a single part of a - message split into multiple mail messages. _message/partial_ is - treated in the same manner as text/plain. - - message/rfc822 - - _message/rfc822_ signifies an included (MIME) mail message. The data - associated with a _message/rfc822_ part is processed by _MHonArc_ in - the same manner as a regular mail message. - - multipart/alternative - - _multipart/alternative_ signifies multiple content\-types with the same - (or similiar) information. _MHonArc_ processes only the latest part - that has a content\-type filter. - - multipart/digest - - mulltipart/digest signifies a series of included mail messages. Each - part is processed in the same manner as message/rfc822 unless an - explicit content\-type is specifed for each part. - - multipart/mixed - - _multipart/mixed_ signifies data with multiple content\-types. _MHonArc_ - extracts each part and calls the appropriate content\-type filter for - each part, if defined. - - multipart/parallel - - _multipart/parallel_ is processed in the same manner as - multipart/mixed. - - text/html - - _text/html_ signifies that the data is HTML markup. The data as left - "as is" with the exception of some processing to legally include the - HTML into the HTMLized mail message. I.e. _MHonArc_ removes the HEAD - an BODY tags, the TITLE element will be replaced with an ADDRESS - element surrounded by HR's, and the BASE element URL will be - propogated to relative URLs. - - text/plain - - _text/plain_ signifies ASCII character data. In the HTMLized message, - the data is wrapped in a PRE element with special characters (< > &) - converted to entity references. _MHonArc_ will also make any URLs into - hyperlinks. The following URL types are recognized: - - * http://... - * ftp://... - * afs://... - * wais://... - * telnet://... - * gopher://... - * news:... - * nntp:... - * mid:... - * cid:... - * mailto:... - * prospero:... - - text/setext - - _text/setext_ signifies "_structure enhanced text_". The data is - converted into HTML containing hyperlinks as defined by the _setext_ - data. For more information on _setext_, see - . - - video/* - - _MHonArc_ extracts the data into a separate file and puts a hyperlink - to the file into the HTMLized message. The name of the file created - follows the same guidelines mentioned under application/*. - - Here is the current list of _video_ sub\-types (with their filename - extensions) supported by _MHonArc_: - - * mpeg (mpg) - * quicktime (mov) - * x\-msvideo (avi) - * x\-sgi\-movie (movie) - - _________________________________________________________________ - -Non\-MIME Messages - - Messages that do not contain a MIME Content\-Type header field are - processed as text/plain messages. - - _________________________________________________________________ - -Writing Filters - - If you want to write your own filter for use in _MHonArc_, you need to - know the Perl programming language. The following information assumes - you know Perl. To learn how to hook in your filters into _MHonArc_, - see Specifying Filters. - - Function Interface of Filter - - _MHonArc_ interfaces with MIME filters by calling a routine with a - specific set of arguments. The prototype of the interface routine is - as follows: - -sub filter { - local($head, *fields, $data, $decoded, $argstring) = @_; - - # Filter code here - - # The last statement should be the return value, unless an - # explicit return is done. See the following for the format of the - # return value. -} - - Argument Descriptions - - $head - This is the header text of the message (or body part if called - in a mulitpart message). - - *fields - This is a pointer to an associative array that has broken down - $head into field label/field value components. The keys are the - lower\-case representations of the field values. _Example_: If - you would like to retrieve the value of the Content\-Type field, - then use the following: $fields{`content\-type'}. - - If a field occurs more than once in a header, _MHonArc_ - separates the field values in the associative array by a `\\034' - character. To make your filter less likely to break due to - changes in _MHonArc_, you may use the $'X variable instead of - `\\034'. - - $data - This is a copy of the message (or body part if called in a - mulitpart message) body. - - $decoded - This flag is set to 1 if _MHonArc_ decoded the message and - $data represents the orginal data before encoded by the sender. - If set to 0, $data has not been decoded. The failure to decode - occurs if _MHonArc_ does not recognizeed the encoding specified - in the Content\-Transfer\-Encoding field. - - _MHonArc_ has decoded the data for you if it was encoded in - 7\-Bit, 8\-Bit, Binary, Quoted\-Printable, Base64, or X\-Uuencode. - - $argstring - This is an optional argument string that may be used to modify - the behavior of the filter. The format of this string is - determined by the filter itself. - - The value of the string is set by the MIMEARGS resource. - - Return Value - - The return value is treated as an array. The first item in the array - is a string representing the HTML markup to insert in the HTMLized - message. An empty string may be returned to tell _MHonArc_ that the - routine was unable to filter data. - - Any other array items are treated as names of any files that were - generated by the filter. _MHonArc_ needs to keep track if any extra - files that a filter may generate in order for _MHonArc_ to delete - those files if the message gets removed from the archive. - - Filter Writing Tips - - The following recommendations/tips are given to help you write - filters: - - * Qualify your filter in its own package. This eliminates possible - variable/routine conflicts with _MHonArc_. - * If the filter creates derived files (like the image filters), you - may use the variable $'OUTDIR to determine the location of the - mail archive. - _NOTE_: _Do not include_ $'OUTDIR _as part as the filename that is - returned to_ _MHonArc_. _If the filter does create files, just - return the base name_. - * Look at the default filters contained in the distribution of - _MHonArc_. You can use these as templates for writing your own. - * Make sure your Perl source file ends with a true statement (like - "1;"). _MHonArc_ just performs a require on the file, and if the - file does not return true, Perl will abort execution. - - Using C - - If a MIME filter requires the utilization of a C program, or other - non\-Perl executable, a Perl wrapper must be written for the program - in\-order to interface with _MHonArc_. The wrapper must follow the - rules as specified in Function Interface of Filter. - - _________________________________________________________________ - -Specifying Filters - - Adding new filters, or overriding existing ones, are done via the - Resource File. The two resources for specifying and controlling MIME - filters are MIMEFILTERS and MIMEARGS. - - MIMEFILTERS - - The resource element MIMEFILTERS in the Resource File is used to hook - in user specifed filters into _MHonArc_. The syntax for each line of - the the MIMEFILTERS element is as follows: - - __:__:__ - - The definition of each colon\-separated value is as follows: - - __ - The MIME content\-type the filter processes. - - __ - The actual routine name of the filter. The name should be fully - qualified by the package it is definedi (e.g. - "mypackage'filter"). - - __ - The name of the file that defines __. If the file - is not a full pathname, _MHonArc_ finds the file by looking in - the standard include paths of Perl, and the paths specified by - the PERLINC resource element. - - Any whitespace is stripped out before processing. - - Example - - The following represents the default value of MIMEFILTERS: - - -application/mac\-binhex40:m2h_external'filter:mhexternal.pl -application/octet\-stream:m2h_external'filter:mhexternal.pl -application/oda:m2h_external'filter:mhexternal.pl -application/pdf:m2h_external'filter:mhexternal.pl -application/postscript:m2h_external'filter:mhexternal.pl -application/rtf:m2h_external'filter:mhexternal.pl -application/x\-bcpio:m2h_external'filter:mhexternal.pl -application/x\-cpio:m2h_external'filter:mhexternal.pl -application/x\-csh:m2h_external'filter:mhexternal.pl -application/x\-dvi:m2h_external'filter:mhexternal.pl -application/x\-gtar:m2h_external'filter:mhexternal.pl -application/x\-hdf:m2h_external'filter:mhexternal.pl -application/x\-latex:m2h_external'filter:mhexternal.pl -application/x\-mif:m2h_external'filter:mhexternal.pl -application/x\-netcdf:m2h_external'filter:mhexternal.pl -application/x\-patch:m2h_text_plain'filter:mhtxtplain.pl -application/x\-sh:m2h_external'filter:mhexternal.pl -application/x\-shar:m2h_external'filter:mhexternal.pl -application/x\-sv4cpio:m2h_external'filter:mhexternal.pl -application/x\-sv4crc:m2h_external'filter:mhexternal.pl -application/x\-tar:m2h_external'filter:mhexternal.pl -application/x\-tcl:m2h_external'filter:mhexternal.pl -application/x\-tex:m2h_external'filter:mhexternal.pl -application/x\-texinfo:m2h_external'filter:mhexternal.pl -application/x\-troff\-man:m2h_external'filter:mhexternal.pl -application/x\-troff\-me:m2h_external'filter:mhexternal.pl -application/x\-troff\-ms:m2h_external'filter:mhexternal.pl -application/x\-troff:m2h_external'filter:mhexternal.pl -application/x\-ustar:m2h_external'filter:mhexternal.pl -application/x\-wais\-source:m2h_external'filter:mhexternal.pl -application/zip:m2h_external'filter:mhexternal.pl -audio/basic:m2h_external'filter:mhexternal.pl -audio/x\-aiff:m2h_external'filter:mhexternal.pl -audio/x\-wav:m2h_external'filter:mhexternal.pl -image/gif:m2h_external'filter:mhexternal.pl -image/ief:m2h_external'filter:mhexternal.pl -image/jpeg:m2h_external'filter:mhexternal.pl -image/tiff:m2h_external'filter:mhexternal.pl -image/x\-bmp:m2h_external'filter:mhexternal.pl -image/x\-cmu\-raster:m2h_external'filter:mhexternal.pl -image/x\-pbm:m2h_external'filter:mhexternal.pl -image/x\-pcx:m2h_external'filter:mhexternal.pl -image/x\-pgm:m2h_external'filter:mhexternal.pl -image/x\-pict:m2h_external'filter:mhexternal.pl -image/x\-pnm:m2h_external'filter:mhexternal.pl -image/x\-portable\-anymap:m2h_external'filter:mhexternal.pl -image/x\-portable\-bitmap:m2h_external'filter:mhexternal.pl -image/x\-portable\-graymap:m2h_external'filter:mhexternal.pl -image/x\-portable\-pixmap:m2h_external'filter:mhexternal.pl -image/x\-ppm:m2h_external'filter:mhexternal.pl -image/x\-rgb:m2h_external'filter:mhexternal.pl -image/x\-xbitmap:m2h_external'filter:mhexternal.pl -image/x\-xbm:m2h_external'filter:mhexternal.pl -image/x\-xpixmap:m2h_external'filter:mhexternal.pl -image/x\-xpm:m2h_external'filter:mhexternal.pl -image/x\-xwd:m2h_external'filter:mhexternal.pl -image/x\-xwindowdump:m2h_external'filter:mhexternal.pl -message/partial:m2h_text_plain'filter:mhtxtplain.pl -text/html:m2h_text_html'filter:mhtxthtml.pl -text/plain:m2h_text_plain'filter:mhtxtplain.pl -text/richtext:m2h_text_plain'filter:mhtxtplain.pl -text/setext:m2h_text_setext'filter:mhtxtsetext.pl -text/tab\-separated\-values:m2h_text_plain'filter:mhtxtplain.pl -text/x\-html:m2h_text_html'filter:mhtxthtml.pl -text/x\-setext:m2h_text_setext'filter:mhtxtsetext.pl -video/mpeg:m2h_external'filter:mhexternal.pl -video/quicktime:m2h_external'filter:mhexternal.pl -video/x\-msvideo:m2h_external'filter:mhexternal.pl -video/x\-sgi\-movie:m2h_external'filter:mhexternal.pl - - - MIMEARGS - - The MIMEARGS resource may be used to pass optional arguments to - filters to control their behavior. Arguments may be defined on a per - content\-type basis, or for a specific filter itself. The syntax for - each line of the the MIMEARGS element is as follows: - - __:__ - - Or, - - __:__ - - The format of argument strings is dependent on the filter that - processes __ or by the specified filter, - __. - - If an argument string is defined for a filter explicitly and for a - content\-type that the filter processes, the content\-type string will - override the filter string. - - Examples - - The following example represents the default settings used by - _MHonArc_: - - -image/gif:inline -image/x\-xbitmap:inline -image/x\-xbm:inline - - - The following example tells the filter that deals handles - content\-types that cannot be converted directly into HTML to use the - "_name_" attribute as defined in the Content\-Type header field as the - name of the file generated: - - -m2h_external'filter:usename - - - The following examples says to inline XBM images and use the name - attribute as the filename if defined: - - -image/x\-xbm:inline usename - - - _________________________________________________________________ - - - _________________________________________________________________ - - Gory Details - - This sections explain in detail how _MHonArc_ functions. Knowing the - material covered in this section may help you when trouble shooting. - - _________________________________________________________________ - -OS Detection - - _MHonArc_ will automatically detect which operating system it is - running under. If the following list of conditions are true, _MHonArc_ - assumes it is running under MS\-DOS: - - * The COMSPEC environment variable is defined. - * The value of the COMSPEC environment variable is a legal MS\-DOS - pathname. - * The value of the COMSPEC environment variable is an executable - file. - - If any of the above conditions is false, _MHonArc_ assumes it is - running under Unix. - - _NOTE_ - The previous conditions are used since the conditions will - exist if Perl has been installed on an MS\-DOS machine. None of - the above conditions exist when Perl is installed on a Unix - system. - - _________________________________________________________________ - -Processing Steps - - This section describes the steps _MHonArc_ performs when - creating/editting an archive. Anytime messages are added or deleted or - the index page layout is changed, _MHonArc_ will perform the following - steps. - - * Creates a lock file. This insures only one _MHonArc_ process is - updating the archive at any given moment. See Archive Integrity - for more information. - * Reads the database file. The name, and location, of the database - file can be explicitly specified via the M2H_DBFILE and M2H_OUTDIR - environment variables or the command\-line options \-dbfile and - \-outdir. Otherwise, the current working directory is used. - _NOTE_: _The database file must be in the same location as the - archive since the _M2H_OUTDIR_ variable and _\-outdir_ option also - specify the location of the archive_. - The database file contains data to update any mail threads and the - resource settings when _MHonArc_ was last invoked. This allows new - messages to contain the same formatting/resource specifications as - existing messages in the archive without having to re\-specify the - resources each time new messages are added. Resources defined in - the database file override the environment variables. - _NOTE_: _If no database file is found, MHonArc will create a new - archive_. - * Read the _MHonArc_ resource file, _if specified_. The resource - file will override any settings contained in the database file. - * Read the settings specified on the command\-line. Command\-line - options override any settings in the database and/or resource - file. - * Update archive. - * Rewrites the index pages to reflect the update. - * Writes a new database file containing the new state of the archive - and all (new) resource settings. - - Normally, knowing all the previous steps is unnecessary. However, it - may be useful to be aware of them if unexpected behavior, or errors, - occur. - - _________________________________________________________________ - -Archive Integrity - - _MHonArc_ applies safeguards to try to insure that a mail archive does - not get corrupted due to exceptional circumstances. _MHonArc_ does the - following to insure a mail archive does not get corrupted: - - * _MHonArc_ creates a lock file, ".mhonarc.lck", when - creating/updating an archive. The lock file insures that only one - _MHonArc_ process is modifying an archive at any given moment. The - \-locktries command\-line option, or the M2H_LOCKTRIES environment - variable, allows you to control how long a given _MHonArc_ process - will wait if an archive is currently locked. If _MHonArc_ can not - lock the archive after the specified number of tries, _MHonArc_ - will exit, unless the \-force option is specified. - * _MHonArc_ will ignore the following signals once messages are - actually being written to disk: SIGABRT, SIGHUP, SIGINT, SIGQUIT, - SIGPIPE, SIGTERM. Possible archive corruption can still occur if a - SIGKILL signal is received since SIGKILLs are uncatchable. A - SIGKILL will also prevent _MHonArc_ from deleting the lock file. - - _________________________________________________________________ - -File Formats - - Database File - - The _MHonArc_ database file is actual Perl code. _MHonArc_ requires it - like any other Perl library to load in the contents of the database. - - _CAUTION_ - You should never modify the database file by hand. Changing the - file by hand could cause future incorrect/unpredictable - behavior when processing the archive. - - Index and Message Files - - The indexes and message files are legal HTML documents. However, - manual editting of the documents is discouraged. The documents contain - special comment declarations. The comment declarations act as markers - which allow _MHonArc_ to correctly edit the documents when needed. - - The comment declarations look like the following: - - - - - -... - - Derived Files - - Derived files are files that are generated by the MIME filters. These - files are created when the data being processed in messages cannot be - converted to HTML (eg. images, postscript, video, binaries). The - format of these files depend on the content\-type of the data. - - _________________________________________________________________ - -Notes - - * Here is the explicit order of decreasing precedence when setting - resources/options: - + command\-line options (_highest precedence_) - + resource file - + database file - + environment variables (_lowest precedence_) - * Mail thread detection is dependent upon the mail messages - containing the message id(s) of referenced messages. Most mailers - _reply function_ will automatically include the message id of the - message being replied to. - * All mail message being converted into HTML are stored in memory - before they are written to disk. This can eat up much memory if - many mail messages are being converted. If you are processing - multiple mailboxes/folders and worried about memory, you can try - the following: - + Invoke _MHonArc_ on each one separately using the \-add - option. - + Or, invoke _MHonArc_ with the \-savemem option. - * The database file, and the index pages, are completely rewritten - evertime new messages are added. This may cause slight slow\-downs - when archives become very large. - * When reading _MH_ mail folders, mail message are assumed to have - numeric filenames. - * When sorting by date, _MHonArc_ tries to use the date listed in - the first _Received_ field of the message. If no _Received_ field - exists, than the _Date_ field is used. - * No distinction is made, in the output, on which messages came from - which mail folder if multiple mail folders are processed. - * _MHonArc_ can probably be modified to handle other types of - mailers (which has been done since the original version only - supported _MH_ mail folders). The MSGSEP resource gives - flexibility in processing Unix style mailbox files. - - _________________________________________________________________ - - - _________________________________________________________________ - - Diagnostics - - Three types of messages exist in _MHonArc_: _Informative_ messages, - _Warnings_, and _Errors_. _Informative_ messages give you the current - status of _MHonArc_'s execution. _Warnings_ signify undesired - conditions, but are _not_ critical in _MHonArc_'s exection. _Errors_ - signify critical conditions that inhibit _MHonArc_ from finishing its - task. - - Another set of messages exists that are generated from the Perl - interpreter itself. _MHonArc_ tries its best to catch any conditions - that may cause Perl to abnormally abort, but conditions may arise - where this is not possible. - - This section describes the various diagnostics _MHonArc_ may produce - and messages Perl may produce. - - _________________________________________________________________ - -Informative messages - - Informative messages may be suppressed via the \-quiet command\-line - option. Only the more important Informative messages are listed here. - - Could not process message with given Content\-Type: ... - - _MHonArc_ will output this statement _in_ filtered mail messages for - content\-types it is unable to process. See Default Filters in MIME for - content\-types that _MHonArc_ supports by default. See Writing Filters - for adding new filters into _MHonArc_. - - This is the only Informative message that does not go to standard - output, but into the actual filtered mail message. - - No new messages - - No mail messages exist when performing an add operation to an archive. - This can occur if an empty _MH_ mail folder, or empty mailbox file, is - passed to _MHonArc_. - - Requiring MIME filter libraries ... - - Indicates _MHonArc_ is loading external libraries for filtering mail - messages. _MHonArc_ will output each library it loads. See MIME for - more information of filter libraries. - - Trying to lock mail archive ... - - The statement means that a lock file is in place for the archive you - are trying to update. Normally, an existing lock file implies that - another _MHonArc_ process is currently using the archive, and other - _MHonArc_ processes will wait awhile to see if the archive will be - unlocked. - - However, there are times when a lock file exists, but no _MHonArc_ - process is modifying the archive. This can occur if _MHonArc_ is - abnormally terminated. If you know that no other _MHonArc_ process is - editting the archive you are try to modify, then manually remove the - lock file or use the \-force option. - - See Archive Integrity for more information. - - _________________________________________________________________ - -Warnings - - Warning messages denote some undesired event occurred, but the event - is not severe enough to cause program termination. - - Warning: Could not find date for message - - _MHonArc_ was unable to find a received/sent date for a mail message. - With respect to other mail messages, a message with no received/sent - date is first in chronological order. - - Warning: Database () != program () version - - Indicates that the version of _MHonArc_ updating an archive is - different from the version of _MHonArc_ that created the database - file. Problems can arise if the database file changes in format from - different version of _MHonArc_. See the release notes of the _MHonArc_ - distribution if changes in the databse format has effects on older - archives. - - Warning: Unable to create / - - Indicates _MHonArc_ was unable to create the database file __ - for the mail archive created/modified in __. This message can - occur if __ permissions changed during _MHonArc_ execution, - the existing __ is read\-only, or the file system is full. - - This message can be severe because no future add operations can be - performed to the archive. - - Warning: Unable to open footer:
          - - _MHonArc_ was unable to open the footer file, _
          _, for - inclusion into the index page. Make sure _
          _ exists, and is - readable by you. - - Warning: Unable to open header:
          - - _MHonArc_ was unable to open the header file, _
          _, for - inclusion into the index page. Make sure _
          _ exists, and is - readable by you. - - Warning: Unable to open - - _MHonArc_ was unable to open the specified mail __ for - reading. Make sure __ exists and is readable (and executable - if a directory) by you. - - Warning: Unable to open message: / - - _MHonArc_ was unable to open the specified _MH_ mail message - _/_ for reading. Make sure _/_ - exists and is readable by you. - - Warning: Unable to open resource file: - - _MHonArc_ was unable to open the resource file, __, for reading. - Make sure __ exists, and is readable by you. - - Warning: Undefined time zone: "" - - _MHonArc_ has found an unrecognized timezone acronym, __, in - a mail message. You can tell _MHonArc_ about other timezone acronyms, - and their hour offset to UTC, by using the TIMEZONES resource element - of the Resource File. - - The timezone UTC (or GMT) is used for an undefined timezone acronym - - _________________________________________________________________ - -Errors - - Errors denote conditions that cause _MHonArc_ to abort execution. - - Some error conditions may cause the _MHonArc_ archive to become - corrupted. If the error occurs when _MHonArc_ is writing files, you - may have to recreate the archive from the original messages. - - ERROR: Database read error of - - An error occured when trying to read an archive's database. The error - can occur if the database file is not readable or the file got - corrupted. - - ERROR: Unable to create - - _MHonArc_ was unable to create __. This message can occur if the - directory being written to is not writable, a read\-only file with the - same name exists, or the file system is full. - - ERROR: Unable to create after <#> tries - - The statement means that a lock file is in place for the archive you - are trying to update. - - Sometimes a lock file exists, but no _MHonArc_ process is modifying - the archive. This can occur if _MHonArc_ is abnormally terminated. If - you know that no other _MHonArc_ process is editting the archive you - are try to modify, then manually remove the lock file or use the - \-force option. - - ERROR: Unable to open - - _MHonArc_ was unable to open __ for reading. Make sure __ - exists, and is readable by you. - - ERROR: Unable to require newgetopt.pl - - The newgetopt.pl library is needed for _MHonArc_ to parse the - command\-line. newgetopt.pl is part of the standard Perl distribution. - Make sure Perl has been correctly installed at your site. - - ERROR: Unable to require timelocal.pl - - The timelocal.pl library is needed for _MHonArc_ to process dates in - messages. timelocal.pl is part of the standard Perl distribution. Make - sure Perl has been correctly installed at your site. - - ERROR: Unable to require - - This message signifies _MHonArc_ was unable to require the library - __. Make sure you properly installed _MHonArc_ via the - installation program. If __ is your own custom filter, make sure - you properly registered it in the Resource File. See also Specifying - Filters and the PERLINC resource element. - - _________________________________________________________________ - -Perl Messages - - Generally, if execution is aborted and the following error messages - appear, then you will have to manually delete the lock file since - _MHonArc_ will not have the chance to delete the file. - - Can't locate in @INC at line . - - A library that _MHonArc_ tried to load was not found in the Perl - include search paths. This error usually implies that _MHonArc_ was - not installed correctly. Make sure that _MHonArc_ was installed via - the install.me program that is provided in the _MHonArc_ distribution. - - did not return a true value at line . - - If you are using your own MIME filters with _MHonArc_, make sure the - library files return 1. - - _________________________________________________________________ - - - _________________________________________________________________ - - Glossary - - _HTML_ - Hypertext Markup Language. HTML is the main document markup - language for the World Wide Web. - - _MIME_ - Multipurpose Internet Mail Extensions. MIME allows the - transmission of non\-ASCII data, and mixed content data, in - electronic mail messages. - - _MH_ - _Message Handler_. MH is a free message handling system - initially developed by the RAND Corporation, with subsequent - development done at the University of Califonia: Irvine. - - _Perl_ - Practical Extraction and Report Language. Perl is an - interpreted programming language suited for processing text and - generating reports. - - _SGML_ - Standard Generalized Markup Language. SGML is a language for - document representation. - - _________________________________________________________________ - - - _________________________________________________________________ - - Contacts - - _________________________________________________________________ - -Mailing List - - A mailing list, mhonarc@rosat.mpe\-garching.mpg.de, is available to - provide a discussion forum on the usage and development of _MHonArc_. - Appropriate topics for the list include: usage questions, bug reports, - behavioral enhancements, documentation bugs, and general help. - - To subscribe to the mailing list, send mail to - mhonarc\-request@rosat.mpe\-garching.mpg.de with the command, - -subscribe - - as the message body. - - If you send mail mhonarc@rosat.mpe\-garching.mpg.de, your message will - be distributed to all subscribers on the list. - - The mailing list is archived by Majordomo. You can also use the WWW to - access the archive (with full text search using _glimpse_) at - - - _________________________________________________________________ - -People - - _Earl Hood_ - ehood@isogen.com - Main developer of _MHonArc_. Contact for bug reports, - behavioral enhancements, documentation bugs, and Unix usage - issues. - - _Steve Pacenka_ - sp17@cornell.edu - Contributing developer. Worked on isolating code that would - conflict with MS\-DOS. Contact for MS\-DOS installation problems - or MS\-DOS usage issues. - - _Achim Bohnet_ - ach@rosat.mpe\-garching.mpg.de - Contributing developer. Administrator, and maintainer, of the - _MHonArc_ mailing list. - - _________________________________________________________________ - -.fi -.in diff --git a/doc/mhonarc.html b/doc/mhonarc.html index fce8adb..1f25541 100644 --- a/doc/mhonarc.html +++ b/doc/mhonarc.html @@ -1,159 +1,85 @@ + -MHonArc v1.2.2 - +MHonArc v2.0 -


          + +
          +

          [Cool Logo Here]

          MHonArc

          -An Internet mail-to-HTML converter. +An Email-to-HTML converter.

          +

          Table of Contents

          - - - - - - - - - - - - - - - -
          -
          -Earl Hood -<ehood@isogen.com>
          -Isogen International Corp
          -2200 North Lamar #230
          -Dallas, TX 75202
          -
          -Phone: (214) 953-004 x127
          -FAX: (214) 953-3152
          -
          + + + + + + + + + +
          -Document converted from Frame by -MifMucker +97/05/15 16:49:00
          + +MHonArc
          +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
          diff --git a/doc/mhonarc.ps b/doc/mhonarc.ps deleted file mode 100644 index 6b3d910..0000000 Binary files a/doc/mhonarc.ps and /dev/null differ diff --git a/doc/mhonarc.txt b/doc/mhonarc.txt deleted file mode 100644 index 345a77c..0000000 --- a/doc/mhonarc.txt +++ /dev/null @@ -1,3779 +0,0 @@ - - [INLINE] - - MHonArc - - An Internet mail-to-HTML converter. - - _________________________________________________________________ - -Table of Contents - - * Introduction - + Why Use MHonArc? - + Supported Platforms - + Availability - + About the Documentation - - * Installation - + System Requirements - + Extracting the Distribution File - + Installing the Software - + Tested Environments - - * Quick Start - + Converting MH mail folders or Mailbox files - + Adding Messages to an Archive - + Converting a single message - - * Overview - + Synopsis - + Options - + Environment - - * Resource File - + Resource Syntax - + Resource Elements - + Example Resource File - + Notes on Resource File - - * Adding Messages - + Examples - - * Removing Messages - + Message Numbers - + Scanning an Archive - - * Index Page Customization - + Filename - + Beginning Markup - + End Markup - + Include Files - + Listing Layout - + Icons - + Examples - - * Thread Index Customization - + Filename - + Beginning Markup - + End Markup - + Listing Layout - - * Message Customization - + Beginning Markup - + End Markup - + Header and Footer - + Navigational Links - + Message Layout - + Other Resources - - * MIME - + Default Filters - + Non-MIME Messages - + Writing Filters - + Specifying Filters - - * Gory Details - + OS Detection - + Processing Steps - + Archive Integrity - + File Formats - + Notes - - * Diagnostics - + Informative messages - + Warnings - + Errors - + Perl Messages - - * Glossary - - * Contacts - + Mailing List - + People - - _________________________________________________________________ - - - Earl Hood - Isogen International Corp - 2200 North Lamar #230 - Dallas, TX 75202 - - Phone: (214) 953-004 x127 - FAX: (214) 953-3152 - - _________________________________________________________________ - - - - _________________________________________________________________ - - Introduction - - _MHonArc_ is a Perl program for converting e-mail messages as - specified in RFC 822 and RFC 1521 (_MIME_) to HTML. _MHonArc_ can - perform the following tasks: - - * Convert mh(1) mail folders or UUCP/Unix style mailboxes into an - HTML mail archive. - * Add or remove messages to an existing HTML mail archive generated - by _MHonArc_. - * Convert a single message to HTML. - - Along with these tasks, _MHonArc_ provides the following: - - * A main customizable index page for mail messages archived. - * A customizable thread index page listing messages by thread. - * Control over message formatting. - * The ability to hook in your own custom message filters. - - _________________________________________________________________ - -Why Use MHonArc? - - Here are some reasons for using _MHonArc_: - - * You want to keep organized archives of mail messages and/or news - articles for a World Wide Web (_WWW_) server; complete with live - hypertext pointers to their authors and to any url's mentioned. - * You would like to control the layout of mail/news archives to keep - a consistent style to your WWW pages. - * You have a WWW client, but no MIME mail reader. _MHonArc_ will - allow you to read MIME messages that includes images, audio, - video, etc via your Web client. - * Muli-platform support: MS-DOS and Unix. - * You think the _MHonArc_ logo is really cool, and it deserves to be - used. - * You like Perl, and you want to see what it can do. - * Just cuz. - - _________________________________________________________________ - -Supported Platforms - - _MHonArc_ (version 1.1, or later) will run under Unix or MS-DOS - operating systems with Perl 4 or 5 installed. - - _________________________________________________________________ - -Availability - - The latest information on _MHonArc_, and its availability, may be - obtained at . - - _________________________________________________________________ - -About the Documentation - - The documentation is oriented towards Unix users. However, the section - on Installation does conver MS-DOS installation instructions. Notes - are made in the documentation when something may differ due to the - operating system. - - _________________________________________________________________ - - - _________________________________________________________________ - - Installation - - This section instructs you on how to install and get _MHonArc_ running - on your machine. The section covers _Unix_ installation and - _MS-DOS/Windows_ installation. - - _NOTE_ - For brevity, anything that applies to MS-DOS also applies to - Windows. - - _________________________________________________________________ - -System Requirements - - _MHonArc_ is written in Perl 4. Therefore, you must have Perl 4 or 5 - installed on your system. If you do not know if Perl is installed on - your system, ask your system administrator. - - If Perl is not installed on your system, you can retrieve Perl at - . I recommend version 4.0 - patchlevel 34, or later. _MHonArc_ has not been tested on earlier - versions. - - _NOTE_ - _MHonArc_ makes use of the Perl libraries newgetopt.pl and - timelocal.pl. These libraries are part of the normal Perl - distribution. - - _________________________________________________________________ - -Extracting the Distribution File - - Before extracting the distribution file, you may want copy the - distribution file into scratch directory, and work in there during - installation. - - Tar/Gzip Distribution - - You must have _gzip_ and _tar_ installed on your system. If _gzip_ is - not installed, you may obtain _gzip_ at - . _Tar_ comes with all Unix - systems. However, MS-DOS users may have to obtain _tar_. - - To extract the file, type the following command at your shell's - prompt: - - _Unix_ - zcat MHonArc.tar.gz | tar xvof - - - _MS-DOS_ - gunzip -dv MHonArc.tar.gz - tar xvf MHonArc.tar - - A directory called "MHonArc" should be created. The directory contains - all the files need for installing _MHonArc_. - - _NOTE_ - The actual name of the distribution file may differ from the - example given. - - Zip Distribution - - You must have _pkzip_ or _unzip_ installed on your system. - - To extract the file, type the following command at your shell's - prompt: - - unzip mhonarc.zip - - OR - - pkunzip -d mhonarc.zip - - _IMPORTANT_ - The directory structure of the zip file must be preserved - during extraction to insure proper installation. - - A directory called "MHonArc" should be created. The directory contains - all the files need for installing _MHonArc_. - - _NOTE_ - The actual name of the distribution file may differ from the - example given. - - _________________________________________________________________ - -Installing the Software - - Once you have extracted the distribution file, change your current - working directory into the MHonArc directory created during the - extraction of the distribution file. - - _Example_: Assuming you are in the directory you extracted the - distribution file in, you can type the following on your command-line: - - _Unix_ - cd MHonArc - - _MS-DOS_ - cd MHONARC - - install.me - - Contained in the MHonArc directory is a Perl program called - "install.me". This program will perform the tasks required to install - _MHonArc_ on you machine. The install program is capable of running - interactively, or in batch. - - Interactive Mode - - To run install.me in interactive mode, type the following at your - shell's prompt: - - perl install.me - - _NOTE_ - Make sure you are in the same directory as the install.me - program. - - The program will then prompt you for the necessary information to - install _MHonArc_ on your system. - - Here's an example (Unix) session: - -% perl install.me -MHonArc Installation -==================== -The installation process will ask you a series of questions on where -the Perl executable is and where to put MHonArc files. Just hit -to accept the default values listed in ()'s. - -If directory path does not exist on your system, the installation -program will create the path for you. - ------------------------------------------------ -Note: Make sure all pathnames are absolute. ------------------------------------------------ - -Hit to continue ... -Perl executable ("/usr/local/bin/perl") --> /usr/bin/perl -Location to install programs ("/usr/local/bin") --> /mnt/ehood/bin -Location to install libraries ("/usr/local/lib/MHonArc") --> /mnt/ehood/lib/MHonArc -Install documentation ("y")? y -Location to install docs ("/usr/local/lib/MHonArc/doc") --> /mnt/ehood/lib/MHonArc/doc - -You've specified the following: - Perl location: /usr/bin/perl - Program directory: /mnt/ehood/bin - Library directory: /mnt/ehood/lib/MHonArc - Doc directory: /mnt/ehood/lib/MHonArc/doc -Is this correct ("y")? y -Installing the following into /mnt/ehood/bin - mhonarc -Installing the following into /mnt/ehood/lib/MHonArc - base64.pl - mhexternal.pl - mhtxthtml.pl - mhtxtplain.pl - mhtxtsetext.pl - qprint.pl - readmail.pl -Installing the following into /mnt/ehood/lib/MHonArc/doc - mhonarc.txt - ... - - Batch Mode - - To run install.me in batch mode, type the following at your shell's - prompt: - - perl install.me install.cfg - - _NOTE_ - Make sure you are in the same directory as the install.me - program. - - The install.cfg contains the necessary information for intalling - _MHonArc_ on your system. You will need to edit install.cfg to reflect - your installation requirements. - - Here is an example install.cfg: - -# Should executables be installed. 0 => NO, non-zero => YES. -# -$dobin = 1; - -# Should libraries be installed. 0 => NO, non-zero => YES. -# -$dolib = 1; - -# Should documentation be installed. 0 => NO, non-zero => YES. -# -$dodoc = 1; - -# Location for executable. If using ms-dos, use something like -# 'C:\\BIN'. -# -$bindir = '/usr/local/bin'; - -# Location for libraries. If using ms-dos, use something like -# 'C:\\LIB\\MHONARC'. -# -$libdir = '/usr/local/lib/MHonArc'; - -# Location for documents. If using ms-dos, use something like -# 'C:\\DOC\\MHONARC'. -# -$docdir = '/usr/local/lib/MHonArc/doc'; - -# Location of perl executable. If using ms-dos, use something like -# 'C:\\BIN\\PERL.EXE'. -# -$perlprg = '/usr/local/bin/perl'; - - -1; # DO NOT DELETE THIS LINE - - The file is Perl code, and therefore, must follow Perl syntax rules: - - * Anything following a `#' character is ignored. - * Strings values need to be enclosed in quotes. - * If you need to use a backslash in a string value, it must be - escaped with a backslash. Example: 'C:\\LIB\\MHONARC'. The same - applies to the '$' character. - * All statements must end with a semi-colon. - * The "1;" line must not be deleted. - - _NOTE_ - You can verify the syntax of the configuration file by invoking - "perl -c" on the file. - - After you have successfully executed install.me, _MHonArc_ is ready to - use. - - MS-DOS Post install.me Note - - If you would like the ability to run _MHonArc_ like other programs, - then create a batch file that contains something like the following: - -@ECHO OFF -C:\BIN\PERL.EXE C:\BIN\MHONARC %1 %2 %3 %4 %5 %6 %7 %8 %9 - - Of course, you will need to change the paths to Perl and _MHonArc_ to - suit your systems configuration. - - Sample batch files are available in the _MHonArc_ distribution. - - Notes on install.me - - * If you do not know the location of the Perl executable on your - system, ask your system administrator. - * All pathnames must be absolute. - * If a path does not exist that you specify, the path will be - automatically created if running in interactive mode. In batch - mode, all paths specified must already exist. - * During the installation process, the main _MHonArc_ source file is - modified to be aware of the location of the Perl executable and - _MHonArc_'s library files. If you ever need to install _MHonArc_ - in a different location, rerun the install.me program. - _NOTE_: Location of the Perl exectuble is only relevant for Unix - systems. MS-DOS systems do not make use of the "#!" line in - scripts. - * _MHonArc_ requires the use of timelocal.pl and newgetopt.pl. These - libraries are part of the normal Perl distribution. - - _________________________________________________________________ - -Tested Environments - - This section covers software environments _MHonArc_ has worked - successfully. Feedback is welcome about other success, or failure, - stories covering _MHonArc_ usage in other environments. - - Perl - - _MHonArc_ is known to work with the following version of Perl 4, or - later: - - $RCSfile: perl.c,v $$Revision: 4.0.1.7 $$Date: 92/06/08 14:50:39 $ - Patch level: 34 - - _MHonArc_ is known also to work with Perl 5.001m and Perl 5.002 beta2. - - _NOTE_ - The version numbers are based upon the Unix versions of Perl. - DOS version numbers may differ. - - Unix - - Mail Software - - * _MH_ - * _Elm_, _Mail_, _mail_, and any other mail software that stores - e-mail in UUCP style mailbox format. UUCP format is where mail - messages are separated by a line beginning with "From " (I.e. the - word "From" followed by a space). You may need to utilize the - MSGSEP resource if the message separator is different from - standard mailbox files (eg. MMDF format). - - News Software - - Different news software store messages differently. Messages are - either stored in a format similiar to _MH_ or similiar to a mailbox - file: - - * _MH_ style is where the messages are stored in a directory with - each post a separate file, and each file has a numeric filename. - * Mailbox style is where messages are stored in a single file. You - may need to utilize the MSGSEP resource if the message separator - is different from standard mailbox files. - - MS-DOS - - Mail/News Software - - _MHonArc_ has been tested under MS-DOS with message files created by - the following mail and news programs: - - * _Eudora_ - * _WinVN_ - * _Windows Trumpet_ - * _NUPop_ - - It also works with individual RFC822 mail messages, but you must run - _MHonArc_ without a batch file if you need to use redirection. For - example: - - perl c:\bin\mhonarc one.htm - perl c:\bin\mhonarc -add /inbox - - Where represents the path to the directory that contains the - mail folder _inbox_. If you are in the directory that contains inbox, - then you can leave out the "/". - - _MHonArc_ prints out messages showing its progress as your e-mail is - processed. When _MHonArc_ finishes, the following files will be - created: - - * maillist.html: The main index file containing links to all mail - messages converted. Messages are listed with subjects and who the - messages are from. All messages are listed in sorted order by date - received/sent. - * threads.html: The file listing messages by thread. - * msg*.html: HTML versions of the mail messages, where * represents - a message number from 0 to the number of message processed minus - 1. - * .mhonarc.db (or MHONARC.DB under MS-DOS): This database file is - needed inorder for _MHonArc_ to perform additions of new mail - messages to the archive. Information is stored to perform mail - threading updates when new messages are added, as well as any - resources set via Environment variables, Resource File, and/or - command-line Options. - * _Other_: Depending on the content-types of the e-mail messages - converted, other files may be created for images, videos, - binaries, etc. See the section on MIME for more information. - - The format of each converted mail message is as follows: - - * A is inserted in the - HEAD element of HTML mail message file. This allows readers of the - message to send comments to the author of the mail message within - Web browsers that support such functionality (like _Lynx_). - * The title (i.e. TITLE element) contains the subject of the - message. - * Hyperlinks to the previous and next messages and the index pages - are located at the top of the message. - * Next, the subject appears in a H1 element. - * Next, follows the mail header with fields listed in a UL element - surrounded by HR's. - * Next, the actual body of the mail message. - * Next, links to any follow-up, or referenced, messages. The - messages are listed by subject and who they are from. These links - allows you to easily follow mail threads. - * Last, are verbose links to the previous mail message, next mail - message, and index pages. - - The following is also done for each mail message processed: - - * Links are created in the "References" and "In-Reply-To" header - fields, and possibly the message body, if the destination - message-ids are being processed. - * E-mail addresses are converted to "mailto" hyperlinks in "To:", - "From:", "Cc:", and "Sender:" mail header fields. Currently, not - all Web browsers support the mailto URL. - * Newsgroups listed in a "Newsgroups:" mail header field are - converted to news hyperlinks. - - _MHonArc_ allows you to specify more than one mail folder to process - on the command-line. - - _Example_ - % mhonarc /home/ehood/mail/inbox1 /home/ehood/mail/inbox2 ... - - All the files created will be put into the current working directory, - by default. You can control the destination of the output location by - using the -outdir option. - - _Example_ - % mhonarc -outdir /home/ehood/htmlarchive - /home/ehood/mail/inbox - - Here is a sample session converting a mail folder: - -% mhonarc ~/mail/inbox -Requiring MIME filter libraries ... - mhexternal.pl - mhtxthtml.pl - mhtxtplain.pl - mhtxtsetext.pl -Converting messages to ./maillist.html -Reading /mnt/ehood/mail/inbox .......... -Writing mail ... -Writing tmp/maillist.html ... -Writing tmp/threads.html ... -10 messages - - _________________________________________________________________ - -Adding Messages to an Archive - - If you have new messages you want to add to an existing archive, you - must utilizing the -add command-line option. With the -add, you can do - the following: - - * Add a mail folder to an archive, or - * Add a single message to an archive. - - Adding a mail folder to an archive in the current working directory - can be done like the following: - - % mhonarc -add /mailfolder - - If you are not in the same directory as the archive, then you can - specify the location of the archive to add to with the -outdir option: - - % mhonarc -add -outdir /mailfolder - - _NOTE_ - _MHonArc_ will skip any messages that already exist in the - archive. Therefore, _MHonArc_ can be used to rescan the same - mail folder and only convert any new messages it finds. - - If no mail folder arguments are specified, then _MHonArc_ will attempt - to add a _single_ message read in from standard input. - - _Example_ - % mhonarc -add < single.msg - - Or, from a pipe: - - % cat single.msg | mhonarc -add - - See the section on Adding Messages for more information and examples - for adding messages to an archive. - - _________________________________________________________________ - -Converting a single message - - _MHonArc_ has the ability to process a single mail message independent - of creating, or modifying, and archive. To convert a single message to - HTML use the -single command-line option. The message to process can - be specified by a filename on the command-line, or by reading the - message from standard input if no file is specified. The filtered - message is sent to standard output. All formatting options apply to - the single message as with messages being processed for an archive, - with the exception of formatting related specificly to archive - processing, like index links and mail thread links. - - Examples - - Input from standard input: - % mhonarc -single < messagefile > file.html - - Filename on command-line: - % mhonarc -single messagefile > file.html - - _________________________________________________________________ - - - _________________________________________________________________ - - Overview - - This section gives an overview of _MHonArc_'s command-line options and - environment variables. The _MHonArc_ resource file is covered in the - section Resource File. The resource file allows you to specify most of - the resources set by environment variables and command-line options, - plus it give you the capability of completely customizing the HTML - output generated by _MHonArc_. - - _________________________________________________________________ - -Synopsis - - Invoke _MHonArc_ from your shell with the following syntax: - - % mhonarc [_options_] _mhfolder_... - % mhonarc [_options_] _mailbox_ ... - % mhonarc -add [_options_] < _message_ - % mhonarc -single [_options_] < _message_ > _message.html - _% mhonarc -single [_options_] _message_ > _message.html - _% mhonarc -rmm [_options_] _msg# _..._ - _ - _________________________________________________________________ - -Options - - The following options are available: - - -add - - Add new messages to an existing archive. If no mail folder arguments - are given, _MHonArc_ assumes that a _single_ message is being added to - the archive via _standard input_. Otherwise, _MHonArc_ adds the - messages contained in the mail folders specified. - - -dbfile name - - Use _name_ for the name of _MHonArc_ database file. The default is - ".mhonarc.db" (or "MHONARC.DB" under MS-DOS). - - _NOTE_ - You should not override the default name unless absolutely - necessary, and you are confident about what you are doing. - - -docurl url - - Use _url_ as the URL to _MHonArc_ documentation. The default is - "http://www.oac.uci.edu/indiv/ehood/mhonarc.html". - - -editidx - - This option tells _MHonArc_ to rewrite the index page and re-edit all - mail messages in the archive. This option is useful if you need to - change the layout of the index page and/or messages. - - -footer filename - - Insert contents of filename at the bottom of the index page. See - Include Files in Index Page Customization for more information about - the footer file. - - -force - - Override a lock on an archive if attempts to lock fail. I.e. After - trying unsuccessfully to lock an archive, _MHonArc_ will still perform - the actions requested. - - This option is useful to help dealing with locks that are no longer - valid (i.e. _stale locks_). A stale lock can exist if the _MHonArc_ - process that created the lock abnormally terminated and could not - perform the proper cleanup procedures. - - -genidx - - Output an index page to standard output based upon the contents of an - archive, and utilizing any extra formatting options specified. - - -header filename - - Insert contents of _filename_ at the beginning of the index page. See - Include Files in Index Page Customization for more information about - the header file. - - -help - - Print out a help message about _MHonArc_. - - -idxfname name - - Sets the name of the main index file to _name_. The default is - "maillist.html". - - -idxsize # - - Set the maximum number of messages listed in the indexes. - - -lockdelay # - - The sleep time, in seconds, between attempts to lock the archive. The - default value is 3. - - -locktries # - - Set the number of time _MHonArc_ tries to lock a mail archive before - processing new messages. The default value is 10. _MHonArc_ waits - approximately 3 seconds before each try. - - See Archive Integrity for more information on the -locktries options. - - -mailtourl url - - Use _url_ for e-mail address hyperlinks in mail message headers. The - url can contain the following _variables_ that get expanded during - run-time: - - $FROM$ - Who the message is from. - - $MSGID$ - Message ID of the message. - - $SUBJECT$ - The subject of the message. - - $TO$ - Destination e-mail address of link. - - The default URL is "mailto:$TO$" - - The -mailtourl option has no effect if the -nomailto option is - specified. - - -maxsize # - - Set the maxinum number of messages allowed in the archive to _#_. If - messages are added to the archive which would cause the total number - of messages to exceed _#_, older messages (based on sort method) are - removed automatically. - - -msgsep expression - - Use the _expression_ as the Perl regular expression that signifies the - message separator in Unix mailbox files. The default expression is - "^From " (minus the quotes). - - _NOTE_ - There is a space character after the From. - - -nodoc - - Do not print link to documentation at end of index page. - - -nomailto - - Do not convert e-mail addresses in mail headers to mailto hyperlinks. - - -nonews - - Do not convert newsgroups in the Newsgroups: mail header field to news - hyperlinks. - - -noreverse - - Do not perform a reverse listing of the mail messages in the index - page. - - -nosort - - Do not sort messages by date. Messages will be in the order they - appear in the mailboxes/folders. By default, _MHonArc_ sorts messages - by date sent/received. - - -nosort takes precedence over the -sort option. - - -nothread - - Do not create a thread index page. - - -notsubsort - - Do not sort threads by subject on thread index page. - - -notreverse - - List threads in the thread index with oldest thread first. - - -outdir path - - Set destination/location of the HTML mail archive to _path_. By - default, the current working directory is used. - - -quiet - - Suppress processing messages when _MHonArc_ is running. - - -rcfile file - - Use file as the resource file for _MHonArc_. _MHonArc_ does the - following to determine the location of file: - - 1. If its an absolute pathname, use it. - 2. If it is a relative pathname, check for it relative to the current - working directory. - 3. Otherwise, check for it relative to the location of the archive. - - See Resource File for more information. There is no default resource - file. - - -reverse - - List messages in reverse order of the sorting option specified. For - example, if date sorting is specified, -reverse will cause messages to - be listed in _reverse_ chronological order. - - -rmm - - All non-option command-line arguments are treated as messages to - remove from the archive. Messages to remove are denoted by their - message numbers. - - -savemem - - Normally, all messages are stored in memory and then written in one - shot. This option causes _MHonArc_ to write the message data as it is - processesd. This option will cause a slow down in execution time as - more disk I/O required, but it may allow large amounts of data to be - processed in a single process if memory is limited. - - _NOTE_ - The reason more disk I/O is required is that when the message - data is first written, all the archive navigational link - information is non-existant. The information required to - correctly generate the navigational link information will not - exist until all messages are processed. Therefore, each new - message file must be reopened to add in the navigational link - information after all messages are processed. - - -scan - - List contents of archive to standard output. - - -single - - Convert a single mail message to HTML. The message can be specified by - a filename on the command-line, or read from standard input if no file - is given. The filtered message is sent to standard output. - - The -single option is useful tp convert individual messages to HTML - not related to a specific mail archive. Any option related to how - message formatting can be used with the -single option. - - The -single takes precedence over the -add option. - - -sort - - Perform chronological date sorting. This is the default. - - -subsort - - Sort messages by subject. Subject sorting is case-insensitive, and - begining "Re:", "A", "An", and "The" words are ignored. - - -tidxfname name - - Sets the name of the thread index file to _name_. The default is - "threads.html". - - -time - - Print out total CPU execution time taken when processing messages. - Time information is written to standard error. - - -title string - - Set the title of the main index page to _string_. The default is - "_Mail Index_". - - -thread - - Create a thread index page. This is the default. - - -tlevels - - Set the maximum number of nested lists for the thread index page. The - default is 3. - - -treverse - - List threads in the thread index with newest thread first. - - -tsubsort - - List threads in the thread index by subject. - - -ttitle string - - Set the title of the thread index page to _string_. The default is - "_Mail Thread Index_". - - -umask umask - - Set the umask of the _MHonArc_ process to _umask_. The value is - treated as an octal number. - - NOTE - - The -no* options always take precedence over their counterparts. For - example, if -noreverse and -reverse are both specified on the - command-line, the -noreverse will be applied. - - _________________________________________________________________ - -Environment - - _MHonArc_ supports the use of environment variables. The environment - variables allow you to set default options everytime you invoke - _MHonArc_. The following environment variables may be used: - - M2H_DBFILE - - Sets the name of _MHonArc_ database file. The default is ".mhonarc.db" - (or "MHONARC.DB" under MS-DOS). - - _NOTE_ - You should not override the default name unless absolutely - necessary, and you are confident about what you are doing. - - M2H_DOCURL - - Set the URL used to point to _MHonArc_ documentation. The default is, - "http://www.oac.uci.edu/indiv/ehood/mhonarc.html". - - M2H_FOOTER - - Set the HTML footer file to insert at the bottom of the index page. No - default footer file is defined. See Include Files in Index Page - Customization for more information about the footer file. - - M2H_HEADER - - Set the HTML header file to insert at the top of the index page. No - default header file is defined. See Include Files in Index Page - Customization for more information about the header file. - - M2H_IDXFNAME - - Set the name of the index file. The default is, "maillist.html". - - M2H_IDXSIZE - - Sets the maximum number of messages listed in the indexes. - - M2H_LOCKFILE - - The sleep time, in seconds, between attempts to lock the archive. The - default value is 3. - - M2H_LOCKFILE - - Set the name of the lock file. The default name use is ".mhonarc.lck" - (or "MHONARC.LCK" under MS-DOS). - - _NOTE_ - You should not change the default unless absolutely necessary. - - See Archive Integrity for more information about the lock file. - - M2H_LOCKTRIES - - Set the number of time _MHonArc_ tries to lock a mail archive before - processing new messages. The default value is 10. _MHonArc_ waits - approximately 3 seconds before each try. - - See Archive Integrity for more information on the M2H_LOCKTRIES - environment variable. - - M2H_MAILTOURL - - Sets the URL for e-mail address hyperlinks in mail message headers. - The URL can contain the following _variables_ that get expanded during - run-time: - - $FROM$ - Who the message is from. - - $MSGID$ - Message ID of the message. - - $SUBJECT$ - The subject of the message. - - $TO$ - Destination e-mail address of link. - - The default URL is "mailto:$TO$" - - M2H_MAXSIZE - - Sets the maximum number of messages that an archive will contain. If - messages are added to the archive which would cause the total number - of messages to exceed M2H_MAXSIZE, older messages (based on sort - method) are removed automatically. - - M2H_OUTDIR - - Sets the destination/location of the HTML mail archive. The default is - the current working directory. - - M2H_RCFILE - - Specifies the Resource File for _MHonArc_. No default resource file is - defined. - - M2H_THREAD - - Flag to determine if _MHonArc_ generates a thread index. If set to - zero, the thread index will not be created. The default behavior is to - create a thread index. - - M2H_TIDXFNAME - - Sets the name of the thread index file. The default is "threads.html". - - M2H_TITLE - - Sets the default title of the index page. The default is "_Main - Index_". - - M2H_TLEVELS - - Sets the maximum number of nested lists for the thread index page. The - default is 3. - - M2H_TTITLE - - Sets the title of the thread index page. The default is "_Mail Thread - Index_". - - NOTE - - Environment variables may be overriden by the Resource File or - command-line Options. - - _________________________________________________________________ - - - _________________________________________________________________ - - Resource File - - _MHonArc_ supports the ability to read in a resource file to control - the behavior of _MHonArc_. The resource file allows you to specify - most of the resources set by environment variables and command-line - options, and it allows you to specify other resources to control - _MHonArc_'s behavior. - - The resource file is specified by the M2H_RCFILE environment variable - or the -rcfile command-line option. The command-line option overrides - the environment variable if both are defined. - - _NOTE_ - _MHonArc_ will store the information specified in the resource - file in the database for the archive. Therefore, it is - unnecessary to respecify the resource file duing archive - updates unless changes are required from the current settings. - - _________________________________________________________________ - -Resource Syntax - - Resources are set in the file by using _elements_ similiar in style to - HTML/SGML markup. However, _MHonArc_ uses simpler parsing rules for - the resource file than standard SGML: - - * Any line that is not a recognized element open tag, _and_ the line - is not contained within an element, is ignored. This implies that - regular text can be put anywhere _outside_ of recognized elements - for commenting purposes. - _NOTE_: You should use SGML comment declarations () - when commenting a resource file. This will eliminate possible - conflict with later versions of _MHonArc_ if more stricter parsing - rules are adopted. - * The opening tag of an element must occur by itself on a single - line. Whitespace is allowed before the the open tag. - * No comments are allowed inside elements because the text will be - treated as element content. - * Each element must be closed with a tag on its own - line unless _explicitly_ stated otherwise in the Resource Elements - section. Whitespace is allowed before the close tag. - * Some elements can take an optional attribute called "Override". - This tells _MHonArc_ that the contents of the element will - completely override the default behavior of _MHonArc_, and - previous instances of the element. _Example_: "". - If "Override" is not specified, then the contents of the element - augment the current setting. - * Element names are case-insensitive. - * Elements can occur in any order in the resource file. - - Resource Variables - - Some resource element contents may contain variables. Variables get - expanded to strings at run-time. - - _NOTE_ - Variable expansion will only take place in resource elements - that are intended to have variables as part of their content. - If an element is not meant to have variables, the variable text - will be taken literally as part of the element content. - - The syntax of the _variables_ to use in resource elements is as - follows: - - $_VARIABLE_[:[_N_][U]]$ - - The items in []'s are optional. Definition of each part: - - $ - The $ character represents the beginning, and ending, of the - variable. - - _VARIABLE_ - This is the the actual name of the variable. All variable names - must be uppercase. - - :[_N_][U] (_optional_) - This defines a maximum length of the replacement string for the - variable. The option "U" denotes that the replacement string - should be treated as part of a URL string. This can be useful - when the variable may contain special characters, and the - variable is used withing a URL. - - _No_ whitespace is allowed between the opening $ and closing $. If an - unrecognized variable is encountered, it gets replaced with an empty - string. If a literal "$" is needed, use "$$". - - _SPECIAL NOTE_ - The MAILTOURL resource has different rules for variable - expansion. If a variable does not exactly match the set of - variables available for the MAILTOURL, the variable text will - be taken literally as part of the element content. Therefore, a - single "$" can be used to represent a "$" character. - - Also, variables in the MAILTOURL should _NOT_ have ":NU" - modifier. This will prevent the variables from be recognized. - _MHonArc_ will automatically treat the replacement value as a - part of a URL string. - - Here are some examples of legal variable usage: - - * $SUBJECT$ - * $FROMNAME$ - * $SUBJECT:50$ - * $SUBJECTNA:60U$ - * $FROMADDR:U$ - - Each resource element will define what variables are defined for it. - - _________________________________________________________________ - -Resource Elements - - The following are complete listings of all the resource elements - defined by _MHonArc_. Many element descriptions will reference to - other sections of the documentation on the exact usage of the element. - - Empty Elements - - The following list of elements contain no textual content. Therefore, - no end tag is required: - - NODOC - - Do not put link to documentation on main index page. - - NOMAILTO - - Do not convert e-mail addresses in mail headers to mailto hyperlinks. - - NONEWS - - Do not convert newsgroups in the Newsgroups: mail header field to news - hyperlinks. - - NOREVERSE - - Do not perform a reverse listing of the mail messages in the main - index page. - - NOSORT - - List messages in the index page in the order they are processed. - - NOTHREAD - - Do not create thread index. - - NOTREVERSE - - List threads in the thread index with oldest thread first. - - NOTSUBSORT - - Do not sort thread by subject in thread index page. - - REVERSE - - List messages in reverse listing order for the main index page. - - SORT - - List messages in the index page in chronological order. - - SUBSORT - - Sort messages by subject. Subject sorting is case-insensitive, and - begining "Re:", "A", "An", and "The" words are ignored. - - THREAD - - Create thread index. This is the default. - - TREVERSE - - List threads in the thread index with newest thread first. - - TSUBSORT - - Sort thread by subject in thread index page. - - Non-Empty Elements - - The following list of elements contain textual content, therefore, - each element must be _explicitly_ closed with an element end tag - (examples are given in Example Resource File): - - BOTLINKS - - Markup for defining the various hyperlinks at the bottom of converted - messages. See Navigational Links of Message Customization for usage of - this element. - - DBFILE - - Use _name_ for the name of _MHonArc_ database file. The default is - ".mhonarc.db" (or "MHONARC.DB" under MS-DOS). - - _NOTE_ - You should not override the default name unless absolutely - necessary, and you are confident about what you are doing. - - DOCURL - - URL to _MHonArc_ documentation. The default is - "http://www.oac.uci.edu/indiv/ehood/mhonarc.html". - - EXCS - - Set of message header fields to exclude from messages. See Excluding - Fields of Message Customization for usage of this element. - - FIELDORDER - - The order the message header fields appear in messages. See Field - Order of Message Customization for usage of this element. - - FIELDSTYLES - - The format specification for message header field values. See Field - Formatting of Message Customization for usage of this element. - - FOOTER - - File to include at the end of the index page. See Include Files in - Index Page Customization for more information about the footer file. - - HEADER - - File to include at the beginning of the index page. See Include Files - in Index Page Customization for more information about the header - file. - - ICONS - - The ICONS element is used to specify the icons that represent the - different content-types of messages. See Icons in Index Page - Customization for usage of this element. - - IDXFNAME - - The name of the index file. The default is "maillist.html". - - LABELSTYLES - - The format specification for message header field labels. See Field - Formatting in Message Customization for usage of this element. - - LISTBEGIN - - Markup for beginning the main index list. See Listing Layout in Index - Page Customization for usage of this element. - - LITEMPLATE - - Markup for an entry in the main index list. See Listing Layout in - Index Page Customization for usage of this element. - - LISTEND - - Markup for terminating the main index list. See Listing Layout in - Index Page Customization for usage of this element. - - MAILTOURL - - Url to use for e-mail hyperlinks. See E-mail Links in Message - Customization for usage of this element. - - MIMEARGS - - Arguments to MIME filters. See Specifying Filters in MIME for usage of - this element. - - MIMEFILTERS - - Routines for filtering messages. See Specifying Filters in MIME for - usage of this element. - - MSGFOOT - - Footer text for converted messages. See Header and Footer in Message - Customization for usage of this element. - - MSGHEAD - - Header text for converted messages. See Header and Footer in Message - Customization for usage of this element. - - MSGSEP - - Perl regular expression that represents the message separator for - mailbox files. The default expression is "^From ". - - OTHERINDEXES - - List of resource files (one per line) defining other index pages to - generate when creating, or updating, an archive. - - _CAUTION_ - It is very important that each resource file specified defines - the IDXFNAME (or the TIDXFNAME _and_ THREAD elements for a - thread index) to prevent overwriting of the default index - pages. - - _MHonArc_ will only store the name of the resource files listed in the - database. Therefore, for any subsequent updates the archive, the extra - index resource files must exist inorder to generate the extra index - pages. - - _NOTE_ - Since _MHonArc_ will look in the archive location for resource - files specified with relative pathnames, you can keep the other - index resource files in the same location as the archive, and - just specify the filenames for the OTHERINDEXES element in the - main resource file. - - When create resource files for extra indexes, make sure to explicitly - set all resources desired since some resource settings may no longer - be set to the defaults due to database settings, or from a previously - read resource file. Ie. _MHonArc_ does not reset to the default - settings when reading in the other resource files. - - PERLINC - - Each line represents a path to search when requiring MIME filters. See - Specifying Filters in MIME for the use of this element. - - TFOOT - - Markup that appears after the thread index listing. See Listing Layout - in Thread Index Customization for usage of this element. - - THEAD - - Markup that appears before the thread index listing. See Listing - Layout in Thread Index Customization for usage of this element. - - TIDXFNAME - - The name of the thread index file. The default is "threads.html". - - TIMEZONES - - Each line of the TIMEZONES element defines a timezone acronym and its - hour offset from UTC/GMT (_Universal Coordinate Time_). The format of - each line is "timezone_acronym:hour_offset". Examples of timezone - acronyms are: UTC, PDT, EST. The hour offset is should be positive for - timezones West of UTC, and negative for time zones East of UTC. - - _MHonArc_ has a default list of timezone acronyms defined with hour - offsets. Therefore, the list given in the resource file will augment - the default list, unless the "Override" attribute is specified. If - "Override" is specified, the default list, along with any other lists - specified in previous TIMEZONES elements, are discarded, and only the - timezone acronyms specified in the TIMEZONES element will be used. - - The following is the default value for TIMEZONES: - - -UTC:0 -GMT:0 -AST:4 -ADT:3 -EST:5 -EDT:4 -CST:6 -CDT:5 -MST:7 -MDT:6 -PST:8 -PDT:7 - - - Most of the time, the date used by _MHonArc_ uses a hour offset - instead of a timezone acronym. However, mail messages may contain - timezone acronyms in received/sent dates and _MHonArc_ must be told - what the hour offset from UTC the timezone acronym represents in order - to properly sort messages by date. - - TITLE - - Title for the main index page. The default is "_Mail Index_". - - TLEVELS - - The maximum number of nested lists for the thread index. The default - is 3. - - TLITXT - - Markup for an entry in the thread index list. See Listing Layout in - Thread Index Customization for usage of this element. - - TOPLINKS - - Markup for defining the various hyperlinks at the top of converted - messages. See Navigational Links in Message Customization for usage of - this element. - - TTITLE - - Title for the thread index page. The default is "_Mail Thread Index_". - - UMASK - - Sets the umask for the _MHonArc_ process. The value is treated as an - octal number. The resource is only applicable on Unix systems. - - _________________________________________________________________ - -Example Resource File - - - - -MHonArc test - - - -MHonArc test - - - - - - -
          -Last updated: $LOCALDATE$
          -$NUMOFMSG$ messages in chronological order
          -
          - -

          -Listing format is the following: -

          -

          • -Subject -(# of follow-ups) -From
            -
          -

          -


          -
            - - - - - -
          • -$SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
            - - - -
          -

          -


          - -Home - -

          - - - - -

          -Thread index
          -Last updated: $LOCALDATE$
          -$NUMOFMSG$ messages
          -
          - -
          - - - - -apparently -errors-to -followup -forward -lines -message-id -mime- -nntp- -originator -path -precedence -received -replied -return-path -status -via -x- - - - --default- -subject:strong -from:strong -to:strong - - - --default- -subject:strong -from:strong -to:strong -keywords:em -newsgroups:strong - - - -
          -MHonArc test archive -
          -
          - - - -Home | -Main Index | -Thread Index - - - - - -application/octet-stream:http://foo.org/icons/binary.xbm -application/postscript:http://foo.org/icons/postscript.xbm -audio/basic:http://foo.org/icons/sound.xbm -image/gif:http://foo.org/icons/image.xbm -image/jpeg:http://foo.org/icons/image.xbm -image/tiff:http://foo.org/icons/image.xbm -multipart/alternative:http://foo.org/icons/alternative.xbm -multipart/digest:http://foo.org/icons/text.xbm -multipart/mixed:http://foo.org/icons/mixed.xbm -multipart/parallel:http://foo.org/icons/mixed.xbm -text/richtext:http://foo.org/icons/mixed.xbm -text/html:http://foo.org/icons/mixed.xbm -text/plain:http://foo.org/icons/text.xbm -unknown:http://foo.org/icons/unknown.doc.xbm -video/mpeg:http://foo.org/icons/movie.xbm -video/quicktime:http://foo.org/icons/movie.xbm - - - _________________________________________________________________ - -Notes on Resource File - - * Elements can be duplicated. The following elements augment - previous instances of themselves: - + EXCS (can specify Override attribute) - + FIELDSTYLES - + ICONS (can specify Override attribute) - + LABELSTYLES - + MIMEFILTERS (can specify Override attribute) - + PERLINC (can specify Override attribute) - + TIMEZONES (can specify Override attribute) - The Override attribute will discard previous settings of the - element. - * If duplicate instances of other elements exist, the last instance - takes precedence. - * If an element only accepts a single line of content, then the last - line is used for the element's content. - * If elements have conflicting resource settings (eg. NOSORT and - SORT), the last element defined takes precedence. - * Resource file settings override environment variables. - * Command-line options override any settings in the resource file. - * If you want to do an exact match of a field in the EXCS element, - append a '$' after the field name. - - _________________________________________________________________ - - - _________________________________________________________________ - - Adding Messages - - Adding messages to an archive is done via the -add option. If no - mailbox/folder arguments are given, _MHonArc_ assumes that a _single_ - message is being added to the archive via _standard input_. Otherwise, - _MHonArc_ adds the messages contained in the mail folders specified. - - _NOTE_ - _MHonArc_ will skip any messages that already exist in an - archive. If a message to be added has a message-ID that equals - a message-ID of an archived message, the message is skipped. - - _________________________________________________________________ - -Examples - - Adding a mail folder - - Here is example session adding an mail folder to an existing archive: - -% mhonarc -add test/www -Requiring MIME filter libraries ... - mhexternal.pl - mhtxthtml.pl - mhtxtplain.pl - mhtxtsetext.pl -Adding messages to ./maillist.html -Reading test/www/ ........................................ -Writing HTML ... -49 messages - - .forward - - _MHonArc_ can be used to add new messages as they are received by - using the ".forward" file in your home directory. Here is how I would - set up my .forward file to invoke _MHonArc_ on incoming mail: - -\ehood, "|/mnt/ehood/bin/webnewmail #ehood" - - _NOTE_ on .forward entry: - The "\ehood" tells sendmail to still deposit the incoming - message to my mail spool file. The "#ehood" Bourne shell - comment is needed to insure the command is unique from another - user. Otherwise, sendmail may not invoke the program for you or - the other user. - - "webnewmail" is a Perl program that calls _MHonArc_ with the - appropriate arguments. A wrapper program is used instead of calling - _MHonArc_ directly to keep the .forward file simple. Here is the code - to the webnewmail program: - -#!/usr/local/bin/perl - -$cmd = "/mnt/ehood/bin/mhonarc -add -quiet " . - "-outdir /mnt/ehood/public_html/newmail"; -open(M2H, "|$cmd"); -print M2H ; -close(M2H); - - The webnewmail can be modified to check the mail header before calling - _MHonArc_ to perform selective archiving of messages. For example, - webnewmail can check the To: field and only archive messages that come - from a specific mailing list. - - Cron - - This example uses cron(1) to update some mail archives from MH mail - folders. - - The following entry is in my crontab file: - -0 0 * * * webmail - - webmail is a script executed every night that calls _MHonArc_ to - perform the update: - -#! /bin/csh -f - -umask 022 -setenv M2H_RCFILE $HOME/.mhonarc.rc -## WWW messages -mhonarc -add \ - -outdir $HOME/public_html/doc/wwwmail \ - $HOME/mail/www -folder +www >& /dev/null -refile first-last +www.ar >& /dev/null # Archive original messages - -## Tools messages -mhonarc -add \ - -outdir $HOME/public_html/doc/toolsmail \ - $HOME/mail/tools $HOME/mail/dtd -folder +tools >& /dev/null -refile first-last +tools.ar >& /dev/null # Archive original messages -folder +dtd >& /dev/null -refile first-last +dtd.ar >& /dev/null # Archive original messages - -folder +inbox >& /dev/null # Set current folder to inbox - - - To avoid mail everynight from cron due to output from _MHonArc_, the - -quiet option can be used for each call to _MHonArc_, or use the - following line in your crontab file: - -0 0 * * * webmail > /dev/null - - Standard error is not redirected to /dev/null so mail is still - received if errors occured during _MHonArc_ execution. - - _________________________________________________________________ - - - _________________________________________________________________ - - Removing Messages - - Removing messages from an archive is done via the -rmm option. - Messages to be deleted are designated by message numbers on the - command-line. - - _Example_ - -% mhonarc -rmm 24 28 39 48 -Removing messages from ./maillist.html ... - Removing message 24 - Removing message 28 - Removing message 39 - Removing message 48 - -Writing mail ... -Writing tmp/maillist.html ... -Writing tmp/threads.html ... -45 messages - - _________________________________________________________________ - -Message Numbers - - Normally, you will never have to worry about message numbers unless - you want to remove messages from an archive. Therefore, you will need - to know how _MHonArc_ assigns message numbers when processing - messages. - - When a message is processed, the smallest available number is assigned - to it, starting with 0. The number assigned to a message becomes part - of the filename for the HTML version of the message (eg. - msg00042.html). - - To avoid message number conflicts, _MHonArc_ determines the smallest - available number by finding the largest assigned number and adding one - to it. - - _________________________________________________________________ - -Scanning an Archive - - You will quickly find out that finding the message numbers for a - messages you want to remove can be a cumbersome task if all you have - to work with are the message filenames. To ease this task, _MHonArc_ - gives you the ability to scan an archives contents via the -scan - command-line option. - - Example - -% mhonarc -scan -100 messages in .: - -Msg # YY/MM/DD From Subject ------ -------- --------------- --------------------------------------------- - 513 95/02/09 Rick Silterra EDComment(sic) - 517 95/02/09 Earl Hood Re: DTD2HTML - 512 95/02/09 Earl Hood Re: edc2html - 516 95/02/09 John Barnum Re: DTD2HTML - 515 95/02/09 Earl Hood Re: DTD2HTML - 511 95/02/09 Rick Silterra edc2html - 514 95/02/08 John Barnum DTD2HTML - 510 95/02/06 jflores mhonarc_diagnostics.doc.html - 509 95/02/06 web Dr.Web: Status Review + Thank You - 508 95/02/05 Earl Hood Re: sgml to html converters - 507 95/02/03 Aileen Barry sgml to html converters - 506 95/01/28 Earl Hood Re: MHonarc: Deleting Messages from an archiv - 505 95/01/28 Floyd Moore MHonarc: Deleting Messages from an archive - 504 95/01/25 Earl Hood Re: MHonArc - 503 95/01/25 Earl Hood Re: MHonArc -... - - The messages are listed in the same order as they are listed in the - archive's index page. You will notice that the list order does not - necessarily correspond with message number order. If you always want - the messages listed in message number order when scanning, use the - following: - -% mhonarc -scan -nosort -noreverse -82 messages in .: - -Msg # YY/MM/DD From Subject ------ -------- --------------- --------------------------------------------- - 0 94/05/09 Michael O´Sulli Re: Finger within an html - 1 94/04/31 John M. Troyer Re: TROFF to HTML Converters - 2 94/05/04 John D. Kilburg ANNOUNCE: Chimera 1.53 - 3 94/05/17 Stephen Billing Re: government www? - 4 94/05/21 C. Emory Tate Re: government www? - 5 94/05/24 Daniel W. Conno Re: Comments on HTML 2.0 document/DTD - 6 94/05/24 Dan Connolly Re: Validating HTML documents: - 7 94/05/25 Henrik Frystyk CERN Common World-Wide Web Library 2.16pre2 A - 8 94/06/04 Denesh Bhabuta Re: Atari on www (revisited) - 9 94/06/07 Dale Newfield ANNOUNCE: Come explore The Edge - SIGGRAPH 94 - 10 94/06/11 Roy T. Fielding Announcing libwww-perl 0.12 -... - - _________________________________________________________________ - - - _________________________________________________________________ - - Index Page Customization - - _MHonArc_ creates an index page with links to all mail messages - filtered (unless processing a single message with the -single option). - _MHonArc_ allows you to have complete customization over the - appearance of the index page by setting various resource either - through environment variables, command-line options, or the resource - file. - - _________________________________________________________________ - -Filename - - By default, the filename of the index page is "maillist.html". - However, a different name may be specified with the M2H_IDXFNAME - environment variable, the IDXFNAME resource element, or the -idxfname - command-line option. - - _________________________________________________________________ - -Beginning Markup - - _MHonArc_ allows you to completely override the begining markup of the - index page. I.e. You can control the opening tag, the HEAD - element contents, the opening tag, etc. Therefore, if you are - not satisfied with the default behavior of how the TITLE resource is - used, or have other needs that require control on the beginning - markup, you can set the IDXPGBEGIN resource file element. - - IDXPGBEGIN - - The best way to show how the IDXPGBEGIN works, the following - represents the default setting _MHonArc_ uses: - - - - - -$IDXTITLE$ - - -

          $IDXTITLE$

          -
          - - _NOTE_ - Technically, setting the TITLE resource, via the M2H_TITLE - environment variable, the TITLE resource element, or the -title - command-line option, sets the $IDXTITLE$ resource file - variable. - - The resource variables allowed in the IDXPGBEGIN element are the - following: - - * $DOCURL$ -- URL to documentation - * $GMTDATE$ -- Current GMT date. - * $IDXFNAME$ -- Filename of main index page. - * $IDXSIZE$ -- Max number of messages that may be listed in the - index. - * $IDXTITLE$ -- The title of the index page. - * $LOCALDATE$ -- Current local date. - * $NUMOFIDXMSG$ -- Number of message listed. - * $NUMOFMSG$ -- Number of messages in the archive. - * $OUTDIR$ -- Pathname of archive. - * $PROG$ -- Program name. - * $TIDXFNAME$ -- Filename of thread index page. - * $TIDXTITLE$ -- Title of thread index page. - * $VERSION$ -- Program version. - - See Resource Variables for more information on the usage of variables. - - _________________________________________________________________ - -End Markup - - Since _MHonArc_ allows you to control the beginning markup, it makes - sense for it to allow you to control the ending markup. - - IDXPGEND - - The IDXPGEND resource element may be used to define the ending markup - of the index page. The default value is the following: - - - - - - - The resource variables allowed are the same as for IDXPGBEGIN. - - _________________________________________________________________ - -Include Files - - _MHonArc_ allows you to include the contents of files into the index - page via the header and footer resources. - - _NOTE_ - The use of include files is discouraged since the LISTBEGIN and - LISTEND resources can be used to achieve the same results. - Also, the support for the include resource may be removed in - future releases. - - The header file is specified via the M2H_HEADER environment variable, - the HEADER resource element, or the -header command-line option. The - contents of the header file are inserted above the message listing, - and right after the H1 title element. - - _NOTE_ - Filename should not contain the , , and - tags; these tags are automatically provided by _MHonArc_, or - defined by the IDXPGBEGIN resource file element. - - The footer file is specified via the M2H_FOOTER environment variable, - the FOOTER resource element, or the -footer command-line option. The - contents of the footer file are inserted after the message listing. - - _NOTE_ - Filename should not contain the , and tags; - these tags are automatically provided by _MHonArc_, or defined - by the IDXPGEND resource file element. - - The header and footer files allow you to incorporate search-forms, - hyperlinks to other pages, or any other HTML markup you like. - - It is only necessary to specify the header and/or footer files the - first time you create an archive. The contents included from the - header and/or footer files are preserved in any subsequent additions - to the archive. Only respecify the header and/or footer files if you - need to make changes to the header/footer contents. - - _________________________________________________________________ - -Listing Layout - - _MHonArc_ lists messages in the order specified by the various sort - options. However, you have complete control on how the message listing - are formatted via the LISTBEGIN, LITEMPLATE, and LISTEND resource - elements in the Resource File. These elements allow you to specify the - HTML markup to use in the index page. - - LISTBEGIN - - The LISTBEGIN resource element specifies the text to begin the message - list. The text can be any valid HTML markup. Plus, _MHonArc_ defines - the following variables you may use which get expanded at run-time: - - * $DOCURL$ -- URL to documentation - * $GMTDATE$ -- Current GMT date. - * $IDXFNAME$ -- Filename of main index page. - * $IDXSIZE$ -- Max number of messages that may be listed in the - index. - * $IDXTITLE$ -- The title of the index page. - * $LOCALDATE$ -- Current local date. - * $NUMOFIDXMSG$ -- Number of message listed. - * $NUMOFMSG$ -- Number of messages in the archive. - * $OUTDIR$ -- Pathname of archive. - * $PROG$ -- Program name. - * $TIDXFNAME$ -- Filename of thread index page. - * $TIDXTITLE$ -- Title of thread index page. - * $VERSION$ -- Program version. - - _MHonArc_'s LISTBEGIN default value is the following: - - - -
          -
            - - - If the NOTHREAD resource is set, the following is the default value: - - -
            -
              - - - LITEMPLATE - - The LITEMPLATE resoure element defines the HTML text to represent each - message list item. You may use the following variables which are - expanded at runtime: - - * $A_ATTR$ -- The NAME and HREF attributes to use in an anchor to - link to the archived message. The NAME attribute links the - messages to the index page. - * $A_HREF$ -- The HREF attribute to use in an anchor to link to the - archived message. - * $A_NAME$ -- The NAME attributes to use in an anchor for messages - to link to the index page. - * $DATE$ -- The date of the message. - * $DDMMYY$ -- Message date in dd/mm/yy format. - * $ICON$ -- The context-type sensistive icon. See Icons for - information. - * $ICONURL$ -- The URL to the context-type sensistive icon. See - Icons for information. - * $MMDDYY$ -- Message date in mm/dd/yy format. - * $NUMFOLUP$ -- Number of follow-ups for the given message. - * $FROM$ -- The complete text in the From: field of the message. - * $FROMADDR$ -- The e-mail address in the From: field of the - message. - * $FROMNAME$ -- The English name of the person in the From: field of - the message. If no English name is found, the username specified - in the e-mail address is used. - * $MSGNUM$ -- The message numbers assigned to the message by - _MHonArc_. - * $ORDNUM$ -- The current listing number of the message. - * $SUBJECT$ -- The subject text of the message wrapped in an anchor - element that hyperlinks to the message. - * $SUBJECTNA$ -- The subject text of the message without the anchor - element. - * $YYMMDD$ -- Message date in yy/mm/dd format. - - _NOTE_ - Do not specify $A_ATTR$, $A_NAME, and $SUBJECT$ together in the - LITEMPLATE element. Since all of these variables contain the - NAME atrribute. Invalid HTML will be created since multiple - anchors will have the same NAME identifier. - - LITEMPLATE's default value is the following: - - -
            • $SUBJECT$ -
              • From: $FROM$
              -
            • -
              - - LISTEND - - The LISTEND resource element specifies the text to use to end the - message list. The text can be any valid HTML markup. LISTEND may - contain the same variables as LISTBEGIN. - - LISTEND's default value is the following: - - -
            - - - _________________________________________________________________ - -Icons - - _MHonArc_ supports the ability to insert icons in the index page for - each message based on the message's content-type. For example: You can - have text/plain messages use a different icon than text/html messages. - - Defining Icons - - To specify the icons for _MHonArc_ to use, you use the ICONS resource - element in the Resource File. The format of each line in the ICONS - element is as follows: - - __:__ - - __ represents a MIME content-type. __ is - the URL to the icon. The special content-type called "unknown" may be - defined to specify the icon to use for non-recognized content-types. - If unknown is not defined, the text/plain icon is used for unknown - content types. - - Example - - -audio/basic:http://foo.org/gifs/gsound.gif -image/gif:http://foo.org/gifs/gimage.gif -image/jpeg:http://foo.org/gifs/gimage.gif -image/tiff:http://foo.org/gifs/ggraphic.gif -multipart/alternative:http://foo.org/gifs/gmulti.gif -multipart/digest:http://foo.org/gifs/gtext.gif -multipart/mixed:http://foo.org/gifs/gdoc2.gif -multipart/parallel:http://foo.org/gifs/gdoc.gif -text/richtext:http://foo.org/gifs/gdoc.gif -text/html:http://foo.org/gifs/gdoc.gif -text/plain:http://foo.org/gifs/gletter.gif -unknown:http://foo.org/gifs/gunknown.gif -video/mpeg:http://foo.org/gifs/gmovie.gif - - - Using Icons - - In order to incorporate icons into the index page, insert the $ICON$ - variable into the LITEMPLATE resource element. - - Example - - -$ICONURL$$SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
            -
            - - The $ICON$ variable expands to the IMG HTML element with the - appropriate URL in the SRC attribute to the icon. The ALT attribute of - the IMG element contains the content-type of the message, surrounded - by []'s, for use with text based browsers. - - $ICONURL$ may also be used if you want redefine the format of the IMG - element. - - Example - - -* $SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
            -
            - - This example overrides what is normally used in the ALT attribute. - - _________________________________________________________________ - -Examples - - Example 1 - - It may be easier to see how the LISTBEGIN, LITEMPLATE, LISTEND - resource elements work when declared together: - - - - -
            -
              - - - -
            • $SUBJECT$ -
              • From: $FROM$
              -
            • -
              - - -
            - - - Example 2 - - Here's another example that changes the layout into a more compact - listing, adds Icons usage, and adds a time stamp information on when - the index page was last updated: - - -
            -Last update: $CURDATE$
            -$NUMOFMSG$ messages
            -
            -

            -

            -

            -Messages listed in chronological order. Listing format is the following: -

            -* -Subject -(# of follow-ups) -From. -
            -

            -


            -
            - - -* $SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
            -
            - - - - - _________________________________________________________________ - - - _________________________________________________________________ - - Message Customization - - This sections shows how to customize the appearance of messages when - converted to HTML. - - _________________________________________________________________ - -Beginning Markup - - _MHonArc_ allows you to completely override the begining markup of the - message pages. I.e. You can control the opening tag, the HEAD - element contents, the opening tag, etc. Therefore, if you are - not satisfied with the default markup used, or have other needs that - require control on the beginning markup, you can set the MSGPGBEGIN - resource file element. - - MSGPGBEGIN - - The MSGPGBEGIN resource file element has the default value: - - - - - -$SUBJECTNA:72$ - - - - - - The following variables may be used in the MSGPGBEGIN element: - - * $DATE$ -- Message date. - * $DDMMYY$ -- Message date in dd/mm/yy format. - * $DOCURL$ -- URL to documentation. - * $FROM$ -- Contents of From field of message. - * $FROMADDR$ -- E-mail address contained in From field of message. - * $FROMNAME$ -- "English" name contained in From field of message. - * $GMTDATE$ -- Current GMT date. - * $IDXFNAME$ -- Filename of main index page. - * $IDXSIZE$ -- Max number of messages that may be listed in the - index. - * $IDXTITLE$ -- The title of the index page. - * $LOCALDATE$ -- Current local date. - * $MMDDYY$ -- Message date in mm/dd/yy format. - * $MSGID$ -- Message ID of message. - * $MSGNUM$ -- Number assigned to message by _MHonArc_. - * $NUMOFIDXMSG$ -- Number of message listed. - * $NUMOFMSG$ -- Number of messages in the archive. - * $OUTDIR$ -- Pathname of archive. - * $PROG$ -- Program name. - * $SUBJECTNA$ -- Message subject text. - * $TIDXFNAME$ -- Filename of thread index page. - * $TIDXTITLE$ -- Title of thread index page. - * $VERSION$ -- Program version. - * $YYMMDD$ -- Message date in yy/mm/dd format. - - _________________________________________________________________ - -End Markup - - The ending markup of messages can be controlled by the MSGPGEND - resource file element. - - MSGPGEND - - The MSGPGEND resource element may be used to define the ending markup - of the message pages. The default value is the following: - - - - - - - The resource variables allowed are the same as for MSGPGBEGIN. - - _________________________________________________________________ - -Header and Footer - - The MSGHEAD resource represents HTML text that should be inserted at - the very beginning of each converted message. The MSGFOOT resource - represents HTML text that should be appended to the end of each - converted message. The default value for both resources is empty. The - following variables may be used in the MSGHEAD and MSGFOOT content: - - * $DATE$ -- Message date. - * $DDMMYY$ -- Message date in dd/mm/yy format. - * $DOCURL$ -- URL to documentation. - * $FROM$ -- Contents of From field of message. - * $FROMADDR$ -- E-mail address contained in From field of message. - * $FROMNAME$ -- "English" name contained in From field of message. - * $GMTDATE$ -- Current GMT date. - * $IDXFNAME$ -- Filename of main index page. - * $IDXSIZE$ -- Max number of messages that may be listed in the - index. - * $IDXTITLE$ -- The title of the index page. - * $LOCALDATE$ -- Current local date. - * $MMDDYY$ -- Message date in mm/dd/yy format. - * $MSGID$ -- Message ID of message. - * $MSGNUM$ -- Number assigned to message by _MHonArc_. - * $OUTDIR$ -- Pathname of archive. - * $PROG$ -- Program name. - * $SUBJECTNA$ -- Message subject text. - * $TIDXFNAME$ -- Filename of thread index page. - * $TIDXTITLE$ -- Title of thread index page. - * $VERSION$ -- Program version. - * $YYMMDD$ -- Message date in yy/mm/dd format. - - _________________________________________________________________ - -Navigational Links - - _MHonArc_ gives you the ability to control the layout of the - navigational links for each message page. Navigational links include - links to previous and next messages, link to main index, link to - thread index, etc. The layout of the navigational links are controlled - by two resource file elements: TOPLINKS and BOTLINKS. - - TOPLINKS - - The TOPLINKS resource element defines the layout of the navigational - links at the top of each message page. The markup defined, will appear - after the MSGHEAD data and before the filtered message data. - - The default value for TOPLINKS is the following: - - -
            -$PREVBUTTON$$NEXTBUTTON$[Index][Thread] -
            - - If no thread index is specified, then the thread link markup is - removed. The following variables are available: - - * $DATE$ -- Message date. - * $DDMMYY$ -- Message date in dd/mm/yy format. - * $DOCURL$ -- URL to documentation. - * $FROM$ -- Contents of From field of message. - * $FROMADDR$ -- E-mail address contained in From field of message. - * $FROMNAME$ -- "English" name contained in From field of message. - * $GMTDATE$ -- Current GMT date. - * $IDXFNAME$ -- Filename of main index page. - * $IDXSIZE$ -- Max number of messages that may be listed in the - index. - * $IDXTITLE$ -- The title of the index page. - * $LOCALDATE$ -- Current local date. - * $MMDDYY$ -- Message date in mm/dd/yy format. - * $MSGID$ -- Message ID of message. - * $MSGNUM$ -- Number assigned to message by _MHonArc_. - * $NEXTBUTTON$ -- Next button markup. See Conditional Links for more - information. - * $NEXTFROM$ -- Contenst of From field of the next message according - to the list order of the main index. - * $NEXTFROMADDR$ -- E-mail address contained in From field of the - next message according to the list order of the main index. - * $NEXTFROMNAME$ -- English" name contained in From field of the - next message according to the list order of the main index. - * $NEXTLINK$ -- Next link markup. See Conditional Links for more - information. - * $NEXTMSG$ -- Filename of next message according to the list order - of the main index. - * $NEXTMSGNUM$ -- Number assigned to next message according to the - list order of the main index. - * $NEXTSUBJECT$ -- Subject of next message according to the list - order of the main index. - * $NUMOFIDXMSG$ -- Number of message listed. - * $NUMOFMSG$ -- Number of messages in the archive. - * $PREVBUTTON$ -- Previous button markup. See Conditional Links for - more information. - * $PREVFROM$ -- Contenst of From field of the previous message - according to the list order of the main index. - * $PREVFROMADDR$ -- E-mail address contained in From field of the - previous message according to the list order of the main index. - * $PREVFROMNAME$ -- English" name contained in From field of the - previous message according to the list order of the main index. - * $PREVLINK$ -- Previous link markup. See Conditional Links for more - information. - * $PREVMSG$ -- Filename of previous message according to the list - order of the main index. - * $PREVMSGNUM$ -- Number assigned to previous message according to - the list order of the main index. - * $PREVSUBJECT$ -- Subject of previous message according to the list - order of the main index. - * $PROG$ -- Program name. - * $SUBJECTNA$ -- Message subject text. - * $TIDXFNAME$ -- Filename of thread index page. - * $TIDXTITLE$ -- Title of thread index page. - * $VERSION$ -- Program version. - * $YYMMDD$ -- Message date in yy/mm/dd format. - - BOTLINKS - - The BOTLINKS resource element defines the layout of the navigational - links at the bottom of each message page. The markup defined, will - appear after the filtered message data and any thread links, and - before the MSGFOOT data. - - The default value for BOTLINKS is the following: - - -
            -
              -$PREVLINK$ -$NEXTLINK$ -
            • Index(es): -
                -
              • Main
              • -
              • Thread
              • - - - If no thread index is specified, then the thread link markup is - removed. The variables available for BOTLINKS are the same as for - TOPLINKS. - - Conditional Links - - Since the state of some navigational links can change due the position - of the message in the archive (eg. first and last messages), special - resources exist that allows you to control the markup of some of the - links based upon if the link is valid or not for a given message. - - The resource elements for defining the conditional links are the - following: PREVBUTTON, NEXTBUTTON, PREVLINK, and NEXTLINK, and their - inactive counterparts, PREVBUTTONIA, NEXTBUTTONIA, PREVLINKIA, and - NEXTLINKIA. The appropriate value of these elements (ie. if it is - active, or inactive) are represented by the $PREVBUTTON$, - $NEXTBUTTON$, $PREVLINK$, and $NEXTLINK$ resource file variables, - respectively, which may be used in other resource elements' contents - (TOPLINKS and BOTLINKS in particular). - - The defaults values for each conditional link resource is as follows: - - PREVBUTTON - - -[Prev] - - - NEXTBUTTON - - -[Next] - - - PREVLINK - - -
              • Prev: $PREVSUBJECT$
              • -
                - - NEXTLINK - - -
              • Next: $NEXTSUBJECT$
              • -
                - - All the "IA" elements default to empty content. - - _NOTE_ - The last newline for the PREVBUTTON, NEXTBUTTON, PREVBUTTONIA, - and NEXTBUTTONIA elements is ignored by _MHonArc_. This allows - a "tight" grouping of button links; ie. no space between - buttons. If you desire to have a newline in the content, just - insert a trailing blank line at the end of the element's - content. - - You should note that there is a correlation between the value of the - conditional links elements and the contents of the TOPLINKS and - BOTLINKS elements. - - The following variables may be used within the conditional link - elements. - - * $NEXTFROM$ -- Contenst of From field of the next message according - to the list order of the main index. - * $NEXTFROMADDR$ -- E-mail address contained in From field of the - next message according to the list order of the main index. - * $NEXTFROMNAME$ -- English" name contained in From field of the - next message according to the list order of the main index. - * $NEXTMSG$ -- Filename of next message according to the list order - of the main index. - * $NEXTMSGNUM$ -- Number assigned to next message according to the - list order of the main index. - * $NEXTSUBJECT$ -- Subject of next message according to the list - order of the main index. - * $PREVFROM$ -- Contenst of From field of the previous message - according to the list order of the main index. - * $PREVFROMADDR$ -- E-mail address contained in From field of the - previous message according to the list order of the main index. - * $PREVFROMNAME$ -- English" name contained in From field of the - previous message according to the list order of the main index. - * $PREVMSG$ -- Filename of previous message according to the list - order of the main index. - * $PREVMSGNUM$ -- Number assigned to previous message according to - the list order of the main index. - * $PREVSUBJECT$ -- Subject of previous message according to the list - order of the main index. - - _WARNING_ - Never include conditional link variables ($PREVBUTTON$, - $NEXTBUTTON$, $PREVLINK$, and $NEXTLINK$) in conditional link - element content. This will cause an infinite loop during - execution and will eventually lead to a crash due to a lack of - memory. - - _________________________________________________________________ - -Message Layout - - Defining the format for the actual mail message data is divided into - two parts: the message head and the message body. Customizing the - message header markup is described in this section, but due to the - nature of how messages are processed, the message body format is - controlled by the various MIME filters directly (see the section on - MIME for further details). - - Excluding Fields - - The EXCS resource allows you to specify what fields should be excluded - in the HTML output. - - EXCS - - Each line of the EXCS element specifies a mail header field to exclude - in the converted HTML output. Each line is treated as a Perl regular - expression (_NOTE_: _the regular expression is already anchored to the - begining of the line_). - - The default value for EXCS is the following: - - -content- -errors-to -forward -lines -message-id -mime- -nntp- -originator -path -precedence -received -replied -return-path -status -via -x- - - - Any fields you specify for the EXCS resource will augment the default - list, unless the "Override" attribute is specified. If "Override" is - specified, the default list is discarded along with any other lists - specified from previous EXCS elements; and only header fields - specified in the EXCS element are excluded. - - Field Order - - The FIELDORDER resource allows you to control the order the message - header fields appear in the HTML output. - - FIELDORDER - - Each line of the FIELDORDER element is the exact case-insensitive name - of a message header field. The order the fields are listed is the - order they will appear in the filtered message. The special field - value "-extra-" represents all fields not explicitly specified in the - FIELDORDER element and not excluded by the EXCS element. Extra fields - are listed in sorted order. - - The following represents the default value of the FIELDORDER resource: - - -to -subject -from -date --extra- - - - Field Formatting - - The FIELDSTYLES and LABELSTYLES resources allow to control how each - message header field is formatted. - - FIELDSTYLES - - Each line in the FIELDSTYLES element defines HTML elements to wrap - around the field text in mail headers (e.g. "To: field text", "From: - field text"). The format of each line is "field_name:html_element". - This specifies to wrap html_element around the text associated with - field_name. If html_element is empty, then the field text is not - wrapped in any element. - - _MHonArc_ defines a special field_name called "-default-". This is - default HTML element to wrap field text in if no explicit specific - element is defined for the label. - - field_name must be the exact name of a header field name, but - character case is ignored. - - The default value of FIELDSTYLES is the following: - - --default- - - - LABELSTYLES - - Each line in the LABELSTYLES element defines HTML elements to wrap - around labels in mail headers (e.g. "To:", "From:"). The format of - each line is "field_name:html_element". This specifies to wrap - html_element around field_name. If html_element is empty, then the - label is not wrapped in any element. - - _MHonArc_ defines a special field_name called "-default-". This is - default HTML element to wrap a label in if no explicit specific - element is defined for the label. - - field_name must be the exact name of a header field name, but - character case is ignored. - - The default value of LABELSTYLES is the following: - - --default-:em - - - _________________________________________________________________ - -Other Resources - - E-mail Links - - MAILTOURL - - URL to use for e-mail address hyperlinks in e-mail message header - fields. The following variables are defined for the MAILTOURL - resource: - - * $FROM$ -- Who the message is from. - * $MSGID$ -- Message ID of the message. - * $SUBJECT$ -- The subject of the message. - * $TO$ -- Destination e-mail address of link. - - _MHonArc_ will use the following URL by default: "mailto:$TO$". - - _NOTE_ - The MAILTOURL resource has different rules for variable - expansion. If a variable does not exactly match the set of - variables available for the MAILTOURL, the variable text will - be taken literally as part of the element content. Therefore, a - single "$" can be used to represent a "$" character. - - Also, variables in the MAILTOURL should _NOT_ have ":NU" - modifier. This will prevent the variables from be recognized. - _MHonArc_ will automatically treat the replacement value as a - part of a URL string. - - _________________________________________________________________ - - - _________________________________________________________________ - - MIME - - _MHonArc_ has support for e-mail messages with _Multipurpose Internet - Mail Extensions_ (MIME) as defined in RFC 1521. _MHonArc_ handles the - filtering of the various content-types used in MIME in a modular - fashion. Since new content-types are occasionally defined for MIME, - this modularity allows users to add new filters to accomodate new - content-types. Also, filters can be hooked in to override _MHonArc's_ - default filters, or provide _MHonArc_ with the ability to process - existing content-types that it cannot handle currently. - - _________________________________________________________________ - -Default Filters - - The default filters provided by _MHonArc_ supports the following MIME - content-types, which may be overriden by user-defined filters: - - * application/* - * audio/* - * image/* - * message/news - * message/partial - * message/rfc822 - * multipart/alternative - * multipart/digest - * multipart/mixed - * multipart/parallel - * text/html - * text/plain - * text/setext - * video/* - - For more information on how to write your filters, or replace existing - filters, see Writing Filters. - - The next sections describes how _MHonArc_ processes the content-types - listed above. - - application/* - - _MHonArc_ extracts the data into a separate file and puts a hyperlink - to the file into the HTMLized message. - - By default, _MHonArc_ ignores any filename specification (the "_name_" - attribute as defined in the Content-Type header field) given in the - message when writing the data to disk. _MHonArc_ generates a unique - filename with an extenstion based upon sub-type. - - If you want _MHonArc_ to use the filename, then you can use the - MIMEARGS resource and specify an argument string of "usename". - - Example: - - -application/postscript:usename - - - If you want _MHonArc_ to use specified filename for all application - types, then use the following: - - -application/*:usename - - - _CAUTION_ - The use of "usename" is discouraged since it can lead to - filename conflicts and security problems. - - Here is the current list of _application_ sub-types (with their - filename extensions) supported by _MHonArc_: - - * mac-binhex40 (hqx) - * octet-stream (bin) - * oda (oda) - * pdf (pdf) - * postscript (ps) - * rtf (rtf) - * x-bcpio (bcpio) - * x-cpio (cpio) - * x-csh (csh) - * x-dvi (dvi) - * x-gtar (gtar) - * x-hdf (hdf) - * x-latex (latex) - * x-mif (mif) - * x-netcdf (cdf) - * x-patch (_no extension_; processed by the text/plain filter) - * x-sh (sh) - * x-shar (shar) - * x-sv4cpio (sv4cpio) - * x-sv4crc (sv4crc) - * x-tar (tar) - * x-tcl (tcl) - * x-tex (tex) - * x-texinfo (texinfo) - * x-troff (roff) - * x-troff-man (man) - * x-troff-me (me) - * x-troff-ms (ms) - * x-ustar (ustar) - * x-wais-source (src) - * zip (zip) - - audio/* - - _MHonArc_ extracts the data into a separate file and puts a hyperlink - to the file into the HTMLized message. The name of the file created - follows the same guidelines mentioned under application/*. - - Here is the current list of _audio_ sub-types (with their filename - extensions) supported by _MHonArc_: - - * basic (snd) - * x-aiff (aif) - * x-wav (wav) - - image/* - - _MHonArc_ will extract the data into a separate file and puts a - hyperlink to the file into the HTMLized message. The name of the file - created follows the same guidelines mentioned under application/*. In - addition to the filename specification mentioned under application/*, - an "inline" argument may be declared to instruct _MHonArc_ to inline - the image in the generated HTML. - - Example: - - -image/gif:inline - - - The following examples says to inline XBM images and use the name - attribute as the filename if defined: - - -image/x-xbm:inline usename - - - The following represents the default argument settings used by - _MHonArc_: - - -image/gif:inline -image/x-xbitmap:inline -image/x-xbm:inline - - - Here is the current list of _image_ sub-types (with their filename - extensions) supported by _MHonArc_: - - * gif (gif) - * ief (ief) - * jpeg (jpg) - * tiff (tif) - * x-bmp (bmp) - * x-cmu-raster (ras) - * x-pcx (pcx) - * x-pict (pict) - * x-portable-anymap (pnm) - * x-pnm (pnm) - * x-portable-bitmap (pbm) - * x-pbm (pbm) - * x-portable-graymap (pgm) - * x-pgm (pgm) - * x-portable-pixmap (ppm) - * x-ppm (ppm) - * x-rgb (rgb) - * x-xbitmap (xbm) - * x-xbm (xbm) - * x-xpixmap (xpm) - * x-xpm (xpm) - * x-xwindowdump (xwd) - * x-xwd (xwd) - - If the image is a GIF or XBM (X bitmap), the HTML IMG element will be - used to in-line the image into the HTMLized message. - - message/news - - _message/news_ signifies an included (MIME) USENET news message. The - data associated with a _message/news_ part is processed by _MHonArc_ - in the same manner as a regular mail message. - - message/partial - - _message/partial_ signifies that the content is a single part of a - message split into multiple mail messages. _message/partial_ is - treated in the same manner as text/plain. - - message/rfc822 - - _message/rfc822_ signifies an included (MIME) mail message. The data - associated with a _message/rfc822_ part is processed by _MHonArc_ in - the same manner as a regular mail message. - - multipart/alternative - - _multipart/alternative_ signifies multiple content-types with the same - (or similiar) information. _MHonArc_ processes only the latest part - that has a content-type filter. - - multipart/digest - - mulltipart/digest signifies a series of included mail messages. Each - part is processed in the same manner as message/rfc822 unless an - explicit content-type is specifed for each part. - - multipart/mixed - - _multipart/mixed_ signifies data with multiple content-types. _MHonArc_ - extracts each part and calls the appropriate content-type filter for - each part, if defined. - - multipart/parallel - - _multipart/parallel_ is processed in the same manner as - multipart/mixed. - - text/html - - _text/html_ signifies that the data is HTML markup. The data as left - "as is" with the exception of some processing to legally include the - HTML into the HTMLized mail message. I.e. _MHonArc_ removes the HEAD - an BODY tags, the TITLE element will be replaced with an ADDRESS - element surrounded by HR's, and the BASE element URL will be - propogated to relative URLs. - - text/plain - - _text/plain_ signifies ASCII character data. In the HTMLized message, - the data is wrapped in a PRE element with special characters (< > &) - converted to entity references. _MHonArc_ will also make any URLs into - hyperlinks. The following URL types are recognized: - - * http://... - * ftp://... - * afs://... - * wais://... - * telnet://... - * gopher://... - * news:... - * nntp:... - * mid:... - * cid:... - * mailto:... - * prospero:... - - text/setext - - _text/setext_ signifies "_structure enhanced text_". The data is - converted into HTML containing hyperlinks as defined by the _setext_ - data. For more information on _setext_, see - . - - video/* - - _MHonArc_ extracts the data into a separate file and puts a hyperlink - to the file into the HTMLized message. The name of the file created - follows the same guidelines mentioned under application/*. - - Here is the current list of _video_ sub-types (with their filename - extensions) supported by _MHonArc_: - - * mpeg (mpg) - * quicktime (mov) - * x-msvideo (avi) - * x-sgi-movie (movie) - - _________________________________________________________________ - -Non-MIME Messages - - Messages that do not contain a MIME Content-Type header field are - processed as text/plain messages. - - _________________________________________________________________ - -Writing Filters - - If you want to write your own filter for use in _MHonArc_, you need to - know the Perl programming language. The following information assumes - you know Perl. To learn how to hook in your filters into _MHonArc_, - see Specifying Filters. - - Function Interface of Filter - - _MHonArc_ interfaces with MIME filters by calling a routine with a - specific set of arguments. The prototype of the interface routine is - as follows: - -sub filter { - local($head, *fields, $data, $decoded, $argstring) = @_; - - # Filter code here - - # The last statement should be the return value, unless an - # explicit return is done. See the following for the format of the - # return value. -} - - Argument Descriptions - - $head - This is the header text of the message (or body part if called - in a mulitpart message). - - *fields - This is a pointer to an associative array that has broken down - $head into field label/field value components. The keys are the - lower-case representations of the field values. _Example_: If - you would like to retrieve the value of the Content-Type field, - then use the following: $fields{`content-type'}. - - If a field occurs more than once in a header, _MHonArc_ - separates the field values in the associative array by a `\034' - character. To make your filter less likely to break due to - changes in _MHonArc_, you may use the $'X variable instead of - `\034'. - - $data - This is a copy of the message (or body part if called in a - mulitpart message) body. - - $decoded - This flag is set to 1 if _MHonArc_ decoded the message and - $data represents the orginal data before encoded by the sender. - If set to 0, $data has not been decoded. The failure to decode - occurs if _MHonArc_ does not recognizeed the encoding specified - in the Content-Transfer-Encoding field. - - _MHonArc_ has decoded the data for you if it was encoded in - 7-Bit, 8-Bit, Binary, Quoted-Printable, Base64, or X-Uuencode. - - $argstring - This is an optional argument string that may be used to modify - the behavior of the filter. The format of this string is - determined by the filter itself. - - The value of the string is set by the MIMEARGS resource. - - Return Value - - The return value is treated as an array. The first item in the array - is a string representing the HTML markup to insert in the HTMLized - message. An empty string may be returned to tell _MHonArc_ that the - routine was unable to filter data. - - Any other array items are treated as names of any files that were - generated by the filter. _MHonArc_ needs to keep track if any extra - files that a filter may generate in order for _MHonArc_ to delete - those files if the message gets removed from the archive. - - Filter Writing Tips - - The following recommendations/tips are given to help you write - filters: - - * Qualify your filter in its own package. This eliminates possible - variable/routine conflicts with _MHonArc_. - * If the filter creates derived files (like the image filters), you - may use the variable $'OUTDIR to determine the location of the - mail archive. - _NOTE_: _Do not include_ $'OUTDIR _as part as the filename that is - returned to_ _MHonArc_. _If the filter does create files, just - return the base name_. - * Look at the default filters contained in the distribution of - _MHonArc_. You can use these as templates for writing your own. - * Make sure your Perl source file ends with a true statement (like - "1;"). _MHonArc_ just performs a require on the file, and if the - file does not return true, Perl will abort execution. - - Using C - - If a MIME filter requires the utilization of a C program, or other - non-Perl executable, a Perl wrapper must be written for the program - in-order to interface with _MHonArc_. The wrapper must follow the - rules as specified in Function Interface of Filter. - - _________________________________________________________________ - -Specifying Filters - - Adding new filters, or overriding existing ones, are done via the - Resource File. The two resources for specifying and controlling MIME - filters are MIMEFILTERS and MIMEARGS. - - MIMEFILTERS - - The resource element MIMEFILTERS in the Resource File is used to hook - in user specifed filters into _MHonArc_. The syntax for each line of - the the MIMEFILTERS element is as follows: - - __:__:__ - - The definition of each colon-separated value is as follows: - - __ - The MIME content-type the filter processes. - - __ - The actual routine name of the filter. The name should be fully - qualified by the package it is definedi (e.g. - "mypackage'filter"). - - __ - The name of the file that defines __. If the file - is not a full pathname, _MHonArc_ finds the file by looking in - the standard include paths of Perl, and the paths specified by - the PERLINC resource element. - - Any whitespace is stripped out before processing. - - Example - - The following represents the default value of MIMEFILTERS: - - -application/mac-binhex40:m2h_external'filter:mhexternal.pl -application/octet-stream:m2h_external'filter:mhexternal.pl -application/oda:m2h_external'filter:mhexternal.pl -application/pdf:m2h_external'filter:mhexternal.pl -application/postscript:m2h_external'filter:mhexternal.pl -application/rtf:m2h_external'filter:mhexternal.pl -application/x-bcpio:m2h_external'filter:mhexternal.pl -application/x-cpio:m2h_external'filter:mhexternal.pl -application/x-csh:m2h_external'filter:mhexternal.pl -application/x-dvi:m2h_external'filter:mhexternal.pl -application/x-gtar:m2h_external'filter:mhexternal.pl -application/x-hdf:m2h_external'filter:mhexternal.pl -application/x-latex:m2h_external'filter:mhexternal.pl -application/x-mif:m2h_external'filter:mhexternal.pl -application/x-netcdf:m2h_external'filter:mhexternal.pl -application/x-patch:m2h_text_plain'filter:mhtxtplain.pl -application/x-sh:m2h_external'filter:mhexternal.pl -application/x-shar:m2h_external'filter:mhexternal.pl -application/x-sv4cpio:m2h_external'filter:mhexternal.pl -application/x-sv4crc:m2h_external'filter:mhexternal.pl -application/x-tar:m2h_external'filter:mhexternal.pl -application/x-tcl:m2h_external'filter:mhexternal.pl -application/x-tex:m2h_external'filter:mhexternal.pl -application/x-texinfo:m2h_external'filter:mhexternal.pl -application/x-troff-man:m2h_external'filter:mhexternal.pl -application/x-troff-me:m2h_external'filter:mhexternal.pl -application/x-troff-ms:m2h_external'filter:mhexternal.pl -application/x-troff:m2h_external'filter:mhexternal.pl -application/x-ustar:m2h_external'filter:mhexternal.pl -application/x-wais-source:m2h_external'filter:mhexternal.pl -application/zip:m2h_external'filter:mhexternal.pl -audio/basic:m2h_external'filter:mhexternal.pl -audio/x-aiff:m2h_external'filter:mhexternal.pl -audio/x-wav:m2h_external'filter:mhexternal.pl -image/gif:m2h_external'filter:mhexternal.pl -image/ief:m2h_external'filter:mhexternal.pl -image/jpeg:m2h_external'filter:mhexternal.pl -image/tiff:m2h_external'filter:mhexternal.pl -image/x-bmp:m2h_external'filter:mhexternal.pl -image/x-cmu-raster:m2h_external'filter:mhexternal.pl -image/x-pbm:m2h_external'filter:mhexternal.pl -image/x-pcx:m2h_external'filter:mhexternal.pl -image/x-pgm:m2h_external'filter:mhexternal.pl -image/x-pict:m2h_external'filter:mhexternal.pl -image/x-pnm:m2h_external'filter:mhexternal.pl -image/x-portable-anymap:m2h_external'filter:mhexternal.pl -image/x-portable-bitmap:m2h_external'filter:mhexternal.pl -image/x-portable-graymap:m2h_external'filter:mhexternal.pl -image/x-portable-pixmap:m2h_external'filter:mhexternal.pl -image/x-ppm:m2h_external'filter:mhexternal.pl -image/x-rgb:m2h_external'filter:mhexternal.pl -image/x-xbitmap:m2h_external'filter:mhexternal.pl -image/x-xbm:m2h_external'filter:mhexternal.pl -image/x-xpixmap:m2h_external'filter:mhexternal.pl -image/x-xpm:m2h_external'filter:mhexternal.pl -image/x-xwd:m2h_external'filter:mhexternal.pl -image/x-xwindowdump:m2h_external'filter:mhexternal.pl -message/partial:m2h_text_plain'filter:mhtxtplain.pl -text/html:m2h_text_html'filter:mhtxthtml.pl -text/plain:m2h_text_plain'filter:mhtxtplain.pl -text/richtext:m2h_text_plain'filter:mhtxtplain.pl -text/setext:m2h_text_setext'filter:mhtxtsetext.pl -text/tab-separated-values:m2h_text_plain'filter:mhtxtplain.pl -text/x-html:m2h_text_html'filter:mhtxthtml.pl -text/x-setext:m2h_text_setext'filter:mhtxtsetext.pl -video/mpeg:m2h_external'filter:mhexternal.pl -video/quicktime:m2h_external'filter:mhexternal.pl -video/x-msvideo:m2h_external'filter:mhexternal.pl -video/x-sgi-movie:m2h_external'filter:mhexternal.pl - - - MIMEARGS - - The MIMEARGS resource may be used to pass optional arguments to - filters to control their behavior. Arguments may be defined on a per - content-type basis, or for a specific filter itself. The syntax for - each line of the the MIMEARGS element is as follows: - - __:__ - - Or, - - __:__ - - The format of argument strings is dependent on the filter that - processes __ or by the specified filter, - __. - - If an argument string is defined for a filter explicitly and for a - content-type that the filter processes, the content-type string will - override the filter string. - - Examples - - The following example represents the default settings used by - _MHonArc_: - - -image/gif:inline -image/x-xbitmap:inline -image/x-xbm:inline - - - The following example tells the filter that deals handles - content-types that cannot be converted directly into HTML to use the - "_name_" attribute as defined in the Content-Type header field as the - name of the file generated: - - -m2h_external'filter:usename - - - The following examples says to inline XBM images and use the name - attribute as the filename if defined: - - -image/x-xbm:inline usename - - - _________________________________________________________________ - - - _________________________________________________________________ - - Gory Details - - This sections explain in detail how _MHonArc_ functions. Knowing the - material covered in this section may help you when trouble shooting. - - _________________________________________________________________ - -OS Detection - - _MHonArc_ will automatically detect which operating system it is - running under. If the following list of conditions are true, _MHonArc_ - assumes it is running under MS-DOS: - - * The COMSPEC environment variable is defined. - * The value of the COMSPEC environment variable is a legal MS-DOS - pathname. - * The value of the COMSPEC environment variable is an executable - file. - - If any of the above conditions is false, _MHonArc_ assumes it is - running under Unix. - - _NOTE_ - The previous conditions are used since the conditions will - exist if Perl has been installed on an MS-DOS machine. None of - the above conditions exist when Perl is installed on a Unix - system. - - _________________________________________________________________ - -Processing Steps - - This section describes the steps _MHonArc_ performs when - creating/editting an archive. Anytime messages are added or deleted or - the index page layout is changed, _MHonArc_ will perform the following - steps. - - * Creates a lock file. This insures only one _MHonArc_ process is - updating the archive at any given moment. See Archive Integrity - for more information. - * Reads the database file. The name, and location, of the database - file can be explicitly specified via the M2H_DBFILE and M2H_OUTDIR - environment variables or the command-line options -dbfile and - -outdir. Otherwise, the current working directory is used. - _NOTE_: _The database file must be in the same location as the - archive since the _M2H_OUTDIR_ variable and _-outdir_ option also - specify the location of the archive_. - The database file contains data to update any mail threads and the - resource settings when _MHonArc_ was last invoked. This allows new - messages to contain the same formatting/resource specifications as - existing messages in the archive without having to re-specify the - resources each time new messages are added. Resources defined in - the database file override the environment variables. - _NOTE_: _If no database file is found, MHonArc will create a new - archive_. - * Read the _MHonArc_ resource file, _if specified_. The resource - file will override any settings contained in the database file. - * Read the settings specified on the command-line. Command-line - options override any settings in the database and/or resource - file. - * Update archive. - * Rewrites the index pages to reflect the update. - * Writes a new database file containing the new state of the archive - and all (new) resource settings. - - Normally, knowing all the previous steps is unnecessary. However, it - may be useful to be aware of them if unexpected behavior, or errors, - occur. - - _________________________________________________________________ - -Archive Integrity - - _MHonArc_ applies safeguards to try to insure that a mail archive does - not get corrupted due to exceptional circumstances. _MHonArc_ does the - following to insure a mail archive does not get corrupted: - - * _MHonArc_ creates a lock file, ".mhonarc.lck", when - creating/updating an archive. The lock file insures that only one - _MHonArc_ process is modifying an archive at any given moment. The - -locktries command-line option, or the M2H_LOCKTRIES environment - variable, allows you to control how long a given _MHonArc_ process - will wait if an archive is currently locked. If _MHonArc_ can not - lock the archive after the specified number of tries, _MHonArc_ - will exit, unless the -force option is specified. - * _MHonArc_ will ignore the following signals once messages are - actually being written to disk: SIGABRT, SIGHUP, SIGINT, SIGQUIT, - SIGPIPE, SIGTERM. Possible archive corruption can still occur if a - SIGKILL signal is received since SIGKILLs are uncatchable. A - SIGKILL will also prevent _MHonArc_ from deleting the lock file. - - _________________________________________________________________ - -File Formats - - Database File - - The _MHonArc_ database file is actual Perl code. _MHonArc_ requires it - like any other Perl library to load in the contents of the database. - - _CAUTION_ - You should never modify the database file by hand. Changing the - file by hand could cause future incorrect/unpredictable - behavior when processing the archive. - - Index and Message Files - - The indexes and message files are legal HTML documents. However, - manual editting of the documents is discouraged. The documents contain - special comment declarations. The comment declarations act as markers - which allow _MHonArc_ to correctly edit the documents when needed. - - The comment declarations look like the following: - - - - - -... - - Derived Files - - Derived files are files that are generated by the MIME filters. These - files are created when the data being processed in messages cannot be - converted to HTML (eg. images, postscript, video, binaries). The - format of these files depend on the content-type of the data. - - _________________________________________________________________ - -Notes - - * Here is the explicit order of decreasing precedence when setting - resources/options: - + command-line options (_highest precedence_) - + resource file - + database file - + environment variables (_lowest precedence_) - * Mail thread detection is dependent upon the mail messages - containing the message id(s) of referenced messages. Most mailers - _reply function_ will automatically include the message id of the - message being replied to. - * All mail message being converted into HTML are stored in memory - before they are written to disk. This can eat up much memory if - many mail messages are being converted. If you are processing - multiple mailboxes/folders and worried about memory, you can try - the following: - + Invoke _MHonArc_ on each one separately using the -add - option. - + Or, invoke _MHonArc_ with the -savemem option. - * The database file, and the index pages, are completely rewritten - evertime new messages are added. This may cause slight slow-downs - when archives become very large. - * When reading _MH_ mail folders, mail message are assumed to have - numeric filenames. - * When sorting by date, _MHonArc_ tries to use the date listed in - the first _Received_ field of the message. If no _Received_ field - exists, than the _Date_ field is used. - * No distinction is made, in the output, on which messages came from - which mail folder if multiple mail folders are processed. - * _MHonArc_ can probably be modified to handle other types of - mailers (which has been done since the original version only - supported _MH_ mail folders). The MSGSEP resource gives - flexibility in processing Unix style mailbox files. - - _________________________________________________________________ - - - _________________________________________________________________ - - Diagnostics - - Three types of messages exist in _MHonArc_: _Informative_ messages, - _Warnings_, and _Errors_. _Informative_ messages give you the current - status of _MHonArc_'s execution. _Warnings_ signify undesired - conditions, but are _not_ critical in _MHonArc_'s exection. _Errors_ - signify critical conditions that inhibit _MHonArc_ from finishing its - task. - - Another set of messages exists that are generated from the Perl - interpreter itself. _MHonArc_ tries its best to catch any conditions - that may cause Perl to abnormally abort, but conditions may arise - where this is not possible. - - This section describes the various diagnostics _MHonArc_ may produce - and messages Perl may produce. - - _________________________________________________________________ - -Informative messages - - Informative messages may be suppressed via the -quiet command-line - option. Only the more important Informative messages are listed here. - - Could not process message with given Content-Type: ... - - _MHonArc_ will output this statement _in_ filtered mail messages for - content-types it is unable to process. See Default Filters in MIME for - content-types that _MHonArc_ supports by default. See Writing Filters - for adding new filters into _MHonArc_. - - This is the only Informative message that does not go to standard - output, but into the actual filtered mail message. - - No new messages - - No mail messages exist when performing an add operation to an archive. - This can occur if an empty _MH_ mail folder, or empty mailbox file, is - passed to _MHonArc_. - - Requiring MIME filter libraries ... - - Indicates _MHonArc_ is loading external libraries for filtering mail - messages. _MHonArc_ will output each library it loads. See MIME for - more information of filter libraries. - - Trying to lock mail archive ... - - The statement means that a lock file is in place for the archive you - are trying to update. Normally, an existing lock file implies that - another _MHonArc_ process is currently using the archive, and other - _MHonArc_ processes will wait awhile to see if the archive will be - unlocked. - - However, there are times when a lock file exists, but no _MHonArc_ - process is modifying the archive. This can occur if _MHonArc_ is - abnormally terminated. If you know that no other _MHonArc_ process is - editting the archive you are try to modify, then manually remove the - lock file or use the -force option. - - See Archive Integrity for more information. - - _________________________________________________________________ - -Warnings - - Warning messages denote some undesired event occurred, but the event - is not severe enough to cause program termination. - - Warning: Could not find date for message - - _MHonArc_ was unable to find a received/sent date for a mail message. - With respect to other mail messages, a message with no received/sent - date is first in chronological order. - - Warning: Database () != program () version - - Indicates that the version of _MHonArc_ updating an archive is - different from the version of _MHonArc_ that created the database - file. Problems can arise if the database file changes in format from - different version of _MHonArc_. See the release notes of the _MHonArc_ - distribution if changes in the databse format has effects on older - archives. - - Warning: Unable to create / - - Indicates _MHonArc_ was unable to create the database file __ - for the mail archive created/modified in __. This message can - occur if __ permissions changed during _MHonArc_ execution, - the existing __ is read-only, or the file system is full. - - This message can be severe because no future add operations can be - performed to the archive. - - Warning: Unable to open footer:
                - - _MHonArc_ was unable to open the footer file, _
                _, for - inclusion into the index page. Make sure _
                _ exists, and is - readable by you. - - Warning: Unable to open header:
                - - _MHonArc_ was unable to open the header file, _
                _, for - inclusion into the index page. Make sure _
                _ exists, and is - readable by you. - - Warning: Unable to open - - _MHonArc_ was unable to open the specified mail __ for - reading. Make sure __ exists and is readable (and executable - if a directory) by you. - - Warning: Unable to open message: / - - _MHonArc_ was unable to open the specified _MH_ mail message - _/_ for reading. Make sure _/_ - exists and is readable by you. - - Warning: Unable to open resource file: - - _MHonArc_ was unable to open the resource file, __, for reading. - Make sure __ exists, and is readable by you. - - Warning: Undefined time zone: "" - - _MHonArc_ has found an unrecognized timezone acronym, __, in - a mail message. You can tell _MHonArc_ about other timezone acronyms, - and their hour offset to UTC, by using the TIMEZONES resource element - of the Resource File. - - The timezone UTC (or GMT) is used for an undefined timezone acronym - - _________________________________________________________________ - -Errors - - Errors denote conditions that cause _MHonArc_ to abort execution. - - Some error conditions may cause the _MHonArc_ archive to become - corrupted. If the error occurs when _MHonArc_ is writing files, you - may have to recreate the archive from the original messages. - - ERROR: Database read error of - - An error occured when trying to read an archive's database. The error - can occur if the database file is not readable or the file got - corrupted. - - ERROR: Unable to create - - _MHonArc_ was unable to create __. This message can occur if the - directory being written to is not writable, a read-only file with the - same name exists, or the file system is full. - - ERROR: Unable to create after <#> tries - - The statement means that a lock file is in place for the archive you - are trying to update. - - Sometimes a lock file exists, but no _MHonArc_ process is modifying - the archive. This can occur if _MHonArc_ is abnormally terminated. If - you know that no other _MHonArc_ process is editting the archive you - are try to modify, then manually remove the lock file or use the - -force option. - - ERROR: Unable to open - - _MHonArc_ was unable to open __ for reading. Make sure __ - exists, and is readable by you. - - ERROR: Unable to require newgetopt.pl - - The newgetopt.pl library is needed for _MHonArc_ to parse the - command-line. newgetopt.pl is part of the standard Perl distribution. - Make sure Perl has been correctly installed at your site. - - ERROR: Unable to require timelocal.pl - - The timelocal.pl library is needed for _MHonArc_ to process dates in - messages. timelocal.pl is part of the standard Perl distribution. Make - sure Perl has been correctly installed at your site. - - ERROR: Unable to require - - This message signifies _MHonArc_ was unable to require the library - __. Make sure you properly installed _MHonArc_ via the - installation program. If __ is your own custom filter, make sure - you properly registered it in the Resource File. See also Specifying - Filters and the PERLINC resource element. - - _________________________________________________________________ - -Perl Messages - - Generally, if execution is aborted and the following error messages - appear, then you will have to manually delete the lock file since - _MHonArc_ will not have the chance to delete the file. - - Can't locate in @INC at line . - - A library that _MHonArc_ tried to load was not found in the Perl - include search paths. This error usually implies that _MHonArc_ was - not installed correctly. Make sure that _MHonArc_ was installed via - the install.me program that is provided in the _MHonArc_ distribution. - - did not return a true value at line . - - If you are using your own MIME filters with _MHonArc_, make sure the - library files return 1. - - _________________________________________________________________ - - - _________________________________________________________________ - - Glossary - - _HTML_ - Hypertext Markup Language. HTML is the main document markup - language for the World Wide Web. - - _MIME_ - Multipurpose Internet Mail Extensions. MIME allows the - transmission of non-ASCII data, and mixed content data, in - electronic mail messages. - - _MH_ - _Message Handler_. MH is a free message handling system - initially developed by the RAND Corporation, with subsequent - development done at the University of Califonia: Irvine. - - _Perl_ - Practical Extraction and Report Language. Perl is an - interpreted programming language suited for processing text and - generating reports. - - _SGML_ - Standard Generalized Markup Language. SGML is a language for - document representation. - - _________________________________________________________________ - - - _________________________________________________________________ - - Contacts - - _________________________________________________________________ - -Mailing List - - A mailing list, mhonarc@rosat.mpe-garching.mpg.de, is available to - provide a discussion forum on the usage and development of _MHonArc_. - Appropriate topics for the list include: usage questions, bug reports, - behavioral enhancements, documentation bugs, and general help. - - To subscribe to the mailing list, send mail to - mhonarc-request@rosat.mpe-garching.mpg.de with the command, - -subscribe - - as the message body. - - If you send mail mhonarc@rosat.mpe-garching.mpg.de, your message will - be distributed to all subscribers on the list. - - The mailing list is archived by Majordomo. You can also use the WWW to - access the archive (with full text search using _glimpse_) at - - - _________________________________________________________________ - -People - - _Earl Hood_ - ehood@isogen.com - Main developer of _MHonArc_. Contact for bug reports, - behavioral enhancements, documentation bugs, and Unix usage - issues. - - _Steve Pacenka_ - sp17@cornell.edu - Contributing developer. Worked on isolating code that would - conflict with MS-DOS. Contact for MS-DOS installation problems - or MS-DOS usage issues. - - _Achim Bohnet_ - ach@rosat.mpe-garching.mpg.de - Contributing developer. Administrator, and maintainer, of the - _MHonArc_ mailing list. - - _________________________________________________________________ - diff --git a/doc/mime.html b/doc/mime.html deleted file mode 100644 index c0af0b1..0000000 --- a/doc/mime.html +++ /dev/null @@ -1,597 +0,0 @@ - - - -MHonArc v1.2.2 -- MIME - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
                - -

                MIME -

                - -

                MHonArc has support for e-mail messages with Multipurpose Internet Mail -Extensions (MIME) as defined in RFC 1521. MHonArc handles the filtering of the -various content-types used in MIME in a modular fashion. Since new -content-types are occasionally defined for MIME, this modularity allows users to -add new filters to accomodate new content-types. Also, filters can be hooked in to -override MHonArc's default filters, or provide MHonArc with the ability to process -existing content-types that it cannot handle currently. -

                -
                -

                Default Filters -

                - -

                The default filters provided by MHonArc supports the following MIME -content-types, which may be overriden by user-defined filters: -

                - -

                For more information on how to write your filters, or replace existing filters, see -Writing Filters. -

                -

                The next sections describes how MHonArc processes the content-types listed -above. -

                -
                -
                - -

                application/* -

                - -

                MHonArc extracts the data into a separate file and puts a hyperlink to the file into -the HTMLized message. -

                -

                By default, MHonArc ignores any filename specification (the "name" attribute as -defined in the Content-Type header field) given in the message when writing -the data to disk. MHonArc generates a unique filename with an extenstion based -upon sub-type. -

                -

                If you want MHonArc to use the filename, then you can use the MIMEARGS -resource and specify an argument string of "usename". -

                -

                Example: -

                -
                <MIMEARGS>
                -application/postscript:usename
                -</MIMEARGS>
                -
                -
                - -

                If you want MHonArc to use specified filename for all application types, then use -the following: -

                -
                <MIMEARGS>
                -application/*:usename
                -</MIMEARGS>
                -
                -
                - -
                -
                CAUTION - -

                The use of "usename" is discouraged since it can lead to filename conflicts -and security problems. -

                -

                Here is the current list of application sub-types (with their filename extensions) -supported by MHonArc: -

                -
                  -
                • mac-binhex40 (hqx) -
                • octet-stream (bin) -
                • oda (oda) -
                • pdf (pdf) -
                • postscript (ps) -
                • rtf (rtf) -
                • x-bcpio (bcpio) -
                • x-cpio (cpio) -
                • x-csh (csh) -
                • x-dvi (dvi) -
                • x-gtar (gtar) -
                • x-hdf (hdf) -
                • x-latex (latex) -
                • x-mif (mif) -
                • x-netcdf (cdf) -
                • x-patch (no extension; processed by the text/plain filter) -
                • x-sh (sh) -
                • x-shar (shar) -
                • x-sv4cpio (sv4cpio) -
                • x-sv4crc (sv4crc) -
                • x-tar (tar) -
                • x-tcl (tcl) -
                • x-tex (tex) -
                • x-texinfo (texinfo) -
                • x-troff (roff) -
                • x-troff-man (man) -
                • x-troff-me (me) -
                • x-troff-ms (ms) -
                • x-ustar (ustar) -
                • x-wais-source (src) -
                • zip (zip) -

                -

                audio/* -

                - -

                MHonArc extracts the data into a separate file and puts a hyperlink to the file into -the HTMLized message. The name of the file created follows the same guidelines -mentioned under application/*. -

                -

                Here is the current list of audio sub-types (with their filename extensions) -supported by MHonArc: -

                -
                  -
                • basic (snd) -
                • x-aiff (aif) -
                • x-wav (wav) -

                -

                image/* -

                - -

                MHonArc will extract the data into a separate file and puts a hyperlink to the file -into the HTMLized message. The name of the file created follows the same -guidelines mentioned under application/*. In addition to the filename -specification mentioned under application/*, an "inline" argument may be -declared to instruct MHonArc to inline the image in the generated HTML. -

                -

                Example: -

                -
                <MIMEARGS>
                -image/gif:inline
                -</MIMEARGS>
                -
                -
                - -

                The following examples says to inline XBM images and use the name attribute as -the filename if defined: -

                -
                <MIMEARGS>
                -image/x-xbm:inline usename
                -</MIMEARGS>
                -
                -
                - -

                The following represents the default argument settings used by MHonArc: -

                -
                <MIMEARGS>
                -image/gif:inline
                -image/x-xbitmap:inline
                -image/x-xbm:inline
                -</MIMEARGS>
                -
                -
                - -

                Here is the current list of image sub-types (with their filename extensions) -supported by MHonArc: -

                -
                  -
                • gif (gif) -
                • ief (ief) -
                • jpeg (jpg) -
                • tiff (tif) -
                • x-bmp (bmp) -
                • x-cmu-raster (ras) -
                • x-pcx (pcx) -
                • x-pict (pict) -
                • x-portable-anymap (pnm) -
                • x-pnm (pnm) -
                • x-portable-bitmap (pbm) -
                • x-pbm (pbm) -
                • x-portable-graymap (pgm) -
                • x-pgm (pgm) -
                • x-portable-pixmap (ppm) -
                • x-ppm (ppm) -
                • x-rgb (rgb) -
                • x-xbitmap (xbm) -
                • x-xbm (xbm) -
                • x-xpixmap (xpm) -
                • x-xpm (xpm) -
                • x-xwindowdump (xwd) -
                • x-xwd (xwd) -

                -

                If the image is a GIF or XBM (X bitmap), the HTML IMG element will be used to -in-line the image into the HTMLized message. -

                -

                message/news -

                - -

                message/news signifies an included (MIME) USENET news message. The data -associated with a message/news part is processed by MHonArc in the same manner -as a regular mail message. -

                -

                message/partial -

                - -

                message/partial signifies that the content is a single part of a message split into -multiple mail messages. message/partial is treated in the same manner as text/plain. -

                -

                message/rfc822 -

                - -

                message/rfc822 signifies an included (MIME) mail message. The data associated -with a message/rfc822 part is processed by MHonArc in the same manner as a -regular mail message. -

                -

                multipart/alternative -

                - -

                multipart/alternative signifies multiple content-types with the same (or similiar) -information. MHonArc processes only the latest part that has a content-type filter. -

                -

                multipart/digest -

                - -

                mulltipart/digest signifies a series of included mail messages. Each part is -processed in the same manner as message/rfc822 unless an explicit content-type is -specifed for each part. -

                -

                multipart/mixed -

                - -

                multipart/mixed signifies data with multiple content-types. MHonArc extracts each -part and calls the appropriate content-type filter for each part, if defined. -

                -

                multipart/parallel -

                - -

                multipart/parallel is processed in the same manner as multipart/mixed. -

                -

                text/html -

                - -

                text/html signifies that the data is HTML markup. The data as left "as is" with the -exception of some processing to legally include the HTML into the HTMLized mail -message. I.e. MHonArc removes the HEAD an BODY tags, the TITLE element will be -replaced with an ADDRESS element surrounded by HR's, and the BASE element -URL will be propogated to relative URLs. -

                -

                text/plain -

                - -

                text/plain signifies ASCII character data. In the HTMLized message, the data is -wrapped in a PRE element with special characters (< > &) converted to entity -references. MHonArc will also make any URLs into hyperlinks. The following URL -types are recognized: -

                -
                  -
                • http://... -
                • ftp://... -
                • afs://... -
                • wais://... -
                • telnet://... -
                • gopher://... -
                • news:... -
                • nntp:... -
                • mid:... -
                • cid:... -
                • mailto:... -
                • prospero:... -

                -

                text/setext -

                - -

                text/setext signifies "structure enhanced text". The data is converted into HTML -containing hyperlinks as defined by the setext data. For more information on setext, -see <URL:http://www.bsdi.com/setext/>. -

                -

                video/* -

                - -

                MHonArc extracts the data into a separate file and puts a hyperlink to the file into -the HTMLized message. The name of the file created follows the same guidelines -mentioned under application/*. -

                -

                Here is the current list of video sub-types (with their filename extensions) -supported by MHonArc: -

                -
                  -
                • mpeg (mpg) -
                • quicktime (mov) -
                • x-msvideo (avi) -
                • x-sgi-movie (movie) -
                -
                -

                Non-MIME Messages -

                - -

                Messages that do not contain a MIME Content-Type header field are processed -as text/plain messages. -

                -
                -

                Writing Filters -

                - -

                If you want to write your own filter for use in MHonArc, you need to know the Perl -programming language. The following information assumes you know Perl. To -learn how to hook in your filters into MHonArc, see Specifying Filters. -

                -

                Function Interface of Filter -

                - -

                MHonArc interfaces with MIME filters by calling a routine with a specific set of -arguments. The prototype of the interface routine is as follows: -

                -
                sub filter {
                -    local($head, *fields, $data, $decoded, $argstring) = @_;
                -
                -    # Filter code here
                -
                -    # The last statement should be the return value, unless an
                -    # explicit return is done. See the following for the format of the
                -    # return value.
                -}
                -
                -
                - -

                Argument Descriptions -

                - -
                -
                $head - -

                This is the header text of the message (or body part if called in a mulitpart -message). -

                -
                -
                *fields - -

                This is a pointer to an associative array that has broken down $head into -field label/field value components. The keys are the lower-case -representations of the field values. Example: If you would like to retrieve -the value of the Content-Type field, then use the following: -$fields{`content-type'}. -

                If a field occurs more than once in a header, MHonArc separates the field -values in the associative array by a `\034' character. To make your filter -less likely to break due to changes in MHonArc, you may use the $'X -variable instead of `\034'. -

                -
                -
                $data - -

                This is a copy of the message (or body part if called in a mulitpart message) -body. -

                -
                -
                $decoded - -

                This flag is set to 1 if MHonArc decoded the message and $data represents -the orginal data before encoded by the sender. If set to 0, $data has not -been decoded. The failure to decode occurs if MHonArc does not -recognizeed the encoding specified in the Content-Transfer-Encoding -field. -

                MHonArc has decoded the data for you if it was encoded in 7-Bit, 8-Bit, -Binary, Quoted-Printable, Base64, or X-Uuencode. -

                -
                -
                $argstring - -

                This is an optional argument string that may be used to modify the -behavior of the filter. The format of this string is determined by the filter -itself. -

                The value of the string is set by the MIMEARGS resource. -

                -

                Return Value -

                - -

                The return value is treated as an array. The first item in the array is a string -representing the HTML markup to insert in the HTMLized message. An empty -string may be returned to tell MHonArc that the routine was unable to filter data. -

                -

                Any other array items are treated as names of any files that were generated by the -filter. MHonArc needs to keep track if any extra files that a filter may generate in -order for MHonArc to delete those files if the message gets removed from the -archive. -

                -

                Filter Writing Tips -

                - -

                The following recommendations/tips are given to help you write filters: -

                -
                  -
                • Qualify your filter in its own package. This eliminates possible -variable/routine conflicts with MHonArc. -

                • If the filter creates derived files (like the image filters), you may use the -variable $'OUTDIR to determine the location of the mail archive. -

                  NOTE: Do not include $'OUTDIR as part as the filename that is returned to -MHonArc. If the filter does create files, just return the base name. -

                • Look at the default filters contained in the distribution of MHonArc. You -can use these as templates for writing your own. -

                • Make sure your Perl source file ends with a true statement (like "1;"). -MHonArc just performs a require on the file, and if the file does not -return true, Perl will abort execution. -

                -

                Using C -

                - -

                If a MIME filter requires the utilization of a C program, or other non-Perl -executable, a Perl wrapper must be written for the program in-order to interface -with MHonArc. The wrapper must follow the rules as specified in Function -Interface of Filter. -

                -
                -

                Specifying Filters -

                - -

                Adding new filters, or overriding existing ones, are done via the Resource File. The -two resources for specifying and controlling MIME filters are MIMEFILTERS and -MIMEARGS. -

                -

                MIMEFILTERS -

                - -

                The resource element MIMEFILTERS in the Resource File is used to hook in user -specifed filters into MHonArc. The syntax for each line of the the MIMEFILTERS -element is as follows: -

                -

                <content-type>:<routine-name>:<file-of-routine> -

                -

                The definition of each colon-separated value is as follows: -

                -
                -
                <content-type> - -

                The MIME content-type the filter processes. -

                -
                -
                <routine-name> - -

                The actual routine name of the filter. The name should be fully qualified -by the package it is definedi (e.g. "mypackage'filter"). -

                -
                -
                <file-of-routine> - -

                The name of the file that defines <routine-name>. If the file is not a full -pathname, MHonArc finds the file by looking in the standard include paths -of Perl, and the paths specified by the PERLINC resource element. -

                -

                Any whitespace is stripped out before processing. -

                -

                Example -

                - -

                The following represents the default value of MIMEFILTERS: -

                -
                <MIMEFILTERS>
                -application/mac-binhex40:m2h_external'filter:mhexternal.pl
                -application/octet-stream:m2h_external'filter:mhexternal.pl
                -application/oda:m2h_external'filter:mhexternal.pl
                -application/pdf:m2h_external'filter:mhexternal.pl
                -application/postscript:m2h_external'filter:mhexternal.pl
                -application/rtf:m2h_external'filter:mhexternal.pl
                -application/x-bcpio:m2h_external'filter:mhexternal.pl
                -application/x-cpio:m2h_external'filter:mhexternal.pl
                -application/x-csh:m2h_external'filter:mhexternal.pl
                -application/x-dvi:m2h_external'filter:mhexternal.pl
                -application/x-gtar:m2h_external'filter:mhexternal.pl
                -application/x-hdf:m2h_external'filter:mhexternal.pl
                -application/x-latex:m2h_external'filter:mhexternal.pl
                -application/x-mif:m2h_external'filter:mhexternal.pl
                -application/x-netcdf:m2h_external'filter:mhexternal.pl
                -application/x-patch:m2h_text_plain'filter:mhtxtplain.pl
                -application/x-sh:m2h_external'filter:mhexternal.pl
                -application/x-shar:m2h_external'filter:mhexternal.pl
                -application/x-sv4cpio:m2h_external'filter:mhexternal.pl
                -application/x-sv4crc:m2h_external'filter:mhexternal.pl
                -application/x-tar:m2h_external'filter:mhexternal.pl
                -application/x-tcl:m2h_external'filter:mhexternal.pl
                -application/x-tex:m2h_external'filter:mhexternal.pl
                -application/x-texinfo:m2h_external'filter:mhexternal.pl
                -application/x-troff-man:m2h_external'filter:mhexternal.pl
                -application/x-troff-me:m2h_external'filter:mhexternal.pl
                -application/x-troff-ms:m2h_external'filter:mhexternal.pl
                -application/x-troff:m2h_external'filter:mhexternal.pl
                -application/x-ustar:m2h_external'filter:mhexternal.pl
                -application/x-wais-source:m2h_external'filter:mhexternal.pl
                -application/zip:m2h_external'filter:mhexternal.pl
                -audio/basic:m2h_external'filter:mhexternal.pl
                -audio/x-aiff:m2h_external'filter:mhexternal.pl
                -audio/x-wav:m2h_external'filter:mhexternal.pl
                -image/gif:m2h_external'filter:mhexternal.pl
                -image/ief:m2h_external'filter:mhexternal.pl
                -image/jpeg:m2h_external'filter:mhexternal.pl
                -image/tiff:m2h_external'filter:mhexternal.pl
                -image/x-bmp:m2h_external'filter:mhexternal.pl
                -image/x-cmu-raster:m2h_external'filter:mhexternal.pl
                -image/x-pbm:m2h_external'filter:mhexternal.pl
                -image/x-pcx:m2h_external'filter:mhexternal.pl
                -image/x-pgm:m2h_external'filter:mhexternal.pl
                -image/x-pict:m2h_external'filter:mhexternal.pl
                -image/x-pnm:m2h_external'filter:mhexternal.pl
                -image/x-portable-anymap:m2h_external'filter:mhexternal.pl
                -image/x-portable-bitmap:m2h_external'filter:mhexternal.pl
                -image/x-portable-graymap:m2h_external'filter:mhexternal.pl
                -image/x-portable-pixmap:m2h_external'filter:mhexternal.pl
                -image/x-ppm:m2h_external'filter:mhexternal.pl
                -image/x-rgb:m2h_external'filter:mhexternal.pl
                -image/x-xbitmap:m2h_external'filter:mhexternal.pl
                -image/x-xbm:m2h_external'filter:mhexternal.pl
                -image/x-xpixmap:m2h_external'filter:mhexternal.pl
                -image/x-xpm:m2h_external'filter:mhexternal.pl
                -image/x-xwd:m2h_external'filter:mhexternal.pl
                -image/x-xwindowdump:m2h_external'filter:mhexternal.pl
                -message/partial:m2h_text_plain'filter:mhtxtplain.pl
                -text/html:m2h_text_html'filter:mhtxthtml.pl
                -text/plain:m2h_text_plain'filter:mhtxtplain.pl
                -text/richtext:m2h_text_plain'filter:mhtxtplain.pl
                -text/setext:m2h_text_setext'filter:mhtxtsetext.pl
                -text/tab-separated-values:m2h_text_plain'filter:mhtxtplain.pl
                -text/x-html:m2h_text_html'filter:mhtxthtml.pl
                -text/x-setext:m2h_text_setext'filter:mhtxtsetext.pl
                -video/mpeg:m2h_external'filter:mhexternal.pl
                -video/quicktime:m2h_external'filter:mhexternal.pl
                -video/x-msvideo:m2h_external'filter:mhexternal.pl
                -video/x-sgi-movie:m2h_external'filter:mhexternal.pl
                -</MIMEFILTERS> 
                -
                - -

                MIMEARGS -

                - -

                The MIMEARGS resource may be used to pass optional arguments to filters to -control their behavior. Arguments may be defined on a per content-type basis, or -for a specific filter itself. The syntax for each line of the the MIMEARGS element is -as follows: -

                -

                <content-type>:<argument-string> -

                -

                Or, -

                -

                <filter-name>:<argument-string> -

                -

                The format of argument strings is dependent on the filter that processes -<content-type> or by the specified filter, <filter-name>. -

                -

                If an argument string is defined for a filter explicitly and for a content-type that the -filter processes, the content-type string will override the filter string. -

                -

                Examples -

                - -

                The following example represents the default settings used by MHonArc: -

                -
                <MIMEARGS>
                -image/gif:inline
                -image/x-xbitmap:inline
                -image/x-xbm:inline
                -</MIMEARGS>
                -
                -
                - -

                The following example tells the filter that deals handles content-types that cannot -be converted directly into HTML to use the "name" attribute as defined in the -Content-Type header field as the name of the file generated: -

                -
                <MIMARGS>
                -m2h_external'filter:usename
                -</MIMEARGS>
                -
                -
                - -

                The following examples says to inline XBM images and use the name attribute as -the filename if defined: -

                -
                <MIMEARGS>
                -image/x-xbm:inline usename
                -</MIMEARGS>
                -
                -
                - - -
                -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/mktxt b/doc/mktxt deleted file mode 100755 index 87c3dec..0000000 --- a/doc/mktxt +++ /dev/null @@ -1,27 +0,0 @@ -#! /usr/local/bin/perl - -$manpage = "mhonarc.1"; -$txtfile = "mhonarc.txt"; - -open(MANPAGE, "> $manpage"); -open(TXTFILE, "> $txtfile"); - -print MANPAGE ".TH MHonArc 1\n", - ".SH NAME\n", - "MHonArc \\- Mail\\-to\\-HTML converter\n", - ".SH DESCRIPTION\n", - ".in 0\n", - ".nf\n"; -while () { - next if /^\s*\[IMAGE\]\s*$/i || /\[contents\]/i || /MifMucker/i; - print TXTFILE; - s/\\/\\\\/g; - s/-/\\-/g; - print MANPAGE; -} -print MANPAGE ".fi\n", - ".in\n"; -close(MANPAGE); -close(TXTFILE); - -exit 0; diff --git a/doc/monicon.gif b/doc/monicon.gif new file mode 100644 index 0000000..a0a9161 Binary files /dev/null and b/doc/monicon.gif differ diff --git a/doc/stamp_t.gif b/doc/monstamp_t.gif similarity index 100% rename from doc/stamp_t.gif rename to doc/monstamp_t.gif diff --git a/doc/overview.html b/doc/overview.html deleted file mode 100644 index cb687a4..0000000 --- a/doc/overview.html +++ /dev/null @@ -1,529 +0,0 @@ - - - -MHonArc v1.2.2 -- Overview - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
                - -

                Overview -

                - -

                This section gives an overview of MHonArc's command-line options and -environment variables. The MHonArc resource file is covered in the section -Resource File. The resource file allows you to specify most of the resources set by -environment variables and command-line options, plus it give you the capability -of completely customizing the HTML output generated by MHonArc. -

                -
                -

                Synopsis -

                - -

                Invoke MHonArc from your shell with the following syntax: -

                -

                % mhonarc [options] mhfolder...
                -% mhonarc [options] mailbox ...
                -% mhonarc -add [options] < message
                -% mhonarc -single [options] < message > message.html
                -
                % mhonarc -single [options] message > message.html
                -
                % mhonarc -rmm [options] msg# ...
                -
                -

                -
                -

                Options -

                - -

                The following options are available: -

                -

                -add -

                - -

                Add new messages to an existing archive. If no mail folder arguments are given, -MHonArc assumes that a single message is being added to the archive via standard -input. Otherwise, MHonArc adds the messages contained in the mail folders -specified. -

                -

                -dbfile name -

                - -

                Use name for the name of MHonArc database file. The default is ".mhonarc.db" -(or "MHONARC.DB" under MS-DOS). -

                -
                -
                NOTE - -

                You should not override the default name unless absolutely necessary, and -you are confident about what you are doing. -

                -

                -docurl url -

                - -

                Use url as the URL to MHonArc documentation. The default is -"http://www.oac.uci.edu/indiv/ehood/mhonarc.html". -

                -

                -editidx -

                - -

                This option tells MHonArc to rewrite the index page and re-edit all mail messages -in the archive. This option is useful if you need to change the layout of the index -page and/or messages. -

                -

                -footer filename -

                - -

                Insert contents of filename at the bottom of the index page. See Include Files in -Index Page Customization for more information about the footer file. -

                -

                -force -

                - -

                Override a lock on an archive if attempts to lock fail. I.e. After trying -unsuccessfully to lock an archive, MHonArc will still perform the actions -requested. -

                -

                This option is useful to help dealing with locks that are no longer valid (i.e. stale -locks). A stale lock can exist if the MHonArc process that created the lock -abnormally terminated and could not perform the proper cleanup procedures. -

                -

                -genidx -

                - -

                Output an index page to standard output based upon the contents of an archive, -and utilizing any extra formatting options specified. -

                -

                -header filename -

                - -

                Insert contents of filename at the beginning of the index page. See Include Files in -Index Page Customization for more information about the header file. -

                -

                -help -

                - -

                Print out a help message about MHonArc. -

                -

                -idxfname name -

                - -

                Sets the name of the main index file to name. The default is "maillist.html". -

                -

                -idxsize # -

                - -

                Set the maximum number of messages listed in the indexes. -

                -

                -lockdelay # -

                - -

                The sleep time, in seconds, between attempts to lock the archive. The default value -is 3. -

                -

                -locktries # -

                - -

                Set the number of time MHonArc tries to lock a mail archive before processing new -messages. The default value is 10. MHonArc waits approximately 3 seconds before -each try. -

                -

                See Archive Integrity for more information on the -locktries options. -

                -

                -mailtourl url -

                - -

                Use url for e-mail address hyperlinks in mail message headers. The url can contain -the following variables that get expanded during run-time: -

                -
                -
                $FROM$ - -

                Who the message is from. -

                -
                -
                $MSGID$ - -

                Message ID of the message. -

                -
                -
                $SUBJECT$ - -

                The subject of the message. -

                -
                -
                $TO$ - -

                Destination e-mail address of link. -

                -

                The default URL is "mailto:$TO$" -

                -

                The -mailtourl option has no effect if the -nomailto option is specified. -

                -

                -maxsize # -

                - -

                Set the maxinum number of messages allowed in the archive to #. If messages are -added to the archive which would cause the total number of messages to exceed #, -older messages (based on sort method) are removed automatically. -

                -

                -msgsep expression -

                - -

                Use the expression as the Perl regular expression that signifies the message -separator in Unix mailbox files. The default expression is "^From " (minus the -quotes). -

                -
                -
                NOTE - -

                There is a space character after the From. -

                -

                -nodoc -

                - -

                Do not print link to documentation at end of index page. -

                -

                -nomailto -

                - -

                Do not convert e-mail addresses in mail headers to mailto hyperlinks. -

                -

                -nonews -

                - -

                Do not convert newsgroups in the Newsgroups: mail header field to news -hyperlinks. -

                -

                -noreverse -

                - -

                Do not perform a reverse listing of the mail messages in the index page. -

                -

                -nosort -

                - -

                Do not sort messages by date. Messages will be in the order they appear in the -mailboxes/folders. By default, MHonArc sorts messages by date sent/received. -

                -

                -nosort takes precedence over the -sort option. -

                -

                -nothread -

                - -

                Do not create a thread index page. -

                -

                -notsubsort -

                - -

                Do not sort threads by subject on thread index page. -

                -

                -notreverse -

                - -

                List threads in the thread index with oldest thread first. -

                -

                -outdir path -

                - -

                Set destination/location of the HTML mail archive to path. By default, the current -working directory is used. -

                -

                -quiet -

                - -

                Suppress processing messages when MHonArc is running. -

                -

                -rcfile file -

                - -

                Use file as the resource file for MHonArc. MHonArc does the following to determine -the location of file: -

                -
                  - -
                1. If its an absolute pathname, use it. -
                2. If it is a relative pathname, check for it relative to the current working -directory. -
                3. Otherwise, check for it relative to the location of the archive. -
                - -

                See Resource File for more information. There is no default resource file. -

                -

                -reverse -

                - -

                List messages in reverse order of the sorting option specified. For example, if date -sorting is specified, -reverse will cause messages to be listed in reverse -chronological order. -

                -

                -rmm -

                - -

                All non-option command-line arguments are treated as messages to remove from -the archive. Messages to remove are denoted by their message numbers. -

                -

                -savemem -

                - -

                Normally, all messages are stored in memory and then written in one shot. This -option causes MHonArc to write the message data as it is processesd. This option -will cause a slow down in execution time as more disk I/O required, but it may -allow large amounts of data to be processed in a single process if memory is -limited. -

                -
                -
                NOTE - -

                The reason more disk I/O is required is that when the message data is first -written, all the archive navigational link information is non-existant. The -information required to correctly generate the navigational link -information will not exist until all messages are processed. Therefore, each -new message file must be reopened to add in the navigational link -information after all messages are processed. -

                -

                -scan -

                - -

                List contents of archive to standard output. -

                -

                -single -

                - -

                Convert a single mail message to HTML. The message can be specified by a -filename on the command-line, or read from standard input if no file is given. The -filtered message is sent to standard output. -

                -

                The -single option is useful tp convert individual messages to HTML not related -to a specific mail archive. Any option related to how message formatting can be -used with the -single option. -

                -

                The -single takes precedence over the -add option. -

                -

                -sort -

                - -

                Perform chronological date sorting. This is the default. -

                -

                -subsort -

                - -

                Sort messages by subject. Subject sorting is case-insensitive, and begining "Re:", -"A", "An", and "The" words are ignored. -

                -

                -tidxfname name -

                - -

                Sets the name of the thread index file to name. The default is "threads.html". -

                -

                -time -

                - -

                Print out total CPU execution time taken when processing messages. Time -information is written to standard error. -

                -

                -title string -

                - -

                Set the title of the main index page to string. The default is "Mail Index". -

                -

                -thread -

                - -

                Create a thread index page. This is the default. -

                -

                -tlevels -

                - -

                Set the maximum number of nested lists for the thread index page. The default is 3. -

                -

                -treverse -

                - -

                List threads in the thread index with newest thread first. -

                -

                -tsubsort -

                - -

                List threads in the thread index by subject. -

                -

                -ttitle string -

                - -

                Set the title of the thread index page to string. The default is "Mail Thread Index". -

                -

                -umask umask -

                - -

                Set the umask of the MHonArc process to umask. The value is treated as an octal -number. -

                -

                NOTE -

                - -

                The -no* options always take precedence over their counterparts. For example, if --noreverse and -reverse are both specified on the command-line, the --noreverse will be applied. -

                -
                -

                Environment -

                - -

                MHonArc supports the use of environment variables. The environment variables -allow you to set default options everytime you invoke MHonArc. The following -environment variables may be used: -

                -

                M2H_DBFILE -

                - -

                Sets the name of MHonArc database file. The default is ".mhonarc.db" (or -"MHONARC.DB" under MS-DOS). -

                -
                -
                NOTE - -

                You should not override the default name unless absolutely necessary, and -you are confident about what you are doing. -

                -

                M2H_DOCURL -

                - -

                Set the URL used to point to MHonArc documentation. The default is, -"http://www.oac.uci.edu/indiv/ehood/mhonarc.html". -

                -

                M2H_FOOTER -

                - -

                Set the HTML footer file to insert at the bottom of the index page. No default footer -file is defined. See Include Files in Index Page Customization for more information -about the footer file. -

                -

                M2H_HEADER -

                - -

                Set the HTML header file to insert at the top of the index page. No default header -file is defined. See Include Files in Index Page Customization for more information -about the header file. -

                -

                M2H_IDXFNAME -

                - -

                Set the name of the index file. The default is, "maillist.html". -

                -

                M2H_IDXSIZE -

                - -

                Sets the maximum number of messages listed in the indexes. -

                -

                M2H_LOCKFILE -

                - -

                The sleep time, in seconds, between attempts to lock the archive. The default value -is 3. -

                -

                M2H_LOCKFILE -

                - -

                Set the name of the lock file. The default name use is ".mhonarc.lck" (or -"MHONARC.LCK" under MS-DOS). -

                -
                -
                NOTE - -

                You should not change the default unless absolutely necessary. -

                -

                See Archive Integrity for more information about the lock file. -

                -

                M2H_LOCKTRIES -

                - -

                Set the number of time MHonArc tries to lock a mail archive before processing new -messages. The default value is 10. MHonArc waits approximately 3 seconds before -each try. -

                -

                See Archive Integrity for more information on the M2H_LOCKTRIES environment -variable. -

                -

                M2H_MAILTOURL -

                - -

                Sets the URL for e-mail address hyperlinks in mail message headers. The URL can -contain the following variables that get expanded during run-time: -

                -
                -
                $FROM$ - -

                Who the message is from. -

                -
                -
                $MSGID$ - -

                Message ID of the message. -

                -
                -
                $SUBJECT$ - -

                The subject of the message. -

                -
                -
                $TO$ - -

                Destination e-mail address of link. -

                -

                The default URL is "mailto:$TO$" -

                -

                M2H_MAXSIZE -

                - -

                Sets the maximum number of messages that an archive will contain. If messages -are added to the archive which would cause the total number of messages to -exceed M2H_MAXSIZE, older messages (based on sort method) are removed -automatically. -

                -

                M2H_OUTDIR -

                - -

                Sets the destination/location of the HTML mail archive. The default is the current -working directory. -

                -

                M2H_RCFILE -

                - -

                Specifies the Resource File for MHonArc. No default resource file is defined. -

                -

                M2H_THREAD -

                - -

                Flag to determine if MHonArc generates a thread index. If set to zero, the thread -index will not be created. The default behavior is to create a thread index. -

                -

                M2H_TIDXFNAME -

                - -

                Sets the name of the thread index file. The default is "threads.html". -

                -

                M2H_TITLE -

                - -

                Sets the default title of the index page. The default is "Main Index". -

                -

                M2H_TLEVELS -

                - -

                Sets the maximum number of nested lists for the thread index page. The default is -3. -

                -

                M2H_TTITLE -

                - -

                Sets the title of the thread index page. The default is "Mail Thread Index". -

                -

                NOTE -

                - -

                Environment variables may be overriden by the Resource File or command-line -Options. -

                - -
                -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/qstart.html b/doc/qstart.html deleted file mode 100644 index f00eec4..0000000 --- a/doc/qstart.html +++ /dev/null @@ -1,192 +0,0 @@ - - - -MHonArc v1.2.2 -- Quick Start - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
                - -

                Quick Start -

                - -

                This section will give you a "quick start" on using MHonArc. However, I -recommend reading through the entire documentation to take full advantage of all -the features of MHonArc. -

                -

                Before continuing, make sure MHonArc has been installed. See Installation if -MHonArc has not been installed on your machine. -

                -
                -

                Converting MH mail folders or Mailbox files -

                - -

                Since MHonArc supports MH mail folders and UUCP/Unix mailbox files, the term -"mail folder" will represent the MH mail folder or mailbox file you want to process. -To convert your mail folder to an HTML archive, use the following: -

                -

                % mhonarc <path>/inbox -

                -

                Where <path> represents the path to the directory that contains the mail folder -inbox. If you are in the directory that contains inbox, then you can leave out the -"<path>/". -

                -

                MHonArc prints out messages showing its progress as your e-mail is processed. -When MHonArc finishes, the following files will be created: -

                -
                  -
                • maillist.html: The main index file containing links to all mail -messages converted. Messages are listed with subjects and who the -messages are from. All messages are listed in sorted order by date -received/sent. -

                • threads.html: The file listing messages by thread. -

                • msg*.html: HTML versions of the mail messages, where * represents a -message number from 0 to the number of message processed minus 1. -

                • .mhonarc.db (or MHONARC.DB under MS-DOS): This database file is -needed inorder for MHonArc to perform additions of new mail messages -to the archive. Information is stored to perform mail threading updates -when new messages are added, as well as any resources set via -Environment variables, Resource File, and/or command-line Options. -

                • Other: Depending on the content-types of the e-mail messages converted, -other files may be created for images, videos, binaries, etc. See the section -on MIME for more information. -

                -

                The format of each converted mail message is as follows: -

                -
                  -
                • A <LINK REV="made" HREF="mailto:from_address"> is inserted -in the HEAD element of HTML mail message file. This allows readers of the -message to send comments to the author of the mail message within Web -browsers that support such functionality (like Lynx). -

                • The title (i.e. TITLE element) contains the subject of the message. -

                • Hyperlinks to the previous and next messages and the index pages are -located at the top of the message. -

                • Next, the subject appears in a H1 element. -

                • Next, follows the mail header with fields listed in a UL element -surrounded by HR's. -

                • Next, the actual body of the mail message. -

                • Next, links to any follow-up, or referenced, messages. The messages are -listed by subject and who they are from. These links allows you to easily -follow mail threads. -

                • Last, are verbose links to the previous mail message, next mail message, -and index pages. -

                -

                The following is also done for each mail message processed: -

                -
                  -
                • Links are created in the "References" and "In-Reply-To" header -fields, and possibly the message body, if the destination message-ids are -being processed. -

                • E-mail addresses are converted to "mailto" hyperlinks in "To:", -"From:", "Cc:", and "Sender:" mail header fields. Currently, not all -Web browsers support the mailto URL. -

                • Newsgroups listed in a "Newsgroups:" mail header field are converted -to news hyperlinks. -

                -

                MHonArc allows you to specify more than one mail folder to process on the -command-line. -

                -
                -
                Example - -

                % mhonarc /home/ehood/mail/inbox1 -/home/ehood/mail/inbox2 ... -

                -

                All the files created will be put into the current working directory, by default. You -can control the destination of the output location by using the -outdir option. -

                -
                -
                Example - -

                % mhonarc -outdir /home/ehood/htmlarchive -/home/ehood/mail/inbox -

                -

                Here is a sample session converting a mail folder: -

                -
                % mhonarc ~/mail/inbox
                -Requiring MIME filter libraries ...
                -        mhexternal.pl
                -        mhtxthtml.pl
                -        mhtxtplain.pl
                -        mhtxtsetext.pl
                -Converting messages to ./maillist.html
                -Reading /mnt/ehood/mail/inbox ..........
                -Writing mail ...
                -Writing tmp/maillist.html ...
                -Writing tmp/threads.html ...
                -10 messages
                -
                -
                - -
                -

                Adding Messages to an Archive -

                - -

                If you have new messages you want to add to an existing archive, you must -utilizing the -add command-line option. With the -add, you can do the following: -

                -
                  -
                • Add a mail folder to an archive, or -

                • Add a single message to an archive. -

                -

                Adding a mail folder to an archive in the current working directory can be done -like the following: -

                -

                % mhonarc -add <path>/mailfolder -

                -

                If you are not in the same directory as the archive, then you can specify the location -of the archive to add to with the -outdir option: -

                -

                % mhonarc -add -outdir <outdir_path> <path>/mailfolder -

                -
                -
                NOTE - -

                MHonArc will skip any messages that already exist in the archive. -Therefore, MHonArc can be used to rescan the same mail folder and only -convert any new messages it finds. -

                -

                If no mail folder arguments are specified, then MHonArc will attempt to add a -single message read in from standard input. -

                -
                -
                Example - -

                % mhonarc -add < single.msg -

                Or, from a pipe: -

                % cat single.msg | mhonarc -add -

                -

                See the section on Adding Messages for more information and examples for -adding messages to an archive. -

                -
                -

                Converting a single message -

                - -

                MHonArc has the ability to process a single mail message independent of creating, -or modifying, and archive. To convert a single message to HTML use the -single -command-line option. The message to process can be specified by a filename on -the command-line, or by reading the message from standard input if no file is -specified. The filtered message is sent to standard output. All formatting options -apply to the single message as with messages being processed for an archive, with -the exception of formatting related specificly to archive processing, like index links -and mail thread links. -

                -

                Examples -

                - -
                -
                Input from standard input: - -

                % mhonarc -single < messagefile > file.html -

                -
                -
                Filename on command-line: - -

                % mhonarc -single messagefile > file.html -

                - -
                -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/quickstart.html b/doc/quickstart.html new file mode 100644 index 0000000..cb2f0e7 --- /dev/null +++ b/doc/quickstart.html @@ -0,0 +1,222 @@ + + + +MHonArc -- Quick Start + + + + + +

                +[Prev][Next][TOC][FAQ][Bugs][Home] +

                + +
                + +

                Quick Start

                + +

                This section will give you a "quick start" on using +MHonArc. However, I recommend reading through the entire +documentation to take full advantage of all the features of +MHonArc.

                + +
                +

                Converting MH mail folders or Mailbox files

                + +

                Since MHonArc supports MH mail folders and +UUCP/Unix mailbox files, the term "mail folder" will represent +the MH mail folder or mailbox file you want to process. +To convert your mail folder to an HTML archive, use the following: +

                + +

                +% mhonarc path/inbox +

                + +

                Where path represents the path to the directory +that contains the mail folder inbox. If you are in the +directory that contains inbox, then you can leave out the +"path/". +

                + +

                MHonArc prints out messages showing its progress as your +e-mail is processed. When MHonArc finishes, the following +files will be created:

                + +
                  + +
                • maillist.html: +The main index file containing links +to all mail messages converted. Messages are listed with subjects and +who the messages are from. All messages are listed in sorted order +by date received/sent.

                  + +
                • threads.html: +The file listing messages by thread. +

                  + +
                • msg*.html: HTML versions of the mail messages, where * represents a +message number from 0 to the number of message processed minus 1. +

                  + +
                • .mhonarc.db +(or MHONARC.DB under MS-DOS): +This database file is +needed inorder for MHonArc to perform additions of new mail messages +to the archive. Information is stored to perform mail threading updates +when new messages are added, as well as any defined +resources. +

                  + +
                • Other: Depending on the content-types of the e-mail +messages converted, other files may be created for images, videos, +binaries, etc. +

                  + +
                + +

                MHonArc allows you to specify more than one mail folder +to process on the command-line.

                + +
                +
                Example + +
                +% mhonarc /home/ehood/mail/inbox1 /home/ehood/mail/inbox2...
                +
                +
                + +

                All the files created will be put into the current +working directory, by default. You can control the +destination of the output location by using the +-outdir option.

                + +
                +
                Example + +
                +% mhonarc -outdir /home/ehood/htmlarchive /home/ehood/mail/inbox
                +
                +
                + +

                Here is a sample session converting a mail folder: +

                + +
                +% mhonarc ~/mail/inbox
                +Requiring content filter libraries ...
                +        mhexternal.pl
                +        mhtxthtml.pl
                +        mhtxtplain.pl
                +        mhtxtsetext.pl
                +Requiring charset filter libraries ...
                +        iso8859.pl
                +Converting messages to .
                +Reading /mnt/ehood/mail/inbox ..........
                +Writing mail ...
                +Writing ./maillist.html ...
                +Writing ./threads.html ...
                +Writing database ...
                +10 messages
                +
                + +
                +

                Adding Messages to an Archive

                + +

                If you have new messages you want to add to an existing archive, +you must utilizing the -add command-line option. With the +-add, you can do the following:

                + +
                  +
                • Add a mail folder to an archive, or +

                  +
                • Add a single message to an archive. +

                  +
                + +

                Adding a mail folder to an archive in the current working directory +can be done like the following:

                + +

                % mhonarc -add <path>/mailfolder +

                + +

                If you are not in the same directory as the archive, then you +can specify the location of the archive to add to with the +-outdir option.

                + +
                +
                NOTE + +

                MHonArc will skip any messages that already exist in +the archive. Therefore, MHonArc can be used to rescan the +same mail folder and only convert any new messages it finds.

                + +

                If no mail folder arguments are specified, then MHonArc +will attempt to add a single message read in from standard +input.

                + +
                +
                Example + +
                +

                % mhonarc -add < single.msg +

                +

                Or, from a pipe: +

                +

                % cat single.msg | mhonarc -add +

                +
                + +
                +

                Converting a single message

                + +

                MHonArc has the ability to process a single +mail message independent of creating, or modifying, an +archive. To convert a single message to HTML use the +-single command-line +option. The message to process can be specified by a filename on the +command-line, or by reading the message from standard input if no file +is specified. The filtered message is sent to standard output. All +formatting options apply to the single message as with messages +being processed for an archive, with the exception of formatting +related specificly to archive processing, like index links and mail +thread links.

                + +

                Examples +

                + +
                +
                Input from standard input: + +

                % mhonarc -single < messagefile > file.html +

                +
                + +
                +
                Filename on command-line: + +
                +

                % mhonarc -single messagefile > file.html +

                +
                + +
                + +

                +[Prev][Next][TOC][FAQ][Bugs][Home] +

                + + +
                +
                +97/05/15 16:49:00
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/rcfile.html b/doc/rcfile.html deleted file mode 100644 index 7129df1..0000000 --- a/doc/rcfile.html +++ /dev/null @@ -1,648 +0,0 @@ - - - -MHonArc v1.2.2 -- Resource File - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
                - -

                Resource File -

                - -

                MHonArc supports the ability to read in a resource file to control the behavior of -MHonArc. The resource file allows you to specify most of the resources set by -environment variables and command-line options, and it allows you to specify -other resources to control MHonArc's behavior. -

                -

                The resource file is specified by the M2H_RCFILE environment variable or the --rcfile command-line option. The command-line option overrides the -environment variable if both are defined. -

                -
                -
                NOTE - -

                MHonArc will store the information specified in the resource file in the -database for the archive. Therefore, it is unnecessary to respecify the -resource file duing archive updates unless changes are required from the -current settings. -

                -
                -

                Resource Syntax -

                - -

                Resources are set in the file by using elements similiar in style to HTML/SGML -markup. However, MHonArc uses simpler parsing rules for the resource file than -standard SGML: -

                -
                  -
                • Any line that is not a recognized element open tag, and the line is not -contained within an element, is ignored. This implies that regular text can -be put anywhere outside of recognized elements for commenting -purposes. -

                  NOTE: You should use SGML comment declarations (<!-- ... -->) when -commenting a resource file. This will eliminate possible conflict with later -versions of MHonArc if more stricter parsing rules are adopted. -

                • The opening tag of an element must occur by itself on a single line. -Whitespace is allowed before the the open tag. -

                • No comments are allowed inside elements because the text will be treated -as element content. -

                • Each element must be closed with a </element_name> tag on its own -line unless explicitly stated otherwise in the Resource Elements section. -Whitespace is allowed before the close tag. -

                • Some elements can take an optional attribute called "Override". This -tells MHonArc that the contents of the element will completely override -the default behavior of MHonArc, and previous instances of the element. -Example: "<EXCS Override>". If "Override" is not specified, then the -contents of the element augment the current setting. -

                • Element names are case-insensitive. -

                • Elements can occur in any order in the resource file. -

                -

                Resource Variables -

                - -

                Some resource element contents may contain variables. Variables get expanded to -strings at run-time. -

                -
                -
                NOTE - -

                Variable expansion will only take place in resource elements that are -intended to have variables as part of their content. If an element is not -meant to have variables, the variable text will be taken literally as part of -the element content. -

                -

                The syntax of the variables to use in resource elements is as follows: -

                -

                $VARIABLE[:[N][U]]$ -

                -

                The items in []'s are optional. Definition of each part: -

                -
                -
                $ - -

                The $ character represents the beginning, and ending, of the variable. -

                -
                -
                VARIABLE - -

                This is the the actual name of the variable. All variable names must be -uppercase. -

                -
                -
                :[N][U] (optional) - -

                This defines a maximum length of the replacement string for the variable. -The option "U" denotes that the replacement string should be treated as -part of a URL string. This can be useful when the variable may contain -special characters, and the variable is used withing a URL. -

                -

                No whitespace is allowed between the opening $ and closing $. If an unrecognized -variable is encountered, it gets replaced with an empty string. If a literal "$" is -needed, use "$$". -

                -
                -
                SPECIAL NOTE - -

                The MAILTOURL resource has different rules for variable expansion. If a -variable does not exactly match the set of variables available for the -MAILTOURL, the variable text will be taken literally as part of the element -content. Therefore, a single "$" can be used to represent a "$" character. -

                Also, variables in the MAILTOURL should NOT have ":NU" modifier. This -will prevent the variables from be recognized. MHonArc will -automatically treat the replacement value as a part of a URL string. -

                -

                Here are some examples of legal variable usage: -

                -
                  -
                • $SUBJECT$ -
                • $FROMNAME$ -
                • $SUBJECT:50$ -
                • $SUBJECTNA:60U$ -
                • $FROMADDR:U$ -
                -

                Each resource element will define what variables are defined for it. -

                -
                -

                Resource Elements -

                - -

                The following are complete listings of all the resource elements defined by -MHonArc. Many element descriptions will reference to other sections of the -documentation on the exact usage of the element. -

                -

                Empty Elements -

                - -

                The following list of elements contain no textual content. Therefore, no end tag is -required: -

                -

                NODOC -

                - -

                Do not put link to documentation on main index page. -

                -

                NOMAILTO -

                - -

                Do not convert e-mail addresses in mail headers to mailto hyperlinks. -

                -

                NONEWS -

                - -

                Do not convert newsgroups in the Newsgroups: mail header field to news -hyperlinks. -

                -

                NOREVERSE -

                - -

                Do not perform a reverse listing of the mail messages in the main index page. -

                -

                NOSORT -

                - -

                List messages in the index page in the order they are processed. -

                -

                NOTHREAD -

                - -

                Do not create thread index. -

                -

                NOTREVERSE -

                - -

                List threads in the thread index with oldest thread first. -

                -

                NOTSUBSORT -

                - -

                Do not sort thread by subject in thread index page. -

                -

                REVERSE -

                - -

                List messages in reverse listing order for the main index page. -

                -

                SORT -

                - -

                List messages in the index page in chronological order. -

                -

                SUBSORT -

                - -

                Sort messages by subject. Subject sorting is case-insensitive, and begining "Re:", -"A", "An", and "The" words are ignored. -

                -

                THREAD -

                - -

                Create thread index. This is the default. -

                -

                TREVERSE -

                - -

                List threads in the thread index with newest thread first. -

                -

                TSUBSORT -

                - -

                Sort thread by subject in thread index page. -

                -

                Non-Empty Elements -

                - -

                The following list of elements contain textual content, therefore, each element must -be explicitly closed with an element end tag (examples are given in Example -Resource File): -

                -

                BOTLINKS -

                - -

                Markup for defining the various hyperlinks at the bottom of converted messages. -See Navigational Links of Message Customization for usage of this element. -

                -

                DBFILE -

                - -

                Use name for the name of MHonArc database file. The default is ".mhonarc.db" -(or "MHONARC.DB" under MS-DOS). -

                -
                -
                NOTE - -

                You should not override the default name unless absolutely necessary, and -you are confident about what you are doing. -

                -

                DOCURL -

                - -

                URL to MHonArc documentation. The default is -"http://www.oac.uci.edu/indiv/ehood/mhonarc.html". -

                -

                EXCS -

                - -

                Set of message header fields to exclude from messages. See Excluding Fields of -Message Customization for usage of this element. -

                -

                FIELDORDER -

                - -

                The order the message header fields appear in messages. See Field Order of -Message Customization for usage of this element. -

                -

                FIELDSTYLES -

                - -

                The format specification for message header field values. See Field Formatting of -Message Customization for usage of this element. -

                -

                FOOTER -

                - -

                File to include at the end of the index page. See Include Files in Index Page -Customization for more information about the footer file. -

                -

                HEADER -

                - -

                File to include at the beginning of the index page. See Include Files in Index Page -Customization for more information about the header file. -

                -

                ICONS -

                - -

                The ICONS element is used to specify the icons that represent the different -content-types of messages. See Icons in Index Page Customization for usage of this -element. -

                -

                IDXFNAME -

                - -

                The name of the index file. The default is "maillist.html". -

                -

                LABELSTYLES -

                - -

                The format specification for message header field labels. See Field Formatting in -Message Customization for usage of this element. -

                -

                LISTBEGIN -

                - -

                Markup for beginning the main index list. See Listing Layout in Index Page -Customization for usage of this element. -

                -

                LITEMPLATE -

                - -

                Markup for an entry in the main index list. See Listing Layout in Index Page -Customization for usage of this element. -

                -

                LISTEND -

                - -

                Markup for terminating the main index list. See Listing Layout in Index Page -Customization for usage of this element. -

                -

                MAILTOURL -

                - -

                Url to use for e-mail hyperlinks. See E-mail Links in Message Customization for -usage of this element. -

                -

                MIMEARGS -

                - -

                Arguments to MIME filters. See Specifying Filters in MIME for usage of this -element. -

                -

                MIMEFILTERS -

                - -

                Routines for filtering messages. See Specifying Filters in MIME for usage of this -element. -

                -

                MSGFOOT -

                - -

                Footer text for converted messages. See Header and Footer in Message -Customization for usage of this element. -

                -

                MSGHEAD -

                - -

                Header text for converted messages. See Header and Footer in Message -Customization for usage of this element. -

                -

                MSGSEP -

                - -

                Perl regular expression that represents the message separator for mailbox files. The -default expression is "^From ". -

                -

                OTHERINDEXES -

                - -

                List of resource files (one per line) defining other index pages to generate when -creating, or updating, an archive. -

                -
                -
                CAUTION - -

                It is very important that each resource file specified defines the IDXFNAME -(or the TIDXFNAME and THREAD elements for a thread index) to prevent -overwriting of the default index pages. -

                -

                MHonArc will only store the name of the resource files listed in the database. -Therefore, for any subsequent updates the archive, the extra index resource files -must exist inorder to generate the extra index pages. -

                -
                -
                NOTE - -

                Since MHonArc will look in the archive location for resource files specified -with relative pathnames, you can keep the other index resource files in the -same location as the archive, and just specify the filenames for the -OTHERINDEXES element in the main resource file. -

                -

                When create resource files for extra indexes, make sure to explicitly set all -resources desired since some resource settings may no longer be set to the defaults -due to database settings, or from a previously read resource file. Ie. MHonArc does -not reset to the default settings when reading in the other resource files. -

                -

                PERLINC -

                - -

                Each line represents a path to search when requiring MIME filters. See Specifying -Filters in MIME for the use of this element. -

                -

                TFOOT -

                - -

                Markup that appears after the thread index listing. See Listing Layout in Thread -Index Customization for usage of this element. -

                -

                THEAD -

                - -

                Markup that appears before the thread index listing. See Listing Layout in Thread -Index Customization for usage of this element. -

                -

                TIDXFNAME -

                - -

                The name of the thread index file. The default is "threads.html". -

                -

                TIMEZONES -

                - -

                Each line of the TIMEZONES element defines a timezone acronym and its hour -offset from UTC/GMT (Universal Coordinate Time). The format of each line is -"timezone_acronym:hour_offset". Examples of timezone acronyms are: -UTC, PDT, EST. The hour offset is should be positive for timezones West of UTC, -and negative for time zones East of UTC. -

                -

                MHonArc has a default list of timezone acronyms defined with hour offsets. -Therefore, the list given in the resource file will augment the default list, unless the -"Override" attribute is specified. If "Override" is specified, the default list, -along with any other lists specified in previous TIMEZONES elements, are -discarded, and only the timezone acronyms specified in the TIMEZONES element -will be used. -

                -

                The following is the default value for TIMEZONES: -

                -
                <TIMEZONES>
                -UTC:0
                -GMT:0
                -AST:4
                -ADT:3
                -EST:5
                -EDT:4
                -CST:6
                -CDT:5
                -MST:7
                -MDT:6
                -PST:8
                -PDT:7
                -</TIMEZONES>
                -
                -
                - -

                Most of the time, the date used by MHonArc uses a hour offset instead of a -timezone acronym. However, mail messages may contain timezone acronyms in -received/sent dates and MHonArc must be told what the hour offset from UTC the -timezone acronym represents in order to properly sort messages by date. -

                -

                TITLE -

                - -

                Title for the main index page. The default is "Mail Index". -

                -

                TLEVELS -

                - -

                The maximum number of nested lists for the thread index. The default is 3. -

                -

                TLITXT -

                - -

                Markup for an entry in the thread index list. See Listing Layout in Thread Index -Customization for usage of this element. -

                -

                TOPLINKS -

                - -

                Markup for defining the various hyperlinks at the top of converted messages. See -Navigational Links in Message Customization for usage of this element. -

                -

                TTITLE -

                - -

                Title for the thread index page. The default is "Mail Thread Index". -

                -

                UMASK -

                - -

                Sets the umask for the MHonArc process. The value is treated as an octal number. -The resource is only applicable on Unix systems. -

                -
                -

                Example Resource File -

                - -
                <!-- MHonArc resource file
                -  -->
                -<SORT>
                -<TITLE>
                -MHonArc test
                -</TITLE>
                -
                -<TTITLE>
                -MHonArc test
                -</TTITLE>
                -
                -<!--=== Index Page Customizations =========================================-->
                -
                -<!-- Have LISTBEGIN contain last updated information
                -  -->
                -<LISTBEGIN>
                -<address>
                -Last updated: $LOCALDATE$<br>
                -$NUMOFMSG$ messages in chronological order<br>
                -</address>
                -<ul>
                -<li><a href="$TIDXFNAME$">Thread Index</a></li>
                -</ul>
                -<p>
                -Listing format is the following:
                -<p>
                -<ul><li> 
                -<strong>Subject</strong>
                -(# of follow-ups)
                -<em>From</em><br>
                -</ul>
                -<p>
                -<hr>
                -<ul>
                -</LISTBEGIN>
                -
                -
                -<!-- A compact listing template
                -  -->
                -<LITEMPLATE>
                -<li> 
                -<strong>$SUBJECT:40$</strong>
                -($NUMFOLUP$) <em>$FROMNAME$</em><br>
                -</LITEMPLATE>
                -
                -<LISTEND>
                -</ul>
                -<p>
                -<hr>
                -<strong>
                -<a href="http://foo.org/">Home</a>
                -</strong>
                -<p>
                -</LISTEND>
                -
                -<!--=== Thread Index Page Customizations ==================================-->
                -<THEAD>
                -<address>
                -Thread index<br>
                -Last updated: $LOCALDATE$<br>
                -$NUMOFMSG$ messages<br>
                -</address>
                -<ul>
                -<li><a href="$IDXFNAME$">Main Index</a></li>
                -</ul>
                -<hr>
                -</THEAD>
                -
                -<!--=== Message Customizations ============================================-->
                -<EXCS override>
                -apparently
                -errors-to 
                -followup
                -forward 
                -lines 
                -message-id
                -mime- 
                -nntp- 
                -originator 
                -path 
                -precedence 
                -received 
                -replied 
                -return-path 
                -status 
                -via 
                -x- 
                -</EXCS>
                -
                -<LABELSTYLES>
                --default-
                -subject:strong
                -from:strong
                -to:strong
                -</LABELSTYLES>
                -
                -<FIELDSTYLES>
                --default-
                -subject:strong
                -from:strong
                -to:strong
                -keywords:em
                -newsgroups:strong
                -</FIELDSTYLES>
                -
                -<MSGHEAD>
                -<address>
                -MHonArc test archive
                -</address>
                -</MSGHEAD>
                -
                -<MSGFOOT>
                -<strong>
                -<a href="http://foo.org/">Home</a> |
                -<a href="$IDXFNAME$">Main Index</a> |
                -<a href="$TIDXFNAME$">Thread Index</a>
                -</strong>
                -</MSGFOOT>
                -
                -<!--=== Icons =============================================================-->
                -<ICONS>
                -application/octet-stream:http://foo.org/icons/binary.xbm
                -application/postscript:http://foo.org/icons/postscript.xbm
                -audio/basic:http://foo.org/icons/sound.xbm
                -image/gif:http://foo.org/icons/image.xbm
                -image/jpeg:http://foo.org/icons/image.xbm
                -image/tiff:http://foo.org/icons/image.xbm
                -multipart/alternative:http://foo.org/icons/alternative.xbm
                -multipart/digest:http://foo.org/icons/text.xbm
                -multipart/mixed:http://foo.org/icons/mixed.xbm
                -multipart/parallel:http://foo.org/icons/mixed.xbm
                -text/richtext:http://foo.org/icons/mixed.xbm
                -text/html:http://foo.org/icons/mixed.xbm
                -text/plain:http://foo.org/icons/text.xbm
                -unknown:http://foo.org/icons/unknown.doc.xbm
                -video/mpeg:http://foo.org/icons/movie.xbm
                -video/quicktime:http://foo.org/icons/movie.xbm
                -</ICONS>
                -
                -
                - -
                -

                Notes on Resource File -

                - -
                  -
                • Elements can be duplicated. The following elements augment previous -instances of themselves: -

                  -

                  The Override attribute will discard previous settings of the element. -

                • If duplicate instances of other elements exist, the last instance takes -precedence. -

                • If an element only accepts a single line of content, then the last line is used -for the element's content. -

                • If elements have conflicting resource settings (eg. NOSORT and SORT), the -last element defined takes precedence. -

                • Resource file settings override environment variables. -

                • Command-line options override any settings in the resource file. -

                • If you want to do an exact match of a field in the EXCS element, append a -'$' after the field name. -

                - -
                -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/removing.html b/doc/removing.html deleted file mode 100644 index adb28f5..0000000 --- a/doc/removing.html +++ /dev/null @@ -1,112 +0,0 @@ - - - -MHonArc v1.2.2 -- Removing Messages - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
                - -

                Removing Messages -

                - -

                Removing messages from an archive is done via the -rmm option. Messages to be -deleted are designated by message numbers on the command-line. -

                -

                Example -

                -
                % mhonarc -rmm 24 28 39 48
                -Removing messages from ./maillist.html ...
                -        Removing message 24
                -        Removing message 28
                -        Removing message 39
                -        Removing message 48
                -
                -Writing mail ...
                -Writing tmp/maillist.html ...
                -Writing tmp/threads.html ...
                -45 messages
                -
                -
                - -
                -

                Message Numbers -

                - -

                Normally, you will never have to worry about message numbers unless you want -to remove messages from an archive. Therefore, you will need to know how -MHonArc assigns message numbers when processing messages. -

                -

                When a message is processed, the smallest available number is assigned to it, -starting with 0. The number assigned to a message becomes part of the filename -for the HTML version of the message (eg. msg00042.html). -

                -

                To avoid message number conflicts, MHonArc determines the smallest available -number by finding the largest assigned number and adding one to it. -

                -
                -

                Scanning an Archive -

                - -

                You will quickly find out that finding the message numbers for a messages you -want to remove can be a cumbersome task if all you have to work with are the -message filenames. To ease this task, MHonArc gives you the ability to scan an -archives contents via the -scan command-line option. -

                -

                Example -

                - -
                % mhonarc -scan
                -100 messages in .:
                -
                -Msg #  YY/MM/DD  From             Subject                                      
                ------  --------  ---------------  ---------------------------------------------
                -  513  95/02/09  Rick Silterra    EDComment(sic)                               
                -  517  95/02/09  Earl Hood        Re: DTD2HTML                                 
                -  512  95/02/09  Earl Hood        Re: edc2html                                 
                -  516  95/02/09  John Barnum      Re: DTD2HTML                                 
                -  515  95/02/09  Earl Hood        Re: DTD2HTML                                 
                -  511  95/02/09  Rick Silterra    edc2html                                     
                -  514  95/02/08  John Barnum      DTD2HTML                                     
                -  510  95/02/06  jflores          mhonarc_diagnostics.doc.html                 
                -  509  95/02/06  web              Dr.Web: Status Review + Thank You            
                -  508  95/02/05  Earl Hood        Re: sgml to html converters                  
                -  507  95/02/03  Aileen Barry     sgml to html converters                      
                -  506  95/01/28  Earl Hood        Re: MHonarc: Deleting Messages from an archiv
                -  505  95/01/28  Floyd Moore      MHonarc: Deleting Messages from an archive   
                -  504  95/01/25  Earl Hood        Re: MHonArc                                  
                -  503  95/01/25  Earl Hood        Re: MHonArc                                  
                -...
                -
                -
                - -

                The messages are listed in the same order as they are listed in the archive's index -page. You will notice that the list order does not necessarily correspond with -message number order. If you always want the messages listed in message number -order when scanning, use the following: -

                -
                % mhonarc -scan -nosort -noreverse 
                -82 messages in .:
                -
                -Msg #  YY/MM/DD  From             Subject                                      
                ------  --------  ---------------  ---------------------------------------------
                -    0  94/05/09  Michael O´Sulli  Re: Finger within an html                    
                -    1  94/04/31  John M. Troyer   Re: TROFF to HTML Converters                 
                -    2  94/05/04  John D. Kilburg  ANNOUNCE: Chimera 1.53                       
                -    3  94/05/17  Stephen Billing  Re: government www?                          
                -    4  94/05/21  C. Emory Tate    Re: government www?                          
                -    5  94/05/24  Daniel W. Conno  Re: Comments on HTML 2.0 document/DTD        
                -    6  94/05/24  Dan Connolly     Re: Validating HTML documents:               
                -    7  94/05/25  Henrik Frystyk   CERN Common World-Wide Web Library 2.16pre2 A
                -    8  94/06/04  Denesh Bhabuta   Re: Atari on www (revisited)                 
                -    9  94/06/07  Dale Newfield    ANNOUNCE: Come explore The Edge - SIGGRAPH 94
                -   10  94/06/11  Roy T. Fielding  Announcing libwww-perl 0.12                  
                -...
                -
                -
                - - -
                -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/doc/resources.html b/doc/resources.html new file mode 100644 index 0000000..ecf6ba5 --- /dev/null +++ b/doc/resources.html @@ -0,0 +1,383 @@ + + + +MHonArc -- Resources + + + + +

                +[Prev][Next][TOC][FAQ][Bugs][Home] +

                + +
                +

                Resources

                + +

                All the behavior of MHonArc is controlled by resources. +Resources may be set via environment variables (envariables +for short), command-line options, and/or elements in a resource file. +For information on the syntax of a MHonArc resource file, +see the RCFILE resource. +

                + + +
                +

                Resource Types

                + +

                There are four basic types of resources: +

                + +
                +
                boolean +

                Boolean resources are resources that are either +on or off; active or deactive; or true or false. They basically +work as flags for controlling MHonArc behavior. +

                +
                +
                string +

                The resource represents a string value. How the +string value is used depends on the resource. +

                +
                +
                list +

                The resource is a list of values. How the list +is used depends on the resource. +

                +
                +
                one-shot +

                One-shot resources are resources that +apply only to the current MHonArc process. You can +tell if a resource is a one-shot by checking if the resource +cannot be defined by a resource file element. One-shot +resources are set only by command-line options or envariables. +

                +
                + +
                + +

                A resource's type can be determined by reading the description +for the resource. +

                + +

                All resources, except one-shots, are stored with the archive +in a simple database. Therefore, after the first time you run +MHonArc on an archive, you do not need to respecify the +resources. MHonArc will remember your settings so subsequent +archive updates are faster to execute. +

                + + +
                +

                Resource Index

                + +

                Each resource is described on its own page. +Each resource page uses the following template: +

                + +
                +
                +
                Syntax
                +

                Brief synopsis on how the resource can be defined. +Command-line options take precedence over resource file elements. +Resource file elements take precedence over environment +variables ("envariables" for short). See +RCFILE for more information +on how resources are defined in a resource file. See +your system's documentation on how to define +envariables.

                +
                +
                Description
                +

                Description of the resource. +

                +
                Default Setting
                +

                The default value of the resource, if applicable. +

                +
                Resource Variables
                +

                Applicable resource variables that can be used for the resource. +See RCFILE for information on +the usage of resource variables. +

                +
                Examples
                +

                Example uses of the resource. +

                +
                Version
                +

                The version of MHonArc the resource became available. +

                +
                See Also
                +

                Links to any related resources. +

                +
                +
                + +

                Resource list

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

                ADDAUTHORBEGINAUTHOREND
                AUTHSORTBOTLINKSCHARSETCONVERTERS
                CONLENDAYBEGINDAYEND
                DBFILEDECODEHEADSDEFINEDERIVED
                DEFINEVARDEFRCFILEDOC
                DOCURLEDITIDXEXCS
                EXPIREAGEEXPIREDATEFIELDORDER
                FIELDSBEGFIELDSENDFIELDSTYLES
                FLDBEGFLDENDFOLREFS
                FOOTERFORCEGENIDX
                GMTDATEFMTHEADBODYSEPHEADER
                ICONSIDXFNAMEIDXLABEL
                IDXPGBEGINIDXPGENDIDXPREFIX
                IDXSIZEINCLUDELABELBEG
                LABELENDLABELSTYLESLISTBEGIN
                LISTENDLITEMPLATELOCALDATEFMT
                LOCKDELAYLOCKTRIESMAILTO
                MAILTOURLMAINMAXSIZE
                MHPATTERNMIMEARGSMIMEFILTERS
                MODTIMEMONTHSMONTHSABR
                MSGFOOTMSGGMTDATEFMTMSGHEAD
                MSGLOCALDATEFMTMSGPGBEGINMSGPGEND
                MSGSEPMULTIPGNEWS
                NEXTBUTTONNEXTBUTTONIANEXTLINK
                NEXTLINKIANEXTPGLINKNEXTPGLINKIA
                OTHERINDEXESOUTDIRPERLINC
                PREVBUTTONPREVBUTTONIAPREVLINK
                PREVLINKIAPREVPGLINKPREVPGLINKIA
                QUIETRCFILEREVERSE
                RMMSCANSINGLE
                SORTSUBJECTBEGINSUBJECTEND
                SUBJECTHEADERSUBSORTTCONTBEGIN
                TCONTENDTFOOTTHEAD
                THREADTIDXFNAMETIDXLABEL
                TIDXPGBEGINTIDXPGENDTIDXPREFIX
                TIMEZONESTINDENTBEGINTINDENTEND
                TITLETLEVELSTLIEND
                TLINONETLINONEENDTLITXT
                TNEXTBUTTONTNEXTBUTTONIATNEXTLINK
                TNEXTLINKIATNEXTPGLINKTNEXTPGLINKIA
                TOPLINKSTPREVBUTTONTPREVBUTTONIA
                TPREVLINKTPREVLINKIATPREVPGLINK
                TPREVPGLINKIATREVERSETSINGLETXT
                TSUBJECTBEGTSUBJECTENDTSUBLISTBEG
                TSUBLISTENDTTITLETTOPBEGIN
                TTOPENDUMASKWEEKDAYS
                WEEKDAYSABR

                + + + +
                + +

                +[Prev][Next][TOC][FAQ][Bugs][Home] +

                + + + +
                +
                +97/05/15 17:14:31
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/add.html b/doc/resources/add.html new file mode 100644 index 0000000..b4a5a7e --- /dev/null +++ b/doc/resources/add.html @@ -0,0 +1,116 @@ + + + +MHonArc Resources: ADD + + + +
                +MHonArc Resource List
                +
                + +
                +

                ADD

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-add folder1 ...
                +-add < single-message +

                +
                + +
                + + +
                +

                Description

                + +

                The ADD resource instructs MHonArc to add messages +to an existing archive. The archive specified does not exist, +MHonArc will automatically create the archive. If input +is coming from standard in, then the input is treated as a single +message to add to the archive. +

                + +

                When adding, MHonArc will skip any messages that +already exists in the archive. This allows one to have MHonArc +rescan a mail folder only add any new messages found. +

                + + +
                +

                Default Setting

                + +

                Off +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                The following example shows adding a mail folder: +

                + +
                +    % mhonarc -outdir /home/ehood/mailarch -add inbox
                +
                + +

                The following shows how a single message can be added. +The message comes from the output of the MH show +program: +

                + +
                +    % show -noshow -noheader | mhonarc -add
                +
                + + + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                OUTDIR +

                + + +
                +
                +97/05/13 17:29:03
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/authorbegin.html b/doc/resources/authorbegin.html new file mode 100644 index 0000000..ea7c1a8 --- /dev/null +++ b/doc/resources/authorbegin.html @@ -0,0 +1,214 @@ + + + +MHonArc Resources: AUTHORBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                AUTHORBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<AUTHORBEGIN>
                +markup ...
                +</AUTHORBEGIN>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                AUTHORBEGIN defines the beginning markup of an author group +in the main index if the +AUTHSORT +reosource is set. +An author group is a group of messages all from the +same author. +

                + +

                Any message related resource variables available for the AUTHORBEGIN +evaluate based on information from the first message in the group. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following example resource settings cause the main index +to be sorted by author. The listing will contain each author's +name followed by a sub-listing of the author's messages: +

                + +
                +<AuthSort>
                +
                +<AuthorBegin>
                +<li><strong>$FROMNAME$</strong>
                +<ul>
                +</AuthorBegin>
                +
                +<AuthorEnd>
                +</li></ul>
                +</AuthorEnd>
                +
                +<LITemplate>
                +<li>$SUBJECT$</li>
                +</LITemplate>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +AUTHOREND, +AUTHSORT +

                + + +
                +
                +97/05/13 17:29:04
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/authorend.html b/doc/resources/authorend.html new file mode 100644 index 0000000..83963d4 --- /dev/null +++ b/doc/resources/authorend.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: AUTHOREND + + + +
                +MHonArc Resource List
                +
                + +
                +

                AUTHOREND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<AUTHOREND>
                +markup ...
                +</AUTHOREND>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                AUTHOREND defines the end markup of an author group +in the main index if the +AUTHSORT +reosource is set. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +AUTHORBEGIN, +AUTHSORT +

                + + +
                +
                +97/05/13 17:29:04
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/authsort.html b/doc/resources/authsort.html new file mode 100644 index 0000000..a6a1bbf --- /dev/null +++ b/doc/resources/authsort.html @@ -0,0 +1,102 @@ + + + +MHonArc Resources: AUTHSORT + + + +
                +MHonArc Resource List
                +
                + +
                +

                AUTHSORT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_AUTHSORT=[ 0 | 1 ] +

                +
                + +
                Element
                +

                +<AUTHSORT>
                +<NOAUTHSORT>
                + +

                +
                + +
                Command-line Option
                +

                +-authsort
                +-noauthsort +

                +
                + +
                + + +
                +

                Description

                + +

                When AUTHSORT is set, messages are sorted by author +in the main index. +

                + + +
                +

                Default Setting

                + +

                Off. +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +SORT, +SUBSORT +

                + + +
                +
                +97/05/13 17:29:05
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/botlinks.html b/doc/resources/botlinks.html new file mode 100644 index 0000000..75b353e --- /dev/null +++ b/doc/resources/botlinks.html @@ -0,0 +1,405 @@ + + + +MHonArc Resources: BOTLINKS + + + +
                +MHonArc Resource List
                +
                + +
                +

                BOTLINKS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<BOTLINKS>
                +markup ...
                +</BOTLINKS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                BOTLINKS defines the markup for the links at the bottom +of a message page. Its usage is analagous to the +TOPLINKS resource, but tends +to be more verbose. However, you can define the resource +anyway you desire. +

                + + +
                +

                Default Setting

                + +

                The following represents the default setting when there are +main and thread indexes. References to either index will not +show up if either index does not exist. +

                + +
                +<BotLinks>
                +<HR>
                +<UL>
                +$PREVLINK$$NEXTLINK$
                +$TPREVLINK$$TNEXTLINK$
                +<LI>Index(es):
                +<UL>
                +<LI><A HREF="$IDXFNAME$#$MSGNUM$">
                +<STRONG>Main</STRONG></A></LI>
                +<LI><A HREF="$TIDXFNAME$#$MSGNUM$">
                +<STRONG>Thread</STRONG></A></LI>
                +</UL>
                +</LI>
                +</UL>
                +</BotLinks>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +IDXFNAME, +NEXTLINK, +PREVLINK, +TIDXFNAME, +TNEXTLINK, +TOPLINKS, +TPREVLINK +

                + + +
                +
                +97/05/13 17:29:06
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/charsetconverters.html b/doc/resources/charsetconverters.html new file mode 100644 index 0000000..081211c --- /dev/null +++ b/doc/resources/charsetconverters.html @@ -0,0 +1,223 @@ + + + +MHonArc Resources: CHARSETCONVERTERS + + + +
                +MHonArc Resource List
                +
                + +
                +

                CHARSETCONVERTERS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<CHARSETCONVERTERS>
                +charset-filter-specification
                +</CHARSETCONVERTERS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The CHARSETCONVERTERS resource specifies Perl routines to call +for filtering characters of a character set to HTML legal characters. +The filtering occurs for message header data encoded +according to the MIME standard. +The following example shows a header with encoded data: +

                + +
                +From: =?US-ASCII?Q?Keith_Moore?= <moore@cs.utk.edu>
                +To: =?ISO-8859-1?Q?Keld_J=F8rn_Simonsen?= <keld@dkuug.dk>
                +CC: =?ISO-8859-1?Q?Andr=E9_?= Pirard <PIRARD@vm1.ulg.ac.be>
                +Subject: =?ISO-8859-1?B?SWYgeW91IGNhbiByZWFkIHRoaXMgeW8=?=
                + =?ISO-8859-2?B?dSB1bmRlcnN0YW5kIHRoZSBleGFtcGxlLg==?=
                +
                + +

                This CHARSETCONVERTERS resource can only be defined via the +resource file. Each line of the element specifies a character set, +the Perl routine for filtering the character set, and the Perl source +file containing the routine. +

                + +

                Example:

                +
                +<CharsetConverters>
                +iso-8859-1:iso_8859'str2sgml:iso8859.pl
                +</CharsetConverters>
                +
                + +

                The first field is the character set specification. The second field +is the routine name (which should contain a package qualifier). +The third field is the source file the routine is defined. The +source file is optional if the routine is known to be define in +an already listed source file. +

                + +
                +
                NOTE
                +

                Package qualification must use Perl 4 syntax. The '::' +qualification is not supported yet. +

                +
                +
                + +

                There are some special character set specifications. They are +as follows: +

                + +
                + +
                plain
                +

                This specifies text that is not explicitly encoded in a +specific character set. +

                +
                + +
                default
                +

                This specifies the default routine to invoke for encoded +data is no specific character specification exists for the data. +

                +
                + +
                + +

                There are some special character set converter routines +values. They are as follows: +

                + +
                + +
                -ignore-
                +

                Leave the data "as-is". I.e. The MIME encoding will be +preserved. +

                +
                + +
                -decode-
                +

                Just decode the data. This is useful if it is known that +the characters set is the native character set for the system. +

                + +
                +
                WARNING
                +

                If the decoded data contains the characters '<', '>', +and '&', this may conflict with HTML markup. See +DECODEHEADS +where "-decode-" can be used. +

                +
                +
                + +
                + +
                + +

                Each charset converter function is invoked as follows: +

                + +
                +    $converted_data = &function($data, $charset);
                +
                + +

                The data passed in will already be decoded from quoted-printable +or base64 (as specified by the MIME syntax). Therefore, the +called routine will be passed the raw byte data. It is important +that the routine convert the data into a format suitable to be +included in HTML markup. +

                + + + +
                +

                Default Setting

                + +
                +<CharsetConverters>
                +plain:main'convert_line
                +us-ascii:main'convert_line
                +iso-8859-1:iso_8859'str2sgml:iso8859.pl
                +iso-8859-2:iso_8859'str2sgml:iso8859.pl
                +iso-8859-3:iso_8859'str2sgml:iso8859.pl
                +iso-8859-4:iso_8859'str2sgml:iso8859.pl
                +iso-8859-5:iso_8859'str2sgml:iso8859.pl
                +iso-8859-6:iso_8859'str2sgml:iso8859.pl
                +iso-8859-7:iso_8859'str2sgml:iso8859.pl
                +iso-8859-8:iso_8859'str2sgml:iso8859.pl
                +iso-8859-9:iso_8859'str2sgml:iso8859.pl
                +iso-8859-10:iso_8859'str2sgml:iso8859.pl
                +default:-ignore-
                +</CharsetConverters>
                +
                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                The following example specifies to just decode iso-8859-1 +character data since it is the default character set used by most +browsers: +

                + +
                +<CharsetConverters>
                +iso-8859-1:-decode-
                +</CharsetConverters>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +DECODEHEADS +

                + + +
                +
                +97/05/13 17:29:08
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/conlen.html b/doc/resources/conlen.html new file mode 100644 index 0000000..6e7bcdf --- /dev/null +++ b/doc/resources/conlen.html @@ -0,0 +1,100 @@ + + + +MHonArc Resources: CONLEN + + + +
                +MHonArc Resource List
                +
                + +
                +

                CONLEN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_CONLEN=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<CONLEN>
                +<NOCONLEN> +

                +
                + +
                Command-line Option(s)
                +

                +-conlen
                +-noconlen +

                +
                + +
                + + +
                +

                Description

                + +

                If the CONLEN resource is on, MHonArc will use the +Content-Length field in message headers to determine +the proper end of a message when reading UUCP style mailbox files. +This resource can be very helpful +for users that have an MTA that defines Content-Length +and does not escape "From" lines. +

                + + +
                +

                Default Setting

                + +

                Off +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +MSGSEP +

                + + +
                +
                +97/05/13 17:29:07
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/daybegin.html b/doc/resources/daybegin.html new file mode 100644 index 0000000..bd15ce4 --- /dev/null +++ b/doc/resources/daybegin.html @@ -0,0 +1,217 @@ + + + +MHonArc Resources: DAYBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                DAYBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<DAYBEGIN>
                +markup ...
                +</DAYBEGIN>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                DAYBEGIN defines the beginning markup of a day group +in the main index if the +SORT +reosource is set. +A day group is a group of messages all from the +same day. +

                + +

                Any message related resource variables available for the DAYBEGIN +evaluate based on information from the first message in the group. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following example resource settings cause the main index +to be sorted by date. The listing will contain each different day +followed by a sub-listing of the messages from that day: +

                + +
                +<Sort>
                +<MsgLocalDateFmt>
                +%B %d, %Y
                +</MsgLocalDateFmt>
                +
                +<DayBegin>
                +<li><strong>$FROMNAME$</strong>
                +<ul>
                +</DayBegin>
                +
                +<DayEnd>
                +</li></ul>
                +</DayEnd>
                +
                +<LITemplate>
                +<li>$SUBJECT$, $FROMNAME$</li>
                +</LITemplate>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +DAYEND, +SORT +

                + + +
                +
                +97/05/13 17:29:07
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/dayend.html b/doc/resources/dayend.html new file mode 100644 index 0000000..0c445c2 --- /dev/null +++ b/doc/resources/dayend.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: DAYEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                DAYEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<DAYEND>
                +markup ...
                +</DAYEND>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                DAYEND defines the end markup of an day group +in the main index if the +SORT +reosource is set. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +DAYBEGIN, +SORT +

                + + +
                +
                +97/05/13 17:29:08
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/dbfile.html b/doc/resources/dbfile.html new file mode 100644 index 0000000..d6571ba --- /dev/null +++ b/doc/resources/dbfile.html @@ -0,0 +1,105 @@ + + + +MHonArc Resources: DBFILE + + + +
                +MHonArc Resource List
                +
                + +
                +

                DBFILE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_DBFILE=filename +

                +
                + +
                Element
                +

                +<DBFILE>
                +filename
                +</DBFILE>
                +

                +
                + +
                Command-line Option
                +

                +-dbfile filename +

                +
                + +
                + + +
                +

                Description

                + +

                DBFILE is the filename to use for the MHonArc database +file. +

                + +
                +
                NOTE +

                You should not override the default name unless +absolutely necessary, and you are confident about what you are doing. +

                +
                +
                + + + +
                +

                Default Setting

                + +

                ".mhonarc.db" ("MHONARC.DB" for MS-DOS +users). +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:09
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/decodeheads.html b/doc/resources/decodeheads.html new file mode 100644 index 0000000..9ebf0a9 --- /dev/null +++ b/doc/resources/decodeheads.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: DECODEHEADS + + + +
                +MHonArc Resource List
                +
                + +
                +

                DECODEHEADS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_DECODEHEADS=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<DECODEHEADS>
                +<NODECODEHEADS> +

                +
                + +
                Command-line Option(s)
                +

                +-decodeheads
                +-nodecodeheads +

                +
                + +
                + + +
                +

                Description

                + +

                MIME encoded message header data is decoded when creating +HTML output and the (relevant) data stored in the database stays +in encoded form. The DECODEHEADS resource can be set to decode +"decode-only" charsets (as specified by the +CHARSETCONVERTERS resource) +when message headers are read. Hence, the +decode-only charsets will be stored in decoded form. Regular MIME +processing is still done to still-encoded data when generating output. +

                + + + +
                +

                Default Setting

                + +

                Off +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +CHARSETCONVERTERS +

                + + +
                +
                +97/05/13 17:29:10
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/definederived.html b/doc/resources/definederived.html new file mode 100644 index 0000000..8861475 --- /dev/null +++ b/doc/resources/definederived.html @@ -0,0 +1,448 @@ + + + +MHonArc Resources: DEFINEDERIVED + + + +
                +MHonArc Resource List
                +
                + +
                +

                DEFINEDERIVED

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<DEFINEDERIVED>
                +filename
                +file contents ...
                +</DEFINEDERIVED>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                DEFINEDERIVED is used to define extra files that are generated +for each message processed. DEFINEDERIVED can only be specified +in a resource file and may occur mutliple times to define multiple +files to be created. The first line of the <DEFINEDERIVED> +element is the name of the file. All subsequent lines represent +the content of the file. +

                + + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following example shows how user defined files can be +used to provide a framed navigational view of an archive. Note +how the filenames contain resource variables to uniquely qualify +the name for each message. +

                + +
                +
                Note
                +

                This +example is not complete since other resources need to be defined +to make everything work. +

                +
                +
                + +

                The following derived file is the main file the index pages +will link to. It defines the subframe definitions for the +navigational links and the message data: +

                + +
                +<DefineDerived>
                +frm$MSGNUM$.html
                +<html>
                +<head>
                +<title>Message View</title>
                +</head>
                +<frameset rows="75,*">
                +<frame src="nav$MSGNUM$.html" name="NAV">
                +<frame src="msg$MSGNUM$.html" name="MESSAGE">
                +</frameset>
                +</html>
                +</DefineDerived>
                +
                + +

                The following derived file defines the navigational links +for a message. The links will be displayed in a frame +above the converted message. +

                + +
                +<DefineDerived>
                +nav$MSGNUM$.html
                +<html>
                +<head>
                +<title>Message Navigation</title>
                +</head>
                +<body>
                +<table cellpadding=0 cellspacing=0 cols=3 border=1 width="100%">
                +<tbody>
                +<tr align="center">
                +<th colspan=3><strong>Thread Links</strong></th>
                +<th colspan=3><strong>Date Links</strong></th>
                +</tr>
                +<tr align="center">
                +<td>$TPREVBUTTON$</td>
                +<td>$TNEXTBUTTON$</td>
                +<td><a $FRAME-IDX$ href="$TIDXFNAME$#$MSGNUM$">Index</a></td>
                +<td>$PREVBUTTON$</td>
                +<td>$NEXTBUTTON$</td>
                +<td><a $FRAME-IDX$ href="$IDXFNAME$#$MSGNUM$">Index</a></td>
                +</tr>
                +</tbody>
                +</table>
                +</body>
                +</html>
                +</DEFINEDERIVED>
                +
                + + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:10
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/definevar.html b/doc/resources/definevar.html new file mode 100644 index 0000000..4ee2ef4 --- /dev/null +++ b/doc/resources/definevar.html @@ -0,0 +1,142 @@ + + + +MHonArc Resources: DEFINEVAR + + + +
                +MHonArc Resource List
                +
                + +
                +

                DEFINEVAR

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<DEFINEVAR>
                +variable-name
                +value ...
                +</DEFINEVAR>
                +

                +
                + +
                Command-line Option
                +

                +-definevars variable-specification-list +

                +
                + +
                + + +
                +

                Description

                + +

                DEFINEVAR is used for creating user-defined resource variables. +DEFINEVAR can be defined on the command-line or in the resource file. +

                + +

                On the command-line, the option is called -definevars +(note the 's'). The following argument after -definevars +is treated as a variable specification list. The specification list +is a string containing name/value pairs with the following format:

                + +

                NAME=VALUE

                + +

                If VALUE contains whitespace, then it must be surrounded +by single or double quotes. Use single quotes if the VALUE +contained double quotes. Use double quotes if the VALUE +contains single quotes. Multiple name/value pairs are separated +by whitespace. +

                + +

                In a resource file the element may occur mutliple times +to define multiple variables. The first line of the <DEFINEVAR> +element is the name of the variables. All subsequent lines represent +the content of the variable.

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                Variables that are applicable to where user-defined +variable is referenced. +

                + + +
                +

                Examples

                + +

                The following is a simple example of defining a variable to +represent the base text for the title of an archive: +

                + +
                +<DefineVar chop>
                +MAIN-TITLE
                +Comp.lang.perl.misc 
                +</DefineVar>
                +
                + +

                Now, the variable can be refernced as follows: +

                + +
                +<TTitle chop>
                +$MAIN-TITLE$ (thread)
                +</TTitle>
                +
                + +

                If you wanted to use the same resource file for multiple arcvhives +it may better to define $MAIN-TITLE$ on the command-line +as follows: +

                + +
                +    % mhonarc -definevars "MAIN-TITLE='mhonarc mailing list'" ...
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:11
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/defrcfile.html b/doc/resources/defrcfile.html new file mode 100644 index 0000000..2f4242c --- /dev/null +++ b/doc/resources/defrcfile.html @@ -0,0 +1,110 @@ + + + +MHonArc Resources: DEFRCFILE + + + +
                +MHonArc Resource List
                +
                + +
                +

                DEFRCFILE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_DEFRCFILE=filename +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                DEFRCFILE points to the default resource file. The file +is read each time MHonArc is invoked. The file is +read before processing the resource file specified by the +RCFILE resource and before command-line options +are processed. +The default resource file allows you change the default values resource +values of MHonArc. +

                + + +
                +

                Default Setting

                + +

                user-home-path/.mhonarc.rc +

                + +

                If the above does not exist, then: +

                + +

                MHonArc-library-path/.mhonarc.rc +

                + +

                Replace .mhonarc.rc with MHONARC.RC +if running under MSDOS/Windows. + + +


                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +RCFILE +

                + + +
                +
                +97/05/13 17:29:12
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/doc.html b/doc/resources/doc.html new file mode 100644 index 0000000..86973df --- /dev/null +++ b/doc/resources/doc.html @@ -0,0 +1,96 @@ + + + +MHonArc Resources: DOC + + + +
                +MHonArc Resource List
                +
                + +
                +

                DOC

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_DOC=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<DOC>
                +<NODOC> +

                +
                + +
                Command-line Option(s)
                +

                +-doc
                +-nodoc +

                +
                + +
                + + +
                +

                Description

                + +

                When set, a link to the MHonArc documentation will be included +at the bottom of each index page.

                + + + +
                +

                Default Setting

                + +

                On +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +DOCURL +

                + + +
                +
                +97/05/13 17:29:12
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/docurl.html b/doc/resources/docurl.html new file mode 100644 index 0000000..d3766d4 --- /dev/null +++ b/doc/resources/docurl.html @@ -0,0 +1,95 @@ + + + +MHonArc Resources: DOCURL + + + +
                +MHonArc Resource List
                +
                + +
                +

                DOCURL

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_DOCURL=URL +

                +
                + +
                Element
                +

                +<DOCURL>
                +URL
                +</DOCURL>
                +

                +
                + +
                Command-line Option
                +

                +-docurl URL +

                +
                + +
                + + +
                +

                Description

                + +

                DOCURL defines the URL to the MHonArc documentation. +

                + + +
                +

                Default Setting

                + +

                http://www.oac.uci.edu/indiv/ehood/mhonarc.html +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +DOC +

                + + +
                +
                +97/05/13 17:29:13
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/editidx.html b/doc/resources/editidx.html new file mode 100644 index 0000000..0c93ffd --- /dev/null +++ b/doc/resources/editidx.html @@ -0,0 +1,94 @@ + + + +MHonArc Resources: EDITIDX + + + +
                +MHonArc Resource List
                +
                + +
                +

                EDITIDX

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-editidx +

                +
                + +
                + + +
                +

                Description

                + +

                EDITIDX is activated only by a command-line option. This +instructs MHonArc to edit all message files and recreate +index pages. Its main use is when you want to make resource changes +without adding a new message to an archive. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +RCFILE +

                + + +
                +
                +97/05/13 17:29:13
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/excs.html b/doc/resources/excs.html new file mode 100644 index 0000000..c5e0c1a --- /dev/null +++ b/doc/resources/excs.html @@ -0,0 +1,139 @@ + + + +MHonArc Resources: EXCS + + + +
                +MHonArc Resource List
                +
                + +
                +

                EXCS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<EXCS>
                +field-name
                +field-name
                +...
                +</EXCS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The EXCS resource allows you to specify what fields should be +excluded in the HTML output.

                + +

                Each line of the <EXCS> element specifies a mail header +field to exclude in the converted HTML output. Each line is treated +as a Perl regular expression (NOTE: the regular +expression is already anchored to the begining of the line).

                + +

                Any fields you specify for the EXCS resource will +augment the default list, unless the "Override" attribute +is specified. If "Override" is specified, the default +list is discarded along with any other lists specified from previous +<EXCS> elements; and only header fields specified in the +<EXCS> element are excluded.

                + + +
                +

                Default Setting

                + +
                +<Excs>
                +content-
                +errors-to
                +forward
                +lines
                +message-id
                +mime-
                +nntp-
                +originator
                +path
                +precedence
                +received
                +replied
                +return-path
                +status
                +via
                +x-
                +</Excs>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following example shows how to exclude all message headers: +

                + +
                +<Excs Override>
                +.*
                +</Excs>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:14
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/expireage.html b/doc/resources/expireage.html new file mode 100644 index 0000000..453020f --- /dev/null +++ b/doc/resources/expireage.html @@ -0,0 +1,150 @@ + + + +MHonArc Resources: EXPIREAGE + + + +
                +MHonArc Resource List
                +
                + +
                +

                EXPIREAGE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_EXPIREAGE=seconds +

                +
                + +
                Element
                +

                +<EXPIREAGE>
                +seconds
                +</EXPIREAGE>
                +

                +
                + +
                Command-line Option
                +

                +-expireage seconds +

                +
                + +
                + + +
                +

                Description

                + +

                EXPIREAGE specifies the time in seconds from the current +time if a message has expired. I.e. If the difference +between the current time and the message time is greater +than EXPIREAGE, the message is expired. Expired messages +do not get added into an archive, and any archived +expired messages will get automatically removed during +an archive update. +

                + +

                EXPIREAGE is specified in seconds. The following table +shows common time periods in seconds: +

                + + + + + + + + + + + + + + + + + + + +
                Time periodEquivalance in seconds
                day86400
                week (7 days)604800
                month (30.5 days)2635200
                year (365 days)31536000
                + +
                +
                NOTE
                +

                Setting EXPIREAGE to zero turns off the +EXPIREAGE check. +

                +
                +
                + +

                If you want to control expiration of messages based +on a specific date, then see +EXPIREDATE. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                EXPIREAGE is useful for "message from the last ..." archives. +For example, if you are archiving a mailing list with much traffic, +you may want to have an archive that shows only messages from the +last 7 days (week). Set set EXPIREAGE as follows:

                + +
                +<ExpireAge>
                +604800
                +</ExpireAge>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXPIREDATE +

                + + +
                +
                +97/05/13 17:29:15
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/expiredate.html b/doc/resources/expiredate.html new file mode 100644 index 0000000..882926e --- /dev/null +++ b/doc/resources/expiredate.html @@ -0,0 +1,147 @@ + + + +MHonArc Resources: EXPIREDATE + + + +
                +MHonArc Resource List
                +
                + +
                +

                EXPIREDATE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_EXPIREDATE=date +

                +
                + +
                Element
                +

                +<EXPIREDATE>
                +date
                +</EXPIREDATE>
                +

                +
                + +
                Command-line Option
                +

                +-expiredate date +

                +
                + +
                + + +
                +

                Description

                + +

                If defined, EXPIREDATE sets the expiration date for messages +in an archive. During an archive update, any messages with +dates less than the EXPIREDATE are automatically removed. If +a message to be added is older than EXPIREDATE, it is not added. +

                + +

                The syntax for EXPIREDATE is as follows: +

                + +
                +

                DD Mon YY HH:MM:SS Zone +

                +
                + +

                24 hour time must be used. +The timezone is optional. If non-existent, the local zone is used. +If a symbolic timezone is used (eg: "EST"), make sure it is defined +in the +TIMEZONES resource. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                EXPIREDATE is useful if you want to insure messages older +than a specified date do not get archived. For example, if +you want to make sure that no message before 1997 is added, then +define EXPIREDATE as follows: +

                + +
                +<ExpireDate>
                +1 Jan 1997 00:00:00
                +</ExpireDate>
                +
                + +

                However, this specifies local time. It is possible that some +message can get excluded that have a 1997 date (depending on +what timezone you are in). The following +is more accurate: +

                + +
                +<ExpireDate>
                +1 Jan 1997 00:00:00 +0000
                +</ExpireDate>
                +
                + +

                Or,

                + +
                +<ExpireDate>
                +1 Jan 1997 00:00:00 GMT
                +</ExpireDate>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXPIREAGE, +TIMEZONES +

                + + +
                +
                +97/05/13 17:29:15
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/fieldorder.html b/doc/resources/fieldorder.html new file mode 100644 index 0000000..feee121 --- /dev/null +++ b/doc/resources/fieldorder.html @@ -0,0 +1,123 @@ + + + +MHonArc Resources: FIELDORDER + + + +
                +MHonArc Resource List
                +
                + +
                +

                FIELDORDER

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<FIELDORDER>
                +1st-field-name
                +2nd-field-name
                +...
                +</FIELDORDER>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The FIELDORDER resource allows you to control the order the message header +fields appear in the HTML output. +

                + +

                Each line of the <FIELDORDER> element is the exact +case-insensitive name of a message header field. The order the fields +are listed is the order they will appear in the filtered message. The +special field value "-extra-" represents all fields not +explicitly specified in the <FIELDORDER> element and not +excluded by the EXCS resource. Extra fields are listed +in sorted order.

                + +

                If -extra- is not specified, then only the fields +listed will be displayed. +

                + + +
                +

                Default Setting

                + +
                +<FieldOrder>
                +to
                +subject
                +from
                +date
                +-extra-
                +</FieldOrder>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:16
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/fieldsbeg.html b/doc/resources/fieldsbeg.html new file mode 100644 index 0000000..96b5f98 --- /dev/null +++ b/doc/resources/fieldsbeg.html @@ -0,0 +1,137 @@ + + + +MHonArc Resources: FIELDSBEG + + + +
                +MHonArc Resource List
                +
                + +
                +

                FIELDSBEG

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<FIELDSBEG>
                +markup ...
                +</FIELDSBEG>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                FIELDSBEG represents the beginning markup of a message +header. +

                + + +
                +

                Default Setting

                + +
                +<FieldsBeg>
                +<UL>
                +</FieldsBeg>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following example shows how FIELDSBEG, with other +message layout resources, be used to have message headers formatted +using table markup: +

                + +
                +<Fieldsbeg>
                +<table border=0>
                +<tbody>
                +</FieldsBeg>
                + 
                +<LabelBeg>
                +<tr>
                +<td align="right" valign="top">
                +</LabelBeg>
                + 
                +<LabelEnd>
                +</td>
                +</LabelEnd>
                + 
                +<FldBeg>
                +<td align="left">
                +</FldBeg>
                + 
                +<FldEnd>
                +</td>
                +</tr>
                +</FldEnd>
                + 
                +<FieldsEnd>
                +</tbody>
                +</table>
                +</FieldsEnd>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:16
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/fieldsend.html b/doc/resources/fieldsend.html new file mode 100644 index 0000000..9d63aea --- /dev/null +++ b/doc/resources/fieldsend.html @@ -0,0 +1,107 @@ + + + +MHonArc Resources: FIELDSEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                FIELDSEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<FIELDSEND>
                +markup ...
                +</FIELDSEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                FIELDSEND represents the ending markup of a message +header. +

                + + +
                +

                Default Setting

                + +
                +<FieldsEnd>
                +</UL>
                +</FieldsEnd>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                See +FIELDSBEG for an example +usage of this resource. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:17
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/fieldstyles.html b/doc/resources/fieldstyles.html new file mode 100644 index 0000000..3f112e7 --- /dev/null +++ b/doc/resources/fieldstyles.html @@ -0,0 +1,131 @@ + + + +MHonArc Resources: FIELDSTYLES + + + +
                +MHonArc Resource List
                +
                + +
                +

                FIELDSTYLES

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<FIELDSTYLES>
                +field_name:html_element
                +field_name:html_element
                +...
                +</FIELDSTYLES>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The FIELDSTYLES resource is set via the FIELDSTYLES +element. Each line in the FIELDSTYLES element +defines HTML elements to wrap around the field text in +mail headers (e.g. "To: field text", +"From: field text"). The format of each line +is "field_name:html_element". This +specifies to wrap html_element around the text associated with +field_name. If html_element is empty, then the field +text is not wrapped in any element.

                + +

                MHonArc defines +a special field_name called "-default-". This +is default HTML element to wrap field text in if no explicit specific +element is defined for the label.

                + +

                field_name must +be the exact name of a header field name, but character case is ignored. +

                + + +
                +

                Default Setting

                + +
                +<FieldStyles>
                +-default-
                +</FieldStyles>
                +
                + + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following causes the subject text to appear in bold and +all other field text to be in italics: +

                + +
                +<FieldStyles>
                +subject:b
                +-default-:i
                +</FieldStyles>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FLDBEG, +FLDEND, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:18
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/fldbeg.html b/doc/resources/fldbeg.html new file mode 100644 index 0000000..ba56522 --- /dev/null +++ b/doc/resources/fldbeg.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: FLDBEG + + + +
                +MHonArc Resource List
                +
                + +
                +

                FLDBEG

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<FLDBEG>
                +markup ...
                +</FLDBEG>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                FLDBEG represents the beginning markup of a field text of +a message field. +

                + + +
                +

                Default Setting

                + +

                The space character.

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                See +FIELDSBEG +for an example usage of this resource. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDEND, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:18
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/fldend.html b/doc/resources/fldend.html new file mode 100644 index 0000000..9df3611 --- /dev/null +++ b/doc/resources/fldend.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: FLDEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                FLDEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<FLDEND>
                +markup ...
                +</FLDEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                FLDEND represents the ending markup of a field text of +a message field. +

                + + +
                +

                Default Setting

                + +

                The space character.

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                See +FIELDSBEG +for an example usage of this resource. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +LABELBEG, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:19
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/folrefs.html b/doc/resources/folrefs.html new file mode 100644 index 0000000..4b8ed9a --- /dev/null +++ b/doc/resources/folrefs.html @@ -0,0 +1,107 @@ + + + +MHonArc Resources: FOLREFS + + + +
                +MHonArc Resource List
                +
                + +
                +

                FOLREFS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_FOLREFS=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<FOLREFS>
                +<NOFOLREFS>
                +

                +
                + +
                Command-line Option(s)
                +

                +-folrefs
                +-nofolrefs
                +

                +
                + +
                + + +
                +

                Description

                + +

                If the FOLREFS resource is On, then MhonArc will +list direct follow-ups and references for a message after the message +body. +

                + +

                The format of the follow-ups and references links cannot be +customized. If you desire to have all message links in a custom +format, you may want to shut this resource off and rely on the +TPREVLINK and +TNEXTLINK resources. +

                + + +
                +

                Default Setting

                + +

                On +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TNEXTLINK, +TNEXTLINKIA, +TPREVLINK, +TPREVLINKIA +

                + + +
                +
                +97/05/13 17:29:19
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/footer.html b/doc/resources/footer.html new file mode 100644 index 0000000..9ae9694 --- /dev/null +++ b/doc/resources/footer.html @@ -0,0 +1,120 @@ + + + +MHonArc Resources: FOOTER + + + +
                +MHonArc Resource List
                +
                + +
                +

                FOOTER

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_FOOTER=filename +

                +
                + +
                Element
                +

                +<FOOTER>
                +filename
                +</FOOTER>
                +

                +
                + +
                Command-line Option
                +

                +-footer filename +

                +
                + +
                + + +
                +

                Description

                + +
                NOTE +

                The use of FOOTER resource is discouraged since the LISTEND resource can be used to achieve +the same results. The support for the FOOTER resource may be +removed in future releases. +No equivalent resource exists for the thread index. +

                + +

                The FOOTER resource specifies a file whose contents are to be included +after the message links listing of the main index. +

                + +
                +
                NOTE +

                filename should not contain the +</BODY>, and </HTML> tags; these +tags are automatically provided by MHonArc, or defined by +the IDXPGEND resource file element. +

                + +

                It is only necessary to specify the FOOTER resource +the first time you create an archive. The contents included from the +footer file is preserved in any subsequent additions +to the archive. Only respecify the FOOTER resource if you +need to make changes to the footer contents.

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 (deprecated) +

                + + +
                +

                See Also

                + +

                +IDXPGEND, +HEADER, +LISTEND +

                + + +
                +
                +97/05/13 17:29:20
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/force.html b/doc/resources/force.html new file mode 100644 index 0000000..9042560 --- /dev/null +++ b/doc/resources/force.html @@ -0,0 +1,117 @@ + + + +MHonArc Resources: FORCE + + + +
                +MHonArc Resource List
                +
                + +
                +

                FORCE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-force +

                +
                + +
                + + +
                +

                Description

                + +

                FORCE causes MHonArc to override the lock on +the archive and perform the operations requested. +

                + +

                When MHonArc processes an archive, it locks the +archive so other MHonArc processes do not try +to modify the archive at the same time. However, if +MHonArc abnormally terminates, the lock may not +be released, causing all future MHonArc processes +to fail in performing any archive operations. If +you get a message from MHonArc that it cannot +lock an archive, and you know the archive is not in use +by another MHonArc process, use the FORCE resource. +

                + +

                The FORCE option should be used with care to avoid +archive corruption. FORCE is active only for the current +MHonArc process. +

                + +

                MHonArc will still try to perform a normal +lock before forcing the issue. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2.2 +

                + + +
                +

                See Also

                + +

                +LOCKDELAY, +LOCKTRIES +

                + + +
                +
                +97/05/13 17:29:20
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/genidx.html b/doc/resources/genidx.html new file mode 100644 index 0000000..a274132 --- /dev/null +++ b/doc/resources/genidx.html @@ -0,0 +1,101 @@ + + + +MHonArc Resources: GENIDX + + + +
                +MHonArc Resource List
                +
                + +
                +

                GENIDX

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-genidx +

                +
                + +
                + + +
                +

                Description

                + +

                GENIDX instructs MHonArc to generate an index +to standard output and perform no archive changes. +Any new resources specified will be applied to the generated +index, but the new resources will NOT be +stored in the archive database. +

                + +

                GENIDX may be used to create dynamic index pages. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:21
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/gmtdatefmt.html b/doc/resources/gmtdatefmt.html new file mode 100644 index 0000000..7d6197a --- /dev/null +++ b/doc/resources/gmtdatefmt.html @@ -0,0 +1,209 @@ + + + +MHonArc Resources: GMTDATEFMT + + + +
                +MHonArc Resource List
                +
                + +
                +

                GMTDATEFMT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_GMTDATEFMT=date-format +

                +
                + +
                Element
                +

                +<GMTDATEFMT>
                +date-format
                +</GMTDATEFMT>
                +

                +
                + +
                Command-line Option
                +

                +-gmtdatefmt date-format +

                +
                + +
                + + +
                +

                Description

                + +

                The GMTDATEFMT resource specifies the date format for the +$GMTDATE$ resource variable +(i.e. The system GMT date). +The format is a string containing zero or more conversion +specifications and regular characters. A conversion specification +consists of the '%' character +followed a character that determines the type of conversion. +

                + +

                The following lists the possible conversion specifications: +

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                SpecValue
                %%the % character
                %aabbreviated weekday name
                %Afull weekday name
                %babbreviated month name
                %Bfull month name
                %cappropriate date and time representation
                %dday of month [1,31]; single digits are preceded by 0
                %habbreviated month name
                %Hhour (24-hour clock) [0,23]; single digits are preceded by 0
                %Ihour (12-hour clock) [1,12]; single digits are preceded by 0
                %jday number of year [1,366]; single digits are preceded by 0
                %mmonth number [1,12]; single digits are preceded by 0
                %Mminute[00,59]; single digits are preceded by 0
                %pam or pm.
                %PAM or PM.
                %Sseconds [00,61]
                %wweekday as a decimal number [0,6], with 0 representing Sunday
                %yyear within century [00,99]
                %Yyear, including the century (for example 1993)
                + +

                Setting GMTDATEFMT to a blank string will reset the resource +to the default setting. +

                + + +
                +

                Default Setting

                + +
                +%a %b %d %H:%M:%S GMT %y
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following sets the GMT date to use the long weekday and +month names and 12 hour am/pm time: +

                + +
                +<GMTDateFmt>
                +%A %B %d %I:%M:%S %p GMT %y
                +</GMTDateFmt>
                +
                + + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +LOCALDATEFMT, +MONTHS, +MONTHSABR, +MSGGMTDATEFMT, +MSGLOCALDATEFMT, +WEEKDAYS, +WEEKDAYSABR +

                + + +
                +
                +97/05/13 17:29:22
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/headbodysep.html b/doc/resources/headbodysep.html new file mode 100644 index 0000000..479bf22 --- /dev/null +++ b/doc/resources/headbodysep.html @@ -0,0 +1,155 @@ + + + +MHonArc Resources: HEADBODYSEP + + + +
                +MHonArc Resource List
                +
                + +
                +

                HEADBODYSEP

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<HEADBODYSEP>
                +markup
                +</HEADBODYSEP>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                HEADBODYSEP defines the markup between the message header +and the message body. +

                + +
                +
                NOTE
                +

                If HEADBODYSEP is changed, +the existing messages in the archive will not get changed, even +if the EDITIDX resource is on. All +new messages will contain the new setting. +

                +
                +
                + + +
                +

                Default Setting

                + +
                +<HR>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EDITIDX +

                + + +
                +
                +97/05/13 17:29:22
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/header.html b/doc/resources/header.html new file mode 100644 index 0000000..e272daa --- /dev/null +++ b/doc/resources/header.html @@ -0,0 +1,121 @@ + + + +MHonArc Resources: HEADER + + + +
                +MHonArc Resource List
                +
                + +
                +

                HEADER

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_HEADER=filename +

                +
                + +
                Element
                +

                +<HEADER>
                +filename
                +</HEADER>
                +

                +
                + +
                Command-line Option
                +

                +-header filename +

                +
                + +
                + + +
                +

                Description

                + +
                NOTE +

                The use of HEADER resource is discouraged since the LISTBEGIN resource can be used to achieve +the same results. The support for the HEADER resource may be +removed in future releases. +No equivalent resource exists for the thread index. +

                + +

                The HEADER resource specifies a file whose contents are to be included +before the message links listing of the main index. +

                + +
                +
                NOTE +

                filename should not contain the +<HTML>, <HEADER>, and +<BODY> tags; these +tags are automatically provided by MHonArc, or defined by +the IDXPGGEING resource file element. +

                + +

                It is only necessary to specify the HEADER resource +the first time you create an archive. The contents included from the +header file is preserved in any subsequent additions +to the archive. Only respecify the HEADER resource if you +need to make changes to the header contents.

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 (deprecated) +

                + + +
                +

                See Also

                + +

                +IDXPGBEGIN, +FOOTER, +LISTBEGIN +

                + + +
                +
                +97/05/13 17:29:23
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/icons.html b/doc/resources/icons.html new file mode 100644 index 0000000..65e81e4 --- /dev/null +++ b/doc/resources/icons.html @@ -0,0 +1,162 @@ + + + +MHonArc Resources: ICONS + + + +
                +MHonArc Resource List
                +
                + +
                +

                ICONS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<ICONS>
                +icon-specification
                +icon-specification
                +...
                +</ICONS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The ICONS resource is used to specify the icons that represent the +different content-types of messages. +

                + +

                The ICON resource can only be defined via the resource file element. +The format of each line in the ICONS element is as +follows: +

                + +

                content-type:URL-for-icon

                + +

                content-type represents a MIME +content-type. URL-for-icon is the URL to the icon. The +special content-type called "unknown" may be defined +to specify the icon to use for non-recognized content-types. If +unknown is not defined, the text/plain icon is used for +unknown content types.

                + +

                In order to have icons appear in your pages, use the +$ICON$ resource variable. +For example: +

                + +
                +<LiTemplate>
                +$ICON$ <strong>$SUBJECT:40$</strong>
                +<em>$FROMNAME$</em><br>
                +</LiTemplate>
                +
                + +

                The $ICON$ variable expands to the IMG +HTML element with the appropriate URL in the SRC attribute +to the icon. The ALT attribute of the IMG +element contains the content-type of the message, surrounded by +[]'s, for use with text based browsers.

                + +

                The $ICONURL$ resource +variable may be used if you want redefine the format of the +IMG element. For example: +

                + +
                +<LiTemplate>
                +<img src="$ICONURL$" alt="*">
                +<strong>$SUBJECT:40$</strong>
                +<em>$FROMNAME$</em><br>
                +</LiTemplate>
                +
                + +

                The example overrides what is normally used in the ALT +attribute.

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +
                +<Icons>
                +audio/basic:http://foo.org/gifs/gsound.gif
                +image/gif:http://foo.org/gifs/gimage.gif
                +image/jpeg:http://foo.org/gifs/gimage.gif
                +image/tiff:http://foo.org/gifs/ggraphic.gif
                +multipart/alternative:http://foo.org/gifs/gmulti.gif
                +multipart/digest:http://foo.org/gifs/gtext.gif
                +multipart/mixed:http://foo.org/gifs/gdoc2.gif
                +multipart/parallel:http://foo.org/gifs/gdoc.gif
                +text/richtext:http://foo.org/gifs/gdoc.gif
                +text/html:http://foo.org/gifs/gdoc.gif
                +text/plain:http://foo.org/gifs/gletter.gif
                +unknown:http://foo.org/gifs/gunknown.gif
                +video/mpeg:http://foo.org/gifs/gmovie.gif
                +</Icons>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +LITEMPLATE, +TLITXT, +TSINGLETXT, +TTOPBEGIN +

                + + +
                +
                +97/05/13 17:29:23
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/idxfname.html b/doc/resources/idxfname.html new file mode 100644 index 0000000..ce36446 --- /dev/null +++ b/doc/resources/idxfname.html @@ -0,0 +1,99 @@ + + + +MHonArc Resources: IDXFNAME + + + +
                +MHonArc Resource List
                +
                + +
                +

                IDXFNAME

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_IDXFNAME=filename +

                +
                + +
                Element
                +

                +<IDXFNAME>
                +filename
                +</IDXFNAME>
                +

                +
                + +
                Command-line Option
                +

                +-idxfname filename +

                +
                + +
                + + +
                +

                Description

                + +

                IDXFNAME defines the filename for the main index page. If +MULTIPG is on, it defines the filename +of the first page of the main index. +

                + + +
                +

                Default Setting

                + +
                +maillist.html
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +TIDXFNAME +

                + + +
                +
                +97/05/13 17:29:24
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/idxlabel.html b/doc/resources/idxlabel.html new file mode 100644 index 0000000..c88a63b --- /dev/null +++ b/doc/resources/idxlabel.html @@ -0,0 +1,109 @@ + + + +MHonArc Resources: IDXLABEL + + + +
                +MHonArc Resource List
                +
                + +
                +

                IDXLABEL

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<IDXLABEL>
                +markup ... +</IDXLABEL>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                IDXLABEL defines the label text for the main index. Specifically, +it defines the value of the $IDXLABEL$ +resource variable. +

                + + +
                +

                Default Setting

                + +

                +If SORT: Date Index
                +If SUBSORT: Subject Index
                +If AUTHSORT: Author Index
                +If no sorting: Message Index
                +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +AUTHSORT, +SORT, +SUBSORT, +TIDXLABEL +

                + + +
                +
                +97/05/13 17:29:24
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/idxpgbegin.html b/doc/resources/idxpgbegin.html new file mode 100644 index 0000000..181a92e --- /dev/null +++ b/doc/resources/idxpgbegin.html @@ -0,0 +1,239 @@ + + + +MHonArc Resources: IDXPGBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                IDXPGBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<IDXPGBEGIN>
                +markup ...
                +</IDXPGBEGIN>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The IDXPGBEGIN resource defines the beginning markup for the main +index page. I.e. You can control the opening <HTML> tag, the +HEAD element contents, the opening <BODY> tag, etc. Therefore, +if you are not satisfied with the default behavior of how the +TITLE +resource is used, or have other needs that require control on the +beginning markup, you can set the IDXPGBEGIN resource to what you +desire. +

                + + +
                +

                Default Setting

                + +
                +<IdxPgBegin>
                +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML//EN">
                +<HTML>
                +<HEAD>
                +<TITLE>$IDXTITLE$</TITLE>
                +</HEAD>
                +<BODY>
                +<H1>$IDXTITLE$</H1>
                +</IdxPgBegin>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                The following shows how you can set HTML body element attributes +to control the appearence of the index page: +

                + +
                +<IdxPgBegin>
                +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML//EN">
                +<HTML>
                +<HEAD>
                +<TITLE>$IDXTITLE$</TITLE>
                +</HEAD>
                +<BODY background="idxbg.gif" bgproperties="fixed">
                +<H1>$IDXTITLE$</H1>
                +</IdxPgBegin>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +IDXPGEND, +TITLE, +TIDXPGBEGIN, +TIDXPGEND +

                + + +
                +
                +97/05/13 17:29:25
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/idxpgend.html b/doc/resources/idxpgend.html new file mode 100644 index 0000000..307e7d1 --- /dev/null +++ b/doc/resources/idxpgend.html @@ -0,0 +1,214 @@ + + + +MHonArc Resources: IDXPGEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                IDXPGEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<IDXPGEND>
                +markup ...
                +</IDXPGEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The IDXPGEND resource defines the end markup for the main +index page. +

                + + +
                +

                Default Setting

                + +
                +<IdxPgEnd>
                +</BODY>
                +</HTML>
                +</IdxPgEnd>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +IDXPGBEGIN, +TIDXPGBEGIN, +TIDXPGEND +

                + + +
                +
                +97/05/13 17:29:26
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/idxprefix.html b/doc/resources/idxprefix.html new file mode 100644 index 0000000..e1430b1 --- /dev/null +++ b/doc/resources/idxprefix.html @@ -0,0 +1,113 @@ + + + +MHonArc Resources: IDXPREFIX + + + +
                +MHonArc Resource List
                +
                + +
                +

                IDXPREFIX

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_IDXPREFIX=prefix +

                +
                + +
                Element
                +

                +<IDXPREFIX>
                +prefix
                +</IDXPREFIX>
                +

                +
                + +
                Command-line Option
                +

                +-idxprefix prefix +

                +
                + +
                + + +
                +

                Description

                + +

                IDXPREFIX defines the prefix for the filenames of a multi-page +main index. The filename of the first page of the main index is always equal +to the value of the +IDXFNAME resource. All other pages have +a filename starting with the IDXPREFIX value with the page number and +".html" following. For example, the filenames for a 4 page +main index would be the following: +

                +
                +    maillist.html
                +    mail2.html
                +    mail3.html
                +    mail4.html
                +
                +

                assuming the default values for the IDXFNAME and IDXPREFIX +resources. +

                + + +
                +

                Default Setting

                + +
                +mail
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +IDXFNAME, +MULTIPG, +TIDXPREFIX +

                + + +
                +
                +97/05/13 17:29:26
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/idxsize.html b/doc/resources/idxsize.html new file mode 100644 index 0000000..881ef8b --- /dev/null +++ b/doc/resources/idxsize.html @@ -0,0 +1,98 @@ + + + +MHonArc Resources: IDXSIZE + + + +
                +MHonArc Resource List
                +
                + +
                +

                IDXSIZE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_IDXSIZE=number +

                +
                + +
                Element
                +

                +<IDXSIZE>
                +number
                +</IDXSIZE>
                +

                +
                + +
                Command-line Option
                +

                +-idxsize number +

                +
                + +
                + + +
                +

                Description

                + +

                IDXSIZE defines the maximum number of messages listed on +an index page. Please do not confuse with +MAXSIZE. +

                + + +
                +

                Default Setting

                + +

                Unlimited. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +MAXSIZE, +MULTIPG +

                + + +
                +
                +97/05/13 17:29:27
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/include.html b/doc/resources/include.html new file mode 100644 index 0000000..98b7ba1 --- /dev/null +++ b/doc/resources/include.html @@ -0,0 +1,110 @@ + + + +MHonArc Resources: INCLUDE + + + +
                +MHonArc Resource List
                +
                + +
                +

                INCLUDE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<INCLUDE>
                +filename
                +...
                +</INCLUDE>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The INCLUDE resource is only applicable in the resource file. +It specifies other resource files to include at the location of the +INCLUDE element that lists the files. When including +multiple files in an INCLUDE element, each file must be +listed on a separate line.

                + +

                Multiple INCLUDE elements can be defined in +a resource file for including files at different locations. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                If managing multiple archives, it is common to have common +resource settings for the archives. With the INCLUDE resource, +you define these common resources in a single file, and have +each archive resource file include it. For example: +

                + +
                +<Include>
                +/usr/local/lib/MHonArc/common.rc
                +</Include>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +RCFILE +

                + + +
                +
                +97/05/13 17:29:27
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/labelbeg.html b/doc/resources/labelbeg.html new file mode 100644 index 0000000..32d9aa7 --- /dev/null +++ b/doc/resources/labelbeg.html @@ -0,0 +1,105 @@ + + + +MHonArc Resources: LABELBEG + + + +
                +MHonArc Resource List
                +
                + +
                +

                LABELBEG

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<LABELBEG>
                +markup ...
                +</LABELBEG>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                LABELBEG represents the beginning markup of the label text of +a message field. +

                + + +
                +

                Default Setting

                + +
                +<LI>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                See +FIELDSBEG +for an example usage of this resource. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELEND, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:28
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/labelend.html b/doc/resources/labelend.html new file mode 100644 index 0000000..9b7a25b --- /dev/null +++ b/doc/resources/labelend.html @@ -0,0 +1,105 @@ + + + +MHonArc Resources: LABELEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                LABELEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<LABELEND>
                +markup ...
                +</LABELEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                LABELEND represents the end markup of the label text of +a message field. +

                + + +
                +

                Default Setting

                + +
                +:
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                See +FIELDSBEG +for an example usage of this resource. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELBEG, +LABELSTYLES +

                + + +
                +
                +97/05/13 17:29:28
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/labelstyles.html b/doc/resources/labelstyles.html new file mode 100644 index 0000000..d572583 --- /dev/null +++ b/doc/resources/labelstyles.html @@ -0,0 +1,132 @@ + + + +MHonArc Resources: LABELSTYLES + + + +
                +MHonArc Resource List
                +
                + +
                +

                LABELSTYLES

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<LABELSTYLES>
                +label_name:html_element
                +label_name:html_element
                +...
                +</LABELSTYLES>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The LABELSTYLES resource is set via the LABELSTYLES +element. Each line in the LABELSTYLES element +defines HTML elements to wrap around the field labels in +mail headers (e.g. "To", +"From"). The format of each line +is "label_name:html_element". This +specifies to wrap html_element around the label +label_name. If html_element is empty, then the label +is not wrapped in any element.

                + +

                MHonArc defines +a special label_name called "-default-". This +is default HTML element to wrap labels in if no explicit specific +element is defined for the label.

                + +

                label_name must +be the exact name of a header field label, but character case is ignored. +

                + + +
                +

                Default Setting

                + +
                +<LabelStyles>
                +-default-:em
                +</LabelStyles>
                +
                + + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following causes the subject and from labels to appear in bold and +all other labels in normal typeface: +

                + +
                +<LabelStyles>
                +subject:b
                +from:b
                +-default-:
                +</LabelStyles>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +EXCS, +FIELDORDER, +FIELDSBEG, +FIELDSEND, +FIELDSTYLES, +FLDBEG, +FLDEND, +LABELBEG, +LABELEND +

                + + +
                +
                +97/05/13 17:29:29
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/listbegin.html b/doc/resources/listbegin.html new file mode 100644 index 0000000..929215a --- /dev/null +++ b/doc/resources/listbegin.html @@ -0,0 +1,260 @@ + + + +MHonArc Resources: LISTBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                LISTBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<LISTBEGIN>
                +markup ...
                +</LISTBEGIN>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The LISTBEGIN resource specifies the markup to +begin the message list. This resource works in conjuction +with +LITEMPLATE and +LISTEND resources +to format the main index page(es). +

                + + +
                +

                Default Setting

                + +

                If MULTIPG is not active: +

                + +
                +<ListBegin>
                +<UL>
                +<LI><A HREF="$TIDXFNAME$">Thread Index</A></LI>
                +</UL>
                +<HR>
                +<UL>
                +</ListBegin>
                +
                + +

                If MULTIPG is active: +

                + +
                +<ListBegin>
                +<UL>
                +<LI><A HREF="$TIDXFNAME$">Thread Index</A></LI>
                +</UL>
                +$PREVPGLINK$$NEXTPGLINK$
                +<HR>
                +<UL>
                +</ListBegin>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                Here is an example that includes links for the first and +last page of the index for a mult-page index: +

                + +
                +<ListBegin>
                +<ul>
                +<li><a href="$TIDXFNAME$">Thread Index</a></li>
                +</ul>
                +<table width="100%" border=0 cols=2 cellpadding=0 cellspacing=0>
                +<tbody>
                +<tr align="center">
                +<th colspan=4>Page $PAGENUM$ of $NUMOFPAGES$
                +<tr>
                +<td align="left">$PREVPGLINK$
                +<td align="right">[<a href="$FIRSTPG$">First Page</a>]
                +<td align="left">[<a href="$LASTPG$">Last Page</a>]
                +<td align="right">$NEXTPGLINK
                +</tbody>
                +</table>
                +<hr>
                +<ul>
                +</ListBegin>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +LISTEND, +LITEMPLATE, +MULTIPG +

                + + +
                +
                +97/05/13 17:29:30
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/listend.html b/doc/resources/listend.html new file mode 100644 index 0000000..baad9c0 --- /dev/null +++ b/doc/resources/listend.html @@ -0,0 +1,216 @@ + + + +MHonArc Resources: LISTEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                LISTEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<LISTEND>
                +markup ...
                +</LISTEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The LISTEND resource specifies the markup to +end the message list in the main index. This resource works in conjuction +with +LISTBEGIN and +LITEMPLATE resources +to format the main index page(es). +

                + + +
                +

                Default Setting

                + +
                +<ListEnd>
                +</UL>
                +</ListEnd>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +LISTBEGIN, +LITEMPLATE +

                + + +
                +
                +97/05/13 17:29:31
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/litemplate.html b/doc/resources/litemplate.html new file mode 100644 index 0000000..e126f6d --- /dev/null +++ b/doc/resources/litemplate.html @@ -0,0 +1,199 @@ + + + +MHonArc Resources: LITEMPLATE + + + +
                +MHonArc Resource List
                +
                + +
                +

                LITEMPLATE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<LITEMPLATE>
                +markup ...
                +</LITEMPLATE>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The LITEMPLATE resource specifies the markup for an entry +in the main index message list. This resource works in conjuction +with +LITEMPLATE and +LISTEND resources +to format the main index page(es). +

                + + +
                +

                Default Setting

                + +
                +<LiTemplate>
                +<LI><STRONG>$SUBJECT$</STRONG>
                +<UL><LI><EM>From</EM>: $FROM$</LI></UL>
                +</LI>
                +</LiTemplate>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                Here is an example that lists each message with subject and +the name of the person who wrote the message: +

                + +
                +<LiTemplate>
                +<LI><STRONG>$SUBJECT$</STRONG>,
                +<EM>$FROMNAME$</EM>
                +</LI>
                +</LiTemplate>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +LIBEGIN, +LISTEND +

                + + +
                +
                +97/05/13 17:29:31
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/localdatefmt.html b/doc/resources/localdatefmt.html new file mode 100644 index 0000000..1711950 --- /dev/null +++ b/doc/resources/localdatefmt.html @@ -0,0 +1,209 @@ + + + +MHonArc Resources: LOCALDATEFMT + + + +
                +MHonArc Resource List
                +
                + +
                +

                LOCALDATEFMT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_LOCALDATEFMT=date-format +

                +
                + +
                Element
                +

                +<LOCALDATEFMT>
                +date-format
                +</LOCALDATEFMT>
                +

                +
                + +
                Command-line Option
                +

                +-localdatefmt date-format +

                +
                + +
                + + +
                +

                Description

                + +

                The LOCALDATEFMT resource specifies the date format for the +$LOCALDATE$ resource variable +(i.e. The local system date). +The format is a string containing zero or more conversion +specifications and regular characters. A conversion specification +consists of the '%' character +followed a character that determines the type of conversion. +

                + +

                The following lists the possible conversion specifications: +

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                SpecValue
                %%the % character
                %aabbreviated weekday name
                %Afull weekday name
                %babbreviated month name
                %Bfull month name
                %cappropriate date and time representation
                %dday of month [1,31]; single digits are preceded by 0
                %habbreviated month name
                %Hhour (24-hour clock) [0,23]; single digits are preceded by 0
                %Ihour (12-hour clock) [1,12]; single digits are preceded by 0
                %jday number of year [1,366]; single digits are preceded by 0
                %mmonth number [1,12]; single digits are preceded by 0
                %Mminute[00,59]; single digits are preceded by 0
                %pam or pm.
                %PAM or PM.
                %Sseconds [00,61]
                %wweekday as a decimal number [0,6], with 0 representing Sunday
                %yyear within century [00,99]
                %Yyear, including the century (for example 1993)
                + +

                Setting LOCALDATEFMT to a blank string will reset the resource +to the default setting. +

                + + +
                +

                Default Setting

                + +
                +%a %b %d %H:%M:%S %y
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following sets the local date to use the long weekday and +month names and 12 hour am/pm time: +

                + +
                +<LocalDateFmt>
                +%A %B %d %I:%M:%S %p %y
                +</LocalDateFmt>
                +
                + + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +GMTDATEFMT, +MONTHS, +MONTHSABR, +MSGGMTDATEFMT, +MSGLOCALDATEFMT, +WEEKDAYS, +WEEKDAYSABR +

                + + +
                +
                +97/05/13 17:29:32
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/lockdelay.html b/doc/resources/lockdelay.html new file mode 100644 index 0000000..4120694 --- /dev/null +++ b/doc/resources/lockdelay.html @@ -0,0 +1,102 @@ + + + +MHonArc Resources: LOCKDELAY + + + +
                +MHonArc Resource List
                +
                + +
                +

                LOCKDELAY

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_LOCKDELAY=seconds +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-lockdelay seconds +

                +
                + +
                + + +
                +

                Description

                + +

                LOCKDELAY defines the number of seconds to wait between +attempts to lock an archive (see +LOCKTRIES). In conjunction +with LOCKTRIES, you can control +how long MHonArc will wait before aborting due +to the inability to lock an archive. +

                + + +
                +

                Default Setting

                + +

                3 +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2.2 +

                + + +
                +

                See Also

                + +

                +FORCE, +LOCKTRIES +

                + + +
                +
                +97/05/13 17:29:32
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/locktries.html b/doc/resources/locktries.html new file mode 100644 index 0000000..17eacee --- /dev/null +++ b/doc/resources/locktries.html @@ -0,0 +1,101 @@ + + + +MHonArc Resources: LOCKTRIES + + + +
                +MHonArc Resource List
                +
                + +
                +

                LOCKTRIES

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_LOCKTRIES=number +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-locktries number +

                +
                + +
                + + +
                +

                Description

                + +

                LOCKTRIES defines the number attempts MHonArc +makes to lock an archive. In conjunction +with LOCKDELAY, you can control +how long MHonArc will wait before aborting due +to the inability to lock an archive. +

                + + +
                +

                Default Setting

                + +

                10 +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2.1 +

                + + +
                +

                See Also

                + +

                +FORCE, +LOCKDELAY +

                + + +
                +
                +97/05/13 17:29:33
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/mailto.html b/doc/resources/mailto.html new file mode 100644 index 0000000..1bba44c --- /dev/null +++ b/doc/resources/mailto.html @@ -0,0 +1,100 @@ + + + +MHonArc Resources: MAILTO + + + +
                +MHonArc Resource List
                +
                + +
                +

                MAILTO

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MAILTO=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<MAILTO>
                +<NOMAILTO> +

                +
                + +
                Command-line Option(s)
                +

                +-mailto
                +-nomailto +
                +

                +
                + +
                + + +
                +

                Description

                + +

                If the MAILTO resource is on, e-mail addresses in message +headers will be converted into mailto URL links +as defined by the +MAILTOURL +resource. +

                + + +
                +

                Default Setting

                + +

                On. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +MAILTOURL +

                + + +
                +
                +97/05/13 17:29:34
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/mailtourl.html b/doc/resources/mailtourl.html new file mode 100644 index 0000000..25de72a --- /dev/null +++ b/doc/resources/mailtourl.html @@ -0,0 +1,147 @@ + + + +MHonArc Resources: MAILTOURL + + + +
                +MHonArc Resource List
                +
                + +
                +

                MAILTOURL

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MAILTOURL=URL-template +

                +
                + +
                Element
                +

                +<MAILTOURL>
                +URL-template
                +</MAILTOURL>
                +

                +
                + +
                Command-line Option
                +

                +-mailtourl URL-template +

                +
                + +
                + + +
                +

                Description

                + +

                The MAILTOURL defines the URL template for hyperlinked e-mail +addressed in message headers when the +MAILTO resource is active. +

                + +
                +
                NOTE +

                The MAILTOURL resource has +different rules for variable expansion. If a +variable does not exactly match the set of variables available for +the MAILTOURL, the variable text will be taken literally +as part of the element content. Therefore, a single "$" +can be used to represent a "$" character.

                +

                Also, +variables in the MAILTOURL should NOT +have ":NU" modifier. This will prevent the +variables from be recognized. MHonArc will automatically +treat the replacement value as a part of a URL string. +

                +
                + + +
                +

                Default Setting

                + +
                +mailto:$TO$
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $FROM$The complete text in the From
                $MSGID$The message-id of the message.
                $SUBJECT$The subject text of the message.
                $SUBJECTNA$The subject text of the message.
                $TO$The complete text in the To field.
                + + +
                +

                Examples

                + +

                The following example defines how MAILTOURL can be used +to have e-mail addresses linked to a CGI program: +

                + +
                +<MailToURL>
                +/cgi-bin/mailform.cgi?to=$TO$;subject=$SUBJECT$;srcid=$MSGID$
                +</MailToURL>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +MAILTO +

                + + +
                +
                +97/05/13 17:29:34
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/main.html b/doc/resources/main.html new file mode 100644 index 0000000..70caabb --- /dev/null +++ b/doc/resources/main.html @@ -0,0 +1,97 @@ + + + +MHonArc Resources: MAIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                MAIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MAIN=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<MAIN>
                +<NOMAIN>
                +

                +
                + +
                Command-line Option(s)
                +

                +-main
                +-nomain +
                +

                +
                + +
                + + +
                +

                Description

                + +

                If MAIN is on, MHonArc will create the main index +page(s) for the archive. If off, no main index is created. +

                + + +
                +

                Default Setting

                + +

                On. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +THREAD +

                + + +
                +
                +97/05/13 17:29:35
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/maxsize.html b/doc/resources/maxsize.html new file mode 100644 index 0000000..332088f --- /dev/null +++ b/doc/resources/maxsize.html @@ -0,0 +1,108 @@ + + + +MHonArc Resources: MAXSIZE + + + +
                +MHonArc Resource List
                +
                + +
                +

                MAXSIZE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MAXSIZE=number +

                +
                + +
                Element
                +

                +<MAXSIZE>
                +number
                +</MAXSIZE>
                +

                +
                + +
                Command-line Option
                +

                +-maxsize number +

                +
                + +
                + + +
                +

                Description

                + +

                MAXSIZE defines the maximum number of messages the archive +can have. If new messages are added that would cause an archive +to go over MAXSIZE, then the oldest, by date, messages are +removed until the number of messages equal MAXSIZE. +

                + +

                If you want no limit on the number of messages allowed in an +archive, set MAXSIZE to zero. +

                + +

                MAXSIZE differs from +IDXSIZE +in that IDXSIZE defines the maximum number of messages to list +on an index page. +

                + + +
                +

                Default Setting

                + +

                Unlimited +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +IDXSIZE +

                + + +
                +
                +97/05/13 17:29:35
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/mhpattern.html b/doc/resources/mhpattern.html new file mode 100644 index 0000000..028bd9b --- /dev/null +++ b/doc/resources/mhpattern.html @@ -0,0 +1,111 @@ + + + +MHonArc Resources: MHPATTERN + + + +
                +MHonArc Resource List
                +
                + +
                +

                MHPATTERN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MHPATTERN=Perl-regexp +

                +
                + +
                Element
                +

                +<MHPATTERN>
                +Perl-regexp
                +</MHPATTERN>
                +

                +
                + +
                Command-line Option
                +

                +-mhpattern Perl-regexp +

                +
                + +
                + + +
                +

                Description

                + +

                MHPATTERN defines the Perl regular expression to use for +matching message files in an MH mail folder. In general, +MHPATTERN allows you to tell MHonArc which message files +to read when a specified mail folder is a directory. +

                + + +
                +

                Default Setting

                + +
                +^\d+$
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following example shows how you can tell MHonArc to +process every non-dotfile in a directory: +

                + +
                +    % mhonarc -add -mhpattern '^[^\.]' msgdir
                +
                + +

                Remember, each file in msgdir must be a single +mail message. +

                + +

                Be careful in that the regexp you define does +not match "." and "..". +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:36
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/mimeargs.html b/doc/resources/mimeargs.html new file mode 100644 index 0000000..8ea3fed --- /dev/null +++ b/doc/resources/mimeargs.html @@ -0,0 +1,129 @@ + + + +MHonArc Resources: MIMEARGS + + + +
                +MHonArc Resource List
                +
                + +
                +

                MIMEARGS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<MIMEARGS>
                +content-type:argument-string
                +...
                +</MIMEARGS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The MIMEARGS resource may be used to pass optional +arguments to MIME filters to control their behavior. Arguments may +be defined on a per content-type basis, or for a specific filter +itself. The MIMEARGS resource can only be set via the +MIMEARGS element. +The syntax for each line of the the MIMEARGS +element is as follows:

                + +

                content-type:argument-string +

                + +

                Or, +

                + +

                filter-name:argument-string +

                + +

                The format of argument strings is dependent on the filter that +processes content-type or by the specified filter, +filter-name.

                + +

                If an argument string is defined for a filter explicitly and for a +content-type that the filter processes, the content-type string will +override the filter string.

                + + +
                +

                Default Setting

                + +
                +<MIMEArgs>
                +image/gif:inline
                +image/jpeg:inline
                +image/x-xbitmap:inline
                +image/x-xbm:inline
                +</MIMEArgs>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following tells the text/plain filter to italicize quoted text +in a followup. +

                + +
                +<MIMEArgs>
                +text/plain:quote
                +</MIMEArgs>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +MIMEFILTERS +

                + + +
                +
                +97/05/13 17:29:36
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/mimefilters.html b/doc/resources/mimefilters.html new file mode 100644 index 0000000..93adb40 --- /dev/null +++ b/doc/resources/mimefilters.html @@ -0,0 +1,609 @@ + + + +MHonArc Resources: MIMEFILTERS + + + +
                +MHonArc Resource List
                +
                + +
                +

                MIMEFILTERS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<MIMEFILTERS>
                +filter-specification
                +...
                +</MIMEFILTERS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The resource MIMEFILTERS +is used to hook in user +specifed filters into MHonArc. +The MIMEFILTERS resource can only be set via the +MIMEFILTERS element. +The syntax for each line of +the the MIMEFILTERS element is as follows:

                + +

                content-type:routine-name:file-of-routine

                + +

                The definition of each colon-separated value is as follows: +

                + +
                +
                content-type + +

                The MIME content-type the filter processes. An explicit +content-type (base/subtype) or a base content-type (base/*) +can be specified. +

                + +
                routine-name +

                The actual routine name of the filter. The name +should be fully qualified by the package it is defined in +(e.g. "mypackage'filter").

                + + + + + +
                NOTE

                Package qualification must use Perl 4 syntax. The '::' +qualification is not supported, yet. +

                +
                + +
                file-of-routine +

                The name of the file that defines +routine-name. If the file is not a full +pathname, MHonArc finds the file by looking in the +standard include paths of Perl, and the paths specified by the +PERLINC +resource. +

                + +
                + +

                Any whitespace is stripped out before processing. +

                + +

                Writing Filters

                + +

                If you want to write your own filter for use in MHonArc, +you need to know the Perl programming language. The following +information assumes you know Perl. +

                + +

                Function Interface of Filter

                + +

                MHonArc interfaces with MIME filters by calling a routine +with a specific set of arguments. The prototype of the interface +routine is as follows:

                + +
                +sub filter {
                +    local($head, *fields, $data, $decoded, $argstring) = @_;
                +
                +    # Filter code here
                +
                +    # The last statement should be the return value, unless an
                +    # explicit return is done. See the following for the format of the
                +    # return value.
                +}
                +
                + +
                Argument Descriptions
                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                $head

                This is the header text of the message (or body part if called +in a multipart message). +

                +
                *fields

                A pointer to an associative array that has broken down +$head into field label/field value components. The +keys are the lower-case representations of the field +values. Example: If you would like to retrieve +the value of the Content-Type field, then use the following: +$fields{`content-type'}. +

                +

                If a field occurs more than once in a header, MHonArc +separates the field values in the associative array by a +`\034' character. To make your filter less likely to break +due to changes in MHonArc, you may use the +$readmail'FieldSep +variable instead of `\034'. +

                +
                $data

                This is a copy of the message (or body part if called in +a mulitpart message) body. +

                +
                $decoded

                This flag is set to 1 if MHonArc decoded the message +and $data +represents the orginal data before encoded by the sender. If +set to 0, $data +has not been decoded. The failure to decode occurs +if MHonArc does not recognizeed the encoding specified in +the Content-Transfer-Encoding field. +

                +

                MHonArc has decoded the data for you if it was encoded +in 7-Bit, 8-Bit, Binary, Quoted-Printable, Base64, Uuencode +(x-uuencode, uuencode, x-uue, uue). +

                +
                $argstring

                This is an optional argument string that may be used to modify the +behavior of the filter. The format of this string is determined by the filter +itself. The value of the string is set by the +MIMEARGS resource. +

                +
                + +
                Return Value
                + +

                The return value is treated as an array. The first item in the array +is a string representing the HTML markup to insert in the HTMLized +message. An empty string may be returned to tell MHonArc +that the routine was unable to filter data.

                + +

                Any other array items are treated as names of any files that were +generated by the filter. MHonArc needs to keep track if any +extra files that a filter may generate in order for MHonArc to +delete those files if the message gets removed from the archive. +

                + + + + + + +
                NOTE

                If the filter creates a subdirectory with files, the filter +only needs to return the subdirectory in the return list. If +the message gets removed, MHonArc will delete the entire +directory. +

                +
                + +

                Filter Writing Tips

                + +

                The following recommendations/tips are given to help you write +filters:

                + +
                  +
                • Qualify your filter in its own package. This eliminates possible +variable/routine conflicts with MHonArc. +

                  + +
                • If the filter creates derived files (like the image filters), +you may use the variable $'OUTDIR +to determine the +location of the mail archive.

                  + + + + + + +
                  NOTE

                  Do not include $'OUTDIR as part as the +filename that is returned to MHonArc. If the filter +does create files, just return the base name. +

                  +

                  + +
                • Look at the default filters contained in the distribution +of MHonArc. You can use these as templates for writing +your own.

                  + +
                • Make sure your Perl source file ends with a true statement +(like "1;"). MHonArc just performs a +require +on the file, and if the file does not return +true, Perl will abort execution.

                  + +
                + +

                Using C

                + +

                If a MIME filter requires the utilization of a C program, or +other non-Perl executable, a Perl wrapper must be written for the +program in-order to interface with MHonArc. +

                + + +
                +

                Default Setting

                + +
                +<MIMEFilters>
                +application/*:m2h_external'filter:mhexternal.pl
                +application/x-patch:m2h_text_plain'filter:mhtxtplain.pl
                +audio/*:m2h_external'filter:mhexternal.pl
                +image/*:m2h_external'filter:mhexternal.pl
                +message/partial:m2h_text_plain'filter:mhtxtplain.pl
                +text/*:m2h_text_plain'filter:mhtxtplain.pl
                +text/html:m2h_text_html'filter:mhtxthtml.pl
                +text/plain:m2h_text_plain'filter:mhtxtplain.pl
                +text/richtext:m2h_text_plain'filter:mhtxtplain.pl
                +text/setext:m2h_text_setext'filter:mhtxtsetext.pl
                +text/tab-separated-values:m2h_text_plain'filter:mhtxtplain.pl
                +text/x-html:m2h_text_html'filter:mhtxthtml.pl
                +text/x-setext:m2h_text_setext'filter:mhtxtsetext.pl
                +video/*:m2h_external'filter:mhexternal.pl
                +</MIMEFilters>
                +
                + +

                The following describes the behavior of each filter. +

                + +

                m2h_external'filter

                + +

                The filter extracts the data into a separate file and puts +a hyperlink to the file into the HTMLized message.

                + +

                By default, the filter ignores any filename specification +given in the message when writing the data to disk. +A unique filename with an extenstion based upon sub-type is +generated. +

                + +

                m2h_external'filter can take the +following +arguments: +

                + + + + + + + + + + + + + + + + + + + + + +
                inline

                Inline image data by default if content-disposition not defined. +

                +
                ext=ext

                Use ext as the filename extension. +The filter already has a large list of extensions for various +content-types. Only use this argument if you process a +content-type not recognized by the filter. +

                +
                type="description"

                Use "description" as type description of the +data. The double quotes are required. +The filter already has a large list of descriptions for various +content-types. Only use this argument if you process a +content-type not recognized by the filter. +

                +
                subdir

                Place derived file in a subdirectory of the archive. +The subdirectory will be called "msgMSGNUM.dir". +This option may be useful if usename is +specified to avoid security and name conflict problems. +

                +
                usename

                Use (file)name attribute for determining name +of derived file. Use this option with caution +since it can lead to filename conflicts and +security problems. +

                +
                + +

                All arguments should be separated by at least one space.

                + +

                The following table shows the default list of content-types, +with descriptions, m2h_external'filter +recognizes: +

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                Content-typeDescription
                application/astoundAstound presentation
                application/fastmanfastman file
                application/mac-binhex40Mac BinHex file
                application/mbedletmbedlet file
                application/mswordMS-Word document
                application/octet-streamBinary data
                application/odaODA file
                application/pdfPDF file
                application/pgpPGP message
                application/pgp-signaturePGP signature
                application/postscriptPostScript document
                application/rtfRTF file
                application/sgmlSGML document
                application/studiomStudio M file
                application/timbuktutimbuktu file
                application/vnd.ms-excelMS-Excel file
                application/vnd.ms-powerpointMS-Powerpoint file
                application/vnd.ms-projectMS-Project file
                application/winhlpWinHelp document
                application/wordperfect5.1WordPerfect 5.1 document
                application/x-NET-InstallNet Install file
                application/x-asapasap file
                application/x-bcpioBCPIO file
                application/x-cpioCPIO file
                application/x-cshC-Shell script
                application/x-dotdot file
                application/x-dviTeX dvi file
                application/x-earthtimeEarthtime file
                application/x-envoyEnvoy file
                application/x-excelMS-Excel Spreadsheet
                application/x-gtarGNU tar file
                application/x-hdfHDF file
                application/x-javascriptJavaScript source
                application/x-kshKorn Shell script
                application/x-latexLaTex document
                application/x-makerFrameMake document
                application/x-mifFrame MIF document
                application/x-mochamocha file
                application/x-msaccessMS-Access database
                application/x-mscardfileMS-CardFile
                application/x-msclipMS-Clip file
                application/x-msmediaviewMS-Media View file
                application/x-msmetafileMS-Metafile
                application/x-msmoneyMS-Money file
                application/x-mspublisherMS-Publisher document
                application/x-msscheduleMS-Schedule file
                application/x-msterminalMS-Terminal
                application/x-mswriteMS-Write document
                application/x-netcdfCdf file
                application/x-ns-proxy-autoconfigNetscape Proxy Auto Config
                application/x-patchPatch file
                application/x-perlPerl source
                application/x-pointpluspointplus file
                application/x-salsasalsa file
                application/x-scriptA script file
                application/x-shBourne shell script
                application/x-sharShar file
                application/x-spritesprite file
                application/x-sv4cpioSV4Cpio file
                application/x-sv4crcSV4Crc file
                application/x-tarTar file
                application/x-tclTcl script
                application/x-texTeX document
                application/x-texinfoTeXInfo document
                application/x-timbuktutimbuktu file
                application/x-tkinedtkined file
                application/x-troffTroff document
                application/x-troff-manTroff manpage
                application/x-troff-meTroff ME
                application/x-troff-msTroff MS
                application/x-ustarUStar file
                application/x-wais-sourceWAIS Source
                application/zipZip archive
                audio/basicBasic audio
                audio/echospeechEchospeech audio
                audio/midiMIDI audio
                audio/x-aiffAIF audio
                audio/x-epacepac audio
                audio/x-midiMIDI audio
                audio/x-pacpac audio
                audio/x-pn-realaudioPN Realaudio
                audio/x-wavWave audio
                image/bmpWindow bitmap
                image/cgmComputer Graphics Metafile
                image/fifFIF image
                image/gifGIF image
                image/iefIEF image
                image/ifsIFS image
                image/jpegJPEG image
                image/pngPNG image
                image/tiffTIFF image
                image/vndVND image
                image/waveletWavelet image
                image/x-bmpWindows bitmap
                image/x-cmu-rasterCMU raster
                image/x-pbmPortable bitmap
                image/x-pcxPCX image
                image/x-pgmPortable graymap
                image/x-pictMac PICT image
                image/x-pnmPortable anymap
                image/x-portable-anymapPortable anymap
                image/x-portable-bitmapPortable bitmap
                image/x-portable-graymapPortable graymap
                image/x-portable-pixmapPortable pixmap
                image/x-ppmPortable pixmap
                image/x-rgbRGB image
                image/x-xbitmapX bitmap
                image/x-xbmX bitmap
                image/x-xpixmapX pixmap
                image/x-xpmX pixmap
                image/x-xwdX window dump
                image/x-xwindowdumpX window dump
                text/htmlHTML document
                text/plainText document
                text/richtextRichtext document
                text/setextSetext document
                text/sgmlSGML document
                text/x-htmlHTML document
                text/x-setextSetext document
                text/x-speechSpeech document
                video/isivideoisi video
                video/mpegMPEG movie
                video/msvideoMS Video
                video/quicktimeQuickTime movie
                video/vivovivo video
                video/waveletWavelet video
                video/x-msvideoMS video
                video/x-sgi-movieSGI movie
                + +

                m2h_text_html'filter

                + +

                This filter is designed to process text/html or +text/x-html messages. +The filter must modify the HTML for merging into the +final filtered HTML messages. Modification is needed so the +resulting filtered message is valid HTML. +

                + + +

                m2h_text_plain'filter

                + +

                This filter is designed to process text/plain messages and +messages with no MIME information. The +filter is also used to process text messages of an unknown +subtype. +

                + +

                The default behavior of the filter is wrap the data in +the HTML PRE element and escape special characters. It will +also convert text that looks like a URL into a hyperlink. +If the data contains non-ASCII character, the filter will +convert the characters to the appropriate entity reference. +

                + +

                m2h_text_plain'filter can take the +following +arguments: +

                + + + + + + + + + + + + + + + + + + + + + + + + +
                asis=set1:...

                Colon separated lists of charsets to leave as-is. +Only HTML special characters will be converted into entities. +

                +
                keepspace

                Preserve all spaces if the nonfixed +option is specified. Each space will be translated to a +&nbsp; entity reference. +

                +
                maxwidth=#

                Force the maximum width of lines to be # characters +in length. Any lines longer than # characters will be +wrapped. +

                +
                nonfixed

                Do not wrap message text in the HTML PRE element. This will +cause text to be rendered in the default font (which is normally +proportionally spaced). Each line of the message will have +a <BR> appended in order to preserve the line representation +of the message. +

                +
                nourl

                Do not hyperlink URLs. +

                +
                quote

                Italicize quoted message text. +

                +
                + +

                All arguments should be separated by at least one space.

                + +

                m2h_text_setext'filter

                + +

                This filter converts text/setext and text/x-setext messages +to HTML. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +MIMEARGS, +PERLINC +

                + + +
                +
                +97/05/13 17:29:38
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/modtime.html b/doc/resources/modtime.html new file mode 100644 index 0000000..03979e3 --- /dev/null +++ b/doc/resources/modtime.html @@ -0,0 +1,100 @@ + + + +MHonArc Resources: MODTIME + + + +
                +MHonArc Resource List
                +
                + +
                +

                MODTIME

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MODTIME=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<MODTIME>
                +<NOMODTIME>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-modtime
                +-nomodtime +
                +

                +
                + +
                + + +
                +

                Description

                + +

                If MODTIME is active, force converted message files to have the same +file modification times as the dates of the messages. This features is +useful for archives that are indexed by a search engine. The search +index can be incrementally updated based upon the modification times +of the message files. +

                + + +
                +

                Default Setting

                + +

                Off. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:37
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/months.html b/doc/resources/months.html new file mode 100644 index 0000000..2febf30 --- /dev/null +++ b/doc/resources/months.html @@ -0,0 +1,112 @@ + + + +MHonArc Resources: MONTHS + + + +
                +MHonArc Resource List
                +
                + +
                +

                MONTHS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MONTHS=month1:month2:...:month12 +

                +
                + +
                Element
                +

                +<MONTHS>
                +month1:month2:...:month12
                +</MONTHS>
                +

                +
                + +
                Command-line Option
                +

                +-months month1:month2:...:month12 +

                +
                + +
                + + +
                +

                Description

                + +

                The MONTHS resource defines the names of the months. You +can set this resource to redefine month names to reflect +a particular locale for the +GMTDATEFMT and +LOCALDATEFMT +resources. When setting this resource, make sure to +define all 12 months. +

                + + +
                +

                Default Setting

                + +
                +January:Febuary:March:April:May:June:July:August:September:October:November:December
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +GMTDATEFMT, +LOCALDATEFMT, +MONTHSABR, +WEEKDAYS, +WEEKDAYSABR +

                + + +
                +
                +97/05/13 17:29:38
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/monthsabr.html b/doc/resources/monthsabr.html new file mode 100644 index 0000000..4b14d80 --- /dev/null +++ b/doc/resources/monthsabr.html @@ -0,0 +1,112 @@ + + + +MHonArc Resources: MONTHSABR + + + +
                +MHonArc Resource List
                +
                + +
                +

                MONTHSABR

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MONTHSABR=month1:month2:...:month12 +

                +
                + +
                Element
                +

                +<MONTHSABR>
                +month1:month2:...:month12
                +</MONTHSABR>
                +

                +
                + +
                Command-line Option
                +

                +-MONTHSABR month1:month2:...:month12 +

                +
                + +
                + + +
                +

                Description

                + +

                The MONTHSABR resource defines the abbreviate month names. You +can set this resource to redefine the abbreviate month names to reflect +a particular locale for the +GMTDATEFMT and +LOCALDATEFMT +resources. When setting this resource, make sure to +define all 12 months. +

                + + +
                +

                Default Setting

                + +
                +Jan:Feb:Mar:Apr:May:Jun:Jul:Aug:Sep:Oct:Nov:Dec
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +GMTDATEFMT, +LOCALDATEFMT, +MONTHS, +WEEKDAYS, +WEEKDAYSABR +

                + + +
                +
                +97/05/13 17:29:39
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msgfoot.html b/doc/resources/msgfoot.html new file mode 100644 index 0000000..32b812b --- /dev/null +++ b/doc/resources/msgfoot.html @@ -0,0 +1,380 @@ + + + +MHonArc Resources: MSGFOOT + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGFOOT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A + +

                +
                + +
                Element
                +

                +<MSGFOOT>
                +markup ...
                +</MSGFOOT>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                MSGFOOT defines the markup to occur at the foot of each +converted message page. +

                + + +
                +

                Default Setting

                + +

                Nil +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.1.0 +

                + + +
                +

                See Also

                + +

                +MSGHEAD, +MSGPGBEGIN, +MSGPGEND +

                + + +
                +
                +97/05/13 17:29:40
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msggmtdatefmt.html b/doc/resources/msggmtdatefmt.html new file mode 100644 index 0000000..4da727c --- /dev/null +++ b/doc/resources/msggmtdatefmt.html @@ -0,0 +1,200 @@ + + + +MHonArc Resources: MSGGMTDATEFMT + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGGMTDATEFMT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MSGGMTDATEFMT=date-format +

                +
                + +
                Element
                +

                +<MSGGMTDATEFMT>
                +date-format
                +</MSGGMTDATEFMT>
                +

                +
                + +
                Command-line Option
                +

                +-msggmtdatefmt date-format +

                +
                + +
                + + +
                +

                Description

                + +

                The MSGGMTDATEFMT resource specifies the date format for the +$MSGGMTDATE$ resource variable +(i.e. The GMT date of the current message). +The format is a string containing zero or more conversion +specifications and regular characters. A conversion specification +consists of the '%' character +followed a character that determines the type of conversion. +

                + +

                The following lists the possible conversion specifications: +

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                SpecValue
                %%the % character
                %aabbreviated weekday name
                %Afull weekday name
                %babbreviated month name
                %Bfull month name
                %cappropriate date and time representation
                %dday of month [1,31]; single digits are preceded by 0
                %habbreviated month name
                %Hhour (24-hour clock) [0,23]; single digits are preceded by 0
                %Ihour (12-hour clock) [1,12]; single digits are preceded by 0
                %jday number of year [1,366]; single digits are preceded by 0
                %mmonth number [1,12]; single digits are preceded by 0
                %Mminute[00,59]; single digits are preceded by 0
                %pam or pm.
                %PAM or PM.
                %Sseconds [00,61]
                %wweekday as a decimal number [0,6], with 0 representing Sunday
                %yyear within century [00,99]
                %Yyear, including the century (for example 1993)
                + +

                Setting MSGGMTDATEFMT to a blank string will reset the resource +to the default setting. +

                + + +
                +

                Default Setting

                + +
                +%a %b %d %H:%M:%S GMT %y
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +GMTDATEFMT, +LOCALDATEFMT, +MONTHS, +MONTHSABR, +WEEKDAYS, +WEEKDAYSABR +

                + + +
                +
                +97/05/13 17:29:41
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msghead.html b/doc/resources/msghead.html new file mode 100644 index 0000000..093c9b3 --- /dev/null +++ b/doc/resources/msghead.html @@ -0,0 +1,380 @@ + + + +MHonArc Resources: MSGHEAD + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGHEAD

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A + +

                +
                + +
                Element
                +

                +<MSGHEAD>
                +markup ...
                +</MSGHEAD>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                MSGHEAD defines the markup to occur at the head of each +converted message page. +

                + + +
                +

                Default Setting

                + +

                Nil +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.1.0 +

                + + +
                +

                See Also

                + +

                +MSGFOOT, +MSGPGBEGIN, +MSGPGEND +

                + + +
                +
                +97/05/13 17:29:41
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msglocaldatefmt.html b/doc/resources/msglocaldatefmt.html new file mode 100644 index 0000000..4ee954f --- /dev/null +++ b/doc/resources/msglocaldatefmt.html @@ -0,0 +1,201 @@ + + + +MHonArc Resources: MSGLOCALDATEFMT + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGLOCALDATEFMT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MSGLOCALDATEFMT=date-format +

                +
                + +
                Element
                +

                +<MSGLOCALDATEFMT>
                +date-format
                +</MSGLOCALDATEFMT>
                +

                +
                + +
                Command-line Option
                +

                +-msglocaldatefmt date-format +

                +
                + +
                + + +
                +

                Description

                + +

                The MSGLOCALDATEFMT resource specifies the date format for the +$MSGLOCALDATE$ resource variable +(i.e. The local date of the current message). +The format is a string containing zero or more conversion +specifications and regular characters. A conversion specification +consists of the '%' character +followed a character that determines the type of conversion. +

                + +

                The following lists the possible conversion specifications: +

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                SpecValue
                %%the % character
                %aabbreviated weekday name
                %Afull weekday name
                %babbreviated month name
                %Bfull month name
                %cappropriate date and time representation
                %dday of month [1,31]; single digits are preceded by 0
                %habbreviated month name
                %Hhour (24-hour clock) [0,23]; single digits are preceded by 0
                %Ihour (12-hour clock) [1,12]; single digits are preceded by 0
                %jday number of year [1,366]; single digits are preceded by 0
                %mmonth number [1,12]; single digits are preceded by 0
                %Mminute[00,59]; single digits are preceded by 0
                %pam or pm.
                %PAM or PM.
                %Sseconds [00,61]
                %wweekday as a decimal number [0,6], with 0 representing Sunday
                %yyear within century [00,99]
                %Yyear, including the century (for example 1993)
                + +

                Setting MSGLOCALDATEFMT to a blank string will reset the resource +to the default setting. +

                + + +
                +

                Default Setting

                + +
                +%a %b %d %H:%M:%S %y
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +GMTDATEFMT, +LOCALDATEFMT, +MONTHS, +MONTHSABR, +MSGGMTDATEFMT, +WEEKDAYS, +WEEKDAYSABR +

                + + +
                +
                +97/05/13 17:29:42
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msgpgbegin.html b/doc/resources/msgpgbegin.html new file mode 100644 index 0000000..8edf201 --- /dev/null +++ b/doc/resources/msgpgbegin.html @@ -0,0 +1,391 @@ + + + +MHonArc Resources: MSGPGBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGPGBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A + +

                +
                + +
                Element
                +

                +<MSGPGBEGIN>
                +markup ...
                +</MSGPGBEGIN>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                MSGPGBEGIN defines the beginning markup of +each message page. It allows you to redefine the opening HTML +element, HEAD element, TITLE element, +opening BODY element, etc. +

                + + +
                +

                Default Setting

                + +
                +<MsgPgBegin>
                +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML//EN">
                +<HTML>
                +<HEAD>
                +<TITLE>$SUBJECTNA:72$</TITLE>
                +<LINK REV="made" HREF="mailto:$FROMADDR$">
                +</HEAD>
                +<BODY>
                +</MsgPgBegin>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2.0 +

                + + +
                +

                See Also

                + +

                +MSGFOOT, +MSGHEAD, +MSGPGEND +

                + + +
                +
                +97/05/13 17:29:43
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msgpgend.html b/doc/resources/msgpgend.html new file mode 100644 index 0000000..6f4cd04 --- /dev/null +++ b/doc/resources/msgpgend.html @@ -0,0 +1,384 @@ + + + +MHonArc Resources: MSGPGEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGPGEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A + +

                +
                + +
                Element
                +

                +<MSGPGEND>
                +markup ...
                +</MSGPGEND>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                MSGPGEND defines the ending markup of +each message page. +

                + + +
                +

                Default Setting

                + +
                +<MsgPgEnd>
                +</BODY>
                +</HTML>
                +</MsgPgEnd>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2.0 +

                + + +
                +

                See Also

                + +

                +MSGFOOT, +MSGHEAD, +MSGPGBEGIN +

                + + +
                +
                +97/05/13 17:29:44
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/msgsep.html b/doc/resources/msgsep.html new file mode 100644 index 0000000..74e8a9b --- /dev/null +++ b/doc/resources/msgsep.html @@ -0,0 +1,118 @@ + + + +MHonArc Resources: MSGSEP + + + +
                +MHonArc Resource List
                +
                + +
                +

                MSGSEP

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MSGSEP=Perl-regexp +

                +
                + +
                Element
                +

                +<MSGSEP>
                +Perl-regexp
                +</MSGSEP>
                +

                +
                + +
                Command-line Option
                +

                +-msgsep Perl-regexp +

                +
                + +
                + + +
                +

                Description

                + +

                MSGSEP defines the Perl regular expression that represents the +message separator for mailbox files.

                + + +
                +

                Default Setting

                + +
                +^From 
                +
                + +

                Note: There is a space character after +"From". +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                Some MTAs do not escape lines that start with "From ". +This will cause MHonArc to split a message into separate +messages since it will treat the line as a message separator +(if MHonArc is processing a mailbox file). One +way to help avoid this problem is to set the MSGSEP resource to +a more specific regular expression. For example: +

                + +
                +<MSGSEP>
                +^From \S+\s+\S+\s+\S+\s+\d+\s+\d+:\d+:\d+\s+\d+
                +</MSGSEP>
                +
                + +

                It is still possible to get bogus splitting if a message +contains a line that matches the regexp. +Therefore, you may +want to activate the CONLEN resource, +if applicable. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +CONLEN +

                + + +
                +
                +97/05/13 17:29:45
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/multipg.html b/doc/resources/multipg.html new file mode 100644 index 0000000..27f6dbc --- /dev/null +++ b/doc/resources/multipg.html @@ -0,0 +1,110 @@ + + + +MHonArc Resources: MULTIPG + + + +
                +MHonArc Resource List
                +
                + +
                +

                MULTIPG

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_MULTIPG=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                + +<MULTIPG>
                +<NOMULTIPG>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-multipg
                +-nomultipg +
                +

                +
                + +
                + + +
                +

                Description

                + +

                When MULTIPG is set, MHonArc will break up the indexes +into muliple pages with each page containing +IDXSIZE messages. If +IDXSIZE is not defined to a finite value, then MULTIPG is +shut off. +

                + + +
                +

                Default Setting

                + +

                Off +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +IDXSIZE +NEXTPGLINK, +NEXTPGLINKIA, +PREVPGLINK, +PREVPGLINKIA, +TNEXTPGLINK, +TNEXTPGLINKIA, +TPREVPGLINK, +TPREVPGLINKIA +

                + + +
                +
                +97/05/13 17:29:45
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/news.html b/doc/resources/news.html new file mode 100644 index 0000000..aae8b4d --- /dev/null +++ b/doc/resources/news.html @@ -0,0 +1,99 @@ + + + +MHonArc Resources: NEWS + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEWS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_NEWS=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                + +<NEWS>
                +<NONEWS>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-news
                +-nonews +
                +

                +
                + +
                + + +
                +

                Description

                + +

                When NEWS is on, newsgroups listed in the Newsgroup field +of a message header will be converted to news URL +hyperlinks. +

                + + +
                +

                Default Setting

                + +

                On. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:46
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/nextbutton.html b/doc/resources/nextbutton.html new file mode 100644 index 0000000..98740ce --- /dev/null +++ b/doc/resources/nextbutton.html @@ -0,0 +1,394 @@ + + + +MHonArc Resources: NEXTBUTTON + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEXTBUTTON

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<NEXTBUTTON>
                +markup ...
                +</NEXTBUTTON>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                NEXTBUTTON defines the value for the $NEXTBUTTON$ +resource variable when there is a next message to the current message +according to the message list order of the main index. See the +NEXTBUTTONIA for defining the +value of $NEXTBUTTON$ when there is no next message. +

                + + +
                +

                Default Setting

                + +
                +<NextButton chop>
                +[<A HREF="$NEXTMSG$">Date Next</A>]
                +</NextButton>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used for +linking to the next message in an archive: +

                + +
                +<NextButton chop>
                +<A HREF="$NEXTMSG$"><IMG SRC="next.gif" ALT="[Date Next]"></A>
                +</NextButton>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +NEXTBUTTONIA, +PREVBUTTON, +PREVBUTTONIA, +TNEXTBUTTON, +TNEXTBUTTONIA, +TOPLINKS +

                + + +
                +
                +97/05/13 17:29:46
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/nextbuttonia.html b/doc/resources/nextbuttonia.html new file mode 100644 index 0000000..5137b6a --- /dev/null +++ b/doc/resources/nextbuttonia.html @@ -0,0 +1,394 @@ + + + +MHonArc Resources: NEXTBUTTONIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEXTBUTTONIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<NEXTBUTTONIA>
                +markup ...
                +</NEXTBUTTONIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                NEXTBUTTONIA defines the value for the $NEXTBUTTON$ +resource variable when there is no next message to the current message +according to the message list order of the main index. See the +NEXTBUTTON for defining the +value of $NEXTBUTTON$ when there is a next message. +

                + + +
                +

                Default Setting

                + +
                +<NextButtonIA chop>
                +[Date Next]
                +</NextButtonIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used to +show no next message is avaliable: +

                + +
                +<NextButtonIA chop>
                +<IMG SRC="nextia.gif" ALT="[Date Next]">
                +</NextButtonIA gt;
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +NEXTBUTTON, +PREVBUTTON, +PREVBUTTONIA, +TNEXTBUTTON, +TNEXTBUTTONIA, +TOPLINKS +

                + + +
                +
                +97/05/13 17:29:47
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/nextlink.html b/doc/resources/nextlink.html new file mode 100644 index 0000000..f7909db --- /dev/null +++ b/doc/resources/nextlink.html @@ -0,0 +1,409 @@ + + + +MHonArc Resources: NEXTLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEXTLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<NEXTLINK>
                +markup ...
                +</NEXTLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                NEXTLINK defines the value for the $NEXTLINK$ +resource variable when there is a next message to the current message +according to the message list order of the main index. NEXTLINK +is analagous to +NEXTBUTTON, but is intended to +provide a more descriptive link to the next message. +

                + +

                See the +NEXTLINKIA for defining the +value of $NEXTLINK$ when there is no next message. +

                + + +
                +

                Default Setting

                + +
                +<NextLink>
                +<LI>Next by sort-type:
                +<STRONG><A HREF="$NEXTMSG$">$NEXTSUBJECT$</A></STRONG>
                +</LI>
                +</NextLink>
                +
                + +

                sort-type will be a string that relects the +sort method in effect. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows an alternative to the default setting by +add the author of the next message: +

                + +
                +<NextLink>
                +<LI>Next by Date:
                +<STRONG><A HREF="$NEXTMSG$">$NEXTSUBJECT$</A></STRONG>,
                +<EM>$NEXTFROMNAME$</EM>
                +</LI>
                +</NextLink>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +NEXTLINKIA, +PREVLINK, +PREVLINKIA, +TNEXTLINK, +TNEXTLINKIA +

                + + +
                +
                +97/05/13 17:29:48
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/nextlinkia.html b/doc/resources/nextlinkia.html new file mode 100644 index 0000000..3451646 --- /dev/null +++ b/doc/resources/nextlinkia.html @@ -0,0 +1,387 @@ + + + +MHonArc Resources: NEXTLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEXTLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<NEXTLINKIA>
                +markup ...
                +</NEXTLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                NEXTLINKIA defines the value for the $NEXTLINKIA$ +resource variable when there is no next message to the current message +according to the message list order of the main index. +

                + +

                See the +NEXTLINK for defining the +value of $NEXTLINK$ when there is a next message. +

                + + +
                +

                Default Setting

                + +

                Nil +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +NEXTLINK, +PREVLINK, +PREVLINKIA, +TNEXTLINK, +TNEXTLINKIA +

                + + +
                +
                +97/05/13 17:29:49
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/nextpglink.html b/doc/resources/nextpglink.html new file mode 100644 index 0000000..726898e --- /dev/null +++ b/doc/resources/nextpglink.html @@ -0,0 +1,222 @@ + + + +MHonArc Resources: NEXTPGLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEXTPGLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<NEXTPGLINK>
                +markup ...
                +</NEXTPGLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                NEXTPGLINK defines the value for the $NEXTPGLINK$ +resource variable when there is a next page to the current page +of the main index. +

                + +

                See the +NEXTPGLINKIA for defining the +value of $NEXTPGLINK$ when there is no next page. +

                + + + +
                +

                Default Setting

                + +
                +<NextPgLink chop>
                +[<A HREF="$NEXTPG$">Next Page</A>]
                +</NextPgLink>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +LISTBEGIN, +MULTIPG, +NEXTPGLINKIA, +PREVPGLINK, +PREVPGLINKIA +

                + + +
                +
                +97/05/13 17:29:50
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/nextpglinkia.html b/doc/resources/nextpglinkia.html new file mode 100644 index 0000000..a0f8503 --- /dev/null +++ b/doc/resources/nextpglinkia.html @@ -0,0 +1,222 @@ + + + +MHonArc Resources: NEXTPGLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                NEXTPGLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<NEXTPGLINKIA>
                +markup ...
                +</NEXTPGLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                NEXTPGLINKIA defines the value for the $NEXTPGLINKIA$ +resource variable when there is no next page to the current page +of the main index. +

                + +

                See the +NEXTPGLINK for defining the +value of $NEXTPGLINK$ when there is a next page. +

                + + + +
                +

                Default Setting

                + +
                +<NextPgLinkIA chop>
                +[Next Page]
                +</NextPgLinkIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +LISTBEGIN, +MULTIPG, +NEXTPGLINK, +PREVPGLINK, +PREVPGLINKIA +

                + + +
                +
                +97/05/13 17:29:51
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/otherindexes.html b/doc/resources/otherindexes.html new file mode 100644 index 0000000..b8b9b29 --- /dev/null +++ b/doc/resources/otherindexes.html @@ -0,0 +1,161 @@ + + + +MHonArc Resources: OTHERINDEXES + + + +
                +MHonArc Resource List
                +
                + +
                +

                OTHERINDEXES

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_OTHERINDEXES=rcfile1:rcfile2:...:rcfileN +

                +
                + +
                Element
                +

                +<OTHERINDEXES>
                +rcfile1:rcfile2:...
                +rcfilei:...:rcfileN
                +</OTHERINDEXES>
                +

                +
                + +
                Command-line Option
                +

                +-otherindexes rcfile1:rcfile2:...:rcfileN +

                +
                + +
                + + +
                +

                Description

                + +

                OTHERINDEXES defines a list of resource files that +define other index pages +to generate when creating, or updating, an archive. When setting +the OTHERINDEXES resource, the filenames are separated by colons +(or semicolons under MSDOS/Windows). Line-breaks can be used +to separate filenames if setting OTHERINDEXES via the +OTHERINDEXES element. +

                + +
                +
                CAUTION + +

                It is very important that each resource file specified +defines the +MAIN or +THREAD resource to determine the +type of index to create. Also, the +IDXFNAME or +TIDXFNAME resource +(and IDXPREFIX or +TIDXPREFIX resource if +MULTIPG is active) +must be defined +to prevent overwriting of the default index pages. +

                + +

                MHonArc will only store the name of the resource files +listed in the database. Therefore, for any subsequent updates of the +archive, the extra index resource files must exist inorder to generate +the extra index pages.

                + +
                +
                NOTE + +

                Since MHonArc will look in the archive location for +resource files specified with relative pathnames, you can keep the +other index resource files in the same location as the archive, and +just specify the filenames for the OTHERINDEXES element +in the main resource file.

                + +

                When create resource files for extra indexes, make sure to +explicitly set all resources desired since some resource settings may +no longer be set to the defaults due to database settings, or from +a previously read resource file. Ie. MHonArc does not reset +to the default settings when reading in the other resource files.

                + + +
                +

                Default Setting

                + +

                Nil +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                Since MHonArc only creates two indexes by default +(the main/date index and the thread index), you can use OTHERINDEXES +to define other index formats for navigating your archive. A +possible setting for OTHERINDEXES may look like this: +

                + +
                +<OtherIndexes>
                +reversedateidx.rc
                +subjectidx.rc
                +</OtherIndexes>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +IDXFNAME, +IDXPREFIX, +MULTIPG, +TIDXFNAME, +TIDXPREFIX, +MAIN, +THREAD +

                + + +
                +
                +97/05/13 17:29:51
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/outdir.html b/doc/resources/outdir.html new file mode 100644 index 0000000..e3ef684 --- /dev/null +++ b/doc/resources/outdir.html @@ -0,0 +1,96 @@ + + + +MHonArc Resources: OUTDIR + + + +
                +MHonArc Resource List
                +
                + +
                +

                OUTDIR

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_OUTDIR=path +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-outdir path +

                +
                + +
                + + +
                +

                Description

                + +

                OUTDIR defines the location of the archive to process. +

                + + +
                +

                Default Setting

                + +
                +.
                +
                + +

                Aka, the current working directory. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +
                +    % mhonarc -add -outdir /home/ehood/archive inbox
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:52
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/perlinc.html b/doc/resources/perlinc.html new file mode 100644 index 0000000..6a2323f --- /dev/null +++ b/doc/resources/perlinc.html @@ -0,0 +1,130 @@ + + + +MHonArc Resources: PERLINC + + + +
                +MHonArc Resource List
                +
                + +
                +

                PERLINC

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_PERLINC=path1:path2:...:pathN +

                +
                + +
                Element
                +

                +<PERLINC>
                +path1:path2:...
                +pathi:...:pathN
                +</PERLINC>
                +

                +
                + +
                Command-line Option
                +

                +-perlinc path1:path2:...:pathN +

                +
                + +
                + + +
                +

                Description

                + +

                PERLINC defines a list of paths to search for MIME filters. +When setting +the PERLINC resource, the filenames are separated by colons +(or semicolons under MSDOS/Windows). Line-breaks can be used +to separate filenames if setting PERLINC via the +PERLINC element. +

                + +

                PERLINC augments the @INC +array in Perl. The paths listed in PERLINC will be searched +before the paths in @INC. +

                + +
                +
                NOTE
                +

                During the installation of MHonArc, the +MHonArc library location gets prepended to +@INC. +

                +
                +
                + + +
                +

                Default Setting

                + +

                Empty. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                When hooking in your own MIME filters, you may want to +put all the source libraries in a single location for maintenance +purposes. Therefore, you will need to define PERLINC similiar +to the following: +

                + +
                +<PerlINC>
                +/home/ehood/lib/mhonarc/local
                +</PerlINC>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +MIMEFILTERS +

                + + +
                +
                +97/05/13 17:29:53
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/prevbutton.html b/doc/resources/prevbutton.html new file mode 100644 index 0000000..44f8bd4 --- /dev/null +++ b/doc/resources/prevbutton.html @@ -0,0 +1,394 @@ + + + +MHonArc Resources: PREVBUTTON + + + +
                +MHonArc Resource List
                +
                + +
                +

                PREVBUTTON

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<PREVBUTTON>
                +markup ...
                +</PREVBUTTON>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                PREVBUTTON defines the value for the $PREVBUTTON$ +resource variable when there is a previous message to the current message +according to the message list order of the main index. See the +PREVBUTTONIA for defining the +value of $PREVBUTTON$ when there is no next message. +

                + + +
                +

                Default Setting

                + +
                +<PrevButton chop>
                +[<A HREF="$PREVMSG$">Date Prev</A>]
                +</PrevButton>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used for +linking to the previous message in an archive: +

                + +
                +<PrevButton chop>
                +<A HREF="$PREVMSG$"><IMG SRC="prev.gif" ALT="[Date Prev]"></A>
                +</PrevButton>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +NEXTBUTTON, +NEXTBUTTONIA, +PREVBUTTONIA, +TPREVBUTTON, +TPREVBUTTONIA, +TOPLINKS +

                + + +
                +
                +97/05/13 17:29:53
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/prevbuttonia.html b/doc/resources/prevbuttonia.html new file mode 100644 index 0000000..cd9a0d7 --- /dev/null +++ b/doc/resources/prevbuttonia.html @@ -0,0 +1,394 @@ + + + +MHonArc Resources: PREVBUTTONIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                PREVBUTTONIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<PREVBUTTONIA>
                +markup ...
                +</PREVBUTTONIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                PREVBUTTONIA defines the value for the $PREVBUTTON$ +resource variable when there is no previous message to the current message +according to the message list order of the main index. See the +PREVBUTTON for defining the +value of $PREVBUTTON$ when there is a next message. +

                + + +
                +

                Default Setting

                + +
                +<PrevButtonIA chop>
                +[Date Prev]
                +<PrevButtonIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used for +showing when there is no previous message: +

                + +
                +<PrevButtonIA chop>
                +<IMG SRC="previa.gif" ALT="[Date Prev]">
                +</PrevButtonIA>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +NEXTBUTTON, +NEXTBUTTONIA, +PREVBUTTON, +TPREVBUTTON, +TPREVBUTTONIA, +TOPLINKS +

                + + +
                +
                +97/05/13 17:29:54
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/prevlink.html b/doc/resources/prevlink.html new file mode 100644 index 0000000..344b045 --- /dev/null +++ b/doc/resources/prevlink.html @@ -0,0 +1,409 @@ + + + +MHonArc Resources: PREVLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                PREVLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<PREVLINK>
                +markup ...
                +</PREVLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                PREVLINK defines the value for the $PREVLINK$ +resource variable when there is a previous message to the current message +according to the message list order of the main index. PREVLINK +is analagous to +PREVBUTTON, but is intended to +provide a more descriptive link to the previous message. +

                + +

                See +PREVLINKIA for defining the +value of $PREVLINK$ when there is no previous message. +

                + + +
                +

                Default Setting

                + +
                +<PrevLink>
                +<LI>Prev by sort-type:
                +<STRONG><A HREF="$PREVMSG$">$PREVSUBJECT$</A></STRONG>
                +</LI>
                +</PrevLink>
                +
                + +

                sort-type will be a string that relects the +sort method in effect. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows an alternative to the default setting by +add the author of the previous message: +

                + +
                +<PrevLink>
                +<LI>Prev by sort-type:
                +<STRONG><A HREF="$PREVMSG$">$PREVSUBJECT$</A></STRONG>,
                +<EM>$PREVFROMNAME$</EM>
                +</LI>
                +</PrevLink>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +NEXTLINK, +NEXTLINKIA, +PREVLINK, +TPREVLINK, +TPREVLINKIA +

                + + +
                +
                +97/05/13 17:29:55
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/prevlinkia.html b/doc/resources/prevlinkia.html new file mode 100644 index 0000000..e0c190f --- /dev/null +++ b/doc/resources/prevlinkia.html @@ -0,0 +1,387 @@ + + + +MHonArc Resources: PREVLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                PREVLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<PREVLINKIA>
                +markup ...
                +</PREVLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                PREVLINKIA defines the value for the $PREVLINK$ +resource variable when there is no previous message to the current message +according to the message list order of the main index. +

                + +

                See +PREVLINK for defining the +value of $PREVLINK$ when there is a previous message. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +NEXTLINK, +NEXTLINKIA, +PREVLINK, +TPREVLINK, +TPREVLINKIA +

                + + +
                +
                +97/05/13 17:29:56
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/prevpglink.html b/doc/resources/prevpglink.html new file mode 100644 index 0000000..cb0e1ba --- /dev/null +++ b/doc/resources/prevpglink.html @@ -0,0 +1,222 @@ + + + +MHonArc Resources: PREVPGLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                PREVPGLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<PREVPGLINK>
                +markup ...
                +</PREVPGLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                PREVPGLINK defines the value for the $PREVPGLINK$ +resource variable when there is a previous page to the current page +of the main index. +

                + +

                See the +PREVPGLINKIA for defining the +value of $PREVPGLINK$ when there is no previous page. +

                + + + +
                +

                Default Setting

                + +
                +<PrevPgLink chop>
                +[<A HREF="$PREVPG$">Prev Page</A>]
                +</PrevPgLink>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +LISTBEGIN, +MULTIPG, +PREVPGLINKIA, +NEXTPGLINK, +NEXTPGLINKIA +

                + + +
                +
                +97/05/13 17:29:57
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/prevpglinkia.html b/doc/resources/prevpglinkia.html new file mode 100644 index 0000000..1c275ef --- /dev/null +++ b/doc/resources/prevpglinkia.html @@ -0,0 +1,222 @@ + + + +MHonArc Resources: PREVPGLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                PREVPGLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<PREVPGLINKIA>
                +markup ...
                +</PREVPGLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                PREVPGLINKIA defines the value for the $PREVPGLINK$ +resource variable when there is no previous page to the current page +of the main index. +

                + +

                See the +PREVPGLINK for defining the +value of $PREVPGLINK$ when there is a previous page. +

                + + + +
                +

                Default Setting

                + +
                +<PrevPgLinkIA chop>
                +[Prev Page]
                +</PrevPgLinkIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NEXTPG$Filename of next page of the main index.
                $NEXTPGLINK$Markup linking to the next page of the main index.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PAGENUM$Current index page number.
                $PREVPG$Filename of the previous page of the main index.
                $PREVPGLINK$Markup linking to the previous page of the main index.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +LISTBEGIN, +MULTIPG, +NEXTPGLINK, +NEXTPGLINKIA, +PREVPGLINK +

                + + +
                +
                +97/05/13 17:29:58
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/quiet.html b/doc/resources/quiet.html new file mode 100644 index 0000000..2eb7b4d --- /dev/null +++ b/doc/resources/quiet.html @@ -0,0 +1,93 @@ + + + +MHonArc Resources: QUIET + + + +
                +MHonArc Resource List
                +
                + +
                +

                QUIET

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-quiet + +

                +
                + +
                + + +
                +

                Description

                + +

                When QUIET is active, MHonArc will suppress all +informational diagnostics when processing. Error and warning +diagnostics will still get outputed. +

                + + +
                +

                Default Setting

                + +

                Off. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:29:59
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/rcfile.html b/doc/resources/rcfile.html new file mode 100644 index 0000000..8ffca23 --- /dev/null +++ b/doc/resources/rcfile.html @@ -0,0 +1,372 @@ + + + +MHonArc Resources: RCFILE + + + +
                +MHonArc Resource List
                +
                + +
                +

                RCFILE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_RCFILE=filename +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-rcfile filename +

                +
                + +
                + + +
                +

                Description

                + +

                RCFILE tells MHonArc what the resource file is. +The resource file allows you to specify most of the resources set by +environment variables and command-line options, and it allows you to specify +other resources to control MHonArc's behavior. +

                + +

                Resource file syntax

                + +

                Resources are set in the file by using elements similiar +in style to HTML/SGML markup. However, MHonArc uses simpler +parsing rules for the resource file than standard SGML:

                + +
                  + +
                • Any line that is not a recognized element open tag, and +the line is not contained within an element, is ignored. This implies +that regular text can be put anywhere outside of +recognized elements for commenting purposes.

                  + +
                  NOTE
                  +

                  You should use SGML comment declarations +(<!-- ... -->) when commenting a +resource file. This will eliminate possible conflict with later +versions of MHonArc if more stricter parsing rules are +adopted.

                  +
                  + +
                • The opening tag of an element must occur by itself on a +single line. Whitespace is allowed before the the open tag.

                  + +
                • No comments are allowed inside elements because the text will +be treated as element content (unless the comment text is supposed +to be part of the resource value).

                  + +
                • Each element must be closed with a +</element_name> tag on +its own line unless resource associated with the element is +a boolean resource. +Whitespace is allowed +before the close tag.

                  + +
                • Some elements can take an optional attribute called +"Override", if applicable. This tells MHonArc +that the contents of the element will completely override the default +behavior of MHonArc, and previous instances of the element. +Example: "<EXCS Override>". If +"Override" is not specified, then the contents of the +element augment the current setting.

                  + +
                • Some elements can take an optional attribute called +"Chop", if applicable. This tells MHonArc +to remove the last line-break of the element's content. +

                  + +
                • Element names are case-insensitive. +

                  + +
                • Elements can occur in any order in the resource file. +

                  + +
                + +

                Resource variables

                + +

                Many resources are allowed to have resource variables as +part of there content. Resource variables represent data that +can only be defined during run-time. I.e. Resource variables +will get expanded to an appropriate value during the execution +of MHonArc. +

                + +

                The syntax of variables in resources +is as follows:

                + +

                $VARIABLE[:[N][U]]$ +

                + +

                The items in []'s are optional. Definition of each part:

                + +
                $ + +

                The $ character represents the beginning, and +ending, of the variable.

                + +
                VARIABLE + +

                This is the the actual name of the variable. Variable names are +case sensitive. +

                + +
                :[N][U] (optional) + +

                This defines a maximum length of the replacement string for +the variable. The option "U" denotes that the replacement +string should be treated as part of a URL string. This can be useful +when the variable may contain special characters, and the variable +is used as part of a URL.

                + +
                + +

                No whitespace is allowed between the opening +$ and closing $. If an unrecognize d variable +is encountered, it gets replaced with an empty string. If a literal +"$" is needed, use "$$".

                + +
                +
                NOTE +

                The +MAILTOURL +resource has +different rules for variable expansion. If a +variable does not exactly match the set of variables available for +the MAILTOURL, the variable text will be taken literally +as part of the element content. Therefore, a single "$" +can be used to represent a "$" character.

                +

                Also, +variables in the MAILTOURL should NOT +have ":NU" modifier. This will prevent the +variables from be recognized. MHonArc will automatically +treat the replacement value as a part of a URL string. +

                +
                + +

                Here are some examples of legal variable usage: +

                +
                  +
                • $SUBJECT$ +
                • $FROMNAME$ +
                • $SUBJECT:50$ +
                • $SUBJECTNA:60U$ +
                • $FROMADDR:U$ +
                + +

                The description of for each resource will contain a list +of all applicable variables that may be used in defining the +resource's value. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                The following shows you what a resource file looks like: +

                + +
                +<!-- MHonArc resource file
                +  -->
                +<SORT>
                +<TITLE>
                +MHonArc test
                +</TITLE>
                + 
                +<TTITLE>
                +MHonArc test (by thread)
                +</TTITLE>
                + 
                +<!--=== Index Page Customizations =========================================-->
                + 
                +<!-- Have LISTBEGIN contain last updated information
                +  -->
                +<LISTBEGIN>
                +<address>
                +Last updated: $LOCALDATE$<br>
                +$NUMOFMSG$ messages in chronological order<br>
                +</address>
                +<ul>
                +<li><a href="$TIDXFNAME$">Thread Index</a></li>
                +</ul>
                +<p>
                +Listing format is the following:
                +<p>
                +<ul><li> 
                +<strong>Subject</strong>
                +(# of follow-ups)
                +<em>From</em><br>
                +</ul>
                +<p>
                +<hr>
                +<ul>
                +</LISTBEGIN>
                + 
                + 
                +<!-- A compact listing template
                +  -->
                +<LITEMPLATE>
                +<li> 
                +<strong>$SUBJECT:40$</strong>
                +($NUMFOLUP$) <em>$FROMNAME$</em><br>
                +</LITEMPLATE>
                + 
                +<LISTEND>
                +</ul>
                +<p>
                +<hr>
                +<strong>
                +<a href="http://foo.org/">Home</a>
                +</strong>
                +<p>
                +</LISTEND>
                + 
                +<!--=== Thread Index Page Customizations ==================================-->
                +<THEAD>
                +<address>
                +Thread index<br>
                +Last updated: $LOCALDATE$<br>
                +$NUMOFMSG$ messages<br>
                +</address>
                +<ul>
                +<li><a href="$IDXFNAME$">Main Index</a></li>
                +</ul>
                +<hr>
                +</THEAD>
                + 
                +<!--=== Message Customizations ============================================-->
                +<EXCS override>
                +apparently
                +errors-to 
                +followup
                +forward 
                +lines 
                +message-id
                +mime- 
                +nntp- 
                +originator 
                +path 
                +precedence 
                +received 
                +replied 
                +return-path 
                +status 
                +via 
                +x- 
                +</EXCS>
                +
                +<LABELSTYLES>
                +-default-
                +subject:strong
                +from:strong
                +to:strong
                +</LABELSTYLES>
                + 
                +<FIELDSTYLES>
                +-default-
                +subject:strong
                +from:strong
                +to:strong
                +keywords:em
                +newsgroups:strong
                +</FIELDSTYLES>
                + 
                +<MSGHEAD>
                +<address>
                +MHonArc test archive
                +</address>
                +</MSGHEAD>
                + 
                +<MSGFOOT>
                +<strong>
                +<a href="http://foo.org/">Home</a> |
                +<a href="$IDXFNAME$">Main Index</a> |
                +<a href="$TIDXFNAME$">Thread Index</a>
                +</strong>
                +</MSGFOOT>
                + 
                +<!--=== Icons =============================================================-->
                +<ICONS>
                +application/octet-stream:http://foo.org/icons/binary.xbm
                +application/postscript:http://foo.org/icons/postscript.xbm
                +audio/basic:http://foo.org/icons/sound.xbm
                +image/gif:http://foo.org/icons/image.xbm
                +image/jpeg:http://foo.org/icons/image.xbm
                +image/tiff:http://foo.org/icons/image.xbm
                +multipart/alternative:http://foo.org/icons/alternative.xbm
                +multipart/digest:http://foo.org/icons/text.xbm
                +multipart/mixed:http://foo.org/icons/mixed.xbm
                +multipart/parallel:http://foo.org/icons/mixed.xbm
                +text/richtext:http://foo.org/icons/mixed.xbm
                +text/html:http://foo.org/icons/mixed.xbm
                +text/plain:http://foo.org/icons/text.xbm
                +unknown:http://foo.org/icons/unknown.doc.xbm
                +video/mpeg:http://foo.org/icons/movie.xbm
                +video/quicktime:http://foo.org/icons/movie.xbm
                +</ICONS>
                +
                + + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:30:00
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/reverse.html b/doc/resources/reverse.html new file mode 100644 index 0000000..7329427 --- /dev/null +++ b/doc/resources/reverse.html @@ -0,0 +1,112 @@ + + + +MHonArc Resources: REVERSE + + + +
                +MHonArc Resource List
                +
                + +
                +

                REVERSE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_REVERSE=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                + +<REVERSE>
                +<NOREVERSE>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-reverse
                +-noreverse +
                +

                +
                + +
                + + +
                +

                Description

                + +

                If the REVERSE resource on, message groups in the main index will be +listed in the reverse chronological +order of the sort option specified. For example, +if date sorting is specified (see +SORT), then the messages will be listed +in reverse chronological order. If SUBSORT +is active, each subject group will have the most recent message +first and oldest last. +

                + + +
                +

                Default Setting

                + +

                Off. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following example shows how to get the most recent messages +to be listed first in the main index: +

                + +
                +    % mhonarc -sort -reverse ...
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +AUTHSORT, +SORT, +SUBSORT +

                + + +
                +
                +97/05/13 17:30:00
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/rmm.html b/doc/resources/rmm.html new file mode 100644 index 0000000..b137186 --- /dev/null +++ b/doc/resources/rmm.html @@ -0,0 +1,110 @@ + + + +MHonArc Resources: RMM + + + +
                +MHonArc Resource List
                +
                + +
                +

                RMM

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-rmm msgnum ... +

                +
                + +
                + + +
                +

                Description

                + +

                The RMM resource is activated by the -rmm command-line +option. When active, all non-option related arguments are treated +as message numbers to delete from the archive. +

                + +

                To help correlate message numbers to messages, see +SCAN. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +
                +    % mhonarc -rmm 24 28 39 48
                +    Removing messages from ./maillist.html ...
                +	    Removing message 24
                +	    Removing message 28
                +	    Removing message 39
                +	    Removing message 48
                +     
                +    Writing mail ...
                +    Writing tmp/maillist.html ...
                +    Writing tmp/threads.html ...
                +    45 messages
                +
                + + + +
                +

                Version

                + +

                1.1.0 +

                + + +
                +

                See Also

                + +

                +OUTDIR, +SCAN +

                + + +
                +
                +97/05/13 17:30:01
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/scan.html b/doc/resources/scan.html new file mode 100644 index 0000000..9623e4d --- /dev/null +++ b/doc/resources/scan.html @@ -0,0 +1,153 @@ + + + +MHonArc Resources: SCAN + + + +
                +MHonArc Resource List
                +
                + +
                +

                SCAN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-scan + +

                +
                + +
                + + +
                +

                Description

                + +

                When SCAN is specified, a text listing of the contents of +the archive are outputed to standard out. Messages are listed +in the order defined for the main index. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                The following example generates an output in the order +defined in the database of the archive: +

                + +
                +% mhonarc -scan -outdir /home/ehood/html/archive
                +Reading database ...
                +117 messages in /home/ehood/html/archive:
                + 
                +Msg #  YYYY/MM/DD  From             Subject                                    
                +-----  ----------  ---------------  -------------------------------------------
                +   62  1996/07/30  Kwin Kramer      Reading STDIN not from keyboard -- or, Syst
                +   23  1996/07/31  Christopher M.   Re: Setting @INC to include my own modules 
                +    9  1996/08/01  Dan Kirkwood     object as hash key loses methods           
                +    2  1996/08/01  James F'jord Ly  Re: We're HIRING hot hackers!              
                +    1  1996/08/01  Christopher Cha  Curious Multi-Dimensional array behavior   
                +   14  1996/08/01  I R A Aggie      Re: Patch for arithmetic bug in 5.003 ?    
                +    3  1996/08/01  Bernard Bellon   Re: How do you grab a URL in perl?         
                +   38  1996/08/01  Mohammed Dewan   Help needed badly win3.1 and perl.         
                +   59  1996/08/01  Mohammed Dewan   Using file in perl.                        
                +    4  1996/08/01  Dan Gildor       Re: Threaded Discusion groups embeded in We
                +    5  1996/08/01  kendall shaw     addicted to emacs lisp                     
                +    6  1996/08/01  Ye He            Q: Sybase extension to Perl                
                +   83  1996/08/01  I R A Aggie      Re: Browser/Page matching CGI script       
                +    7  1996/08/01  Chris Schleiche  Re: Simple program looks good, but gives er
                +   13  1996/08/01  Steve McCullagh  Perl 5.002 and $| errors                   
                +...
                +
                + +

                If you to always get a listing that shows messages by number, +use somthing like the following: +

                + +
                +% mhonarc -scan -noreverse -nosort -outdir /home/ehood/html/archive
                +Reading database ...
                +117 messages in /home/ehood/html/archive:
                + 
                +Msg #  YYYY/MM/DD  From             Subject                                    
                +-----  ----------  ---------------  -------------------------------------------
                +    0  1996/08/02  Markus Spring    How to build a stack of associative arrays?
                +    1  1996/08/01  Christopher Cha  Curious Multi-Dimensional array behavior   
                +    2  1996/08/01  James F'jord Ly  Re: We're HIRING hot hackers!              
                +    3  1996/08/01  Bernard Bellon   Re: How do you grab a URL in perl?         
                +    4  1996/08/01  Dan Gildor       Re: Threaded Discusion groups embeded in We
                +    5  1996/08/01  kendall shaw     addicted to emacs lisp                     
                +    6  1996/08/01  Ye He            Q: Sybase extension to Perl                
                +    7  1996/08/01  Chris Schleiche  Re: Simple program looks good, but gives er
                +    8  1996/08/02  Paul             Re: Eric Herrmann's Sams.Net Teach Yourself
                +    9  1996/08/01  Dan Kirkwood     object as hash key loses methods           
                +   10  1996/08/02  Mike Stok        Re: I cannot rename files using rename.  I 
                +   11  1996/08/02  Elisabeth Freem  Re: current working directory              
                +   12  1996/08/02  Søren Maagaard   Re: Make an entire site searchable         
                +   13  1996/08/01  Steve McCullagh  Perl 5.002 and $| errors                   
                +   14  1996/08/01  I R A Aggie      Re: Patch for arithmetic bug in 5.003 ?    
                +   15  1996/08/02  Mike Stok        Re: More on -w  (was Re: Is this a known bu
                +...
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +OUTDIR, +REVERSE, +SORT, +SUBSORT +

                + + +
                +
                +97/05/13 17:30:01
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/single.html b/doc/resources/single.html new file mode 100644 index 0000000..eba9988 --- /dev/null +++ b/doc/resources/single.html @@ -0,0 +1,111 @@ + + + +MHonArc Resources: SINGLE + + + +
                +MHonArc Resource List
                +
                + +
                +

                SINGLE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                N/A +

                +
                + +
                Command-line Option
                +

                +-single +

                +
                + +
                + + +
                +

                Description

                + +

                When SINGLE is on, MHonArc will interpret input +as a single message to convert to HTML with no archive +processing performed. Input can from a filename on the command-line +or from standard input. The converted message is sent to +standard output. +

                + + +
                +

                Default Setting

                + +

                N/A +

                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +
                +
                Input from standard input: + +
                +% mhonarc -single < messagefile > file.html
                +or,
                +% cat messagefile | mhonarc -single > file.html +
                + +
                +
                Filename on command-line: + +
                +% mhonarc -single messagefile > file.html +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:30:02
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/sort.html b/doc/resources/sort.html new file mode 100644 index 0000000..0f48863 --- /dev/null +++ b/doc/resources/sort.html @@ -0,0 +1,101 @@ + + + +MHonArc Resources: SORT + + + +
                +MHonArc Resource List
                +
                + +
                +

                SORT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_SORT=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                + +<SORT>
                +<NOSORT>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-sort
                +-nosort +
                +

                +
                + +
                + + +
                +

                Description

                + +

                When SORT is active, messages are sorted by date in the +main index. When SORT is off, messages are listed in the +ordered processed. +

                + + +
                +

                Default Setting

                + +

                On. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +REVERSE, +SUBSORT +

                + + +
                +
                +97/05/13 17:30:03
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/subjectbegin.html b/doc/resources/subjectbegin.html new file mode 100644 index 0000000..ad43405 --- /dev/null +++ b/doc/resources/subjectbegin.html @@ -0,0 +1,213 @@ + + + +MHonArc Resources: SUBJECTBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                SUBJECTBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<SUBJECTBEGIN>
                +markup ...
                +</SUBJECTBEGIN>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                SUBJECTBEGIN defines the beginning markup of a subject group +in the main index if the +SUBSORT +reosource is set. +A subject group is a group of messages with the same subject. +

                + +

                Any message related resource variables available for the SUBJECTBEGIN +evaluate based on information from the first message in the group. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following example resource settings cause the main index +to be sorted by subject. The listing will contain each subject +followed by a sub-listing of the author's: +

                + +
                +<SubSort>
                +
                +<SubjectBegin>
                +<li><strong>$SUBJECTNA$</strong>
                +<ul>
                +</SubjectBegin>
                +
                +<SubjectEnd>
                +</li></ul>
                +</SubjectEnd>
                +
                +<LITemplate>
                +<li><a $A_ATTR$>$FROMNAME$</a></li>
                +</LITemplate>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +SUBJECTEND, +SUBSORT +

                + + +
                +
                +97/05/13 17:30:04
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/subjectend.html b/doc/resources/subjectend.html new file mode 100644 index 0000000..b637186 --- /dev/null +++ b/doc/resources/subjectend.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: SUBJECTEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                SUBJECTEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<SUBJECTEND>
                +markup ...
                +</SUBJECTEND>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                SUBJECTEND defines the end markup of a subject group +in the main index if the +SUBSORT +reosource is set. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +SUBJECTBEGIN, +SUBSORT +

                + + +
                +
                +97/05/13 17:30:05
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/subjectheader.html b/doc/resources/subjectheader.html new file mode 100644 index 0000000..03bd17b --- /dev/null +++ b/doc/resources/subjectheader.html @@ -0,0 +1,151 @@ + + + +MHonArc Resources: SUBJECTHEADER + + + +
                +MHonArc Resource List
                +
                + +
                +

                SUBJECTHEADER

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<SUBJECTHEADER>
                +markup ...
                +</SUBJECTHEADER>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                SUBJECTHEADER defines the markup for the main subject line +above the message header of message pages. If the +SUBJECTHEADER resource is changed and messages already exist +in the archive, those messages will not inherit the change. +Therefore, you need to be sure about the value of SUBJECTHEADER +when create an archive. +

                + + +
                +

                Default Setting

                + +
                +<SubjectHeader>
                +<H1>$SUBJECTNA$</H1>
                +<HR>
                +</SubjectHeader>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:30:06
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/subsort.html b/doc/resources/subsort.html new file mode 100644 index 0000000..1a0a3e3 --- /dev/null +++ b/doc/resources/subsort.html @@ -0,0 +1,100 @@ + + + +MHonArc Resources: SUBSORT + + + +
                +MHonArc Resource List
                +
                + +
                +

                SUBSORT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_SUBSORT=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                + +<SUBSORT>
                +<NOSUBSORT>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-subsort
                +-nosubsort +
                +

                +
                + +
                + + +
                +

                Description

                + +

                When SUBSORT is active, messages are listed by subject in the +main index. +

                + + +
                +

                Default Setting

                + +

                Off. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +REVERSE, +SORT +

                + + +
                +
                +97/05/13 17:30:06
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tcontbegin.html b/doc/resources/tcontbegin.html new file mode 100644 index 0000000..c0d2e6d --- /dev/null +++ b/doc/resources/tcontbegin.html @@ -0,0 +1,201 @@ + + + +MHonArc Resources: TCONTBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                TCONTBEGIN

                + + +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TCONTBEGIN>
                +markup...
                +</TCONTBEGIN>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +

                Description

                + +

                TCONTBEGIN defines the markup to occur before the continuation +of a broken thread. When MHonArc creates a multi-page +thread index, it is possible that a thread may be split across +mulitple pages. The use of TCONTBEGIN is to prompt the reader +that the following messages listed are a continuation of a thread +from the previous page. +

                + + + + + + +
                NOTE

                The values of the resource variables are based upon the first +message on the page. However, a normal listing will be made for +the first message. Therefore, the value of TCONTBEGIN should +NOT contain linkage to a message. The purpose +of TCONTBEGIN is purely informative. +

                +
                + + + +

                Default Setting

                + +
                +<TContBegin>
                +<LI><STRONG>$SUBJECTNA$</STRONG>, <EM>(continued)</EM>
                +</TContBegin>
                +
                + + + +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +

                Examples

                + +

                None. +

                + + +

                Version

                + +

                2.0 +

                + + +

                See Also

                + +

                +MULTIPG, +TCONTEND, +TINDENTBEGIN +

                + + +
                +
                +97/05/13 17:30:36
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tcontend.html b/doc/resources/tcontend.html new file mode 100644 index 0000000..1afb9bc --- /dev/null +++ b/doc/resources/tcontend.html @@ -0,0 +1,96 @@ + + + +MHonArc Resources: TCONTEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                TCONTEND

                + + +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TCONTEND>
                +markup...
                +</TCONTEND>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +

                Description

                + +

                TCONTEND defines the closing markup of the continuation +of a broken thread. +

                + + + +

                Default Setting

                + +
                +<TContEnd>
                +</LI>
                +</TContEnd>
                +
                + + + +

                Resource Variables

                + +

                N/A

                + + +

                Examples

                + +

                None. +

                + + +

                Version

                + +

                2.0 +

                + + +

                See Also

                + +

                +TINDENTBEGIN +

                + + +
                +
                +97/05/13 17:30:37
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tfoot.html b/doc/resources/tfoot.html new file mode 100644 index 0000000..2bc41b7 --- /dev/null +++ b/doc/resources/tfoot.html @@ -0,0 +1,227 @@ + + + +MHonArc Resources: TFOOT + + + +
                +MHonArc Resource List
                +
                + +
                +

                TFOOT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TFOOT>
                +markup ...
                +</TFOOT>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TFOOT defines the footer markup of thread index pages. It +is also responsible for defining the closing markup for the +thread listing. +

                + + +
                +

                Default Setting

                + +
                +<TFoot>
                +</UL>
                +</TFoot>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                The following example sets TFOOT to contain page links +for a multi-page thread index: +

                + +
                +<TFoot>
                +</ul>
                +<hr>
                +<table border=0 width="100%">
                +<tbody>
                +<tr>
                +<td align="left">$TPREVPGLINK$
                +<td align="right">[<a href="$TFIRSTPG$">First Page</a>]
                +<td align="left">[<a href="$TLASTPG$">Last Page</a>]
                +<td align="right">$TNEXTPGLINK$
                +<tr align="center">
                +<th colspan=4>Page $PAGENUM$ of $NUMOFPAGES$
                +</tbody>
                +</table>
                +</TFoot>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +THEAD +

                + + +
                +
                +97/05/13 17:30:07
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/thead.html b/doc/resources/thead.html new file mode 100644 index 0000000..b991545 --- /dev/null +++ b/doc/resources/thead.html @@ -0,0 +1,255 @@ + + + +MHonArc Resources: THEAD + + + +
                +MHonArc Resource List
                +
                + +
                +

                THEAD

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<THEAD>
                +markup ...
                +</THEAD>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                THEAD defines the header markup of thread index pages. It +is also responsible for defining the opening markup for the +thread listing. +

                + + +
                +

                Default Setting

                + +

                If MULTIPG is on: +

                + +
                +<THead>
                +<UL>
                +<LI><A HREF="$IDXFNAME$">Main Index</A></LI>
                +</UL>
                +$TPREVPGLINK$$TNEXTPGLINK$
                +<HR>
                +<UL>
                +</THead>
                +
                + +

                If MULTIPG is off: +

                + +
                +<THead>
                +<UL>
                +<LI><A HREF="$IDXFNAME$">Main Index</A></LI>
                +</UL>
                +<HR>
                +<UL>
                +</THead>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                The following example sets THEAD to contain page links +for a multi-page thread index: +

                + +
                +<THead>
                +<ul>
                +<li><a href="$IDXFNAME$">Date Index</a></li>
                +</ul>
                +<hr>
                +<table border=0 width="100%">
                +<tbody>
                +<tr align="center">
                +<th colspan=4>Page $PAGENUM$ of $NUMOFPAGES$
                +<tr>
                +<td align="left">$TPREVPGLINK$
                +<td align="right">[<a href="$TFIRSTPG$">First Page</a>]
                +<td align="left">[<a href="$TLASTPG$">Last Page</a>]
                +<td align="right">$TNEXTPGLINK$
                +</tbody>
                +</table>
                +<hr>
                +<ul>
                +</THead>
                +
                + + +
                +

                Version

                + +

                1.1 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +TFOOT, +TNEXTPGLINK, +TPREVPGLINK +

                + + +
                +
                +97/05/13 17:30:07
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/thread.html b/doc/resources/thread.html new file mode 100644 index 0000000..d98b895 --- /dev/null +++ b/doc/resources/thread.html @@ -0,0 +1,97 @@ + + + +MHonArc Resources: THREAD + + + +
                +MHonArc Resource List
                +
                + +
                +

                THREAD

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_THREAD=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                +<THREAD>
                +<NOTHREAD>
                +

                +
                + +
                Command-line Option(s)
                +

                +-thread
                +-nothread +
                +

                +
                + +
                + + +
                +

                Description

                + +

                If THREAD is on, MHonArc will create the thread index +page(s) for the archive. If off, no thread index is created. +

                + + +
                +

                Default Setting

                + +

                On. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.1.0 +

                + + +
                +

                See Also

                + +

                +MAIN +

                + + +
                +
                +97/05/13 17:30:08
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tidxfname.html b/doc/resources/tidxfname.html new file mode 100644 index 0000000..39a5da3 --- /dev/null +++ b/doc/resources/tidxfname.html @@ -0,0 +1,99 @@ + + + +MHonArc Resources: TIDXFNAME + + + +
                +MHonArc Resource List
                +
                + +
                +

                TIDXFNAME

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_TIDXFNAME=filename +

                +
                + +
                Element
                +

                +<TIDXFNAME>
                +filename
                +</TIDXFNAME>
                +

                +
                + +
                Command-line Option
                +

                +-tidxfname filename +

                +
                + +
                + + +
                +

                Description

                + +

                TIDXFNAME defines the filename for the thread index page. If +MULTIPG is on, it defines the filename +of the first page of the thread index. +

                + + +
                +

                Default Setting

                + +
                +threads.html
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.1.0 +

                + + +
                +

                See Also

                + +

                +IDXFNAME, +MULTIPG +

                + + +
                +
                +97/05/13 17:30:09
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tidxlabel.html b/doc/resources/tidxlabel.html new file mode 100644 index 0000000..231cfe9 --- /dev/null +++ b/doc/resources/tidxlabel.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: TIDXLABEL + + + +
                +MHonArc Resource List
                +
                + +
                +

                TIDXLABEL

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +N/A +

                +
                + +
                Element
                +

                +<TIDXLABEL>
                +markup ... +</TIDXLABEL>
                + +

                +
                + +
                Command-line Option
                +

                +N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TIDXLABEL defines the label text for the thread index. Specifically, +it defines the value of the $TIDXLABEL$ +resource variable. +

                + + +
                +

                Default Setting

                + +
                +Thread Index
                +
                + + +
                +

                Resource Variables

                + +

                N/A +

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +IDXLABEL +

                + + +
                +
                +97/05/13 17:30:09
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tidxpgbegin.html b/doc/resources/tidxpgbegin.html new file mode 100644 index 0000000..c62c3d5 --- /dev/null +++ b/doc/resources/tidxpgbegin.html @@ -0,0 +1,234 @@ + + + +MHonArc Resources: TIDXPGBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                TIDXPGBEGIN

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TIDXPGBEGIN>
                +markup ...
                +</TIDXPGBEGIN>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The TIDXPGBEGIN resource defines the beginning markup for the thread +index pages. I.e. You can control the opening <HTML> tag, the +HEAD element contents, the opening <BODY> tag, etc. Therefore, +if you are not satisfied with the default behavior of how the +TTITLE +resource is used, or have other needs that require control on the +beginning markup, you can set the TIDXPGBEGIN resource to what you +desire. +

                + + +
                +

                Default Setting

                + +
                +<TIdxPgBegin>
                +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML//EN">
                +<HTML>
                +<HEAD>
                +<TITLE>$TIDXTITLE$</TITLE>
                +</HEAD>
                +<BODY>
                +<H1>$TIDXTITLE$</H1>
                +</TIdxPgBegin>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                The following shows how you can set HTML body element attributes +to control the appearence of the thread index pages: +

                + +
                +<TIdxPgBegin>
                +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML//EN">
                +<HTML>
                +<HEAD>
                +<TITLE>$TIDXTITLE$</TITLE>
                +</HEAD>
                +<BODY background="tidxbg.gif" bgproperties="fixed">
                +<H1>$TIDXTITLE$</H1>
                +</TIdxPgBegin>
                +
                + + + +
                +

                Version

                + +

                1.2.0 +

                + + +
                +

                See Also

                + +

                +TIDXPGEND, +TTITLE +

                + + +
                +
                +97/05/13 17:30:10
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tidxpgend.html b/doc/resources/tidxpgend.html new file mode 100644 index 0000000..703027d --- /dev/null +++ b/doc/resources/tidxpgend.html @@ -0,0 +1,208 @@ + + + +MHonArc Resources: TIDXPGEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                TIDXPGEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TIDXPGEND>
                +markup ...
                +</TIDXPGEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                The TIDXPGEND resource defines the end markup for the thread +index pages. +

                + + +
                +

                Default Setting

                + +
                +<TIdxPgEnd>
                +</BODY>
                +</HTML>
                +</TIdxPgEnd>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                +TIDXPGBEGIN +

                + + +
                +
                +97/05/13 17:30:10
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tidxprefix.html b/doc/resources/tidxprefix.html new file mode 100644 index 0000000..5e04208 --- /dev/null +++ b/doc/resources/tidxprefix.html @@ -0,0 +1,114 @@ + + + +MHonArc Resources: TIDXPREFIX + + + +
                +MHonArc Resource List
                +
                + +
                +

                TIDXPREFIX

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_TIDXPREFIX=prefix +

                +
                + +
                Element
                +

                +<TIDXPREFIX>
                +prefix
                +</TIDXPREFIX>
                +

                +
                + +
                Command-line Option
                +

                +-tidxprefix prefix +

                +
                + +
                + + +
                +

                Description

                + +

                TIDXPREFIX defines the prefix for the filenames of a multi-page +thread index. The filename of the first page of the thread index is always equal +to the value of the +TIDXFNAME resource. All other pages have +a filename starting with the TIDXPREFIX value with the page number and +".html" following. For example, the filenames for a 4 page +thread index would be the following: +

                + +
                +    threads.html
                +    thrd2.html
                +    thrd3.html
                +    thrd4.html
                +
                + +

                assuming the default values for the TIDXFNAME and TIDXPREFIX +resources. +

                + + +
                +

                Default Setting

                + +
                +thrd
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +TIDXFNAME +

                + + +
                +
                +97/05/13 17:30:11
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/timezones.html b/doc/resources/timezones.html new file mode 100644 index 0000000..6a23908 --- /dev/null +++ b/doc/resources/timezones.html @@ -0,0 +1,131 @@ + + + +MHonArc Resources: TIMEZONES + + + +
                +MHonArc Resource List
                +
                + +
                +

                TIMEZONES

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TIMEZONES>
                +timezone_acronym:hour_offset
                +timezone_acronym:hour_offset
                +...
                +</TIMEZONES>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TIMEZONES maps timezones to hour offsets from UTC/GMT +(Universal Coordinate Time). The TIMEZONES resource +can be defined only by the +TIMEZONES element +The format of each line of content is +"timezone_acronym:hour_offset". +Examples of timezone acronyms are: UTC, PDT, +EST. The hour offset should be positive for timezones +West of UTC, and negative for time zones East of UTC.

                + +

                MHonArc has a default list of timezone acronyms +defined with hour offsets. Therefore, the list given in +the resource file will augment the default list, unless the +"Override" attribute is specified. If +"Override" is specified, the default list, along with any +other lists specified in previous TIMEZONES elements, +are discarded, and only the timezone acronyms specified in the +TIMEZONES element will be used.

                + +

                Much of the time, the date used by MHonArc has an hour +offset instead of a timezone acronym. However, mail messages may +contain timezone acronyms in received/sent dates and MHonArc +must be told what the hour offset from UTC the timezone acronym +represents in order to properly sort messages by date.

                + + +
                +

                Default Setting

                + +
                +<TimeZones>
                +UTC:0
                +GMT:0
                +AST:4
                +ADT:3
                +EST:5
                +EDT:4
                +CST:6
                +CDT:5
                +MST:7
                +MDT:6
                +PST:8
                +PDT:7
                +</TimeZones>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:30:13
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tindentbegin.html b/doc/resources/tindentbegin.html new file mode 100644 index 0000000..9a552f5 --- /dev/null +++ b/doc/resources/tindentbegin.html @@ -0,0 +1,121 @@ + + + +MHonArc Resources: TINDENTBEGIN + + + +
                +MHonArc Resource List
                +
                + +
                +

                TINDENTBEGIN

                + + +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TINDENTBEGIN>
                +markup...
                +</TINDENTBEGIN>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +

                Description

                + +

                TINDENTBEGIN defines the markup for opening a level for the +continuation of a broken thread. When MHonArc creates a +multi-page thread index, it is possible that a thread may be split +across mulitple pages. TINDENTBEGIN is used to create a thread +level indent inorder to restart a thread at the proper level. +TINDENTBEGIN will be used for each level that MHonArc +must create inorder to restart the thread. +

                + +

                The resource, TINDENTEND, is used +to close a level created by TINDENTBEGIN. +

                + + + +

                Default Setting

                + +
                +<TIndentBegin>
                +<UL>
                +</TIndentBegin>
                +
                + + +

                Resource Variables

                + +

                N/A +

                + + +

                Examples

                + +

                By default, MHonArc uses the UL element for listing +messages in a thread index. An alternative, is to use the DL +element if bullets before messages are not desired. Therefore, +the following may be used for continuing a broken a thread if +DL's are used for listing messages for the thread index: +

                + +
                +<TIndentBegin>
                +<DL><DD>
                +</TIndentBegin>
                +
                +<TIndentEnd>
                +</DD></DL>
                +</TIndentEnd>
                +
                + + +

                Version

                + +

                2.0 +

                + + +

                See Also

                + +

                +MULTIPG, +TCONTBEGIN, +TINDENTEND +

                + + +
                +
                +97/05/13 17:30:37
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tindentend.html b/doc/resources/tindentend.html new file mode 100644 index 0000000..e40798a --- /dev/null +++ b/doc/resources/tindentend.html @@ -0,0 +1,98 @@ + + + +MHonArc Resources: TINDENTEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                TINDENTEND

                + + +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TINDENTEND>
                +markup...
                +</TINDENTEND>
                + +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +

                Description

                + +

                TINDENTEND defines the markup for closing a level for the +continuation of a broken thread. +See TINDENTBEGIN for more information. +

                + + + +

                Default Setting

                + +
                +<TIndentEnd>
                +</UL>
                +</TIndentEnd>
                +
                + + +

                Resource Variables

                + +

                N/A +

                + + +

                Examples

                + +

                See TINDENTBEGIN. +

                + + + +

                Version

                + +

                2.0 +

                + + +

                See Also

                + +

                +TINDENTBEGIN +

                + + +
                +
                +97/05/13 17:30:38
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/title.html b/doc/resources/title.html new file mode 100644 index 0000000..148d350 --- /dev/null +++ b/doc/resources/title.html @@ -0,0 +1,107 @@ + + + +MHonArc Resources: TITLE + + + +
                +MHonArc Resource List
                +
                + +
                +

                TITLE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_TITLE=string +

                +
                + +
                Element
                +

                +<TITLE>
                +string
                +</TITLE>
                +

                +
                + +
                Command-line Option
                +

                +-title string +

                +
                + +
                + + +
                +

                Description

                + +

                TITLE defines the value of the $IDXTITLE resource +variable. Unless doing custom page layout, the effect of setting +the TITLE resource sets the title of the main index. +

                + + +
                +

                Default Setting

                + +
                +Mail Index
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                It is common to set TITLE to the name of the mailing list, or +newsgroup, being archived. Also, it is common have the title +state the list order of the main index. For example: +

                + +
                +<Title>
                +MHonArc Mailing List (by date)
                +</Title>
                +
                + + +
                +

                Version

                + +

                1.0 +

                + + +
                +

                See Also

                + +

                +IDXPGBEGIN, +TTITLE +

                + + +
                +
                +97/05/13 17:30:14
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tlevels.html b/doc/resources/tlevels.html new file mode 100644 index 0000000..1441a98 --- /dev/null +++ b/doc/resources/tlevels.html @@ -0,0 +1,97 @@ + + + +MHonArc Resources: TLEVELS + + + +
                +MHonArc Resource List
                +
                + +
                +

                TLEVELS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_TLEVELS=number +

                +
                + +
                Element
                +

                +<TLEVELS>
                +number
                +</TLEVELS>
                +

                +
                + +
                Command-line Option
                +

                +-tlevels number +

                +
                + +
                + + +
                +

                Description

                + +

                TLEVELS defines the maximum number of nested listings in a thread +index. Any threads that go over TLEVELS in depth are flattened to +the value of TLEVELS. This resource is helpful in preventing huge +indentations in deep threads and cause text to be squished on the +left-side of an HTML viewer.

                + + +
                +

                Default Setting

                + +

                3 +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                1.1.0 +

                + + +
                +

                See Also

                + +

                +

                + + +
                +
                +97/05/13 17:30:15
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tliend.html b/doc/resources/tliend.html new file mode 100644 index 0000000..c2b2ef8 --- /dev/null +++ b/doc/resources/tliend.html @@ -0,0 +1,190 @@ + + + +MHonArc Resources: TLIEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                TLIEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TLIEND>
                +markup ...
                +</TLIEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TLIEND defines the end markup for a regular entry in +the thread index. A regular entry is a message that has +either a previous or next message and is not the +top message in a thread. +

                + +
                +
                NOTE
                +

                Use +TLITXT for defining +the start and content markup for a regular entry. +

                +
                +
                + + +
                +

                Default Setting

                + +
                +<TLiEnd>
                +</LI>
                +</TLiEnd>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From field.
                $FROMADDR$The e-mail address in the From field.
                $FROMNAME$The human name of the person in the From field.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGID$The message-id of the message.
                $MSGNUM$The message numbers assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TLITXT +

                + + +
                +
                +97/05/13 17:30:15
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tlinone.html b/doc/resources/tlinone.html new file mode 100644 index 0000000..03d3395 --- /dev/null +++ b/doc/resources/tlinone.html @@ -0,0 +1,108 @@ + + + +MHonArc Resources: TLINONE + + + +
                +MHonArc Resource List
                +
                + +
                +

                TLINONE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TLINONE>
                +markup ...
                +</TLINONE>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TLINONE defines the markup for a missing message in +a thread. Occasionally, a message may not be present within +a thread. TLINONE defines the starting and content markup to use to +represent a missing message. +

                + +
                +
                NOTE
                +

                Use +TLINONEEND for defining +the end markup for a missing message. +

                +
                +
                + + +
                +

                Default Setting

                + +
                +<TLiNone>
                +<LI><EM>Message not available</EM>
                +</TLiNone>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TLINONEEND +

                + + +
                +
                +97/05/13 17:30:16
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tlinoneend.html b/doc/resources/tlinoneend.html new file mode 100644 index 0000000..27bd9aa --- /dev/null +++ b/doc/resources/tlinoneend.html @@ -0,0 +1,107 @@ + + + +MHonArc Resources: TLINONEEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                TLINONEEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TLINONEEND>
                +markup ...
                +</TLINONEEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                Occasionally, a message may not be present within +a thread. TLINONEEND defines the end markup to use to +represent a missing message. +

                + +
                +
                NOTE
                +

                Use +TLINONE for defining +the start and content markup for a missing message. +

                +
                +
                + + +
                +

                Default Setting

                + +
                +<TLiNoneEnd>
                +</LI>
                +</TLiNoneEnd>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TLINONE +

                + + +
                +
                +97/05/13 17:30:16
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tlitxt.html b/doc/resources/tlitxt.html new file mode 100644 index 0000000..f48c3b7 --- /dev/null +++ b/doc/resources/tlitxt.html @@ -0,0 +1,197 @@ + + + +MHonArc Resources: TLITXT + + + +
                +MHonArc Resource List
                +
                + +
                +

                TLITXT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TLITXT>
                +markup ...
                +</TLITXT>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TLITXT defines the starting markup and content for a regular entry in +the thread index. A regular entry is a message that has +either a previous or next message and is not the +top message in a thread. +

                + +
                +
                NOTE
                +

                Use +TLIEND for defining +the end markup for a regular entry. +

                +
                +
                + + +
                +

                Default Setting

                + +
                +<TLiTxt>
                +<LI><STRONG>$SUBJECT$</STRONG>,
                +<EM>$FROMNAME$</EM>
                +</TLiTxt>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.1 +

                + + +
                +

                See Also

                + +

                +TLIEND, +TSINGLETXT, +TTOPBEGIN +

                + + +
                +
                +97/05/13 17:30:17
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tnextbutton.html b/doc/resources/tnextbutton.html new file mode 100644 index 0000000..5235fdd --- /dev/null +++ b/doc/resources/tnextbutton.html @@ -0,0 +1,392 @@ + + + +MHonArc Resources: TNEXTBUTTON + + + +
                +MHonArc Resource List
                +
                + +
                +

                TNEXTBUTTON

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TNEXTBUTTON>
                +markup ...
                +</TNEXTBUTTON>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TNEXTBUTTON defines the value for the $TNEXTBUTTON$ +resource variable when there is a next message to the current message +according to the message list order of the thread index. See the +TNEXTBUTTONIA for defining the +value of $TNEXTBUTTON$ when there is no next message. +

                + + +
                +

                Default Setting

                + +
                +<TNextButton chop>
                +[<A HREF="$TNEXTMSG$">Thread Next</A>]
                +<TNextButton>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used for +linking to the next message in an archive: +

                + +
                +<TNextButton chop>
                +<A HREF="$TNEXTMSG$"><IMG SRC="tnext.gif" ALT="[Thread Next]"></A>
                +<TNextButton>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TNEXTBUTTONIA, +TOPLINKS, +TPREVBUTTON, +TPREVBUTTONIA +

                + + +
                +
                +97/05/13 17:30:18
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tnextbuttonia.html b/doc/resources/tnextbuttonia.html new file mode 100644 index 0000000..b6fb8de --- /dev/null +++ b/doc/resources/tnextbuttonia.html @@ -0,0 +1,392 @@ + + + +MHonArc Resources: TNEXTBUTTONIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                TNEXTBUTTONIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TNEXTBUTTONIA>
                +markup ...
                +</TNEXTBUTTONIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TNEXTBUTTONIA defines the value for the $TNEXTBUTTON$ +resource variable when there is no next message to the current message +according to the message list order of the thread index. See the +TNEXTBUTTON for defining the +value of $TNEXTBUTTON$ when there is a next message. +

                + + +
                +

                Default Setting

                + +
                +<TNextButtonIA chop>
                +[Thread Next]
                +</TNextButtonIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used to +show no next message is avaliable: +

                + +
                +<TNextButtonIA chop>
                +<IMG SRC="tnextia.gif" ALT="[Thread Next]">
                +</TNextButtonIA>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TNEXTBUTTONIA, +TOPLINKS, +TPREVBUTTON, +TPREVBUTTONIA +

                + + +
                +
                +97/05/13 17:30:19
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tnextlink.html b/doc/resources/tnextlink.html new file mode 100644 index 0000000..fa18a42 --- /dev/null +++ b/doc/resources/tnextlink.html @@ -0,0 +1,403 @@ + + + +MHonArc Resources: TNEXTLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                TNEXTLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TNEXTLINK>
                +markup ...
                +</TNEXTLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TNEXTLINK defines the value for the $TNEXTLINK$ +resource variable when there is a next message to the current message +according to the message list order of the thread index. TNEXTLINK +is analagous to +TNEXTBUTTON, but is intended to +provide a more descriptive link to the next message. +

                + +

                See the +TNEXTLINKIA for defining the +value of $TNEXTLINK$ when there is no next message. +

                + + +
                +

                Default Setting

                + +
                +<TNextLink>
                +<LI>Next by Thread:
                +<STRONG><A HREF="$TNEXTMSG$">$TNEXTSUBJECT$</A></STRONG>
                +</LI>
                +</TNextLink>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows an alternative to the default setting by +add the author of the next message: +

                + +
                +<TNextLink>
                +<LI>Next by Thread:
                +<STRONG><A HREF="$TNEXTMSG$">$TNEXTSUBJECT$</A></STRONG>,
                +<EM>$TNEXTFROMNAME$</EM>
                +</LI>
                +</TNextLink>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +TNEXTLINKIA, +TPREVLINK, +TPREVLINKIA +

                + + +
                +
                +97/05/13 17:30:20
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tnextlinkia.html b/doc/resources/tnextlinkia.html new file mode 100644 index 0000000..fc580fd --- /dev/null +++ b/doc/resources/tnextlinkia.html @@ -0,0 +1,385 @@ + + + +MHonArc Resources: TNEXTLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                TNEXTLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TNEXTLINKIA>
                +markup ...
                +</TNEXTLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TNEXTLINKIA defines the value for the $TNEXTLINKIA$ +resource variable when there is no next message to the current message +according to the message list order of the thread index. +

                + +

                See the +TNEXTLINK for defining the +value of $TNEXTLINK$ when there is a next message. +

                + + +
                +

                Default Setting

                + +

                Nil +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +TNEXTLINK, +TPREVLINK, +TPREVLINKIA +

                + + +
                +
                +97/05/13 17:30:21
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tnextpglink.html b/doc/resources/tnextpglink.html new file mode 100644 index 0000000..2e95f0d --- /dev/null +++ b/doc/resources/tnextpglink.html @@ -0,0 +1,218 @@ + + + +MHonArc Resources: TNEXTPGLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                TNEXTPGLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TNEXTPGLINK>
                +markup ...
                +</TNEXTPGLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TNEXTPGLINK defines the value for the $TNEXTPGLINK$ +resource variable when there is a next page to the current page +of the thread index. +

                + +

                See the +TNEXTPGLINKIA for defining the +value of $TNEXTPGLINK$ when there is no next page. +

                + + + +
                +

                Default Setting

                + +
                +<TNextPgLink chop>
                +[<A HREF="$TNEXTPG$">Next Page</A>]
                +</TNextPgLink>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +THEAD, +TNEXTPGLINKIA, +TPREVPGLINK, +TPREVPGLINKIA +

                + + +
                +
                +97/05/13 17:30:22
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tnextpglinkia.html b/doc/resources/tnextpglinkia.html new file mode 100644 index 0000000..ef16248 --- /dev/null +++ b/doc/resources/tnextpglinkia.html @@ -0,0 +1,218 @@ + + + +MHonArc Resources: TNEXTPGLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                TNEXTPGLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TNEXTPGLINKIA>
                +markup ...
                +</TNEXTPGLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TNEXTPGLINKIA defines the value for the $TNEXTPGLINKIA$ +resource variable when there is no next page to the current page +of the thread index. +

                + +

                See the +TNEXTPGLINK for defining the +value of $TNEXTPGLINK$ when there is a next page. +

                + + + +
                +

                Default Setting

                + +
                +<TNextPgLinkIA chop>
                +[Next Page]
                +</TNextPgLinkIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +THEAD, +TNEXTPGLINK, +TPREVPGLINK, +TPREVPGLINKIA +

                + + +
                +
                +97/05/13 17:30:22
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/toplinks.html b/doc/resources/toplinks.html new file mode 100644 index 0000000..f01118e --- /dev/null +++ b/doc/resources/toplinks.html @@ -0,0 +1,409 @@ + + + +MHonArc Resources: TOPLINKS + + + +
                +MHonArc Resource List
                +
                + +
                +

                TOPLINKS

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TOPLINKS>
                +markup ...
                +</TOPLINKS>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TOPLINKS defines the markup for the navigational links at the top +of a message page. Its usage is analagous to the +BOTLINKS resource, but tends +to be terser. However, you can define the resource +anyway you desire. +

                + + +
                +

                Default Setting

                + +

                The following represents the default setting when there are +main and thread indexes. References to either index will not +show up if either index does not exist. +

                + +
                +<TopLinks>
                +<HR>
                +$PREVBUTTON$$NEXTBUTTON$$TPREVBUTTON$$TNEXTBUTTON$[<A
                +HREF="$IDXFNAME$#$MSGNUM$">Date Index</A>][<A
                +HREF="$TIDXFNAME$#$MSGNUM$">Thread Index</A>]
                +</TopLinks>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows an example of using button icons for +links to the index pages: +

                + +
                +<TopLinks>
                +<HR>
                +$PREVBUTTON$$NEXTBUTTON$$TPREVBUTTON$$TNEXTBUTTON$<A
                +HREF="$IDXFNAME$#$MSGNUM$"><IMG
                +SRC="dateidx.gif" ALT="[Date Index]"></A><A
                +HREF="$TIDXFNAME$#$MSGNUM$"><IMG
                +SRC="thrdidx.gif" ALT="[Thread Index]"></A>]
                +</TopLinks>
                +
                + + +
                +

                Version

                + +

                1.2 +

                + + +
                +

                See Also

                + +

                + +BOTLINKS, +IDXFNAME, +NEXTBUTTON, +PREVBUTTON, +TIDXFNAME, +TNEXTBUTTON, +TPREVBUTTON +

                + + +
                +
                +97/05/13 17:30:23
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tprevbutton.html b/doc/resources/tprevbutton.html new file mode 100644 index 0000000..341a4c0 --- /dev/null +++ b/doc/resources/tprevbutton.html @@ -0,0 +1,392 @@ + + + +MHonArc Resources: TPREVBUTTON + + + +
                +MHonArc Resource List
                +
                + +
                +

                TPREVBUTTON

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TPREVBUTTON>
                +markup ...
                +</TPREVBUTTON>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TPREVBUTTON defines the value for the $TPREVBUTTON$ +resource variable when there is a previous message to the current message +according to the message list order of the thread index. See the +TPREVBUTTONIA for defining the +value of $TPREVBUTTON$ when there is no next message. +

                + + +
                +

                Default Setting

                + +
                +<TPrevButton chop>
                +[<A HREF="$PREVMSG$">Thread Prev</A>]
                +</TPrevButton>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used for +linking to the previous message in an archive: +

                + +
                +<TPrevButton chop>
                +<A HREF="$TPREVMSG$"><IMG SRC="tprev.gif" ALT="[Thread Prev]"></A>
                +</TPrevButton>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TNEXTBUTTON, +TNEXTBUTTONIA, +TOPLINKS, +TPREVBUTTONIA +

                + + +
                +
                +97/05/13 17:30:24
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tprevbuttonia.html b/doc/resources/tprevbuttonia.html new file mode 100644 index 0000000..c5bb07d --- /dev/null +++ b/doc/resources/tprevbuttonia.html @@ -0,0 +1,392 @@ + + + +MHonArc Resources: TPREVBUTTONIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                TPREVBUTTONIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TPREVBUTTONIA>
                +markup ...
                +</TPREVBUTTONIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TPREVBUTTONIA defines the value for the $TPREVBUTTON$ +resource variable when there is no previous message to the current message +according to the message list order of the thread index. See the +TPREVBUTTON for defining the +value of $TPREVBUTTON$ when there is a next message. +

                + + +
                +

                Default Setting

                + +
                +<TPrevButtonIA chop>
                +[Thread Prev]
                +</TPrevButtonIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows how an button image can be used for +showing when there is no previous message: +

                + +
                +<TPrevButtonIA chop>
                +<IMG SRC="tprevia.gif" ALT="[Thread Prev]">
                +</TPrevButtonIA>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TNEXTBUTTON, +TNEXTBUTTONIA, +TOPLINKS, +TPREVBUTTON +

                + + +
                +
                +97/05/13 17:30:25
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tprevlink.html b/doc/resources/tprevlink.html new file mode 100644 index 0000000..43655e4 --- /dev/null +++ b/doc/resources/tprevlink.html @@ -0,0 +1,403 @@ + + + +MHonArc Resources: TPREVLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                TPREVLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TPREVLINK>
                +markup ...
                +</TPREVLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TPREVLINK defines the value for the $TPREVLINK$ +resource variable when there is a previous message to the current message +according to the message list order of the thread index. TPREVLINK +is analagous to +TPREVBUTTON, but is intended to +provide a more descriptive link to the previous message. +

                + +

                See +TPREVLINKIA for defining the +value of $TPREVLINK$ when there is no previous message. +

                + + +
                +

                Default Setting

                + +
                +<TPrevLink>
                +<LI>Prev by Thread:
                +<STRONG><A HREF="$TPREVMSG$">$TPREVSUBJECT$</A></STRONG>
                +</LI>
                +</TPrevLink>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                The following shows an alternative to the default setting by +add the author of the previous message: +

                + +
                +<TPrevLink>
                +<LI>Prev by Thread:
                +<STRONG><A HREF="$TPREVMSG$">$TPREVSUBJECT$</A></STRONG>,
                +<EM>$TPREVFROMNAME$</EM>
                +</LI>
                +</TPrevLink>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +TNEXTLINK, +TNEXTLINKIA, +TPREVLINKIA +

                + + +
                +
                +97/05/13 17:30:26
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tprevlinkia.html b/doc/resources/tprevlinkia.html new file mode 100644 index 0000000..271a3f7 --- /dev/null +++ b/doc/resources/tprevlinkia.html @@ -0,0 +1,385 @@ + + + +MHonArc Resources: TPREVLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                TPREVLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TPREVLINKIA>
                +markup ...
                +</TPREVLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TPREVLINKIA defines the value for the $TPREVLINK$ +resource variable when there is no previous message to the current message +according to the message list order of the thread index. +

                + +

                See +TPREVLINK for defining the +value of $TPREVLINK$ when there is a previous message. +

                + + +
                +

                Default Setting

                + +

                Nil. +

                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $GMTDATE$Current GMT date.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NEXTBUTTON$Next button markup linking to the next message.
                $NEXTFROM$Content of From field of the next message.
                $NEXTFROMADDR$E-mail address contained in From field of the next message.
                $NEXTFROMNAME$Human name contained in From field of the next message.
                $NEXTLINK$Next link markup linking to the next message.
                $NEXTMSG$Filename of next message.
                $NEXTMSGNUM$Number assigned to next message.
                $NEXTSUBJECT$Subject of next message.
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $ORDNUM$The current listing number of the message.
                $OUTDIR$Pathname of archive.
                $PREVBUTTON$Previous button markup linking to the previous message.
                $PREVFROM$Content of From field of the previous message.
                $PREVFROMADDR$E-mail address contained in From field of the previous message.
                $PREVFROMNAME$Human name contained in From field of the previous message.
                $PREVLINK$Previous link markup linking to the previous message.
                $PREVMSG$Filename of previous message.
                $PREVMSGNUM$Number assigned to previous message.
                $PREVSUBJECT$Subject of previous message.
                $PROG$Program name
                $SUBJECTNA$The subject text of the message without the anchor element.
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTBUTTON$Next button markup linking to the next message according to the thread index list order.
                $TNEXTFROM$Content of From field of the next message according to the list order of the thread index.
                $TNEXTFROMADDR$E-mail address contained in From field of the next message according to the list order of the thread index.
                $TNEXTFROMNAME$Human name contained in From field of the next message according to the list order of the thread index.
                $TNEXTLINK$Next link markup linking to the next message according to the thread index list order.
                $TNEXTMSG$Filename of next message according to the list order of the thread index.
                $TNEXTMSGNUM$Number assigned to next message according to the list order of the thread index.
                $TNEXTSUBJECT$Subject of next message according to the list order of the thread index.
                $TPREVBUTTON$Previous button markup linking to the previous message according to the thread index list order.
                $TPREVFROM$Content of From field of the previous message according to the list order of the thread index.
                $TPREVFROMADDR$E-mail address contained in From field of the previous message according to the list order of the thread index.
                $TPREVFROMNAME$Human name contained in From field of the previous message according to the list order of the thread index.
                $TPREVLINK$Previous link markup linking to the previous message according to the thread index list order.
                $TPREVMSG$Filename of previous message according to the list order of the thread index.
                $TPREVMSGNUM$Number assigned to previous message according to the list order of the thread index.
                $TPREVSUBJECT$Subject of previous message according to the list order of the thread index.
                $VERSION$Program version.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +BOTLINKS, +TNEXTLINK, +TNEXTLINKIA, +TPREVLINK +

                + + +
                +
                +97/05/13 17:30:27
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tprevpglink.html b/doc/resources/tprevpglink.html new file mode 100644 index 0000000..7144e31 --- /dev/null +++ b/doc/resources/tprevpglink.html @@ -0,0 +1,218 @@ + + + +MHonArc Resources: TPREVPGLINK + + + +
                +MHonArc Resource List
                +
                + +
                +

                TPREVPGLINK

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TPREVPGLINK>
                +markup ...
                +</TPREVPGLINK>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TPREVPGLINK defines the value for the $TPREVPGLINK$ +resource variable when there is a previous page to the current page +of the thread index. +

                + +

                See the +TPREVPGLINKIA for defining the +value of $TPREVPGLINK$ when there is no previous page. +

                + + + +
                +

                Default Setting

                + +
                +<TPrevPgLink chop>
                +[<A HREF="$TPREVPG$">Prev Page</A>]
                +</TPrevPgLink>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +THEAD, +TNEXTPGLINK, +TNEXTPGLINKIA, +TPREVPGLINKIA +

                + + +
                +
                +97/05/13 17:30:28
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tprevpglinkia.html b/doc/resources/tprevpglinkia.html new file mode 100644 index 0000000..f95c6c6 --- /dev/null +++ b/doc/resources/tprevpglinkia.html @@ -0,0 +1,218 @@ + + + +MHonArc Resources: TPREVPGLINKIA + + + +
                +MHonArc Resource List
                +
                + +
                +

                TPREVPGLINKIA

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TPREVPGLINKIA>
                +markup ...
                +</TPREVPGLINKIA>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TPREVPGLINKIA defines the value for the $TPREVPGLINK$ +resource variable when there is no previous page to the current page +of the thread index. +

                + +

                See the +TPREVPGLINK for defining the +value of $TPREVPGLINK$ when there is a previous page. +

                + + + +
                +

                Default Setting

                + +
                +<TPrevPgLinkIA chop>
                +[Prev Page]
                +</TPrevPgLinkIA>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $DOCURL$URL to documentation.
                $FIRSTPG$Filename of first page of main index.
                $GMTDATE$Current GMT date.
                $IDXFNAME$Filename of main index page.
                $IDXLABEL$Label for main index page.
                $IDXPREFIX$Prefix of filenames of main index pages.
                $IDXSIZE$Max number of messages that may be listed in index page.
                $IDXTITLE$The title of the main index page.
                $LASTPG$Filename of last page in of main index.
                $LOCALDATE$Current local date.
                $NUMOFIDXMSG$Number of message listed.
                $NUMOFMSG$Number of messages in the archive.
                $NUMOFPAGES$Number of index pages.
                $OUTDIR$Pathname of archive.
                $PROG$Program name
                $TFIRSTPG$Filename of first page of thread index.
                $TIDXFNAME$Filename of thread index page.
                $TIDXLABEL$Label for thread index page.
                $TIDXPREFIX$Prefix of filenames of thread index pages.
                $TIDXTITLE$Title of thread index.
                $TLASTPG$Filename of last page of thread index.
                $TNEXTPG$Filename of next page of the thread index.
                $TNEXTPGLINK$Markup linking to the next page of the thread index.
                $TPREVPG$Filename of the previous page of the thread index.
                $TPREVPGLINK$Markup linking to the previous page of the thread index.
                $VERSION$Program version.
                + + +
                +

                Examples

                + +

                None +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +MULTIPG, +THEAD, +TNEXTPGLINK, +TNEXTPGLINKIA, +TPREVPGLINK +

                + + +
                +
                +97/05/13 17:30:29
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/treverse.html b/doc/resources/treverse.html new file mode 100644 index 0000000..5ef778c --- /dev/null +++ b/doc/resources/treverse.html @@ -0,0 +1,100 @@ + + + +MHonArc Resources: TREVERSE + + + +
                +MHonArc Resource List
                +
                + +
                +

                TREVERSE

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                +M2H_TREVERSE=[ 0 | 1 ] +

                +
                + +
                Element(s)
                +

                + +<TREVERSE>
                +<NOTREVERSE>
                +
                +

                +
                + +
                Command-line Option(s)
                +

                +-treverse
                +-notreverse +
                +

                +
                + +
                + + +
                +

                Description

                + +

                If the TREVERSE resource on, messages in the thread index will be +listed with most recent thread first and oldest thread last. If +off, the oldest thread is listed first. +

                + + +
                +

                Default Setting

                + +

                Off. +

                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                1.1 +

                + + +
                +

                See Also

                + +

                +THREAD +

                + + +
                +
                +97/05/13 17:30:29
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tsingletxt.html b/doc/resources/tsingletxt.html new file mode 100644 index 0000000..a8fa518 --- /dev/null +++ b/doc/resources/tsingletxt.html @@ -0,0 +1,194 @@ + + + +MHonArc Resources: TSINGLETXT + + + +
                +MHonArc Resource List
                +
                + +
                +

                TSINGLETXT

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TSINGLETXT>
                +markup ...
                +</TSINGLETXT>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TSINGLETXT defines the markup for a thread index entry that is +not in a thread. I.e. The message has no references or follow-ups +in the archive. +

                + +
                +
                NOTE
                +

                TSINGLETXT should define the start markup, content, and +end markup. +

                +
                +
                + + +
                +

                Default Setting

                + +
                +<TSingleTxt>
                +<LI><STRONG>$SUBJECT$</STRONG>,
                +<EM>$FROMNAME$</EM>
                +</TSingleTxt>
                +
                + + +
                +

                Resource Variables

                + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
                VariableValue
                $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
                $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
                $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
                $DATE$The date of the message.
                $DDMMYY$Message date in dd/mm/yy format.
                $FROM$The complete text in the From: field of the message.
                $FROMADDR$The e-mail address in the From: field of the message.
                $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
                $ICON$The context-type sensistive icon.
                $ICONURL$The URL to the context-type sensistive icon.
                $MMDDYY$Message date in mm/dd/yy format.
                $MSGGMTDATE$GMT date of current message.
                $MSGID$The message-id of the message.
                $MSGLOCALDATE$Local date of current message.
                $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
                $NUMFOLUP$Number of explicit follow-ups to the message.
                $ORDNUM$The current listing number of the message.
                $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
                $SUBJECTNA$The subject text of the message without the anchor element.
                $YYMMDD$Message date in yy/mm/dd format.
                + + +
                +

                Examples

                + +

                None. +

                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TLITXT, +TTOPBEGIN +

                + + +
                +
                +97/05/13 17:30:30
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tsubjectbeg.html b/doc/resources/tsubjectbeg.html new file mode 100644 index 0000000..b168036 --- /dev/null +++ b/doc/resources/tsubjectbeg.html @@ -0,0 +1,108 @@ + + + +MHonArc Resources: TSUBJECTBEG + + + +
                +MHonArc Resource List
                +
                + +
                +

                TSUBJECTBEG

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TSUBJECTBEG>
                +markup ...
                +</TSUBJECTBEG>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TSUBJECTBEG defines the markup to include before +a subject based thread listing. I.e. It allows you to +insert some text in the thread index to signal the reader that +the following messages after the text were included in the +thread by subject text and not explicit message ID references. +

                + + +
                +

                Default Setting

                + +
                +<TSubjectBeg>
                +&lt;Possible follow-up(s)&gt;<BR>
                +</TSubjectBeg>
                +
                + + +
                +

                Resource Variables

                + +

                N/A

                + + +
                +

                Examples

                + +

                You may not care if messages are in a thread based upon +message ID references or subject text, therefore, just define +TSUBJECTBEG to be blank: +

                + +
                +<TSubjectBeg>
                +
                +</TSubjectBeg>
                +
                + + +
                +

                Version

                + +

                2.0 +

                + + +
                +

                See Also

                + +

                +TSUBJECTEND +

                + + +
                +
                +97/05/13 17:30:30
                + +MHonArc
                +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
                +
                + + + diff --git a/doc/resources/tsubjectend.html b/doc/resources/tsubjectend.html new file mode 100644 index 0000000..a7cee9a --- /dev/null +++ b/doc/resources/tsubjectend.html @@ -0,0 +1,94 @@ + + + +MHonArc Resources: TSUBJECTEND + + + +
                +MHonArc Resource List
                +
                + +
                +

                TSUBJECTEND

                + + +
                +

                Syntax

                + +
                + +
                Envariable
                +

                N/A +

                +
                + +
                Element
                +

                +<TSUBJECTEND>
                +markup ...
                +</TSUBJECTEND>
                +

                +
                + +
                Command-line Option
                +

                N/A +

                +
                + +
                + + +
                +

                Description

                + +

                TSUBJECTEND defines the markup that occurs to be included after +a subject based thread listing. This resource may have no +practical use, but is provided for completeness. +

                + + +
                +

                Default Setting

                + +

                Nil. +

  • + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    None. + + +


    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +TSUBJECTBEG +

    + + +
    +
    +97/05/13 17:30:31
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/tsublistbeg.html b/doc/resources/tsublistbeg.html new file mode 100644 index 0000000..c60d665 --- /dev/null +++ b/doc/resources/tsublistbeg.html @@ -0,0 +1,208 @@ + + + +MHonArc Resources: TSUBLISTBEG + + + +
    +MHonArc Resource List
    +
    + +
    +

    TSUBLISTBEG

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    N/A +

    +
    + +
    Element
    +

    +<TSUBLISTBEG>
    +markup ...
    +</TSUBLISTBEG>
    +

    +
    + +
    Command-line Option
    +

    N/A +

    +
    + +
    + + +
    +

    Description

    + +

    TSUBLISTBEG defines the markup for starting a sub-thread +listing. +

    + + +
    +

    Default Setting

    + +
    +<TSubListBeg>
    +<UL>
    +</TSubListBeg>
    +
    + + +
    +

    Resource Variables

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    VariableValue
    $DOCURL$URL to documentation.
    $FIRSTPG$Filename of first page of main index.
    $GMTDATE$Current GMT date.
    $IDXFNAME$Filename of main index page.
    $IDXLABEL$Label for main index page.
    $IDXPREFIX$Prefix of filenames of main index pages.
    $IDXSIZE$Max number of messages that may be listed in index page.
    $IDXTITLE$The title of the main index page.
    $LASTPG$Filename of last page in of main index.
    $LOCALDATE$Current local date.
    $NUMOFIDXMSG$Number of message listed.
    $NUMOFMSG$Number of messages in the archive.
    $NUMOFPAGES$Number of index pages.
    $OUTDIR$Pathname of archive.
    $PROG$Program name
    $TFIRSTPG$Filename of first page of thread index.
    $TIDXFNAME$Filename of thread index page.
    $TIDXLABEL$Label for thread index page.
    $TIDXPREFIX$Prefix of filenames of thread index pages.
    $TIDXTITLE$Title of thread index.
    $TLASTPG$Filename of last page of thread index.
    $TNEXTPG$Filename of next page of the thread index.
    $TNEXTPGLINK$Markup linking to the next page of the thread index.
    $TPREVPG$Filename of the previous page of the thread index.
    $TPREVPGLINK$Markup linking to the previous page of the thread index.
    $VERSION$Program version.
    + + +
    +

    Examples

    + +

    None. +

    + + +
    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +TSUBLISTEND, +TTOPBEGIN +

    + + +
    +
    +97/05/13 17:30:32
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/tsublistend.html b/doc/resources/tsublistend.html new file mode 100644 index 0000000..90e18ff --- /dev/null +++ b/doc/resources/tsublistend.html @@ -0,0 +1,97 @@ + + + +MHonArc Resources: TSUBLISTEND + + + +
    +MHonArc Resource List
    +
    + +
    +

    TSUBLISTEND

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    N/A +

    +
    + +
    Element
    +

    +<TSUBLISTEND>
    +markup ...
    +</TSUBLISTEND>
    +

    +
    + +
    Command-line Option
    +

    N/A +

    +
    + +
    + + +
    +

    Description

    + +

    TSUBLISTEND defines the markup for ending a sub-thread +listing. +

    + + +
    +

    Default Setting

    + +
    +<TSubListEnd>
    +</UL>
    +</TSubListEnd>
    +
    + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    None. +

    + + +
    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +TSUBLISTBEG, +

    + + +
    +
    +97/05/13 17:30:32
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/ttitle.html b/doc/resources/ttitle.html new file mode 100644 index 0000000..77bd950 --- /dev/null +++ b/doc/resources/ttitle.html @@ -0,0 +1,107 @@ + + + +MHonArc Resources: TTITLE + + + +
    +MHonArc Resource List
    +
    + +
    +

    TTITLE

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    +M2H_TTITLE=string +

    +
    + +
    Element
    +

    +<TTITLE>
    +string
    +</TTITLE>
    +

    +
    + +
    Command-line Option
    +

    +-ttitle string +

    +
    + +
    + + +
    +

    Description

    + +

    TTITLE defines the value of the $TIDXTITLE resource +variable. Unless doing custom page layout, the effect of setting +the TTITLE resource sets the title of the thread index. +

    + + +
    +

    Default Setting

    + +
    +Mail Thread Index
    +
    + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    It is common to set TTITLE to the name of the mailing list, or +newsgroup, being archived and that the index is a thread index. +For example: +

    + +
    +<TTitle>
    +MHonArc Mailing List (by thread)
    +</TTitle>
    +
    + + +
    +

    Version

    + +

    1.1 +

    + + +
    +

    See Also

    + +

    +TIDXPGBEGIN, +TITLE +

    + + +
    +
    +97/05/13 17:30:33
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/ttopbegin.html b/doc/resources/ttopbegin.html new file mode 100644 index 0000000..2bd9694 --- /dev/null +++ b/doc/resources/ttopbegin.html @@ -0,0 +1,250 @@ + + + +MHonArc Resources: TTOPBEGIN + + + +
    +MHonArc Resource List
    +
    + +
    +

    TTOPBEGIN

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    N/A +

    +
    + +
    Element
    +

    +<TTOPBEGIN>
    +markup ...
    +</TTOPBEGIN>
    +

    +
    + +
    Command-line Option
    +

    N/A +

    +
    + +
    + + +
    +

    Description

    + +

    TTOPBEGIN defines the markup for the root, or start, +of a thread. TTOPBEGIN should define any starting markup +for the thread and markup for the root message of the thread. +

    + + +
    +

    Default Setting

    + +
    +<TTopBegin>
    +<LI><STRONG>$SUBJECT$</STRONG>,
    +<EM>$FROMNAME$</EM>
    +</TTopBegin>
    +
    + + +
    +

    Resource Variables

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    VariableValue
    $A_ATTR$The NAME and HREF attributes to use in an anchor to link to the archived message. The NAME attribute links the messages to the index page.
    $A_HREF$The HREF attribute to use in an anchor to link to the archived message.
    $A_NAME$The NAME attribute to use in an anchor for messages to link to the index page.
    $DATE$The date of the message.
    $DDMMYY$Message date in dd/mm/yy format.
    $FROM$The complete text in the From: field of the message.
    $FROMADDR$The e-mail address in the From: field of the message.
    $FROMNAME$The human name of the person in the From: field of the message. If no human name is found, the username specified in the e-mail address is used.
    $ICON$The context-type sensistive icon.
    $ICONURL$The URL to the context-type sensistive icon.
    $MMDDYY$Message date in mm/dd/yy format.
    $MSGGMTDATE$GMT date of current message.
    $MSGID$The message-id of the message.
    $MSGLOCALDATE$Local date of current message.
    $MSGNUM$The message number assigned to the message by MHonArc (includes leading zeros).
    $NUMFOLUP$Number of explicit follow-ups to the message.
    $ORDNUM$The current listing number of the message.
    $SUBJECT$The subject text of the message wrapped in an anchor element that hyperlinks to the message.
    $SUBJECTNA$The subject text of the message without the anchor element.
    $YYMMDD$Message date in yy/mm/dd format.
    + + +
    +

    Examples

    + +

    MHonArc has several resources for customizing +thread page layout. Therefore the following shows a way to +customize the layout using the various thread resource +available. +

    + +

    For this example, +The thread index is setup where a thread will have the subject +in bold at the top of the thread and the names of the authors +of the messages in the thread will be hyperlinked to the +actual message. Nested unordered lists are used to provide a +visual cue of the depths of the thread. +Unique messages are show in normal text. +

    + +
    +<!--    TTOPBEGIN is the markup for the beginning of a thread, and the
    +        first message in a thread.
    +  -->
    +<TTOPBEGIN>
    +<p>
    +<li><a $A_NAME$><strong>$SUBJECTNA$</strong></a><br>
    +<a $A_HREF$>$FROMNAME$</a>
    +</TTOPBEGIN>
    + 
    +<!--    TTOPEND is the markup for closing a main thread.
    +  -->
    +<TTOPEND>
    +</li>
    +</p>
    +</TTOPEND>
    + 
    +<!--    TLITXT is the markup for a message *within* a thread
    +  -->
    +<TLITXT>
    +<li><a $A_ATTR$>$FROMNAME$</a>
    +</TLITXT>
    + 
    +<TLIEND>
    +</li>
    +</TLIEND>
    + 
    +<!--    TSINGLETXT is the markup for a message not in a thread.  I.e.
    +        it does not start a thread or is part of a thread.
    +  -->
    +<TSINGLETXT>
    +<li><a $A_NAME$>$SUBJECTNA$</a>,
    +<a $A_HREF$>$FROMNAME$</a>
    +</li>
    +</TSINGLETXT>
    + 
    +<!--    TSUBJECTBEG is any markup at the beginning of a sub-thread that
    +        is based on the subject of the message.  We just put in a
    +	comment declaration so the reader will see nothing.
    +  -->
    +<TSUBJECTBEG>
    +<!-- Possible follow-ups -->
    +</TSUBJECTBEG>
    +
    + +

    An item to note is how the example includes the proper resource +variables, $A_NAME$ and $A_ATTR$, to allow the +index hyperlinks in messages to behave properly. +

    + + +
    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +TLITXT, +TSINGLETXT, +TSUBJECTBEG, +TTOPEND +

    + + +
    +
    +97/05/13 17:30:33
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/ttopend.html b/doc/resources/ttopend.html new file mode 100644 index 0000000..a207447 --- /dev/null +++ b/doc/resources/ttopend.html @@ -0,0 +1,96 @@ + + + +MHonArc Resources: TTOPEND + + + +
    +MHonArc Resource List
    +
    + +
    +

    TTOPEND

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    N/A +

    +
    + +
    Element
    +

    +<TTOPEND>
    +markup ...
    +</TTOPEND>
    +

    +
    + +
    Command-line Option
    +

    N/A +

    +
    + +
    + + +
    +

    Description

    + +

    TTOPEND defines the markup for the end of a thread listing. +

    + + +
    +

    Default Setting

    + +
    +<TTopEnd>
    +</LI>
    +</TTopEnd>
    +
    + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    None. +

    + + +
    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +TTOPBEGIN +

    + + +
    +
    +97/05/13 17:30:34
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/umask.html b/doc/resources/umask.html new file mode 100644 index 0000000..1f56ef5 --- /dev/null +++ b/doc/resources/umask.html @@ -0,0 +1,103 @@ + + + +MHonArc Resources: UMASK + + + +
    +MHonArc Resource List
    +
    + +
    +

    UMASK

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    +M2H_UMASK=umask +

    +
    + +
    Element
    +

    +<UMASK>
    +umask
    +</UMASK>
    +

    +
    + +
    Command-line Option
    +

    +-umask umask +

    +
    + +
    + + +
    +

    Description

    + +

    The UMASK resource defines the umask value for the +MHonArc process. This resource is only valid +on Unix systems. Consult the umask(1) manpage for +more information. +

    + + +
    +

    Default Setting

    + +

    Value inherited from the parent process. +

    + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    If you want to make sure that the files created by +MHonArc are readable by others, do something like +the following: +

    + +
    +    % mhonarc -umask 022  ...
    +
    + + +
    +

    Version

    + +

    1.0 +

    + + +
    +

    See Also

    + +

    +

    + + +
    +
    +97/05/13 17:30:35
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/weekdays.html b/doc/resources/weekdays.html new file mode 100644 index 0000000..cef0201 --- /dev/null +++ b/doc/resources/weekdays.html @@ -0,0 +1,112 @@ + + + +MHonArc Resources: WEEKDAYS + + + +
    +MHonArc Resource List
    +
    + +
    +

    WEEKDAYS

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    +M2H_WEEKDAYS=day1:day2:...:day7 +

    +
    + +
    Element
    +

    +<WEEKDAYS>
    +day1:day2:...:day7
    +</WEEKDAYS>
    +

    +
    + +
    Command-line Option
    +

    +-weekdays day1:day2:...:day7 +

    +
    + +
    + + +
    +

    Description

    + +

    The WEEKDAYS resource defines the names for the days of the week. You +can set this resource to redefine weekday names to reflect +a particular locale for the +GMTDATEFMT and +LOCALDATEFMT +resources. When setting this resource, make sure to +define all 7 days. +

    + + +
    +

    Default Setting

    + +
    +Sunday:Monday:Tuesday:Wednesday:Thursday:Friday:Saturday
    +
    + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    None. +

    + + +
    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +GMTDATEFMT, +LOCALDATEFMT, +MONTHS, +MONTHSABR, +WEEKDAYSABR +

    + + +
    +
    +97/05/13 17:30:35
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/resources/weekdaysabr.html b/doc/resources/weekdaysabr.html new file mode 100644 index 0000000..5188652 --- /dev/null +++ b/doc/resources/weekdaysabr.html @@ -0,0 +1,113 @@ + + + +MHonArc Resources: WEEKDAYSABR + + + +
    +MHonArc Resource List
    +
    + +
    +

    WEEKDAYSABR

    + + +
    +

    Syntax

    + +
    + +
    Envariable
    +

    +M2H_WEEKDAYSABR=day1:day2:...:day7 +

    +
    + +
    Element
    +

    +<WEEKDAYSABR>
    +day1:day2:...:day7
    +</WEEKDAYSABR>
    +

    +
    + +
    Command-line Option
    +

    +-weekdaysabr day1:day2:...:day7 +

    +
    + +
    + + +
    +

    Description

    + +

    The WEEKDAYSABR resource defines the abbreviated +names for the days of the week. You +can set this resource to redefine abbreviated weekday names to reflect +a particular locale for the +GMTDATEFMT and +LOCALDATEFMT +resources. When setting this resource, make sure to +define all 7 days. +

    + + +
    +

    Default Setting

    + +
    +Sun:Mon:Tue:Wed:Thu:Fri:Sat
    +
    + + +
    +

    Resource Variables

    + +

    N/A

    + + +
    +

    Examples

    + +

    None. +

    + + +
    +

    Version

    + +

    2.0 +

    + + +
    +

    See Also

    + +

    +GMTDATEFMT, +LOCALDATEFMT, +MONTHS, +MONTHSABR, +WEEKDAYS +

    + + +
    +
    +97/05/13 17:30:36
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/doc/thread.html b/doc/thread.html deleted file mode 100644 index b1b92b4..0000000 --- a/doc/thread.html +++ /dev/null @@ -1,225 +0,0 @@ - - - -MHonArc v1.2.2 -- Thread Index Customization - - -[Previous][Next][Contents][FAQ][Bugs][Home] -
    - -

    Thread Index Customization -

    - -

    The thread index compliments the main index. If a thread index is created, each -message in the archive will contain an extra link to the thread index. -

    -

    Customizing the thread index is very similiar to customizing the main index. -

    -
    -

    Filename -

    - -

    By default, the filename of the index page is "threads.html". However, a -different name may be specified with the M2H_TIDXFNAME environment variable, -the TIDXFNAME resource element, or the -tidxfname command-line option. -

    -
    -

    Beginning Markup -

    - -

    MHonArc allows you to completely override the begining markup of the thread -index page. I.e. You can control the opening <HTML> tag, the HEAD element -contents, the opening <BODY> tag, etc. Therefore, if you are not satisfied with the -default behavior of how the TTITLE resource is used, or have other needs that -require control on the beginning markup, you can set the TIDXPGBEGIN resource -file element. -

    -

    TIDXPGBEGIN -

    - -

    The best way to show how the TIDXPGBEGIN works, the following represents the -default setting MHonArc uses: -

    -
    <TIDXPGBEGIN>
    -<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
    -<HTML>
    -<HEAD>
    -<TITLE>$TIDXTITLE$</TITLE>
    -</HEAD>
    -<BODY>
    -<H1>$TIDXTITLE$</H1>
    -</TIDXPGBEGIN>
    -
    -
    - -
    -
    NOTE - -

    Technically, setting the TTITLE resource, via the M2H_TTITLE -environment variable, the TTITLE resource file element, or the -ttitle -command-line option, sets the $TIDXTITLE$ resource file variable. -

    -

    The resource variables allowed in the TIDXPGBEGIN element are the following: -

    -
      -
    • $DOCURL$ -- URL to documentation -
    • $GMTDATE$ -- Current GMT date. -
    • $IDXFNAME$ -- Filename of main index page. -
    • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
    • $IDXTITLE$ -- The title of the index page. -
    • $LOCALDATE$ -- Current local date. -
    • $NUMOFIDXMSG$ -- Number of message listed. -
    • $NUMOFMSG$ -- Number of messages in the archive. -
    • $OUTDIR$ -- Pathname of archive. -
    • $PROG$ -- Program name. -
    • $TIDXFNAME$ -- Filename of thread index page. -
    • $TIDXTITLE$ -- Title of thread index page. -
    • $VERSION$ -- Program version. -
    -

    See Resource Variables for more information on the usage of variables. -

    -
    -

    End Markup -

    - -

    Along with controlling the beginning markup, you can control the ending markup. -

    -

    TIDXPGEND -

    - -

    The TIDXPGEND resource element may be used to define the ending markup of the -index page. The default value is the following: -

    -
    <TIDXPGEND>
    -</BODY>
    -</HTML>
    -</TIDXPGEND>
    -
    -
    - -

    The resource variables allowed are the same as for TIDXPGBEGIN. -

    -
    -

    Listing Layout -

    - -

    By default, MHonArc lists the threads in chronological order. The thread with the -oldest initital messsage is listed first, and the thread with the newest initital -message is listed last. The TREVERSE resource may be set to have the thread listing -from newest thread to oldest thread. If the TSUBSORT resource is set, then threads -are sorted by subject. -

    -

    HTML markup can be added to the thread index page by defining the THEAD and -TFOOT resource file elements. Usage of THEAD and TFOOT is discussed later in this -section. -

    -

    MHonArc uses HTML unorder lists for formatting the thread index list. Nested list -markup is used to show the threads. Since threads can become very large, the -TLEVELS resource can be used to limit the number of nested lists allowed. The -default nesting level is 3. -

    -

    Customization over the thread index list format is more restrictive than the main -index. All thread index entries are contained in the HTML LI element, which is -contained in an UL element. The entry text itself can be customized via the TLITXT -resource file element. Usage of TLITXT is discussed later in this section. -

    -

    THEAD -

    - -

    The THEAD resource element specifies text to be inserted before the thread index -listing. The text can be any valid HTML markup. Plus, MHonArc defines the -following variables you may use which get expanded at run-time: -

    -
      -
    • $DOCURL$ -- URL to documentation -
    • $GMTDATE$ -- Current GMT date. -
    • $IDXFNAME$ -- Filename of main index page. -
    • $IDXSIZE$ -- Max number of messages that may be listed in the index. -
    • $IDXTITLE$ -- The title of the index page. -
    • $LOCALDATE$ -- Current local date. -
    • $NUMOFIDXMSG$ -- Number of message listed. -
    • $NUMOFMSG$ -- Number of messages in the archive. -
    • $OUTDIR$ -- Pathname of archive. -
    • $PROG$ -- Program name. -
    • $TIDXFNAME$ -- Filename of thread index page. -
    • $TIDXTITLE$ -- Title of thread index page. -
    • $VERSION$ -- Program version. -
    -

    MHonArc's THEAD default value is the following: -

    -
    <THEAD>
    -<UL>
    -<LI><A HREF="$IDXFNAME$">Main Index</A></LI>
    -</UL>
    -<HR>
    -</THEAD>
    -
    -
    - -

    TLITXT -

    - -

    The TLITXT specifies the markup to use for each entry in the thread index. Only -markup that is legal within the HTML LI element should be used. When you -define the contents for the TLITXT resource element, you may use the following -variables defined by MHonArc (see Resource Variables on the usage of variables): -

    -
      -
    • $A_ATTR$ -- The NAME and HREF attributes to use in an anchor to link to -the archived message. The NAME attribute links the messages to the index -page. -
    • $A_HREF$ -- The HREF attribute to use in an anchor to link to the archived -message. -
    • $A_NAME$ -- The NAME attributes to use in an anchor for messages to link -to the index page. -
    • $DATE$ -- The date of the message. -
    • $DDMMYY$ -- Message date in dd/mm/yy format. -
    • $ICON$ -- The context-type sensistive icon. See Icons for information. -
    • $ICONURL$ -- The URL to the context-type sensistive icon. See Icons for -information. -
    • $MMDDYY$ -- Message date in mm/dd/yy format. -
    • $NUMFOLUP$ -- Number of follow-ups for the given message. -
    • $FROM$ -- The complete text in the From: field of the message. -
    • $FROMADDR$ -- The e-mail address in the From: field of the message. -
    • $FROMNAME$ -- The English name of the person in the From: field of the -message. If no English name is found, the username specified in the e-mail -address is used. -
    • $MSGNUM$ -- The message numbers assigned to the message by MHonArc. -
    • $ORDNUM$ -- The current listing number of the message. -
    • $SUBJECT$ -- The subject text of the message wrapped in an anchor -element that hyperlinks to the message. -
    • $SUBJECTNA$ -- The subject text of the message without the anchor -element. -
    • $YYMMDD$ -- Message date in yy/mm/dd format. -
    -

    -

    -
    -
    NOTE - -

    Do not specify $A_ATTR$, $A_NAME, and $SUBJECT$ together in the -LITEMPLATE element. Since all of these variables contain the NAME -atrribute. Invalid HTML will be created since multiple anchors will have -the same NAME identifier. -

    -

    TLITXT's default value is the following: -

    -
    <TLITXT>
    -($NUMFOLUP$) <STRONG>$SUBJECT:40$</STRONG>, <EM>$FROMNAME$</EM>
    -</TLITXT>
    -
    - -

    TFOOT -

    - -

    The TFOOT resource element specifies the text to use after the end the thread index -list. The text can be any valid HTML markup. TFOOT may contain the same -variables as THEAD. -

    -

    TFOOT's default value is nil. -

    - -
    -[Previous][Next][Contents][FAQ][Bugs][Home] - - diff --git a/examples/deffilters.rc b/examples/deffilters.rc deleted file mode 100644 index 3b0d8b4..0000000 --- a/examples/deffilters.rc +++ /dev/null @@ -1,73 +0,0 @@ - - - -application/mac-binhex40:m2h_external'filter:mhexternal.pl -application/octet-stream:m2h_external'filter:mhexternal.pl -application/oda:m2h_external'filter:mhexternal.pl -application/pdf:m2h_external'filter:mhexternal.pl -application/postscript:m2h_external'filter:mhexternal.pl -application/rtf:m2h_external'filter:mhexternal.pl -application/x-bcpio:m2h_external'filter:mhexternal.pl -application/x-cpio:m2h_external'filter:mhexternal.pl -application/x-csh:m2h_external'filter:mhexternal.pl -application/x-dvi:m2h_external'filter:mhexternal.pl -application/x-gtar:m2h_external'filter:mhexternal.pl -application/x-hdf:m2h_external'filter:mhexternal.pl -application/x-latex:m2h_external'filter:mhexternal.pl -application/x-mif:m2h_external'filter:mhexternal.pl -application/x-netcdf:m2h_external'filter:mhexternal.pl -application/x-patch:m2h_text_plain'filter:mhtxtplain.pl -application/x-sh:m2h_external'filter:mhexternal.pl -application/x-shar:m2h_external'filter:mhexternal.pl -application/x-sv4cpio:m2h_external'filter:mhexternal.pl -application/x-sv4crc:m2h_external'filter:mhexternal.pl -application/x-tar:m2h_external'filter:mhexternal.pl -application/x-tcl:m2h_external'filter:mhexternal.pl -application/x-tex:m2h_external'filter:mhexternal.pl -application/x-texinfo:m2h_external'filter:mhexternal.pl -application/x-troff-man:m2h_external'filter:mhexternal.pl -application/x-troff-me:m2h_external'filter:mhexternal.pl -application/x-troff-ms:m2h_external'filter:mhexternal.pl -application/x-troff:m2h_external'filter:mhexternal.pl -application/x-ustar:m2h_external'filter:mhexternal.pl -application/x-wais-source:m2h_external'filter:mhexternal.pl -application/zip:m2h_external'filter:mhexternal.pl -audio/basic:m2h_external'filter:mhexternal.pl -audio/x-aiff:m2h_external'filter:mhexternal.pl -audio/x-wav:m2h_external'filter:mhexternal.pl -image/gif:m2h_external'filter:mhexternal.pl -image/ief:m2h_external'filter:mhexternal.pl -image/jpeg:m2h_external'filter:mhexternal.pl -image/tiff:m2h_external'filter:mhexternal.pl -image/x-cmu-raster:m2h_external'filter:mhexternal.pl -image/x-pbm:m2h_external'filter:mhexternal.pl -image/x-pgm:m2h_external'filter:mhexternal.pl -image/x-pict:m2h_external'filter:mhexternal.pl -image/x-pnm:m2h_external'filter:mhexternal.pl -image/x-portable-anymap:m2h_external'filter:mhexternal.pl -image/x-portable-bitmap:m2h_external'filter:mhexternal.pl -image/x-portable-graymap:m2h_external'filter:mhexternal.pl -image/x-portable-pixmap:m2h_external'filter:mhexternal.pl -image/x-ppm:m2h_external'filter:mhexternal.pl -image/x-rgb:m2h_external'filter:mhexternal.pl -image/x-xbitmap:m2h_external'filter:mhexternal.pl -image/x-xbm:m2h_external'filter:mhexternal.pl -image/x-xpixmap:m2h_external'filter:mhexternal.pl -image/x-xpm:m2h_external'filter:mhexternal.pl -image/x-xwd:m2h_external'filter:mhexternal.pl -image/x-xwindowdump:m2h_external'filter:mhexternal.pl -message/partial:m2h_text_plain'filter:mhtxtplain.pl -text/html:m2h_text_html'filter:mhtxthtml.pl -text/plain:m2h_text_plain'filter:mhtxtplain.pl -text/richtext:m2h_text_plain'filter:mhtxtplain.pl -text/setext:m2h_text_setext'filter:mhtxtsetext.pl -text/tab-separated-values:m2h_text_plain'filter:mhtxtplain.pl -text/x-html:m2h_text_html'filter:mhtxthtml.pl -text/x-setext:m2h_text_setext'filter:mhtxtsetext.pl -video/mpeg:m2h_external'filter:mhexternal.pl -video/quicktime:m2h_external'filter:mhexternal.pl -video/x-msvideo:m2h_external'filter:mhexternal.pl -video/x-sgi-movie:m2h_external'filter:mhexternal.pl - diff --git a/examples/frames.rc b/examples/frames.rc new file mode 100644 index 0000000..6112958 --- /dev/null +++ b/examples/frames.rc @@ -0,0 +1,577 @@ + + + + + + + + + + + + +FRAME-MAIN +target="MAIN" + + + +FRAME-IDX +target="INDEX" + + + + +NAV-LINKS + + + + + + + + + + + + + + + +
    Thread LinksDate Links
    $TPREVBUTTON$$TNEXTBUTTON$Index$PREVBUTTON$$NEXTBUTTON$Index
    +
    + + + +IDXPG-TBL-LINKS-ATTRS +width="100%" border=0 cellpadding=0 cellspacing=0 + + + + + + + +
    + + + + + + + + +25 + + + + + + + + + + + + + +frm$MSGNUM$.html + + +Message View + + + + + + + + + + +nav$MSGNUM$.html + + +Message Navigation + + +$NAV-LINKS$ + + + + + + + + + + + + +$MAIN-TITLE$ (thread) + + + + +>> + + +>> + + + +<< + + +<< + + + + + +
    + + + + + +
    Page $PAGENUM$ of $NUMOFPAGES$ +
    <<<< +$TPREVPGLINK$ +$TNEXTPGLINK$ +>>>> +
    +
    +
      + + + + +
    +
    + + + + + +
    <<<< +$TPREVPGLINK$ +$TNEXTPGLINK$ +>>>> +
    Page $PAGENUM$ of $NUMOFPAGES$ +
    + + + + + +

    +

  • $SUBJECTNA$
    +$FROMNAME$ + + + + +
  • +

    + + + + + +
  • $FROMNAME$ + + + +
  • + + + + +
  • $SUBJECTNA$, +$FROMNAME$ +
  • +
    + + + +Possible follow-ups + + + + +
  • $SUBJECTNA$, (continued) + + + + +
  • + + + + +
      + + + + +
    + + + + + + + + +$MAIN-TITLE$ (date) + + + + +>> + + +>> + + + + +<< + + +<< + + + + + + + + + + +
    Page $PAGENUM$ of $NUMOFPAGES$ +
    <<<< +$PREVPGLINK$ +$NEXTPGLINK$ +>>>> +
    +
    +
      + + + + +
    +
    + + + + + +
    <<<< +$PREVPGLINK$ +$NEXTPGLINK$ +>>>> +
    Page $PAGENUM$ of $NUMOFPAGES$ +
    + + + + +
  • $SUBJECTNA$ +
    • $FROMNAME$
    +
  • +
    + + + + + + + +

    $SUBJECTNA$

    +
    +
    + + + + + +subject +xref + + + + +-default-:strong + + + + +-default-: + + + + + + + + + + + + + + + + + + + + + + + +
    + + + + + + + + + +
    + + + + +
    +
    + + + + + + + + + + + + + + + +Next + + + +Next + + + +Prev + + + +Prev + + + +Next + + + +Next + + + +Prev + + + +Prev + + + + + + + + +text/plain:quote maxwidth=78 + + + + + +iso-8859-1:-decode- + diff --git a/examples/icons.rc b/examples/icons.rc index 2be0034..c972909 100644 --- a/examples/icons.rc +++ b/examples/icons.rc @@ -1,10 +1,15 @@ +
    + + diff --git a/examples/mhonarc.rc b/examples/mhonarc.rc deleted file mode 100644 index 86463ad..0000000 --- a/examples/mhonarc.rc +++ /dev/null @@ -1,96 +0,0 @@ - - - -Example MIME mail messages converted by MHonArc - - - - -
    -Last update: $LOCALDATE$
    -$NUMOFMSG$ messages in chronological order
    -
    -

    -Listing format is the following: -

    -* -Subject -(# of follow-ups) -From
    -

    -


    -
    - - - -* -$SUBJECT:40$ -($NUMFOLUP$) $FROMNAME$
    -
    - - - -

    -


    -Back to Earl Hood's Home Page -

    - - - -apparently -errors-to -followup -forward -lines -message-id -mime- -nntp- -originator -path -precedence -received -replied -return-path -status -via -x- - - - --default- -subject:strong -from:strong -to:strong - - - --default- -subject:strong -from:strong -to:strong -keywords:em -newsgroups:strong - - - -application/octet-stream:http://www.oac.uci.edu/indiv/ehood/icons/binary.xbm -application/postscript:http://www.oac.uci.edu/indiv/ehood/icons/postscript.xbm -audio/basic:http://www.oac.uci.edu/indiv/ehood/icons/sound.xbm -image/gif:http://www.oac.uci.edu/indiv/ehood/icons/image.xbm -image/jpeg:http://www.oac.uci.edu/indiv/ehood/icons/image.xbm -image/tiff:http://www.oac.uci.edu/indiv/ehood/icons/image.xbm -multipart/alternative:http://www.oac.uci.edu/indiv/ehood/icons/alternative.xbm -multipart/digest:http://www.oac.uci.edu/indiv/ehood/icons/text.xbm -multipart/mixed:http://www.oac.uci.edu/indiv/ehood/icons/mixed.xbm -multipart/parallel:http://www.oac.uci.edu/indiv/ehood/icons/mixed.xbm -text/richtext:http://www.oac.uci.edu/indiv/ehood/icons/mixed.xbm -text/html:http://www.oac.uci.edu/indiv/ehood/icons/mixed.xbm -text/plain:http://www.oac.uci.edu/indiv/ehood/icons/text.xbm -unknown:http://www.oac.uci.edu/indiv/ehood/icons/unknown.doc.xbm -video/mpeg:http://www.oac.uci.edu/indiv/ehood/icons/movie.xbm -video/quicktime:http://www.oac.uci.edu/indiv/ehood/icons/movie.xbm - - diff --git a/faq/about.html b/faq/about.html new file mode 100644 index 0000000..f5b3182 --- /dev/null +++ b/faq/about.html @@ -0,0 +1,72 @@ + + + +MHonArc FAQ: About the FAQ + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    About the FAQ

    + +

    Summary

    + +

    This documents contains answers to some of the frequently +asked question on MHonArc. MHonArc is +a Perl program +for converting e-mail messages as specified in RFC 822 and MIME to HTML. +MHonArc has the ability to maintain an archive of converted +messages, or it can be used as a basic e-mail->HTML converter.

    + +

    The FAQ is intended to compliment the documentation provided in +the MHonArc distribution. The documentation is still +the key source to answers to any question you may have. +While reading this FAQ, it may be beneficial to have the +documentation easily accessible. +

    + +

    Version

    + +

    Since the FAQ has multiple pages, the date that each page is +updated is at the bottom of each page. +

    + +

    Location

    + +

    (http://www.oac.uci.edu/indiv/ehood/MHonArc/faq/faq.html) +

    + +

    Author

    + +

    Earl Hood, ehood@medusa.acs.uci.edu

    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:05
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/archives.html b/faq/archives.html new file mode 100644 index 0000000..676ecf4 --- /dev/null +++ b/faq/archives.html @@ -0,0 +1,480 @@ + + + +MHonArc FAQ: Archives + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    Archives

    + + +

    Why does a message get split into mulitple messages with no headers?

    + +

    If you are processing UUCP mailbox files, messages are +separated by a line starting with "From " (ie. The +word "From" followed by a space). Some mail software +will prefix lines in message bodies with a `>' +to avoid MUA's from incorrectly treating the line as a message +separator. However, some mail software doesn't.

    + +

    To avoid incorrect separator detection, many MUAs perform +a more stricter detection of separators beyond "From ". +MHonArc, by default, will treat lines starting +with "From " as a message separator, which can lead to +incorrect message termination if the From line has not been escaped +with a `>'.

    + +

    To fix the problem, use the MSGSEP resource to +instruct MHonArc to use a stricter test detecting a message +separator. The following MSGSEP resource setting is +known to work well:

    + +
    +<MsgSep>
    +^From \S+\s+\S+\s+\S+\s+\d+\s+\d+:\d+:\d+\s+\d+
    +</MsgSep>
    +
    + +

    If this fails, you can try the CONLEN +resource available in v2.0. The CONLEN resource, when set, tells +MHonArc to utilize the Content-Length fields +in the message head. If your MTA defines this field accurately +(sendmail on Solaris does), then you can utilize this +feature.

    + + +

    Can I move a message from one archive to another?

    + +

    No. In order to achieve the same effect, you must add the original, +unprocessed, message to the destination archive, then remove the +appropriate HTML version of the message from the source archive.

    + + +

    Can I reconstruct a database from the HTML messages?

    + +

    Yes. The following was contributed by +Stephane Bortzmeyer: +

    + +
    +
      +
    • Subject: Improvment to MHonArc FAQ
    • +
    • From: bortzmeyer@internatif.org (Stephane Bortzmeyer)
    • +
    • Date: Sun, 13 Apr 1997 15:29:31 +0200
    • +
    +
    +... some text deleted ...
    +
    +Having rmed my database :-( I had to write such a program. I include it at the end,
    +it seems quite simple, while necessiting a few text edition after (you just have to
    +include the output of my program in an empty database).
    +
    +
    +#!/usr/local/bin/perl
    +
    +require 'timelocal.pl';
    +require '/web/mail/MHonArc/lib/mhutil.pl';
    +require '/web/mail/MHonArc/lib/mhtime.pl';
    +
    +$dir = shift (@ARGV);
    +
    +opendir (DIR, "$dir") || die "Cannot open $dir: $!";
    +while ($file = readdir (DIR)) {
    +    if ($file =~ /^msg([0-9]+)\.html$/) {
    +        $no = $1;
    +        open (FILE, "< $dir/$file") || die "Cannot open $file: $!";
    +        while (<FILE>) {
    +            chop;
    +            if (/^<!--X-([^:]*): (.*)-->$/) {
    +                $headers{$1} = $2;
    +                $headers{$1} =~ s/ *$//;
    +            }
    +        }
    +        close (FILE);
    +        @date = &parse_date ($headers{'Date'});
    +        $date = &get_time_from_date ($date[1], $date[2], $date[3], $date[4], $date[5], $date[6]);
    +        $id = "$date $no";
    +        print STDERR "Message $id:\n";
    +        foreach $header (keys (%headers)) {
    +            print STDERR "$header: $headers{$header}\n";
    +            $name = $header;
    +            $name =~ s/-//;
    +            $$name{$id} = $headers{$header};
    +        }
    +    } 
    +}
    +closedir (DIR);
    +print "%ContentType = (\n";
    +foreach $key (keys (%ContentType)) {
    +    print "\'$key\', \'$ContentType{$key}\',\n";
    +}
    +print ");\n";
    +print "%Date = (\n";
    +foreach $key (keys (%Date)) {
    +    print "\'$key\', \'$Date{$key}\',\n";
    +}
    +print ");\n";
    +print "%From = (\n";
    +foreach $key (keys (%From)) {
    +    print "\'$key\', \'$From{$key}\',\n";
    +}
    +print ");\n";
    +print "%MsgId = (\n";
    +foreach $key (keys (%MessageId)) {
    +    print "\'$key\', \'$MessageId{$key}\',\n";
    +}
    +print ");\n";
    +print "%Subject = (\n";
    +foreach $key (keys (%Subject)) {
    +    print "\'$key\', \'$Subject{$key}\',\n";
    +}
    +print ");\n";
    +print "%IndexNum = (\n";
    +foreach $key (keys (%MessageId)) {
    +    ($garbage, $num) = split (' ', $key);
    +    print "\'$key\', \'$num\',\n";
    +}
    +print ");\n";
    +
    +
    + + + +

    Is it safe to add messages to an archive as they are received?

    + +

    Yes. MHonArc performs archive locking to protect from +multiple MHonArc process attempting to write to an archive +at the same time. This locking allows MHonArc to safely +be used to add messages as they are received. +

    + + +

    So it is safe. How do I do it??

    + +

    The following example assumes you are using on a Unix system +using sendmail as the mail transfer agent. +Please refer to documentation about sendmail if you +are not familiar with it +(sendmail, 2ed, from O'Reilly is an excellent source). +

    + +

    The approach shown here uses a +.forward file in the home directory of the +account you want mailed archived. For this example, let's +assume it is my account. +Here is how to set up the .forward file +to invoke MHonArc on incoming mail:

    + +
    +\ehood, "|/home/ehood/bin/webnewmail #ehood"
    +
    + +
    +
    NOTE on .forward entry: +

    The "\ehood" tells sendmail +to still deposit the incoming message to my mail spool file. The +"#ehood" Bourne shell comment is needed to insure the +command is unique from another user. Otherwise, sendmail +may not invoke the program for you or the other user. +

    + +

    webnewmail is a Perl program that calls +MHonArc with the appropriate arguments. A wrapper program +is used instead of calling MHonArc directly to keep +the .forward file simple, but you can call MHonArc +directly if you want. Here is the code to the +webnewmail program:

    + +
    +#!/usr/local/bin/perl
    +# Edit above path to point to where perl is on your system.
    +
    +##	Specify a package to protect names from MHonArc.
    +##	MHonArc uses package main for most stuff; a minor
    +##	inconvenience.
    +
    +package webnewmail;
    +
    +##	Edit to point to installed mhonarc.
    +
    +$MHonArc = "/home/ehood/bin/mhonarc";
    +
    +##	Define ARGV (ARGV is same across all packages).
    +##	Edit options as required/desired.
    +
    +@ARGV = ("-add",
    +	 "-quiet",
    +	 "-outdir", "/home/ehood/public_html/newmail");
    +
    +##	Just require mhonarc, this prevents the overhead of a
    +##	fork/exec.  We reset the namespace to main just in-case.
    +
    +package main;
    +require $webnewmail'MHonArc;
    +	# Or, $webnewmail::MHonArc (Perl 5 style)
    +
    +
    + +

    The webnewmail program has to have the executable +bit set. This is achieved by using "chmod a+x webnewmail". +

    + + +

    Can I get MHonArc to filter messages to different archives?

    + +

    No. This is outside of the MHonArc's scope. You can grow your +own filter, using the method described in the previous question, to +scan the message header an invoke MHonArc with the proper arguments. +Or. you can use a tool like Procmail +(http://www.ii.com/internet/robots/procmail/). +Here are a some messages from users about using Procmail: +

    + +
    + +
    +... some text deleted ...
    +
    +Here is what I use in .procmailrc to archive the mhonarc list:
    +
    +NEWDATE="`/usr/bin/date +%Y-%m`"
    +MHONARC_MBOX="/local/mail/lists/mhonarc/$NEWDATE.mbox"
    +:0: $MHONARC_MBOX$LOCKEXT
    +* ^Sender:.*owner-mhonarc@
    +{
    +        :0 c
    +        $MHONARC_MBOX
    +
    +        :0 c
    +        | /local/mail/mhonarc-1.2.2/mailarchive -add mhonarc "$NEWDATE"
    +}
    +
    +Mailarchive is nothing more than a wrapper around mhonarc with my long.
    +list of options.
    +
    +Achim
    +P.S. Procmail itself comes with an example manual page. It's worth
    +     looking into it.
    +
    +
    +
    + +
    + +
    +You can actually dispense with the wrapper if you use environment
    +variables to pass options to MHonArc, but I'm sure Achim has a good
    +reason for doing it his way.  Just for the purposes of comparion,
    +here's how I do it:
    +
    +eeeweb% cat .procmailrc
    +#Set on when debugging
    +VERBOSE=off
    +#Replace `mail' with your mail directory (Pine uses mail, Elm uses Mail)
    +MAILDIR=$HOME/Mail
    +#Directory for storing procmail log and rc files
    +PMDIR=$HOME/.procmail
    +#Path and options for mhonarc
    +MHONARC='/dcs/packages/infosys/bin/mhonarc -add -quiet -umask 022 -idxfname inde
    +x.html'
    +:0
    +* ^Originator:.*@classes.uci.edu
    +{
    +  MHHOME=$HOME/classarc
    +  LOGFILE=$PMDIR/classlists.log
    +  INCLUDERC=$PMDIR/rc.classlists
    +}
    +:0 E
    +{
    +  MHHOME=$HOME/mail-arc
    +  LOGFILE=$PMDIR/otherlists.log
    +  INCLUDERC=$PMDIR/rc.otherlists
    +}
    +
    +and then in the file .procmail/rc.classlists or rc.otherlists (depending
    +on the Originator: of the message), lots of the following:
    +
    +# Procmail Entry for uci-www
    +:0 E
    +* ^TOuci-www
    +{
    +  :0 c
    +  uci-www/.
    +
    +  :0
    +  |$MHONARC -rcfile $MHHOME/uci-www/0-rcfile.html -outdir $MHHOME/uci-www
    +}
    +
    +Eric D. Friedman
    +friedman@uci.edu
    +
    +
    + +
    + +
    +... some text deleted ...
    +
    +I use procmail to drive mhonarc archives from Majordomo.  I set up a
    +single pseudouser and drive several archives from the one pseudouser. 
    +
    +Here's a sample .forward file:
    +
    +"|/usr/ucb/rsh cappuccino \"set IFS=' '; exec
    +/usr/local/procmail/bin/procmail #widget\""
    +
    +Another example is:
    +
    +"|/bin/csh -c \"set IFS=' '; exec /usr/local/procmail/bin/procmail
    +#widget\""
    +
    +Two reasons to use the "rsh cappuccino":
    +1. doesn't require the user to be able to login to server, although
    +   the username must still be valid
    +2. gets the processing load off the mail server
    +
    +Here's an example .procmail recipe:
    +
    +LOGFILE=$HOME/procmail_errors
    +LOGABSTRACT=all
    +LOCKEXT=.lock
    +VERBOSE=on
    +UMASK=003
    +
    +# widget: list short description
    +:0 H
    +* ^List-Name: widget
    +{
    +  # The rotate call (under construction) does archive rotation
    +  # leave commented!
    +  #:0c i
    +  #| /home/web-arch/bin/rotate /usr/local/web/webarchive/widget
    +
    +  # Put the mail in the mailbox, which is used by archiver to re-generate
    +  # the html indexes
    +  :0 cA
    +  /usr/local/web/webarchive/widget/current/mbox
    +
    +  # The mhonarc call examines mbox, turns the mail messages into .html
    +  # documents, and compiles the indexes.
    +  # -reverse -treverse\
    +  :0 ia
    +  | /usr/local/mhonarc/bin/mhonarc \
    +    -idxfname index.shtml \
    +    -tidxfname threads.shtml \
    +    -rcfile widget.rc\
    +    -outdir /usr/local/web/webarchive/widget/current \
    +    /usr/local/web/webarchive/widget/current/mbox
    +
    +}
    +
    +I have a directory per archive, and put the current period in directory
    +"current".  Then I have an index page per archive that indexes the
    +periods, plus gives information about the list and how to
    +subscribe/unsubscribe.  The widget.rc file resides in the pseudouser's
    +home directory.
    +
    +Note the 
    +* ^List-Name: widget
    +I put the following in the majordomo list's config file:
    +
    +message_headers   <<  END
    +List-Name: widget
    +END
    +
    +This adds the "List-Name" header to messages, which is what procmail
    +filters for.
    +
    +Hope this helps
    +
    +Paul McKinley
    +Unix SysAdmin Contractor
    +
    +
    + + +

    Is it safe to specify -add when no archive exists?

    + +

    Yes. If MHonArc sees no archive exists when perform +an add, it will automatically create the archive. +

    + +
    +
    WARNING
    +

    Make sure the file maillist.html (or the value +of the IDXFNAME resource) does not exist if no archive exists and +-add has been specified. Otherwise, unpredictable output +of the maillist.html file may result if maillist.html +is not in the proper format. +

    +
    +
    + + +

    Why are there "jumps" in message numbers?

    + +

    Big gaps in the message number sequence may occur if you +defined the MAXSIZE resource and you have +MHonArc rescanning a mail folder for adding new messages. +The problem occurs when MHonArc +reads in messages that will automatically get deleted due +to MAXSIZE. Ie. Messages subject to automatic deletion are +the oldest ones. If the input contains old messages that will +get deleted at the end of processing, the old messages will +still use up message numbers since messages to be deleted are not +determined until all input is read. Since MHonArc does +not keep information about deleted messages, if the messages are +fed into MHonArc again, the "jumping" will occur +again (and the jump will get larger for each additional update). +

    + +

    To avoid the problem, try to pass only new, never processed, +messages to MHonArc instead of having MHonArc +rescanning the same mail folder for new messages. Another +approach is to set either the EXPIREAGE or +EXPIREDATE resources (available in v2.0 beta 2, +or later). These work as an alternative to MAXSIZE and will help in +preventing message number jumping since expiration of a message is +checked when it is initially read (bypassing the assignment of +a message number).

    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/20 12:42:04
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + + diff --git a/faq/envs.html b/faq/envs.html new file mode 100644 index 0000000..4dc937d --- /dev/null +++ b/faq/envs.html @@ -0,0 +1,184 @@ + + + +MHonArc FAQ: Supported Environments + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    Supported Environments

    + + +

    What platforms can MHonArc run under?

    + +

    MHonArc is known to run under many varieties of Unix, +MS-DOS/Windows, WinNT, Win95, OS/2. +

    + + +

    What about Mac?

    + +

    MHonArc has been coded to support MacPerl, but no +adequate testing has been done to verify the code. +Please notify the author if you are interested in +testing MHonArc under MacPerl. +

    + + +

    What version of Perl is required to run MHonArc?

    + +

    MHonArc can run under Perl 4 or 5. Perl 5 is recommended +for performance reasons and for the possibility that future releases +of MHonArc will use Perl 5 features.

    + +
    +
    NOTE
    +

    Current plans are for MHonArc v3 +to be the Perl 5 rewrite of MHonArc v2.x. v2.x will +probably be the last major version to run under Perl 4. +

    +
    +
    + + +

    What mail user agents (MUA's) does MHonarc support?

    + +

    MHonArc can convert mail that is stored in UUCP mailbox +format (ie. all messages are in a single file), or in the format used +by the +Rand Message Handler +(MH) (messages are contained in separate +files within a directory). MHonArc is known to work with +the following MUAs: MH, mail, Mail, +Elm, Eudora, WinVN, Windows +Trumpet, and NUPop.

    + +
    +
    NOTE + +

    To support some MUA's, it may require redefining the +MSGSEP or MHPATTERN resource. Please consult the documentation +for more information about these resources.

    +
    + + +

    Can MHonArc process Compuserve messages?

    + +

    Here is a response from a user: +

    +
    +
      +
    • Subject: Re: CompuServe --> html
    • +
    • From: Steve Pacenka <sp17@cornell.edu>
    • +
    • Date: Thu, 06 Mar 1997 09:09:00 -0500
    • +
    +
    +At 11:38 AM 3/6/97 +0100, Bernard Frit wrote:
    +>Hi everybody,
    +>
    +>A friend of mine has a lot of archives in CompuServe
    +>thread and message format. He'd like to convert them
    +>in a convenient format (html or whatever) with thread
    +>indexing features as MHonArc is doing it for mail
    +>archives.
    +>
    +>At the first glance, I didn't find out how to configure
    +>MHonArc to do the job.
    +
    +The Compuserve "file cabinet" format is too far from the basic SMTP message
    +format that MHonArc recognizes.
    +
    +Your friend can find software on Compuserve to read the file cabinet format
    +and emit ascii text that is closer to SMTP message format that MHonArc can
    +use.  A search of IBMFF using the keywords "cabinet" and "convert" yielded
    +several items including these two:
    +
    +Forum Name: CSNAVSUPPORT                 Library: Member Uploads  (6)
    +  Accesses: 839                       Size: 11368
    +      File: THRDCO.ZIP           Submitted: [72662,70]   26-Aug-94
    +
    +
    +This program converts forum message threads to a plain text file  called
    +COLLECT.TXT.  Your favorite word processor can then search  for any message
    +on any topic that you have downloaded.  It is  public domain and was
    +created because I have so many forum  thread messages which I can't search.
    +
    +-----
    +Forum Name: PCEFORUM                 Library: Telecom/Reseaux  (8)
    +  Accesses: 32                        Size: 30865
    +      File: SHWCIM.ZIP           Submitted: [72241,2132]   08-Nov-96
    +
    +Une fois stockes dans le "Cabinet"  CompuServe, les messages des forums et
    +les courriers sont codes dans des fichiers binaires que l'on ne peut pas
    +relire directement. Cet utilitaire a pour but de convertir n'importe quel
    +fichier de la base WinCIM en fichier ASCII pur. Freeware en anglais.
    +
    +-- SP
    +
    +
    +
    + + +

    Can MHonArc create non-English archives?

    + +

    Yes. With MHonArc's page layout customizations features, +you can have MHonArc create pages in any language supported +by Web client software. Plus, messages containing non-English text +is supported during message conversion. For text messages, +MHonArc supports the ISO-8859 character sets and the +ISO-2022-JP character set. +

    + + +

    Can I create bilingual archives?

    + +

    Yes. You can actually create archives that have as many +indexes as you want in as many languages that you want. Through +the OTHERINDEXES resource can define any number of extra indexes +to create. For each index, you can redfine the index resources +to use whatever text (English or non-English) you desire. +

    +
    +
    NOTE
    +

    There is no support for mulitple variations of message +pages in an archive. Therefore, a single language must be +chosen for message pages, or you can include redundant information +using multiple languages. +

    +
    +
    +
    +
    NOTE
    +

    Actual message data will be in the language used in the +message. MHonArc has no built-in language translation. +

    +
    +
    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:06
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/faq.html b/faq/faq.html new file mode 100644 index 0000000..bd04c2d --- /dev/null +++ b/faq/faq.html @@ -0,0 +1,139 @@ + + + +MHonArc Frequently Asked Questions + + + + + + + +

    MHonArc Frequently Asked Questions

    + +

    This documents contains answers to some of the frequently +asked question on MHonArc. MHonArc is +a Perl program +for converting e-mail messages as specified in RFC 822 and MIME to HTML. +MHonArc has the ability to maintain an archive of converted +messages, or it can be used as a basic e-mail->HTML converter.

    + + +
    +

    Table of Contents

    + + + + + + + + + + + + + + +
    +
    +97/05/15 16:48:07
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/general.html b/faq/general.html new file mode 100644 index 0000000..899ef0b --- /dev/null +++ b/faq/general.html @@ -0,0 +1,188 @@ + + + +MHonArc FAQ: General Information + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    General

    + + +

    What is MHonArc?

    + +

    MHonArc is +a Perl program +for converting e-mail messages as specified in RFC 822 and MIME to HTML. +MHonArc has the ability to maintain an archive of converted +messages, or it can be used as basic e-mail->HTML converter. +

    + + +

    What's the latest version of MhonArc?

    + +

    2.0.0. +

    + + +

    Where can I get MHonArc?

    + +

    The latest information on MHonArc, +and its availability, may be obtained at (http://www.oac.uci.edu/indiv/ehood/mhonarc.html). +

    + + +

    How much does MHonArc cost?

    + +

    Its FREE! MHonArc is distributed under +the GNU General Public License. A copy of the license is included in +the distribution. Please read it for more information.

    + +

    Although MHonArc is freely available, it is NOT +in the public domain. Applicable copyrights still apply. +

    + + +

    Where can I get help on MHonArc?

    + +

    The first place to try is the documentation that comes with +MHonArc. The documentation is quite extensive, and may +provide answers to most of your questions.

    + +

    Second, you can read this FAQ. +

    + +

    Third, a mailing list, mhonarc@rosat.mpe-garching.mpg.de, is available to +provide a discussion forum on the usage and development of +MHonArc. Appropriate topics for the list include: usage +questions, bug reports, behavioral enhancements, documentation bugs, +and general help.

    + +

    To subscribe to the mailing list, send mail to mhonarc-request@rosat.mpe-garching.mpg.de +with the command,

    + +
    +subscribe
    +
    + +

    as the message body. +

    + +

    If you send mail mhonarc@rosat.mpe-garching.mpg.de, your message will be +distributed to all subscribers on the list.

    + +

    The mailing list is archived by +Majordomo. You can also use the WWW to access +the archive (with full text search using +Glimpse) at +(http://www.rosat.mpe-garching.mpg.de/mailing-lists/mhonarc/) +

    + + +

    How does MHonArc compare to other e-mail converters, like Hypermail?

    + +

    Hypermail, +(http://www.eit.com/software/hypermail/hypermail.html) +is probably the only other major free program for archiving +e-mail on the Web. There are other free programs available, +but Hypermail and MHonArc appear to be the two major programs +in use. + +

    Although Hypermail is a good product, +MHonArc has the following advanatages: +

    +

      +
    • Support variant mail folders types. Hypermail supports only +UUCP style mailboxes. +

      +
    • +
    • Support for MIME. Hypermail does not support MIME. With +the MIME model, you can extend MHonArc to handle content-types +that it does not support by default. Also, with MIME, non-textual +data like images will be handled properly. +

      +
    • +
    • Page customization. MHonArc gives you complete control +on how pages are formatted. This allows you to tailor your archives +to fit the style of your Web site. Hypermail has a predefined +style for pages generated. Note, Hypermail does support some +simple options that effect how data is converted to HTML. +

      +
    • +
    • Multi-platform support. MHonArc basically runs on any system +that Perl runs. Hypermail is only known to run on Unix systems, +however, there may be a WinNT port. +

      +
    • +
    + +

    The other major difference is that MHonArc is written in +Perl, and Hypermail is written in C (there is also a Lisp version). +There are pros and cons of both languages. In sum, Perl allows +for easier modification, portability, and extensiblility. C +provides better execution speed. +

    + +

    There are other differences, so consult the documentation of +both programs to get a more complete list. Your needs willl +ultimately decide which program is best for you. +

    + + +

    Are their "real-world" examples of MHonArc usage?

    + +

    Take your pick: +

    + + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:08
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/indexpgs.html b/faq/indexpgs.html new file mode 100644 index 0000000..2b60f79 --- /dev/null +++ b/faq/indexpgs.html @@ -0,0 +1,100 @@ + + + +MHonArc FAQ: Index Pages + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    Index Pages

    + + +

    What are all the different index types?

    + +

    MHonArc catagorizes indexes into to types: +main and thread. Main covers indexes +listing messages by the following criteria: +

    +
      +
    • Author +
    • Date +
    • Subject +
    • Message number +
    + +

    When the documentation refers to main index, +it refers to the index listing messages by author, date, or +subject. Therfore, all resources. and resource variables, that +refer to the main index apply to either an author, date, or +subject index. The type of main index is controled by +the SORT, SUBSORT, AUTHSORT resources. +

    + +

    By default, MHonArc creates a date index +and a thread index. +Author index support is available only in v2.0 beta 2 or later. +

    + + +

    Can I have additional indexes beyond the default main and thread index?

    + +

    Yes. In version 1.2 (or later), a resource was added called +OTHERINDEXES. With this resource, you are able to +define an arbitrary number of indexes you desire. The additional +indexes may be in any format you desire and that is supported +by MHonArc. Refer to the documentation for the usage of +OTHERINDEXES. +

    + +
    +
    NOTE
    +

    MHonArc will NOT automatically +create links to any indexes created via the OTHERINDEXES resource. +You will need to modify the relevant index and messages resources +to contain the additional links. See the LISTBEGIN and +THEAD resources. +

    +
    +
    + + +

    Can I have multi-page indexes?

    + +

    Yes, in v2.0 or later. Setting the MULTIPG and IDXSIZE will cause +indexes to to be listed across multiple pages with IDXSIZE determine +the number of messages listed per page. +

    + + +

    Can I sort messages by author?

    + +

    Yes, with v2.0 beta 2, or later. +

    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:09
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/mime.html b/faq/mime.html new file mode 100644 index 0000000..ee3bae8 --- /dev/null +++ b/faq/mime.html @@ -0,0 +1,83 @@ + + + +MHonArc FAQ: MIME + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    MIME

    + + +

    What is MIME?

    + +

    MIME stands for Multipurpose Internet +Mail Extensions. +An HTML version of the RFCs that define MIME are available at (http://www.oac.uci.edu/indiv/ehood/MIME/MIME.html). +

    + +

    In sum, MIME "redefines the format of message bodies to +allow multi-part textual and non-textual message bodies to +be represented and exchanged without loss of information." [RFC +1521]

    + + +

    Does MHonArc support message header extensions for non-ASCII text

    + +

    v2.0 or later. +

    + + +

    How can I get MHonArc to recognize content-types it states it does not recognize?

    + +

    This question can be anwsered by reading about the MIMEFILTERS +resource of the +MHonArc documentation. The solution may require registering +a pre-existing filter for the given content-type, or hooking in a +new filter.

    + + +

    Can I override the default filters in MHonArc

    + +

    Yes. MHonArc's default filters are hooked in +as described in the MIMEFILTERS resource. +

    + + +

    Can I override the multipart/* processing of MHonArc

    + +

    Yes, but not recommended. Make sure you are familiar with how +MHonArc does things before considering implemting your own multipart +filter. In sum, you can completely replace MHonArc's filters +with your own if you so desire. +

    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:09
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/monicon.gif b/faq/monicon.gif new file mode 100644 index 0000000..a0a9161 Binary files /dev/null and b/faq/monicon.gif differ diff --git a/logo/small_t.gif b/faq/monsmall_t.gif similarity index 100% rename from logo/small_t.gif rename to faq/monsmall_t.gif diff --git a/faq/msgpgs.html b/faq/msgpgs.html new file mode 100644 index 0000000..70d8b5c --- /dev/null +++ b/faq/msgpgs.html @@ -0,0 +1,169 @@ + + + +MHonArc FAQ: Message Pages + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    Message Pages

    + + +

    Can I change the order the message resources are printed?

    + +

    No. However, with the exceptions of the message header and body +(but see next questions), those resource can be defined +anyway you like. For example, I can change the TOPLINKS resource +to look like the BOTLINKS resource. Or, I can change the +default meaning of the resource so it really outputs something +else entirely. If you look at the documentation, the resources +are just defined by HTML markup and resource variables. Many +of the resource variables can be used within any resource. +

    + + +

    How can I change how message headers gets formatted?

    + +

    There are several resources for controlling how message headers +are converted into HTML. You can exclude fields and style fields +with your own HTML markup. For example, here are resources that +cause message headers to be formatted with a table: +

    +
    +<FIELDSBEG>
    +<table>
    +<tbody>
    +</FIELDSBEG>
    +<LABELBEG>
    +<tr>
    +<td align="right" valign="top">
    +</LABELBEG>
    +<LABELEND>
    +</td>
    +</LABELEND>
    +<FLDBEG>
    +<td align="left">
    +</FLDBEG>
    +<FLDEND>
    +</td>
    +</tr>
    +</FLDEND>
    +<FIELDSEND>
    +</tbody>
    +</table>
    +</FIELDSEND>
    +
    + +

    You can also control the order message fields are displayed: +

    +
    +<FIELDORDER>
    +from
    +subject
    +date
    +-extra-
    +</FIELDORDER>
    +
    +

    The "-extra-" signifies all other message fields in alphabetic +order. +

    + +

    You can also exclude specific message fields: +

    +
    +<EXCS>
    +x-
    +precendence
    +</EXCS>
    +
    +

    Here, we are exluding all "X-..." fields and the Precendence +field. +

    + +

    Consult the MHonArc documentation for more information +on how to use the resources shown here and other resources for +controlling message header formatting. +

    + + +

    How can I change how message body data gets formatted?

    + +

    Message body conversion are controlled by content-type filters. +See the MIME section of this FAQ for +more information. +

    + + +

    Can I have the message header come after the body?

    + +

    In general, no. A limitation of MHonArc is that you cannot change +the relative order of the resources/message-data in the output (but see +other questions in this section). MHonArc expects +a specific order so it can edit archived messages when needed w/o +using a bunch of logic, and performance degradation (special comment +declarations are used to mark off the different sections of a message). +Therefore, you cannot have the body come before the message header. +The best you can do is suppress the header (via EXCS) and create a +bogus header via the resource variables available. For example: +

    +
    +<EXCS override>
    +.
    +</EXCS>
    +<MSGFOOT>
    +<ul>
    +<li>From: $FROM$
    +<li>Subject: $SUBJECTNA$
    +<li>Date: $DATE$
    +<ul>
    +</MSGFOOT>
    +
    + + +

    Can I make changes to message formatting on existing archived messages?

    + +

    Yes, mostly. The only thing cannot be changed once converted +is the message header and message body. All other parts of the +message page can be changed at any time. To make any changes +appear on existing archived messages, set the EDITIDX resource. +The EDITIDX resource tells MHonArc to recreate all archive +pages. +

    + + +

    What are those "<!--X-... -->"?

    + +

    If you ever looked at the HTML source of converted messages, +you will notice a bunch of comment declarations, "<!--X-... -->". +These comment declarations are used by MHonArc to +properly edit messages when needed. Therefore, DO NOT +MESS WITH THEM. +

    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:13
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/threads.html b/faq/threads.html new file mode 100644 index 0000000..06767d1 --- /dev/null +++ b/faq/threads.html @@ -0,0 +1,90 @@ + + + +MHonArc FAQ: Threading + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    Threading

    + + +

    How does threading work?

    + +

    MHonArc utilizes the References and +In-Reply-To fields of mail messages for generating +threads. It is up to the mail user agents (MUAs) to define these +fields. The References field is normally utilized by +news software, while In-Reply-To is normally utilized +be e-mail software.

    + +

    In v2.0, MHonArc will also check message subjects for +threads. Hence, if the MUA fails to include the reference message +ID, MHonArc will still group messages of the same subject +together (utilizing the message date for thread order). +

    + + +

    Why isn't threading working for me?

    + +

    In versions prior to v2.0, If the mail you archive does not +contain References and In-Reply-To fields, +MHonArc will not detect a thread, even though there are +messages that are follow-ups to existing messages.

    + + + +

    How can I get my MUA to define the References or In-Reply-To field?

    + +

    The answer varies depending on your MUA. You'll need to look at the +documentation of your MUA to find the answer. +

    + +

    For MH users, the following in your replcomps file will work: +

    + +
    %<{date}In-reply-to: Your message of "\
    +%<(nodate{date})%{date}%|%(pretty{date})%>."%<{message-id}
    +             %{message-id}%>\n%>\
    +
    +
    + +

    Or, you can use the following if you prefer the +References field format:

    + +
    %<{message-id}References: \
    +%<{references}%(void{references})%(trim)%(putstr) %>
    +            %(void{message-id})%(trim)%(putstr)\n%>\
    +
    +
    + +

    Author welcomes feedback from users on how to configure other MUAs. +

    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:10
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/faq/usage.html b/faq/usage.html new file mode 100644 index 0000000..5ad524c --- /dev/null +++ b/faq/usage.html @@ -0,0 +1,180 @@ + + + +MHonArc FAQ: General Usage + + + +

    +[Prev][Next][TOC][Home] +

    + + + +
    +

    General Usage

    + + +

    What are "resources"?

    + +

    The behavior of MHonArc is controled by resources. +Resources are set, or defined, by command-line options, environment +variables, or a resource file. For example, the MAXSIZE resource tells +MHonArc the maximum number of messages in an archive. To set +the resource, you can use the -maxsize +command-line option, the M2H_MAXSIZE envariable, or the +<MAXSIZE> resource file element. +

    + +

    See the documentation for more information. +

    + + +

    I get an error that "newgetopt.pl" cannot be required, where is it?

    + +

    newgetopt.pl comes with the standard Perl distribution. Check with +your sys admin on where it is located (it should be in the default Perl +search path). +

    + + +

    Does MHonArc provide searching of archives?

    + +

    No, but a searching can be provided by another utility. See +the MHonArc home page +(http://www.oac.uci.edu/indiv/ehood/mhonarc.html) to +some links to contributed programs for searching MHonArc +archives. +Also, any standard search engine can be used. For example, the +MHonArc mailing list archive +(http://www.rosat.mpe-garching.mpg.de/mailing-lists/mhonarc/) +provides a +Glimpse +(http://glimpse.cs.arizona.edu:1994/) +search engine for searching messages. For more information, see +the respective documentation of the search engine software of +interest. +

    + +
    +
    NOTE
    +

    Through MHonArc's resources, it is easy to provide +a search form to whatever search utility you may use without +modifying MHonArc source code. +

    +
    +
    + + +

    Is there a Web interface for MHonArc?

    + +

    There is no known Web interface that uses MHonArc to +allow people to read incoming mail or perform archive administration +function. If you know of one, please contact the author of the FAQ. +

    + + +

    Does MHonArc require that the original message be available when updating an archive?

    + +

    No. Once a message is archived, the original can be stored +away. MHonArc preserves all relevant information in its +database. For possible recovering purposes, it is recommended +to preserve original messages in a storage archive. This allows +you to rebuild MHonArc archives in case of data corruption. +

    + + +

    Do I have to respecify the resource file each time I update an archive?

    + +

    No. The archive database stores all resource settings. The only +time you need to respecify the resource file is if changes are required +in the layout of the archive.

    + +
    +
    NOTE + +

    When utilizing the OTHERINDEXES resource, +the resource filenames listed in the main resource file are stored +in the database, but the resources for each additional index are +NOT. Hence, the resource files defining the additional +indexes must be accesible. +

    + + +

    Can I have MHonArc process a bunch of separate message files?

    + +

    Yes. MH mail folder processing is just processing a bunch of +separate message files in a directory. MHonArc uses +the MHPATTERN resource to determine which files to process. Therefore, +all you need to do is redefine the MHPATTERN resource and pass +the directory your message files are in when invoking MHonArc. +

    + +

    For example, say I want to process all files in a directory +called "messages". I'd do the following: +

    +
    +    % mhonarc -mhpattern "^[^.]" messages
    +
    +

    MHPATTERN can be any Perl regular expression. The one in +the example matches any file not beginning with ".". This +is to avoid the special files "." and ".." which are directories. +

    + +

    The other way to process individual message files is to do +it one at a time. For example: +

    +
    +    % mhonarc -add < file1.822
    +    % mhonarc -add < file2.822
    +    ...
    +
    + + +

    Can I tell MHonArc to read a mailbox from standard input?

    + +

    Yes, but only in v2.0 or later (v2.0 beta releases do not have +the capability). The syntax is something like the following: +

    +
    +    % mhonarc [options-here] -- -
    +
    +

    The "--" tells MHonArc to terminate all command-line +option processing and treat all following arguments as mail +folders. The "-" signifies to use standard input as a mailbox +source. +

    + +

    Since MHonArc can read a mailbox from stdin, this +allows MHonArc to be part of a pipeline where MHonArc +takes input from some preprocessor that massages some data to +make it suitable for processing by MHonArc. For example: +

    +
    +    % mypreproc | mhonarc -- -
    +
    + + +
    + + +

    +[Prev][Next][TOC][Home] +

    + + +
    +
    +97/05/15 16:48:11
    + +MHonArc
    +Copyright © 1997, Earl Hood, ehood@medusa.acs.uci.edu
    +
    + + diff --git a/install.cfg b/install.cfg index afaa147..da4639b 100644 --- a/install.cfg +++ b/install.cfg @@ -1,68 +1,74 @@ -##---------------------------------------------------------------------------## -## File: -## install.cfg -## Description: -## This is a sample configuration file for install.me for -## non-interactive use. This allows you to install the program -## in batch mode. To invoke install.me in batch mode, just -## specify the configuration file on the command-line: -## -## perl install.me install.cfg -## -## This file is Perl code, and therefore, must follow Perl syntax -## rules: -## -## o Anything following a '#' character is ignored. -## -## o Strings values need to be enclosed in quotes. -## -## o If you need to use a backslash in a string value, -## it must be escaped with a backslash. Example: -## -## 'C:\\LIB\\MHONARC'. -## -## The same applies to the '$' character. -## -## o All statements must end with a semi-colon: ; -## -## Notes: -## o Paths specified in the configuration file should exist. -## install.me will not automatically create them as it does -## in interactive mode. -## -##---------------------------------------------------------------------------## +##************************************************************************## +## 97/02/24 12:34:23 +##************************************************************************## -# Should executables be installed. 0 => NO, non-zero => YES. -# -$dobin = 1; +## Set flags +$dobin = 1; # Set to 1 if exectuables to install +$dolib = 1; # Set to 1 if libraries to install +$dodoc = 1; # Set to 1 if documents to install +$doman = 0; # No manpages to install -# Should libraries be installed. 0 => NO, non-zero => YES. -# -$dolib = 1; +## Set default values +$bindir = (!$MSDOS ? '/usr/local/bin' : 'C:\\BIN'); +$libdir = (!$MSDOS ? '/usr/local/lib/MHonArc' : 'C:\\LIB\\MHONARC'); +$docdir = (!$MSDOS ? '/usr/local/lib/MHonArc/doc' : 'C:\\DOC\\MHONARC'); +$perlprg = (!$MSDOS ? '/usr/local/bin/perl' : 'C:\\BIN\\PERL.EXE'); -# Should documentation be installed. 0 => NO, non-zero => YES. -# -$dodoc = 1; -# Location for executable. If using ms-dos, use something like -# 'C:\\BIN'. -# -$bindir = '/usr/local/bin'; +##************************************************************************## +## SHOULD NOT HAVE TO MODIFY ANYTHING PASSED HERE +##************************************************************************## -# Location for libraries. If using ms-dos, use something like -# 'C:\\LIB\\MHONARC'. -# -$libdir = '/usr/local/lib/MHonArc'; +## Set files to install +$relbin = '.'; # Location of source bin files relative to install.me +@binfiles = ( + 'mhonarc', +); +$rellib = 'lib'; # Location of source lib files relative to install.me +@libfiles = ( + 'base64.pl', + 'ewhutil.pl', + 'iso8859.pl', + 'mhdb.pl', + 'mhdysub.pl', + 'mhexternal.pl', + 'mhidxrc.pl', + 'mhinit.pl', + 'mhrcfile.pl', + 'mhrcvars.pl', + 'mhtime.pl', + 'mhtxthtml.pl', + 'mhtxtplain.pl', + 'mhtxtsetext.pl', + 'mhusage.pl', + 'mhutil.pl', + 'osinit.pl', + 'qprint.pl', + 'readmail.pl', + 'rfc822.pl', +); +$reldoc = 'doc'; # Location of source doc files relative to install.me +@docfiles = ( + 'contacts.html', + 'diagnos.html', + 'intro.html', + 'layout.html', + 'mhonarc.html', + 'quickstart.html', + 'resources', # This is a directory + 'resources.html', + 'monicon.gif', + 'monstamp_t.gif', +); -# Location for documents. If using ms-dos, use something like -# 'C:\\DOC\\MHONARC'. -# -$docdir = '/usr/local/lib/MHonArc/doc'; +## Define intro text +$introText =< to accept +the default values listed in ()'s. -# Location of perl executable. If using ms-dos, use something like -# 'C:\\BIN\\PERL.EXE'. -# -$perlprg = '/usr/local/bin/perl'; +EndofIntro - -1; # DO NOT DELETE THIS LINE +1; diff --git a/install.me b/install.me index e8128d3..91b2018 100755 --- a/install.me +++ b/install.me @@ -1,18 +1,16 @@ #! /usr/local/bin/perl ##---------------------------------------------------------------------------## ## File: -## install.me +## @(#) install.me 1.8 97/05/15 16:55:42 @(#) ## Author: -## Earl Hood ehood@isogen.com +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Configurable installation program. -## Just edit the variables in the CONFIG section for setting defaults -## for the particular program. -## To Do: -## o Add support for manpages to go in different section directories. +## Create an install.cfg file to define variables with the +## values appropriate for the software you want to install. ## ##---------------------------------------------------------------------------## -## Copyright (C) 1995,1996 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -45,102 +43,94 @@ package main; $'DIRSEP = '/'; $'CURDIR = '.'; } ## Store name of program - ($tmp = $'DIRSEP) =~ s/(\W)/\\$1/g; - ($'PROG = $0) =~ s%.*[$tmp]%%o; + ($'DIRSEPrxp = $'DIRSEP) =~ s/(\W)/\\$1/g; + ($'PROG = $0) =~ s%.*[$DIRSEPrxp]%%o; } +eval 'umask 022' if $UNIX; # Set umask + ##--------------------------------------------------------------------------- -## Begin CONFIG section +## BEGIN template for install.cfg ## -eval 'umask 022' if $UNIX; # Set umask +## Flag if Perl 5 install (use "use lib ..." instead if @INC) +$doPerl5 = 0; ## Set flags $dobin = 1; # Set to 1 if exectuables to install $dolib = 1; # Set to 1 if libraries to install $dodoc = 1; # Set to 1 if documents to install +$doman = 1; # Set to 1 if manpages to install ## Set default values $bindir = (!$MSDOS ? '/usr/local/bin' : 'C:\\BIN'); -$libdir = (!$MSDOS ? '/usr/local/lib/MHonArc' : 'C:\\LIB\\MHONARC'); -$docdir = (!$MSDOS ? '/usr/local/lib/MHonArc/doc' : 'C:\\DOC\\MHONARC'); +$libdir = (!$MSDOS ? '/usr/local/lib' : 'C:\\LIB'); +$docdir = (!$MSDOS ? '/usr/local/lib' : 'C:\\DOC'); +$mandir = (!$MSDOS ? '/usr/local/man' : 'C:\\MAN'); $perlprg = (!$MSDOS ? '/usr/local/bin/perl' : 'C:\\BIN\\PERL.EXE'); -## Set files to install +## Set files to install. File can be a directory. If so, the +## directory is copied to destination + $relbin = '.'; # Location of source bin files relative to install.me -@binfiles = ( - "mhonarc", -); +@binfiles = (); + $rellib = 'lib'; # Location of source lib files relative to install.me -@libfiles = ( - "base64.pl", - "mhdb.pl", - "mhexternal.pl", - "mhtxt2022.pl", - "mhtxthtml.pl", - "mhtxtplain.pl", - "mhtxtsetext.pl", - "mhinit.pl", - "mhutil.pl", - "osinit.pl", - "qprint.pl", - "readmail.pl", -); +@libfiles = (); + $reldoc = 'doc'; # Location of source doc files relative to install.me -@docfiles = ( - "adding.html", - "contacts.html", - "details.html", - "diagnos.html", - "indexpg.html", - "install.html", - "intro.html", - "message.html", - "mhonarc.html", - "mhonarc.txt", - "mime.html", - "overview.html", - "qstart.html", - "rcfile.html", - "removing.html", - "stamp_t.gif", - "thread.html", -); +@docfiles = (); + +$relman = 'man'; # Location of source manpages relative to install.me +@manfiles = (); ## Define intro text $introText =< -to accept the default values listed in ()'s. - -If directory path does not exist on your system, the installation -program will create the path for you. +the Perl executable is and where to put files. Just hit to accept +the default values listed in ()'s. EndofIntro ## -## End CONFIG section +## END template for install.cfg ##--------------------------------------------------------------------------- + ##--------------------------------------------------------------------------- -## Main routine +## Main routine ##--------------------------------------------------------------------------- { + +$Batch = 0; +$CfgFile = "install.cfg"; +if ($ARGV[0] =~ /^batch$/i) { + shift(@ARGV); + $Batch = 1; +} +if ($ARGV[0] =~ /\S/) { + $CfgFile = shift(@ARGV); +} + +require $CfgFile || die "Unable to require $CfgFile\n"; + { package uio; - @LastText = (); ## Cached text - $use_handler = 1; ## Flag to use private CONT signal handler - $ext_sigcont; ## External CONT handler + @LastText = (); ## Cached text + $use_handler = 1; ## Flag to use private CONT signal handler } -if ($ARGV[0]) { ## Check for batch mode - eval qq{require "$ARGV[0]"}; - die "ERROR: Unable to read $ARGV[0]\n" if $@; +if ($Batch) { ## Check for batch mode + print STDOUT "Batch mode install ...\n"; -} else { ## Interactive mode +} else { ## Interactive mode print STDOUT $introText; &print_note("Make sure all pathnames are absolute."); &pause(); + $dobin = 0 unless scalar(@binfiles); + $dolib = 0 unless scalar(@libfiles); + $dodoc = 0 unless scalar(@docfiles); + $doman = 0 unless scalar(@manfiles); do { ## Get installation directories and path to Perl while (1) { @@ -151,88 +141,129 @@ if ($ARGV[0]) { ## Check for batch mode $perlprg = $tmp; if ($dobin) { do { - $tmp = &prompt_user_def("Location to install programs", - $bindir, 0, 1); + $tmp = &interpolate_path( + &prompt_user_def("Location to install programs", + $bindir, 0, 1)); } while (!&create_dir($tmp)); $bindir = $tmp; } if ($dolib) { do { - $tmp = &prompt_user_def("Location to install libraries", - $libdir, 0, 1); + $tmp = &interpolate_path( + &prompt_user_def("Location to install libraries", + $libdir, 0, 1)); } while (!&create_dir($tmp)); $libdir = $tmp; } if ($dodoc) { if (&ask_question("Install documentation", 1)) { do { - $tmp = &prompt_user_def("Location to install docs", - $docdir, 0, 1); + $tmp = &interpolate_path( + &prompt_user_def("Location to install docs", + $docdir, 0, 1)); } while (!&create_dir($tmp)); $docdir = $tmp; } else { $dodoc = 0; } } + if ($doman) { + if (&ask_question("Install manpages", 1)) { + do { + $tmp = &interpolate_path( + &prompt_user_def("Location to install manpages", + $mandir, 0, 1)); + } while (!&create_dir($tmp)); + $mandir = $tmp; + } else { + $doman = 0; + } + } print STDOUT "\n", "You've specified the following:\n", "\tPerl location: $perlprg\n"; print STDOUT "\tProgram directory: $bindir\n" if $dobin; print STDOUT "\tLibrary directory: $libdir\n" if $dolib; print STDOUT "\tDoc directory: $docdir\n" if $dodoc; + print STDOUT "\tMan directory: $mandir\n" if $doman; } while (!&ask_question("Is this correct", 1)); } ## Install files -$perlprg = "#! $perlprg\n"; -$perlprg .= "unshift(\@INC, '$libdir');\n" if $dolib; +$perlprg = "#!$perlprg\n"; +if ($dolib) { + if ($doPerl5) { + $perlprg .= "use lib '$libdir';\n"; + } else { + $perlprg .= "unshift(\@INC, '$libdir');\n"; + } +} if ($dobin && @binfiles) { print STDOUT "Installing the following into $bindir\n"; foreach $file (@binfiles) { - &cp("$relbin$DIRSEP$file", "$bindir$DIRSEP$file", $perlprg); + ($destfile = $file) =~ s%.*$DIRSEPrxp%%o; + &cp("$relbin$DIRSEP$file", "$bindir$DIRSEP$destfile", $perlprg); print STDOUT "\t", $file, "\n"; - chmod 0755, "$bindir/$file"; + eval 'chmod 0755, "$bindir$DIRSEP$file"'; } } if ($dolib && @libfiles) { print STDOUT "Installing the following into $libdir\n"; foreach $file (@libfiles) { - &cp("$rellib$DIRSEP$file", "$libdir$DIRSEP$file"); + ($destfile = $file) =~ s%.*$DIRSEPrxp%%o; + &cp("$rellib$DIRSEP$file", "$libdir$DIRSEP$destfile"); print STDOUT "\t", $file, "\n"; } } if ($dodoc && @docfiles) { print STDOUT "Installing the following into $docdir\n"; foreach $file (@docfiles) { - &cp("$reldoc$DIRSEP$file", "$docdir$DIRSEP$file"); + ($destfile = $file) =~ s%.*$DIRSEPrxp%%o; + &cp("$reldoc$DIRSEP$file", "$docdir$DIRSEP$destfile"); print STDOUT "\t", $file, "\n"; } } +if ($doman && @manfiles) { + print STDOUT "Installing the following into $mandir\n"; + local($sect) = (1); + foreach $file (@manfiles) { + ($destfile = $file) =~ s%.*$DIRSEPrxp%%o; + ($sect) = $destfile =~ m%\.([\d\w]+)$%; + &create_dir("$mandir${DIRSEP}man${sect}", 1); + &cp("$relman$DIRSEP$file", + "$mandir${DIRSEP}man${sect}${DIRSEP}$destfile"); + print STDOUT "\t$file -> $mandir${DIRSEP}man${sect}\n"; + } +} exit 0; } + ##--------------------------------------------------------------------------- ## Main subroutines ##--------------------------------------------------------------------------- + sub create_dir { local($d) = shift; - local($tmp); - ($tmp = $DIRSEP) =~ s/(\W)/\\$1/g; - local(@a) = grep($_ ne '', split(/$tmp/o, $d)); + local($noask) = shift; + local(@a) = grep($_ ne '', split(/$'DIRSEPrxp/o, $d)); local($path, $dir); + if ((! -e $d) && (!$noask)) { + return 0 unless &ask_question(qq{$d does not exist. Create}, 1); + } if ($MSDOS) { if ($d =~ m%^\s*([a-zA-Z]:)?[/\\]%) { $path = shift @a; } else { - $path = '.'; + $path = $CURDIR; } } else { if ($d =~ /^\s*\//) { $path = ''; } else { - $path = '.'; + $path = $CURDIR; } } foreach $dir (@a) { @@ -253,9 +284,47 @@ sub create_dir { } 1; } + +##--------------------------------------------------------------------------- +sub interpolate_path { + local($path) = shift; + + $path =~ s/^~/$ENV{'HOME'}/; + $path =~ s/\$(\w+)/$ENV{$1}/ge; + $path; +} + ##--------------------------------------------------------------------------- sub cp { local($src, $dst, $prepend) = @_; + + if (-d $src) { + if (! -e $dst) { + mkdir($dst,0777) || die "Unable to create $dst: $!\n"; + } + opendir(DIR, $src) || die "Unable to open $src: $!\n"; + @files = grep(!/^(sccs|\.|\..)$/i, readdir(DIR)); + closedir(DIR); + foreach $file (@files) { + $srcpn = "$src$DIRSEP$file"; + $dstpn = "$dst$DIRSEP$file"; + if (-d $srcpn) { + &cp($srcpn, $dstpn, $prepend); + } else { + &cpfile($srcpn, $dstpn, $prepend); + } + } + + + } else { + &cpfile($src, $dst, $prepend); + } +} + +##--------------------------------------------------------------------------- +sub cpfile { + local($src, $dst, $prepend) = @_; + open(SRC, $src) || die "Unable to open $src: $!\n"; open(DST, "> $dst") || die "Unable to create $dst: $!\n"; if (-B $src) { binmode( SRC ); binmode( DST ); } @@ -269,6 +338,37 @@ sub cp { ############################################################################### +##---------------------------------------------------------------------------## +## File: +## @(#) uio.pl 1.2 97/03/11 12:29:46 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## This package contains subroutines for user input routines and +## screen output routines. +##---------------------------------------------------------------------------## +## Copyright (C) 1994-1997 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +if (!$uio'NoDate) { + # date.pl is needed for get_later_date() + require 'date.pl' || warn "Unable to require date.pl\n"; +} + package uio; ##---------------------------------------------------------------------------## @@ -312,14 +412,20 @@ package uio; ## value is one. More inforamtion is below in the various ## subroutine descriptions. ##---------------------------------------------------------------------------## + ##------------------## ## Global variables ## ##------------------## ##--------------------------------------------------------------------------- + @LastText = (); ## Cached text $use_handler = 1; ## Flag to use private CONT signal handler +$term_io_bug = 0; ## Flag if bogus reads must be done when + ## consective suspend/foregrounds are done $ext_sigcont; ## External CONT handler + ##--------------------------------------------------------------------------- + ##---------------------------------## ## Private subroutine declerations ## ##---------------------------------## @@ -332,6 +438,7 @@ $ext_sigcont; ## External CONT handler sub print_txt { print STDOUT @_; @LastText = @_; } + ##--------------------------------------------------------------------------- ## This routine is used by print_{error, info, note, warning} ## routines to output an informitive message to STDOUT. @@ -352,6 +459,7 @@ sub print_message { print STDOUT "$dashes\n", "$mesg\n", "$dashes\n"; $* = 0; } + ##--------------------------------------------------------------------------- ## handler() is the private signal handler for the uio package. ## It's used to when SIGCONT is caught for redisplay cached text. @@ -362,8 +470,9 @@ sub handler { $ext_sigcont ne "") { &$ext_sigcont(@_); } print STDOUT @LastText; &'flush(STDOUT); - push(@Redo, 1); + push(@Redo, 1) if $term_io_bug; } + ##--------------------------------------------------------------------------- ## set_handler() sets the private CONT signal handler. ## @@ -372,6 +481,7 @@ sub set_handler { $ext_sigcont = $SIG{'CONT'}; $SIG{'CONT'} = "uio'handler"; } + ##--------------------------------------------------------------------------- ## reset_handler() restores the external handler ## @@ -379,7 +489,9 @@ sub reset_handler { return unless $use_handler; $SIG{'CONT'} = $ext_sigcont; } + ##--------------------------------------------------------------------------- + ##--------------------------------## ## Public subroutine declerations ## ##--------------------------------## @@ -469,7 +581,7 @@ sub main'print_warning { &print_message("WARNING", @_); } sub main'get_lc_string { local($tmp); $tmp = ; - while (shift(@Redo)) { $tmp = ; } + if ($term_io_bug) { while (shift(@Redo)) { $tmp = ; } } chop $tmp; $tmp =~ tr/A-Z/a-z/; $tmp; @@ -480,7 +592,7 @@ sub main'get_lc_string { sub main'get_string { local($tmp); $tmp = ; - while (shift(@Redo)) { $tmp = ; } + if ($term_io_bug) { while (shift(@Redo)) { $tmp = ; } } chop $tmp; $tmp; } @@ -492,7 +604,7 @@ sub main'pause { local($tmp); &print_txt("\nHit to continue ... "); $tmp = ; - while (shift(@Redo)) { $tmp = ; } + if ($term_io_bug) { while (shift(@Redo)) { $tmp = ; } } &reset_handler(); } ##--------------------------------------------------------------------------- diff --git a/lib/base64.pl b/lib/base64.pl index edc463d..55c70c0 100644 --- a/lib/base64.pl +++ b/lib/base64.pl @@ -3,6 +3,8 @@ # A. P. Barrett , October 1993 # $Revision: 1.4 $$Date: 1994/08/11 16:08:51 $ # +# @(#) base64.pl 1.1 96/09/17 @(#) +# # Modified March 21, 1996 by ehood@convex.com # -> Changes to base64'uudecode to strip out any begin/end # lines from input string. diff --git a/lib/ewhutil.pl b/lib/ewhutil.pl new file mode 100644 index 0000000..96a0c39 --- /dev/null +++ b/lib/ewhutil.pl @@ -0,0 +1,129 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) ewhutil.pl 1.5 97/04/23 13:38:51 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Generic utility routines +##---------------------------------------------------------------------------## +## Copyright (C) 1996,1997 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +##--------------------------------------------------------------------------- +## Remove duplicates in an array. +## +sub remove_dups { + local(*array) = shift; + local(%dup); + @array = grep($dup{$_}++ < 1, @array); + %dup = (); +} + +##--------------------------------------------------------------------------- +## numerically() is used to tell 'sort' to sort by numbers. +## +sub numerically { + $a <=> $b; +} + +##--------------------------------------------------------------------------- +## "Entify" special characters +## +sub htmlize { # Older name + local($txt) = $_[0]; + $txt =~ s/&/\&/g; $txt =~ s/>/>/g; $txt =~ s//>/g; $txt =~ s/ $dst") || die("ERROR: Unable to create $dst\n"); + print DST ; + close(SRC); + close(DST); +} + +##--------------------------------------------------------------------------- +## Remove a directory (or file) +## +sub rmdir { + local($file) = shift; + + if (-d $file) { + local(@files) = (); + + if (!opendir(DIR, $file)) { + warn qq{Warning: Unable to open "$file"\n}; + return 0; + } + @files = grep(!/^(\.|\..)$/i, readdir(DIR)); + closedir(DIR); + foreach (@files) { + &rmdir($file . $'DIRSEP . $_); + } + if (!rmdir($file)) { + warn qq{Warning: Unable to remove "$file": $!\n}; + return 0; + } + + } else { + if (!unlink($file)) { + warn qq{Warning: Unable to delete "$file": $!\n}; + return 0; + } + } + 1; +} + +##--------------------------------------------------------------------------- +## Translate html string back to regular string +## +sub dehtmlize { + local($str) = shift; + $str =~ s/\<//g; + $str =~ s/\&/\&/g; + $str; +} + +##--------------------------------------------------------------------------- +## Escape special characters in string for URL use. +## +sub urlize { + local($url) = shift; + $url =~ s/([^\w])/sprintf("%%%X",unpack("C",$1))/ge; + $url; +} + +##---------------------------------------------------------------------------## +1; diff --git a/lib/iso8859.pl b/lib/iso8859.pl new file mode 100644 index 0000000..f68d0a4 --- /dev/null +++ b/lib/iso8859.pl @@ -0,0 +1,1167 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) iso8859.pl 1.1 96/09/17 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Routines to process data encoded in iso8859 character sets. +##---------------------------------------------------------------------------## +## Copyright (C) 1996 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +package iso_8859; + +############################################################################### +## Mapping arrays for characters to entity references +############################################################################### + +##--------------------------------------------------------------------------- +## US-ASCII/Common characters +##--------------------------------------------------------------------------- + +%US_ASCII_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0x26, "&", # ISOnum : Ampersand + 0x3C, "<", # ISOnum : Less-than sign + 0x3E, ">", # ISOnum : Greater-than sign + + 0xA0, " ", # ISOnum : NO-BREAK SPACE +); + +##--------------------------------------------------------------------------- +## ISO-8859-1: Latin-1 +##--------------------------------------------------------------------------- + +%ISO_8859_1_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "¡", # ISOnum : INVERTED EXCLAMATION MARK + 0xA2, "¢", # ISOnum : CENT SIGN + 0xA3, "£", # ISOnum : POUND SIGN + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xA5, "¥", # ISOnum : YEN SIGN + 0xA6, "¦", # ISOnum : BROKEN BAR + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "©", # ISOnum : COPYRIGHT SIGN + 0xAA, "ª", # ISOnum : FEMININE ORDINAL INDICATOR + 0xAB, "«", # ISOnum : LEFT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xAC, "¬", # ISOnum : NOT SIGN + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "®", # ISOnum : REGISTERED SIGN + 0xAF, "¯", # ISOdia : OVERLINE (MACRON) + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "±", # ISOnum : PLUS-MINUS SIGN + 0xB2, "²", # ISOnum : SUPERSCRIPT TWO + 0xB3, "³", # ISOnum : SUPERSCRIPT THREE + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "µ", # ISOnum : MICRO SIGN + 0xB6, "¶", # ISOnum : PILCROW SIGN + 0xB7, "·", # ISOnum : MIDDLE DOT + 0xB8, "¸", # ISOdia : CEDILLA + 0xB9, "¹", # ISOnum : SUPERSCRIPT ONE + 0xBA, "º", # ISOnum : MASCULINE ORDINAL INDICATOR + 0xBB, "»", # ISOnum : RIGHT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xBC, "¼", # ISOnum : VULGAR FRACTION ONE QUARTER + 0xBD, "½", # ISOnum : VULGAR FRACTION ONE HALF + 0xBE, "¾", # ISOnum : VULGAR FRACTION THREE QUARTERS + 0xBF, "¿", # ISOnum : INVERTED QUESTION MARK + 0xC0, "À", # ISOlat1: LATIN CAPITAL LETTER A WITH GRAVE + 0xC1, "Á", # ISOlat1: LATIN CAPITAL LETTER A WITH ACUTE + 0xC2, "Â", # ISOlat1: LATIN CAPITAL LETTER A WITH + # CIRCUMFLEX + 0xC3, "Ã", # ISOlat1: LATIN CAPITAL LETTER A WITH TILDE + 0xC4, "Ä", # ISOlat1: LATIN CAPITAL LETTER A WITH + # DIAERESIS + 0xC5, "Å", # ISOlat1: LATIN CAPITAL LETTER A WITH RING + # ABOVE + 0xC6, "Æ", # ISOlat1: LATIN CAPITAL LETTER AE + 0xC7, "Ç", # ISOlat1: LATIN CAPITAL LETTER C WITH CEDILLA + 0xC8, "È", # ISOlat1: LATIN CAPITAL LETTER E WITH GRAVE + 0xC9, "É", # ISOlat1: LATIN CAPITAL LETTER E WITH ACUTE + 0xCA, "Ê", # ISOlat1: LATIN CAPITAL LETTER E WITH + # CIRCUMFLEX + 0xCB, "Ë", # ISOlat1: LATIN CAPITAL LETTER E WITH + # DIAERESIS + 0xCC, "Ì", # ISOlat1: LATIN CAPITAL LETTER I WITH GRAVE + 0xCD, "Í", # ISOlat1: LATIN CAPITAL LETTER I WITH ACUTE + 0xCE, "Î", # ISOlat1: LATIN CAPITAL LETTER I WITH + # CIRCUMFLEX + 0xCF, "Ï", # ISOlat1: LATIN CAPITAL LETTER I WITH + # DIAERESIS + 0xD0, "Ð", # ISOlat1: LATIN CAPITAL LETTER ETH (Icelandic) + 0xD1, "Ñ", # ISOlat1: LATIN CAPITAL LETTER N WITH TILDE + 0xD2, "Ò", # ISOlat1: LATIN CAPITAL LETTER O WITH GRAVE + 0xD3, "Ó", # ISOlat1: LATIN CAPITAL LETTER O WITH ACUTE + 0xD4, "Ô", # ISOlat1: LATIN CAPITAL LETTER O WITH + # CIRCUMFLEX + 0xD5, "Õ", # ISOlat1: LATIN CAPITAL LETTER O WITH TILDE + 0xD6, "Ö", # ISOlat1: LATIN CAPITAL LETTER O WITH + # DIAERESIS + 0xD7, "×", # ISOnum : MULTIPLICATION SIGN + 0xD8, "Ø", # ISOlat1: LATIN CAPITAL LETTER O WITH STROKE + 0xD9, "Ù", # ISOlat1: LATIN CAPITAL LETTER U WITH GRAVE + 0xDA, "Ú", # ISOlat1: LATIN CAPITAL LETTER U WITH ACUTE + 0xDB, "Û", # ISOlat1: LATIN CAPITAL LETTER U WITH + # CIRCUMFLEX + 0xDC, "Ü", # ISOlat1: LATIN CAPITAL LETTER U WITH + # DIAERESIS + 0xDD, "Ý", # ISOlat1: LATIN CAPITAL LETTER Y WITH ACUTE + 0xDE, "Þ", # ISOlat1: LATIN CAPITAL LETTER THORN + # (Icelandic) + 0xDF, "ß", # ISOlat1: LATIN SMALL LETTER SHARP S (German) + 0xE0, "à", # ISOlat1: LATIN SMALL LETTER A WITH GRAVE + 0xE1, "á", # ISOlat1: LATIN SMALL LETTER A WITH ACUTE + 0xE2, "â", # ISOlat1: LATIN SMALL LETTER A WITH CIRCUMFLEX + 0xE3, "ã", # ISOlat1: LATIN SMALL LETTER A WITH TILDE + 0xE4, "ä", # ISOlat1: LATIN SMALL LETTER A WITH DIAERESIS + 0xE5, "å", # ISOlat1: LATIN SMALL LETTER A WITH RING ABOVE + 0xE6, "æ", # ISOlat1: LATIN SMALL LETTER AE + 0xE7, "ç", # ISOlat1: LATIN SMALL LETTER C WITH CEDILLA + 0xE8, "è", # ISOlat1: LATIN SMALL LETTER E WITH GRAVE + 0xE9, "é", # ISOlat1: LATIN SMALL LETTER E WITH ACUTE + 0xEA, "ê", # ISOlat1: LATIN SMALL LETTER E WITH CIRCUMFLEX + 0xEB, "ë", # ISOlat1: LATIN SMALL LETTER E WITH DIAERESIS + 0xEC, "ì", # ISOlat1: LATIN SMALL LETTER I WITH GRAVE + 0xED, "í", # ISOlat1: LATIN SMALL LETTER I WITH ACUTE + 0xEE, "î", # ISOlat1: LATIN SMALL LETTER I WITH CIRCUMFLEX + 0xEF, "ï", # ISOlat1: LATIN SMALL LETTER I WITH DIAERESIS + 0xF0, "ð", # ISOlat1: LATIN SMALL LETTER ETH (Icelandic) + 0xF1, "ñ", # ISOlat1: LATIN SMALL LETTER N WITH TILDE + 0xF2, "ò", # ISOlat1: LATIN SMALL LETTER O WITH GRAVE + 0xF3, "ó", # ISOlat1: LATIN SMALL LETTER O WITH ACUTE + 0xF4, "ô", # ISOlat1: LATIN SMALL LETTER O WITH CIRCUMFLEX + 0xF5, "õ", # ISOlat1: LATIN SMALL LETTER O WITH TILDE + 0xF6, "ö", # ISOlat1: LATIN SMALL LETTER O WITH DIAERESIS + 0xF7, "÷", # ISOnum : DIVISION SIGN + 0xF8, "ø", # ISOlat1: LATIN SMALL LETTER O WITH STROKE + 0xF9, "ù", # ISOlat1: LATIN SMALL LETTER U WITH GRAVE + 0xFA, "ú", # ISOlat1: LATIN SMALL LETTER U WITH ACUTE + 0xFB, "û", # ISOlat1: LATIN SMALL LETTER U WITH CIRCUMFLEX + 0xFC, "ü", # ISOlat1: LATIN SMALL LETTER U WITH DIAERESIS + 0xFD, "ý", # ISOlat1: LATIN SMALL LETTER Y WITH ACUTE + 0xFE, "þ", # ISOlat1: LATIN SMALL LETTER THORN + # (Icelandic) + 0xFF, "ÿ", # ISOlat1: LATIN SMALL LETTER Y WITH DIAERESIS +); + +##--------------------------------------------------------------------------- +## ISO-8859-2: Latin-2 +##--------------------------------------------------------------------------- + +%ISO_8859_2_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "Ą", # ISOlat2: LATIN CAPITAL LETTER A WITH OGONEK + 0xA2, "˘", # ISOdia : BREVE + 0xA3, "Ł", # ISOlat2: LATIN CAPITAL LETTER L WITH STROKE + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xA5, "Ľ", # ISOlat2: LATIN CAPITAL LETTER L WITH CARON + 0xA6, "Ś", # ISOlat2: LATIN CAPITAL LETTER S WITH ACUTE + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "Š", # ISOlat2: LATIN CAPITAL LETTER S WITH CARON + 0xAA, "Ş", # ISOlat2: LATIN CAPITAL LETTER S WITH CEDILLA + 0xAB, "Ť", # ISOlat2: LATIN CAPITAL LETTER T WITH CARON + 0xAC, "Ź", # ISOlat2: LATIN CAPITAL LETTER Z WITH ACUTE + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "Ž", # ISOlat2: LATIN CAPITAL LETTER Z WITH CARON + 0xAF, "Ż", # ISOlat2: LATIN CAPITAL LETTER Z WITH DOT + # ABOVE + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "ą", # ISOlat2: LATIN SMALL LETTER A WITH OGONEK + 0xB2, "˛", # ISOdia : OGONEK + 0xB3, "ł", # ISOlat2: LATIN SMALL LETTER L WITH STROKE + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "ľ", # ISOlat2: LATIN SMALL LETTER L WITH CARON + 0xB6, "ś", # ISOlat2: LATIN SMALL LETTER S WITH ACUTE + 0xB7, "ˇ", # ISOdia : CARON + 0xB8, "¸", # ISOdia : CEDILLA + 0xB9, "š", # ISOlat2: LATIN SMALL LETTER S WITH CARON + 0xBA, "ş", # ISOlat2: LATIN SMALL LETTER S WITH CEDILLA + 0xBB, "ť", # ISOlat2: LATIN SMALL LETTER T WITH CARON + 0xBC, "ź", # ISOlat2: LATIN SMALL LETTER Z WITH ACUTE + 0xBD, "˝", # ISOdia : DOUBLE ACUTE ACCENT + 0xBE, "ž", # ISOlat2: LATIN SMALL LETTER Z WITH CARON + 0xBF, "ż", # ISOlat2: LATIN SMALL LETTER Z WITH DOT ABOVE + 0xC0, "Ŕ", # ISOlat2: LATIN CAPITAL LETTER R WITH ACUTE + 0xC1, "Á", # ISOlat1: LATIN CAPITAL LETTER A WITH ACUTE + 0xC2, "Â", # ISOlat1: LATIN CAPITAL LETTER A WITH + # CIRCUMFLEX + 0xC3, "Ă", # ISOlat2: LATIN CAPITAL LETTER A WITH BREVE + 0xC4, "Ä", # ISOlat1: LATIN CAPITAL LETTER A WITH + # DIAERESIS + 0xC5, "Ĺ", # ISOlat2: LATIN CAPITAL LETTER L WITH ACUTE + 0xC6, "Ć", # ISOlat2: LATIN CAPITAL LETTER C WITH ACUTE + 0xC7, "Ç", # ISOlat2: LATIN CAPITAL LETTER C WITH CEDILLA + 0xC8, "Č", # ISOlat2: LATIN CAPITAL LETTER C WITH CARON + 0xC9, "É", # ISOlat1: LATIN CAPITAL LETTER E WITH ACUTE + 0xCA, "Ę", # ISOlat2: LATIN CAPITAL LETTER E WITH OGONEK + 0xCB, "Ë", # ISOlat1: LATIN CAPITAL LETTER E WITH + # DIAERESIS + 0xCC, "Ě", # ISOlat2: LATIN CAPITAL LETTER E WITH CARON + 0xCD, "Í", # ISOlat1: LATIN CAPITAL LETTER I WITH ACUTE + 0xCE, "Î", # ISOlat1: LATIN CAPITAL LETTER I WITH + # CIRCUMFLEX + 0xCF, "Ď", # ISOlat2: LATIN CAPITAL LETTER D WITH CARON + 0xD0, "Đ", # ISOlat2: LATIN CAPITAL LETTER D WITH STROKE + 0xD1, "Ń", # ISOlat2: LATIN CAPITAL LETTER N WITH ACUTE + 0xD2, "Ň", # ISOlat2: LATIN CAPITAL LETTER N WITH CARON + 0xD3, "Ó", # ISOlat1: LATIN CAPITAL LETTER O WITH ACUTE + 0xD4, "Ô", # ISOlat1: LATIN CAPITAL LETTER O WITH + # CIRCUMFLEX + 0xD5, "Ő", # ISOlat2: LATIN CAPITAL LETTER O WITH DOUBLE + # ACUTE + 0xD6, "Ö", # ISOlat1: LATIN CAPITAL LETTER O WITH + # DIAERESIS + 0xD7, "×", # ISOnum : MULTIPLICATION SIGN + 0xD8, "Ř", # ISOlat2: LATIN CAPITAL LETTER R WITH CARON + 0xD9, "Ů", # ISOlat2: LATIN CAPITAL LETTER U WITH RING + # ABOVE + 0xDA, "Ú", # ISOlat1: LATIN CAPITAL LETTER U WITH ACUTE + 0xDB, "Ű", # ISOlat2: LATIN CAPITAL LETTER U WITH DOUBLE + # ACUTE + 0xDC, "Ü", # ISOlat1: LATIN CAPITAL LETTER U WITH + # DIAERESIS + 0xDD, "Ý", # ISOlat2: LATIN CAPITAL LETTER Y WITH ACUTE + 0xDE, "Ţ", # ISOlat2: LATIN CAPITAL LETTER T WITH CEDILLA + 0xDF, "ß", # ISOlat1: LATIN SMALL LETTER SHARP S (German) + 0xE0, "ŕ", # ISOlat2: LATIN SMALL LETTER R WITH ACUTE + 0xE1, "á", # ISOlat1: LATIN SMALL LETTER A WITH ACUTE + 0xE2, "â", # ISOlat1: LATIN SMALL LETTER A WITH CIRCUMFLEX + 0xE3, "ă", # ISOlat2: LATIN SMALL LETTER A WITH BREVE + 0xE4, "ä", # ISOlat1: LATIN SMALL LETTER A WITH DIAERESIS + 0xE5, "ĺ", # ISOlat2: LATIN SMALL LETTER L WITH ACUTE + 0xE6, "ć", # ISOlat2: LATIN SMALL LETTER C WITH ACUTE + 0xE7, "ç", # ISOlat1: LATIN SMALL LETTER C WITH CEDILLA + 0xE8, "č", # ISOlat2: LATIN SMALL LETTER C WITH CARON + 0xE9, "é", # ISOlat1: LATIN SMALL LETTER E WITH ACUTE + 0xEA, "ę", # ISOlat2: LATIN SMALL LETTER E WITH OGONEK + 0xEB, "ë", # ISOlat1: LATIN SMALL LETTER E WITH DIAERESIS + 0xEC, "ě", # ISOlat2: LATIN SMALL LETTER E WITH CARON + 0xED, "í", # ISOlat1: LATIN SMALL LETTER I WITH ACUTE + 0xEE, "î", # ISOlat1: LATIN SMALL LETTER I WITH CIRCUMFLEX + 0xEF, "ď", # ISOlat2: LATIN SMALL LETTER D WITH CARON + 0xF0, "đ", # ISOlat2: LATIN SMALL LETTER D WITH STROKE + 0xF1, "ń", # ISOlat2: LATIN SMALL LETTER N WITH ACUTE + 0xF2, "ň", # ISOlat2: LATIN SMALL LETTER N WITH CARON + 0xF3, "ó", # ISOlat1: LATIN SMALL LETTER O WITH ACUTE + 0xF4, "ô", # ISOlat1: LATIN SMALL LETTER O WITH CIRCUMFLEX + 0xF5, "ő", # ISOlat2: LATIN SMALL LETTER O WITH DOUBLE + # ACUTE + 0xF6, "ö", # ISOlat1: LATIN SMALL LETTER O WITH DIAERESIS + 0xF7, "÷", # ISOnum : DIVISION SIGN + 0xF8, "ř", # ISOlat2: LATIN SMALL LETTER R WITH CARON + 0xF9, "ů", # ISOlat2: LATIN SMALL LETTER U WITH RING ABOVE + 0xFA, "ú", # ISOlat1: LATIN SMALL LETTER U WITH ACUTE + 0xFB, "ű", # ISOlat2: LATIN SMALL LETTER U WITH DOUBLE + # ACUTE + 0xFC, "ü", # ISOlat1: LATIN SMALL LETTER U WITH DIAERESIS + 0xFD, "ý", # ISOlat1: LATIN SMALL LETTER Y WITH ACUTE + 0xFE, "ţ", # ISOlat2: LATIN SMALL LETTER T WITH CEDILLA + 0xFF, "˙", # ISOdia : DOT ABOVE +); + +##--------------------------------------------------------------------------- +## ISO-8859-3: Latin-3 +##--------------------------------------------------------------------------- + +%ISO_8859_3_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "Ħ", # ISOlat2: LATIN CAPITAL LETTER H WITH STROKE + 0xA2, "˘", # ISOdia : BREVE + 0xA3, "£", # ISOnum : POUND SIGN + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xA6, "Ĥ", # ISOlat2: LATIN CAPITAL LETTER H WITH + # CIRCUMFLEX + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "İ", # ISOlat2: LATIN CAPITAL LETTER I WITH DOT + # ABOVE + 0xAA, "Ş", # ISOlat2: LATIN CAPITAL LETTER S WITH CEDILLA + 0xAB, "Ğ", # ISOlat2: LATIN CAPITAL LETTER G WITH BREVE + 0xAC, "Ĵ", # ISOlat2: LATIN CAPITAL LETTER J WITH + # CIRCUMFLEX + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAF, "Ż", # ISOlat2: LATIN CAPITAL LETTER Z WITH DOT + # ABOVE + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "ħ", # ISOlat2: LATIN SMALL LETTER H WITH STROKE + 0xB2, "²", # ISOnum : SUPERSCRIPT TWO + 0xB3, "³", # ISOnum : SUPERSCRIPT THREE + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "µ", # ISOnum : MICRO SIGN + 0xB6, "ĥ", # ISOlat2: LATIN SMALL LETTER H WITH + # CIRCUMFLEX + 0xB7, "·", # ISOnum : MIDDLE DOT + 0xB8, "¸", # ISOdia : CEDILLA + 0xB9, "ı", # ISOlat2: LATIN SMALL LETTER I DOTLESS + 0xBA, "ş", # ISOlat2: LATIN SMALL LETTER S WITH CEDILLA + 0xBB, "ğ", # ISOlat2: LATIN SMALL LETTER G WITH BREVE + 0xBC, "ĵ", # ISOlat2: LATIN SMALL LETTER J WITH CIRCUMFLEX + 0xBD, "½", # ISOnum : VULGAR FRACTION ONE HALF + 0xBF, "ż", # ISOlat2: LATIN SMALL LETTER Z WITH DOT ABOVE + 0xC0, "À", # ISOlat1: LATIN CAPITAL LETTER A WITH GRAVE + 0xC1, "Á", # ISOlat1: LATIN CAPITAL LETTER A WITH ACUTE + 0xC2, "Â", # ISOlat1: LATIN CAPITAL LETTER A WITH + # CIRCUMFLEX + 0xC4, "Ä", # ISOlat1: LATIN CAPITAL LETTER A WITH + # DIAERESIS + 0xC5, "Ċ", # ISOlat2: LATIN CAPITAL LETTER C WITH DOT + # ABOVE + 0xC6, "Ĉ", # ISOlat2: LATIN CAPITAL LETTER C WITH + # CIRCUMFLEX + 0xC7, "Ç", # ISOlat2: LATIN CAPITAL LETTER C WITH CEDILLA + 0xC8, "È", # ISOlat1: LATIN CAPITAL LETTER E WITH GRAVE + 0xC9, "É", # ISOlat1: LATIN CAPITAL LETTER E WITH ACUTE + 0xCA, "Ê", # ISOlat2: LATIN CAPITAL LETTER E WITH + # CIRCUMFLEX + 0xCB, "Ë", # ISOlat1: LATIN CAPITAL LETTER E WITH + # DIAERESIS + 0xCC, "Ì", # ISOlat1: LATIN CAPITAL LETTER I WITH GRAVE + 0xCD, "Í", # ISOlat1: LATIN CAPITAL LETTER I WITH ACUTE + 0xCE, "Î", # ISOlat1: LATIN CAPITAL LETTER I WITH + # CIRCUMFLEX + 0xCF, "Ï", # ISOlat1: LATIN CAPITAL LETTER I WITH + # DIAERESIS + 0xD1, "Ñ", # ISOlat1: LATIN CAPITAL LETTER N WITH TILDE + 0xD2, "Ò", # ISOlat1: LATIN CAPITAL LETTER O WITH GRAVE + 0xD3, "Ó", # ISOlat1: LATIN CAPITAL LETTER O WITH ACUTE + 0xD4, "Ô", # ISOlat1: LATIN CAPITAL LETTER O WITH + # CIRCUMFLEX + 0xD5, "Ġ", # ISOlat2: LATIN CAPITAL LETTER G WITH DOT + # ABOVE + 0xD6, "Ö", # ISOlat1: LATIN CAPITAL LETTER O WITH + # DIAERESIS + 0xD7, "×", # ISOnum : MULTIPLICATION SIGN + 0xD8, "Ĝ", # ISOlat2: LATIN CAPITAL LETTER G WITH + # CIRCUMFLEX + 0xD9, "Ù", # ISOlat1: LATIN CAPITAL LETTER U WITH GRAVE + # ABOVE + 0xDA, "Ú", # ISOlat1: LATIN CAPITAL LETTER U WITH ACUTE + 0xDB, "Û", # ISOlat1: LATIN CAPITAL LETTER U WITH + # CIRCUMFLEX + 0xDC, "Ü", # ISOlat1: LATIN CAPITAL LETTER U WITH + # DIAERESIS + 0xDD, "Ŭ", # ISOlat2: LATIN CAPITAL LETTER U WITH BREVE + 0xDE, "Ŝ", # ISOlat2: LATIN CAPITAL LETTER S WITH + # CIRCUMFLEX + 0xDF, "ß", # ISOlat1: LATIN SMALL LETTER SHARP S (German) + 0xE0, "à", # ISOlat1: LATIN SMALL LETTER A WITH GRAVE + 0xE1, "á", # ISOlat1: LATIN SMALL LETTER A WITH ACUTE + 0xE2, "â", # ISOlat1: LATIN SMALL LETTER A WITH CIRCUMFLEX + 0xE4, "ä", # ISOlat1: LATIN SMALL LETTER A WITH DIAERESIS + 0xE5, "ċ", # ISOlat2: LATIN SMALL LETTER C WITH DOT ABOVE + 0xE6, "&ccirce;", # ISOlat2: LATIN SMALL LETTER C WITH + # CIRCUMFLEX + 0xE7, "ç", # ISOlat1: LATIN SMALL LETTER C WITH CEDILLA + 0xE8, "è", # ISOlat1: LATIN SMALL LETTER E WITH GRAVE + 0xE9, "é", # ISOlat2: LATIN SMALL LETTER E WITH ACUTE + 0xEA, "ê", # ISOlat2: LATIN SMALL LETTER E WITH + # CIRCUMFLEX + 0xEB, "ë", # ISOlat1: LATIN SMALL LETTER E WITH DIAERESIS + 0xEC, "ì", # ISOlat1: LATIN SMALL LETTER I WITH GRAVE + 0xED, "í", # ISOlat1: LATIN SMALL LETTER I WITH ACUTE + 0xEE, "î", # ISOlat1: LATIN SMALL LETTER I WITH CIRCUMFLEX + 0xEF, "ï", # ISOlat1: LATIN SMALL LETTER I WITH DIAERESIS + 0xF1, "ñ", # ISOlat1: LATIN SMALL LETTER N WITH TILDE + 0xF2, "ò", # ISOlat1: LATIN SMALL LETTER O WITH GRAVE + 0xF3, "ó", # ISOlat1: LATIN SMALL LETTER O WITH ACUTE + 0xF4, "ô", # ISOlat1: LATIN SMALL LETTER O WITH CIRCUMFLEX + 0xF5, "ġ", # ISOlat2: LATIN SMALL LETTER G WITH DOT ABOVE + 0xF6, "ö", # ISOlat1: LATIN SMALL LETTER O WITH DIAERESIS + 0xF7, "÷", # ISOnum : DIVISION SIGN + 0xF8, "ĝ", # ISOlat2: LATIN SMALL LETTER G WITH + # CIRCUMFLEX + 0xF9, "ù", # ISOlat1: LATIN SMALL LETTER U WITH GRAVE + 0xFA, "ú", # ISOlat1: LATIN SMALL LETTER U WITH ACUTE + 0xFB, "û", # ISOlat1: LATIN SMALL LETTER U WITH + # CIRCUMFLEX + 0xFC, "ü", # ISOlat1: LATIN SMALL LETTER U WITH DIAERESIS + 0xFD, "ŭ", # ISOlat2: LATIN SMALL LETTER U WITH BREVE + 0xFE, "ŝ", # ISOlat2: LATIN SMALL LETTER S WITH + # CIRCUMFLEX + 0xFF, "˙", # ISOdia : DOT ABOVE +); + +##--------------------------------------------------------------------------- +## ISO-8859-4: Latin-4 +##--------------------------------------------------------------------------- + +%ISO_8859_4_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "Ą", # ISOlat2: LATIN CAPITAL LETTER A WITH OGONEK + 0xA2, "ĸ", # ISOlat2: LATIN SMALL LETTER KRA (Greenlandic) + 0xA3, "Ŗ", # ISOlat2: LATIN CAPITAL LETTER R WITH CEDILLA + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xA5, "&Itilde", # ISOlat2: LATIN CAPITAL LETTER I WITH TILDE + 0xA6, "Ļ", # ISOlat2: LATIN CAPITAL LETTER L WITH CEDILLA + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "Š", # ISOlat2: LATIN CAPITAL LETTER S WITH CARON + 0xAA, "Ē", # ISOlat2: LATIN CAPITAL LETTER E WITH MACRON + 0xAB, "Ģ", # ISOlat2: LATIN CAPITAL LETTER G WITH CEDILLA + 0xAC, "Ŧ", # ISOlat2: LATIN CAPITAL LETTER T WITH STROKE + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "&Zcaron", # ISOlat2: LATIN CAPITAL LETTER Z WITH CARON + 0xAF, "¯", # ISOdia : MACRON + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "ą", # ISOlat2: LATIN SMALL LETTER A WITH OGONEK + 0xB2, "˛", # ISOdia : OGONEK + 0xB3, "ŗ", # ISOlat2: LATIN SMALL LETTER R WITH CEDILLA + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "ĩ", # ISOlat2: LATIN SMALL LETTER I WITH TILDE + 0xB6, "ļ", # ISOlat2: LATIN SMALL LETTER L WITH CEDILLA + 0xB7, "ˇ", # ISOdia : CARON + 0xB8, "¸", # ISOdia : CEDILLA + 0xB9, "š", # ISOlat2: LATIN SMALL LETTER S WITH CARON + 0xBA, "ē", # ISOlat2: LATIN SMALL LETTER E WITH MACRON + 0xBB, "&gcedil;", # ISOlat2: LATIN SMALL LETTER G WITH CEDILLA + 0xBC, "ŧ", # ISOlat2: LATIN SMALL LETTER J WITH STROKE + 0xBD, "Ŋ", # ISOlat2: LATIN CAPITAL LETTER ENG (Lappish) + 0xBE, "ž", # ISOlat2: LATIN SMALL LETTER Z WITH CARON + 0xBF, "ŋ", # ISOlat2: LATIN SMALL LETTER ENG (Lappish) + 0xC0, "Ā", # ISOlat1: LATIN CAPITAL LETTER A WITH MACRON + 0xC1, "Á", # ISOlat1: LATIN CAPITAL LETTER A WITH ACUTE + 0xC2, "Â", # ISOlat1: LATIN CAPITAL LETTER A WITH + # CIRCUMFLEX + 0xC3, "Ã", # ISOlat1: LATIN CAPITAL LETTER A WITH TILDE + 0xC4, "Ä", # ISOlat1: LATIN CAPITAL LETTER A WITH + # DIAERESIS + 0xC5, "Å", # ISOlat1: LATIN CAPITAL LETTER A WITH RING + # ABOVE + 0xC6, "Æ", # ISOlat1: LATIN CAPITAL LETTER AE + 0xC7, "Į", # ISOlat2: LATIN CAPITAL LETTER I WITH OGONEK + 0xC8, "Č", # ISOlat2: LATIN CAPITAL LETTER C WITH CARON + 0xC9, "É", # ISOlat1: LATIN CAPITAL LETTER E WITH ACUTE + 0xCA, "Ę", # ISOlat2: LATIN CAPITAL LETTER E WITH OGONEK + 0xCB, "Ë", # ISOlat1: LATIN CAPITAL LETTER E WITH + # DIAERESIS + 0xCC, "Ė", # ISOlat1: LATIN CAPITAL LETTER E WITH DOT + # ABOVE + 0xCD, "Í", # ISOlat1: LATIN CAPITAL LETTER I WITH ACUTE + 0xCE, "Î", # ISOlat1: LATIN CAPITAL LETTER I WITH + # CIRCUMFLEX + 0xCF, "Ī", # ISOlat2: LATIN CAPITAL LETTER I WITH MACRON + 0xD0, "&Dstrok", # ISOlat2: LATIN CAPITAL LETTER D WITH STROKE + 0xD1, "Ņ", # ISOlat2: LATIN CAPITAL LETTER N WITH CEDILLA + 0xD2, "Ō", # ISOlat2: LATIN CAPITAL LETTER O WITH MACRON + 0xD3, "Ķ", # ISOlat2: LATIN CAPITAL LETTER K WITH CEDILLA + 0xD4, "Ô", # ISOlat1: LATIN CAPITAL LETTER O WITH + # CIRCUMFLEX + 0xD5, "Õ", # ISOlat1: LATIN CAPITAL LETTER O WITH TILDE + 0xD6, "Ö", # ISOlat1: LATIN CAPITAL LETTER O WITH + # DIAERESIS + 0xD7, "×", # ISOnum : MULTIPLICATION SIGN + 0xD8, "Ø", # ISOlat1: LATIN CAPITAL LETTER O WITH STROKE + 0xD9, "Ų", # ISOlat2: LATIN CAPITAL LETTER U WITH OGONEK + 0xDA, "Ú", # ISOlat1: LATIN CAPITAL LETTER U WITH ACUTE + 0xDB, "Û", # ISOlat1: LATIN CAPITAL LETTER U WITH + # CIRCUMFLEX + 0xDC, "Ü", # ISOlat1: LATIN CAPITAL LETTER U WITH + # DIAERESIS + 0xDD, "Ũ", # ISOlat2: LATIN CAPITAL LETTER U WITH TILDE + 0xDE, "Ū", # ISOlat2: LATIN CAPITAL LETTER U WITH MACRON + 0xDF, "ß", # ISOlat1: LATIN SMALL LETTER SHARP S (German) + 0xE0, "ā", # ISOlat1: LATIN SMALL LETTER A WITH MACRON + 0xE1, "á", # ISOlat1: LATIN SMALL LETTER A WITH ACUTE + 0xE2, "â", # ISOlat1: LATIN SMALL LETTER A WITH CIRCUMFLEX + 0xE3, "ã", # ISOlat1: LATIN SMALL LETTER A WITH TILDE + 0xE4, "ä", # ISOlat1: LATIN SMALL LETTER A WITH DIAERESIS + 0xE5, "å", # ISOlat1: LATIN SMALL LETTER A WITH RING ABOVE + 0xE6, "æ", # ISOlat1: LATIN SMALL LETTER AE + 0xE7, "į", # ISOlat2: LATIN SMALL LETTER I WITH OGONEK + 0xE8, "č", # ISOlat2: LATIN SMALL LETTER C WITH CARON + 0xE9, "é", # ISOlat2: LATIN SMALL LETTER E WITH ACUTE + 0xEA, "ę", # ISOlat2: LATIN SMALL LETTER E WITH OGONEK + 0xEB, "ë", # ISOlat1: LATIN SMALL LETTER E WITH DIAERESIS + 0xEC, "ė", # ISOlat2: LATIN SMALL LETTER E WITH DOT ABOVE + 0xED, "í", # ISOlat1: LATIN SMALL LETTER I WITH ACUTE + 0xEE, "î", # ISOlat1: LATIN SMALL LETTER I WITH CIRCUMFLEX + 0xEF, "ī", # ISOlat2: LATIN SMALL LETTER I WITH MACRON + 0xF0, "đ", # ISOlat2: LATIN SMALL LETTER D WITH STROKE + 0xF1, "ņ", # ISOlat2: LATIN SMALL LETTER N WITH CEDILLA + 0xF2, "ō", # ISOlat2: LATIN SMALL LETTER O WITH MACRON + 0xF3, "ķ", # ISOlat2: LATIN SMALL LETTER K WITH CEDILLA + 0xF4, "ô", # ISOlat1: LATIN SMALL LETTER O WITH CIRCUMFLEX + 0xF5, "õ", # ISOlat1: LATIN SMALL LETTER O WITH TILDE + 0xF6, "ö", # ISOlat1: LATIN SMALL LETTER O WITH DIAERESIS + 0xF7, "÷", # ISOnum : DIVISION SIGN + 0xF8, "ø", # ISOlat1: LATIN SMALL LETTER O WITH STROKE + 0xF9, "ų", # ISOlat2: LATIN SMALL LETTER U WITH OGONEK + 0xFA, "ú", # ISOlat1: LATIN SMALL LETTER U WITH ACUTE + 0xFB, "û", # ISOlat1: LATIN SMALL LETTER U WITH + # CIRCUMFLEX + 0xFC, "ü", # ISOlat1: LATIN SMALL LETTER U WITH DIAERESIS + 0xFD, "ũ", # ISOlat2: LATIN SMALL LETTER U WITH TILDE + 0xFE, "ū", # ISOlat2: LATIN SMALL LETTER U WITH MACRON + 0xFF, "˙", # ISOdia : DOT ABOVE +); + +##--------------------------------------------------------------------------- +## ISO-8859-5: Cyrillic +##--------------------------------------------------------------------------- + +%ISO_8859_5_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "Ё", # ISOcyr1: CYRILLIC CAPITAL LETTER IO + 0xA2, "Ђ", # ISOcyr2: CYRILLIC CAPITAL LETTER DJE + # (Serbocroatian) + 0xA3, "Ѓ", # ISOcyr2: CYRILLIC CAPITAL LETTER GJE + # (Macedonian) + 0xA4, "Е", # ISOcyr1: CYRILLIC CAPITAL LETTER UKRAINIAN IE + 0xA5, "Ѕ", # ISOcyr2: CYRILLIC CAPITAL LETTER DZE + # (Macedonian) + 0xA6, "І", # ISOcyr2: CYRILLIC CAPITAL LETTER + # BYELORUSSIAN-UKRAINIAN I + 0xA7, "Ї", # ISOcyr2: CYRILLIC CAPITAL LETTER YI + # (Ukrainian) + 0xA8, "Є", # ISOcyr2: CYRILLIC CAPITAL LETTER JE + 0xA9, "Љ", # ISOcyr2: CYRILLIC CAPITAL LETTER LJE + 0xAA, "Њ", # ISOcyr2: CYRILLIC CAPITAL LETTER NJE + 0xAB, "Ћ", # ISOcyr2: CYRILLIC CAPITAL LETTER TSHE + # (Serbocroatian) + 0xAC, "Ќ", # ISOcyr2: CYRILLIC CAPITAL LETTER KJE + # (Macedonian) + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "Ў", # ISOcyr2: CYRILLIC CAPITAL LETTER SHORT U + # (Byelorussian) + 0xAF, "Џ", # ISOcyr2: CYRILLIC CAPITAL LETTER DZHE + 0xB0, "А", # ISOcyr1: CYRILLIC CAPITAL LETTER A + 0xB1, "Б", # ISOcyr1: CYRILLIC CAPITAL LETTER BE + 0xB2, "В", # ISOcyr1: CYRILLIC CAPITAL LETTER VE + 0xB3, "Г", # ISOcyr1: CYRILLIC CAPITAL LETTER GHE + 0xB4, "Д", # ISOcyr1: CYRILLIC CAPITAL LETTER DE + 0xB5, "Е", # ISOcyr1: CYRILLIC CAPITAL LETTER IE + 0xB6, "Ж", # ISOcyr1: CYRILLIC CAPITAL LETTER ZHE + 0xB7, "З", # ISOcyr1: CYRILLIC CAPITAL LETTER ZE + 0xB8, "И", # ISOcyr1: CYRILLIC CAPITAL LETTER I + 0xB9, "Й", # ISOcyr1: CYRILLIC CAPITAL LETTER SHORT I + 0xBA, "К", # ISOcyr1: CYRILLIC CAPITAL LETTER KA + 0xBB, "Л", # ISOcyr1: CYRILLIC CAPITAL LETTER EL + 0xBC, "М", # ISOcyr1: CYRILLIC CAPITAL LETTER EM + 0xBD, "Н", # ISOcyr1: CYRILLIC CAPITAL LETTER EN + 0xBE, "О", # ISOcyr1: CYRILLIC CAPITAL LETTER O + 0xBF, "П", # ISOcyr1: CYRILLIC CAPITAL LETTER PE + 0xC0, "Р", # ISOcyr1: CYRILLIC CAPITAL LETTER ER + 0xC1, "С", # ISOcyr1: CYRILLIC CAPITAL LETTER ES + 0xC2, "Т", # ISOcyr1: CYRILLIC CAPITAL LETTER TE + 0xC3, "У", # ISOcyr1: CYRILLIC CAPITAL LETTER U + 0xC4, "Ф", # ISOcyr1: CYRILLIC CAPITAL LETTER EF + 0xC5, "Х", # ISOcyr1: CYRILLIC CAPITAL LETTER HA + 0xC6, "Ц", # ISOcyr1: CYRILLIC CAPITAL LETTER TSE + 0xC7, "Ч", # ISOcyr1: CYRILLIC CAPITAL LETTER CHE + 0xC8, "Ш", # ISOcyr1: CYRILLIC CAPITAL LETTER SHA + 0xC9, "Щ", # ISOcyr1: CYRILLIC CAPITAL LETTER SHCHA + 0xCA, "Ъ", # ISOcyr1: CYRILLIC CAPITAL LETTER HARD SIGN + 0xCB, "Ы", # ISOcyr1: CYRILLIC CAPITAL LETTER YERU + 0xCC, "Ь", # ISOcyr1: CYRILLIC CAPITAL LETTER SOFT SIGN + 0xCD, "Э", # ISOcyr1: CYRILLIC CAPITAL LETTER E + 0xCE, "Ю", # ISOcyr1: CYRILLIC CAPITAL LETTER YU + 0xCF, "Я", # ISOcyr1: CYRILLIC CAPITAL LETTER YA + 0xD0, "а", # ISOcyr1: CYRILLIC SMALL LETTER A + 0xD1, "б", # ISOcyr1: CYRILLIC SMALL LETTER BE + 0xD2, "в", # ISOcyr1: CYRILLIC SMALL LETTER VE + 0xD3, "г", # ISOcyr1: CYRILLIC SMALL LETTER GHE + 0xD4, "д", # ISOcyr1: CYRILLIC SMALL LETTER DE + 0xD5, "е", # ISOcyr1: CYRILLIC SMALL LETTER IE + 0xD6, "ж", # ISOcyr1: CYRILLIC SMALL LETTER ZHE + 0xD7, "з", # ISOcyr1: CYRILLIC SMALL LETTER ZE + 0xD8, "и", # ISOcyr1: CYRILLIC SMALL LETTER I + 0xD9, "й", # ISOcyr1: CYRILLIC SMALL LETTER SHORT I + 0xDA, "к", # ISOcyr1: CYRILLIC SMALL LETTER KA + 0xDB, "л", # ISOcyr1: CYRILLIC SMALL LETTER EL + 0xDC, "м", # ISOcyr1: CYRILLIC SMALL LETTER EM + 0xDD, "н", # ISOcyr1: CYRILLIC SMALL LETTER EN + 0xDE, "о", # ISOcyr1: CYRILLIC SMALL LETTER O + 0xDF, "п", # ISOcyr1: CYRILLIC SMALL LETTER PE + 0xE0, "р", # ISOcyr1: CYRILLIC SMALL LETTER ER + 0xE1, "с", # ISOcyr1: CYRILLIC SMALL LETTER ES + 0xE2, "т", # ISOcyr1: CYRILLIC SMALL LETTER TE + 0xE3, "у", # ISOcyr1: CYRILLIC SMALL LETTER U + 0xE4, "ф", # ISOcyr1: CYRILLIC SMALL LETTER EF + 0xE5, "х", # ISOcyr1: CYRILLIC SMALL LETTER HA + 0xE6, "ц", # ISOcyr1: CYRILLIC SMALL LETTER TSE + 0xE7, "ч", # ISOcyr1: CYRILLIC SMALL LETTER CHE + 0xE8, "ш", # ISOcyr1: CYRILLIC SMALL LETTER SHA + 0xE9, "щ", # ISOcyr1: CYRILLIC SMALL LETTER SHCHA + 0xEA, "ъ", # ISOcyr1: CYRILLIC SMALL LETTER HARD SIGN + 0xEB, "ы", # ISOcyr1: CYRILLIC SMALL LETTER YERU + 0xEC, "ь", # ISOcyr1: CYRILLIC SMALL LETTER SOFT SIGN + 0xED, "э", # ISOcyr1: CYRILLIC SMALL LETTER E + 0xEE, "ю", # ISOcyr1: CYRILLIC SMALL LETTER YU + 0xEF, "я", # ISOcyr1: CYRILLIC SMALL LETTER YA + 0xF0, "№", # ISOcyr1: NUMERO SIGN + 0xF1, "ё", # ISOcyr1: CYRILLIC SMALL LETTER IO + 0xF2, "ђ", # ISOcyr2: CYRILLIC SMALL LETTER DJE + # (Serbocroatian) + 0xF3, "ѓ", # ISOcyr2: CYRILLIC SMALL LETTER GJE + # (Macedonian) + 0xF4, "е", # ISOcyr1: CYRILLIC SMALL LETTER UKRAINIAN IE + 0xF5, "ѕ", # ISOcyr2: CYRILLIC SMALL LETTER DZE + # (Macedonian) + 0xF6, "і", # ISOcyr2: CYRILLIC SMALL LETTER + # BYELORUSSIAN-UKRAINIAN I + 0xF7, "ї", # ISOcyr2: CYRILLIC SMALL LETTER YI + # (Ukrainian) + 0xF8, "ј", # ISOcyr2: CYRILLIC SMALL LETTER JE + 0xF9, "љ", # ISOcyr2: CYRILLIC SMALL LETTER LJE + 0xFA, "њ", # ISOcyr2: CYRILLIC SMALL LETTER NJE + 0xFB, "ћ", # ISOcyr2: CYRILLIC SMALL LETTER TSHE + # (Serbocroatian) + 0xFC, "ќ", # ISOcyr2: CYRILLIC SMALL LETTER KJE + # (Macedonian) + 0xFD, "§", # ISOnum : SECTION SIGN + 0xFE, "ў", # ISOcyr2: CYRILLIC SMALL LETTER SHORT U + # (Byelorussian) + 0xFF, "џ", # ISOcyr2: CYRILLIC SMALL LETTER DZHE +); + +##--------------------------------------------------------------------------- +## ISO-8859-6: Arabic +##--------------------------------------------------------------------------- +## Note: There is no ISO entities for arabic characters. Some of +## the following are non-standard entity references. "ISOarbc" +## is used as the entity defining the Arabic entities in +## anticipation that ISO will define such an entity. + +%ISO_8859_6_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xAC, "&arcomma;", # ISOarbc: ARABIC COMMA + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xBB, "&arsemi;", # ISOarbc: ARABIC SEMICOLON + 0xBF, "&arquest;", # ISOarbc: ARABIC QUESTION MARK + 0xC1, "&hamz;", # ISOarbc: ARABIC LETTER HAMZA + 0xC2, "&alefmadd;", # ISOarbc: ARABIC LETTER ALEF WITH MADDA ABOVE + 0xC3, "&alefhamz;", # ISOarbc: ARABIC LETTER ALEF WITH HAMZA ABOVE + 0xC4, "&wawhamz;", # ISOarbc: ARABIC LETTER WAW WITH HAMZA ABOVE + 0xC5, "&alefhamz;", # ISOarbc: ARABIC LETTER ALEF WITH HAMZA BELOW + 0xC6, "&yehhamz;", # ISOarbc: ARABIC LETTER YEH WITH HAMZA ABOVE + 0xC7, "&alef;", # ISOarbc: ARABIC LETTER ALEF + 0xC8, "&beh;", # ISOarbc: ARABIC LETTER BEH + 0xC9, "&tehmarb;", # ISOarbc: ARABIC LETTER TEH MARBUTA + 0xCA, "&teh;", # ISOarbc: ARABIC LETTER TEH + 0xCB, "&theh;", # ISOarbc: ARABIC LETTER THEH + 0xCC, "&jeem;", # ISOarbc: ARABIC LETTER JEEM + 0xCD, "&hah;", # ISOarbc: ARABIC LETTER HAH + 0xCE, "&khah;", # ISOarbc: ARABIC LETTER KHAH + 0xCF, "&dal;", # ISOarbc: ARABIC LETTER DAL + 0xD0, "&thal;", # ISOarbc: ARABIC LETTER THAL + 0xD1, "&reh;", # ISOarbc: ARABIC LETTER REH + 0xD2, "&zain;", # ISOarbc: ARABIC LETTER ZAIN + 0xD3, "&seen;", # ISOarbc: ARABIC LETTER SEEN + 0xD4, "&sheen;", # ISOarbc: ARABIC LETTER SHEEN + 0xD5, "&sad;", # ISOarbc: ARABIC LETTER SAD + 0xD6, "&dad;", # ISOarbc: ARABIC LETTER DAD + 0xD7, "&tah;", # ISOarbc: ARABIC LETTER TAH + 0xD8, "&zah;", # ISOarbc: ARABIC LETTER ZAH + 0xD9, "&ain;", # ISOarbc: ARABIC LETTER AIN + 0xDA, "&ghain;", # ISOarbc: ARABIC LETTER GHAIN + 0xE0, "&tatweel;", # ISOarbc: ARABIC TATWEEL + 0xE1, "&feh;", # ISOarbc: ARABIC LETTER FEH + 0xE2, "&qaf;", # ISOarbc: ARABIC LETTER QAF + 0xE3, "&kaf;", # ISOarbc: ARABIC LETTER KAF + 0xE4, "&lam;", # ISOarbc: ARABIC LETTER LAM + 0xE5, "&meem;", # ISOarbc: ARABIC LETTER MEEM + 0xE6, "&noon;", # ISOarbc: ARABIC LETTER NOON + 0xE7, "&heh;", # ISOarbc: ARABIC LETTER HEH + 0xE8, "&waw;", # ISOarbc: ARABIC LETTER WAW + 0xE9, "&alefmaks;", # ISOarbc: ARABIC LETTER ALEF MAKSURA + 0xEA, "&yeh;", # ISOarbc: ARABIC LETTER YEH + 0xEB, "&fathatan;", # ISOarbc: ARABIC FATHATAN + 0xEC, "&dammatan;", # ISOarbc: ARABIC DAMMATAN + 0xED, "&kasratan;", # ISOarbc: ARABIC KASRATAN + 0xEE, "&fatha;", # ISOarbc: ARABIC FATHA + 0xEF, "&damma;", # ISOarbc: ARABIC DAMMA + 0xF0, "&kasra;", # ISOarbc: ARABIC KASRA + 0xF1, "&shadda;", # ISOarbc: ARABIC SHADDA + 0xF2, "&sukun;", # ISOarbc: ARABIC SUKUN +); + +##--------------------------------------------------------------------------- +## ISO-8859-7: Greek +##--------------------------------------------------------------------------- + +%ISO_8859_7_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "‘", # ISOnum : SINGLE HIGH-REVERSED-9 QUOTATION + # MARK + 0xA2, "’", # ISOnum : RIGHT SINGLE QUOTATION MARK + 0xA3, "£", # ISOnum : POUND SIGN + 0xA6, "¦", # ISOnum : BROKEN BAR + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "©", # ISOnum : COPYRIGHT SIGN + 0xAB, "«", # ISOnum : LEFT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xAC, "¬", # ISOnum : NOT SIGN + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAF, "—", # ISOpub : EM DASH + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "±", # ISOnum : PLUS-MINUS SIGN + 0xB2, "²", # ISOnum : SUPERSCRIPT TWO + 0xB3, "³", # ISOnum : SUPERSCRIPT THREE + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "&diagr;", # ISOgrk?: ACUTE ACCENT AND DIAERESIS + # (Tonos and Dialytika) + 0xB6, "&Aacgr;", # ISOgrk2: GREEK CAPITAL LETTER ALPHA WITH + # ACUTE + 0xB7, "·", # ISOnum : MIDDLE DOT + 0xB8, "&Eacgr;", # ISOgrk2: GREEK CAPITAL LETTER EPSILON WITH + # ACUTE + 0xB9, "&EEacgr;", # ISOgrk2: GREEK CAPITAL LETTER ETA WITH ACUTE + 0xBA, "&Iacgr;", # ISOgrk2: GREEK CAPITAL LETTER IOTA WITH ACUTE + 0xBB, "»", # ISOnum : RIGHT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xBC, "&Oacgr;", # ISOgrk2: GREEK CAPITAL LETTER OMICRON WITH + # ACUTE + 0xBD, "½", # ISOnum : VULGAR FRACTION ONE HALF + 0xBE, "&Uacgr;", # ISOgrk2: GREEK CAPITAL LETTER UPSILON WITH + # ACUTE + 0xBF, "&OHacgr;", # ISOgrk2: GREEK CAPITAL LETTER OMEGA WITH + # ACUTE + 0xC0, "&idiagr;", # ISOgrk2: GREEK SMALL LETTER IOTA WITH ACUTE + # AND DIAERESIS + 0xC1, "&Agr;", # ISOgrk1: GREEK CAPITAL LETTER ALPHA + 0xC2, "&Bgr;", # ISOgrk1: GREEK CAPITAL LETTER BETA + 0xC3, "&Ggr;", # ISOgrk1: GREEK CAPITAL LETTER GAMMA + 0xC4, "&Dgr;", # ISOgrk1: GREEK CAPITAL LETTER DELTA + 0xC5, "&Egr;", # ISOgrk1: GREEK CAPITAL LETTER EPSILON + 0xC6, "&Zgr;", # ISOgrk1: GREEK CAPITAL LETTER ZETA + 0xC7, "&EEgr;", # ISOgrk1: GREEK CAPITAL LETTER ETA + 0xC8, "&THgr;", # ISOgrk1: GREEK CAPITAL LETTER THETA + 0xC9, "&Igr;", # ISOgrk1: GREEK CAPITAL LETTER IOTA + 0xCA, "&Kgr;", # ISOgrk1: GREEK CAPITAL LETTER KAPPA + 0xCB, "&Lgr;", # ISOgrk1: GREEK CAPITAL LETTER LAMDA + 0xCC, "&Mgr;", # ISOgrk1: GREEK CAPITAL LETTER MU + 0xCD, "&Ngr;", # ISOgrk1: GREEK CAPITAL LETTER NU + 0xCE, "&Xgr;", # ISOgrk1: GREEK CAPITAL LETTER XI + 0xCF, "&Ogr;", # ISOgrk1: GREEK CAPITAL LETTER OMICRON + 0xD0, "&Pgr;", # ISOgrk1: GREEK CAPITAL LETTER PI + 0xD1, "&Rgr;", # ISOgrk1: GREEK CAPITAL LETTER RHO + 0xD3, "&Sgr;", # ISOgrk1: GREEK CAPITAL LETTER SIGMA + 0xD4, "&Tgr;", # ISOgrk1: GREEK CAPITAL LETTER TAU + 0xD5, "&Ugr;", # ISOgrk1: GREEK CAPITAL LETTER UPSILON + 0xD6, "&PHgr;", # ISOgrk1: GREEK CAPITAL LETTER PHI + 0xD7, "&KHgr;", # ISOgrk1: GREEK CAPITAL LETTER CHI + 0xD8, "&PSgr;", # ISOgrk1: GREEK CAPITAL LETTER PSI + 0xD9, "&OHgr;", # ISOgrk1: GREEK CAPITAL LETTER OMEGA + 0xDA, "&Idigr;", # ISOgrk2: GREEK CAPITAL LETTER IOTA WITH + # DIAERESIS + 0xDB, "&Udigr;", # ISOgrk2: GREEK CAPITAL LETTER UPSILON WITH + # DIAERESIS + 0xDC, "&aacgr;", # ISOgrk2: GREEK SMALL LETTER ALPHA WITH ACUTE + 0xDD, "&eacgr;", # ISOgrk2: GREEK SMALL LETTER EPSILON WITH + # ACUTE + 0xDE, "&eeacgr;", # ISOgrk2: GREEK SMALL LETTER ETA WITH ACUTE + 0xDF, "&iacgr;", # ISOgrk2: GREEK SMALL LETTER IOTA WITH ACUTE + 0xE0, "&udiagr;", # ISOgrk2: GREEK SMALL LETTER UPSILON WITH + # ACUTE AND DIAERESIS + 0xE1, "&agr;", # ISOgrk1: GREEK SMALL LETTER ALPHA + 0xE2, "&bgr;", # ISOgrk1: GREEK SMALL LETTER BETA + 0xE3, "&ggr;", # ISOgrk1: GREEK SMALL LETTER GAMMA + 0xE4, "&dgr;", # ISOgrk1: GREEK SMALL LETTER DELTA + 0xE5, "&egr;", # ISOgrk1: GREEK SMALL LETTER EPSILON + 0xE6, "&zgr;", # ISOgrk1: GREEK SMALL LETTER ZETA + 0xE7, "&eegr;", # ISOgrk1: GREEK SMALL LETTER ETA + 0xE8, "&thgr;", # ISOgrk1: GREEK SMALL LETTER THETA + 0xE9, "&igr;", # ISOgrk1: GREEK SMALL LETTER IOTA + 0xEA, "&kgr;", # ISOgrk1: GREEK SMALL LETTER KAPPA + 0xEB, "&lgr;", # ISOgrk1: GREEK SMALL LETTER LAMDA + 0xEC, "&mgr;", # ISOgrk1: GREEK SMALL LETTER MU + 0xED, "&ngr;", # ISOgrk1: GREEK SMALL LETTER NU + 0xEE, "&xgr;", # ISOgrk1: GREEK SMALL LETTER XI + 0xEF, "&ogr;", # ISOgrk1: GREEK SMALL LETTER OMICRON + 0xF0, "&pgr;", # ISOgrk1: GREEK SMALL LETTER PI + 0xF1, "&rgr;", # ISOgrk1: GREEK SMALL LETTER RHO + 0xF2, "&sfgr;", # ISOgrk1: GREEK SMALL LETTER FINAL SIGMA + 0xF3, "&sgr;", # ISOgrk1: GREEK SMALL LETTER SIGMA + 0xF4, "&tgr;", # ISOgrk1: GREEK SMALL LETTER TAU + 0xF5, "&ugr;", # ISOgrk1: GREEK SMALL LETTER UPSILON + 0xF6, "&phgr;", # ISOgrk1: GREEK SMALL LETTER PHI + 0xF7, "&khgr;", # ISOgrk1: GREEK SMALL LETTER CHI + 0xF8, "&psgr;", # ISOgrk1: GREEK SMALL LETTER PSI + 0xF9, "&ohgr;", # ISOgrk1: GREEK SMALL LETTER OMEGA + 0xFA, "&idigr;", # ISOgrk2: GREEK SMALL LETTER IOTA WITH + # DIAERESIS + 0xFB, "&udigr;", # ISOgrk2: GREEK SMALL LETTER UPSILON WITH + # DIAERESIS + 0xFC, "&oacgr;", # ISOgrk2: GREEK SMALL LETTER OMICRON WITH + # ACUTE + 0xFD, "&uacgr;", # ISOgrk2: GREEK SMALL LETTER UPSILON WITH + # ACUTE + 0xFE, "&ohacgr;", # ISOgrk2: GREEK SMALL LETTER OMEGA WITH ACUTE +); + +##--------------------------------------------------------------------------- +## ISO-8859-8: Hebrew +##--------------------------------------------------------------------------- +## Note: There is no ISO entities for hebrew characters. ISOamso +## defines a few characters, but they are for math purposes. +## Some of the following are non-standard entity references. +## "ISOhbrw" is used as the entity defining the Hebrew entities +## in anticipation that ISO will define such an entity. + +%ISO_8859_8_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA2, "¢", # ISOnum : CENT SIGN + 0xA3, "£", # ISOnum : POUND SIGN + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xA5, "¥", # ISOnum : YEN SIGN + 0xA6, "¦", # ISOnum : BROKEN BAR + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "©", # ISOnum : COPYRIGHT SIGN + 0xAA, "×", # ISOnum : MULTIPLICATION SIGN + 0xAB, "«", # ISOnum : LEFT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xAC, "¬", # ISOnum : NOT SIGN + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "®", # ISOnum : REGISTERED SIGN + 0xAF, "¯", # ISOdia : OVERLINE (MACRON) + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "±", # ISOnum : PLUS-MINUS SIGN + 0xB2, "²", # ISOnum : SUPERSCRIPT TWO + 0xB3, "³", # ISOnum : SUPERSCRIPT THREE + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "µ", # ISOnum : MICRO SIGN + 0xB6, "¶", # ISOnum : PILCROW SIGN + 0xB7, "·", # ISOnum : MIDDLE DOT + 0xB8, "¸", # ISOdia : CEDILLA + 0xB9, "¹", # ISOnum : SUPERSCRIPT ONE + 0xBA, "÷", # ISOlat1: DIVISION SIGN + 0xBB, "»", # ISOnum : RIGHT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xBC, "¼", # ISOnum : VULGAR FRACTION ONE QUARTER + 0xBD, "½", # ISOnum : VULGAR FRACTION ONE HALF + 0xBE, "¾", # ISOnum : VULGAR FRACTION THREE QUARTERS + 0xDF, "&dlowbar;", # ISOnum?: DOUBLE LOW LINE + 0xE0, "&alef;", # ISOhbrw: HEBREW LETTER ALEF + 0xE1, "&bet;", # ISOhbrw: HEBREW LETTER BET + 0xE2, "ℷ", # ISOhbrw: HEBREW LETTER GIMEL + 0xE3, "&dalet;", # ISOhbrw: HEBREW LETTER DALET + 0xE4, "&he;", # ISOhbrw: HEBREW LETTER HE + 0xE5, "&vav;", # ISOhbrw: HEBREW LETTER VAV + 0xE6, "&zayin;", # ISOhbrw: HEBREW LETTER ZAYIN + 0xE7, "&het;", # ISOhbrw: HEBREW LETTER HET + 0xE8, "&tet;", # ISOhbrw: HEBREW LETTER TET + 0xE9, "&yod;", # ISOhbrw: HEBREW LETTER YOD + 0xEA, "&fkaf;", # ISOhbrw: HEBREW LETTER FINAL KAF + 0xEB, "&kaf;", # ISOhbrw: HEBREW LETTER KAF + 0xEC, "&lamed;", # ISOhbrw: HEBREW LETTER LAMED + 0xED, "&fmem;", # ISOhbrw: HEBREW LETTER FINAL MEM + 0xEE, "&mem;", # ISOhbrw: HEBREW LETTER MEM + 0xEF, "&fnun;", # ISOhbrw: HEBREW LETTER FINAL NUN + 0xF0, "&nun;", # ISOhbrw: HEBREW LETTER NUN + 0xF1, "&samekh;", # ISOhbrw: HEBREW LETTER SAMEKH + 0xF2, "&ayin;", # ISOhbrw: HEBREW LETTER AYIN + 0xF3, "&fpe;", # ISOhbrw: HEBREW LETTER FINAL PE + 0xF4, "&pe;", # ISOhbrw: HEBREW LETTER PE + 0xF5, "&ftsadi;", # ISOhbrw: HEBREW LETTER FINAL TSADI + 0xF6, "&tsadi;", # ISOhbrw: HEBREW LETTER TSADI + 0xF7, "&qof;", # ISOhbrw: HEBREW LETTER QOF + 0xF8, "&resh;", # ISOhbrw: HEBREW LETTER RESH + 0xF9, "&shin;", # ISOhbrw: HEBREW LETTER SHIN + 0xFA, "&tav;", # ISOhbrw: HEBREW LETTER TAV +); + +##--------------------------------------------------------------------------- +## ISO-8859-9: Latin-5 +##--------------------------------------------------------------------------- + +%ISO_8859_9_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "¡", # ISOnum : INVERTED EXCLAMATION MARK + 0xA2, "¢", # ISOnum : CENT SIGN + 0xA3, "£", # ISOnum : POUND SIGN + 0xA4, "¤", # ISOnum : CURRENCY SIGN + 0xA5, "¥", # ISOnum : YEN SIGN + 0xA6, "¦", # ISOnum : BROKEN BAR + 0xA7, "§", # ISOnum : SECTION SIGN + 0xA8, "¨", # ISOdia : DIAERESIS + 0xA9, "©", # ISOnum : COPYRIGHT SIGN + 0xAA, "ª", # ISOnum : FEMININE ORDINAL INDICATOR + 0xAB, "«", # ISOnum : LEFT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xAC, "¬", # ISOnum : NOT SIGN + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "®", # ISOnum : REGISTERED SIGN + 0xAF, "¯", # ISOdia : OVERLINE (MACRON) + 0xB0, "°", # ISOnum : DEGREE SIGN + 0xB1, "±", # ISOnum : PLUS-MINUS SIGN + 0xB2, "²", # ISOnum : SUPERSCRIPT TWO + 0xB3, "³", # ISOnum : SUPERSCRIPT THREE + 0xB4, "´", # ISOdia : ACUTE ACCENT + 0xB5, "µ", # ISOnum : MICRO SIGN + 0xB6, "¶", # ISOnum : PILCROW SIGN + 0xB7, "·", # ISOnum : MIDDLE DOT + 0xB8, "¸", # ISOdia : CEDILLA + 0xB9, "¹", # ISOnum : SUPERSCRIPT ONE + 0xBA, "º", # ISOnum : MASCULINE ORDINAL INDICATOR + 0xBB, "»", # ISOnum : RIGHT-POINTING DOUBLE ANGLE + # QUOTATION MARK + 0xBC, "¼", # ISOnum : VULGAR FRACTION ONE QUARTER + 0xBD, "½", # ISOnum : VULGAR FRACTION ONE HALF + 0xBE, "¾", # ISOnum : VULGAR FRACTION THREE QUARTERS + 0xBF, "¿", # ISOnum : INVERTED QUESTION MARK + 0xC0, "À", # ISOlat1: LATIN CAPITAL LETTER A WITH GRAVE + 0xC1, "Á", # ISOlat1: LATIN CAPITAL LETTER A WITH ACUTE + 0xC2, "Â", # ISOlat1: LATIN CAPITAL LETTER A WITH + # CIRCUMFLEX + 0xC3, "Ã", # ISOlat1: LATIN CAPITAL LETTER A WITH TILDE + 0xC4, "Ä", # ISOlat1: LATIN CAPITAL LETTER A WITH + # DIAERESIS + 0xC5, "Å", # ISOlat1: LATIN CAPITAL LETTER A WITH RING + # ABOVE + 0xC6, "Æ", # ISOlat1: LATIN CAPITAL LETTER AE + 0xC7, "Ç", # ISOlat1: LATIN CAPITAL LETTER C WITH CEDILLA + 0xC8, "È", # ISOlat1: LATIN CAPITAL LETTER E WITH GRAVE + 0xC9, "É", # ISOlat1: LATIN CAPITAL LETTER E WITH ACUTE + 0xCA, "Ê", # ISOlat1: LATIN CAPITAL LETTER E WITH + # CIRCUMFLEX + 0xCB, "Ë", # ISOlat1: LATIN CAPITAL LETTER E WITH + # DIAERESIS + 0xCC, "Ì", # ISOlat1: LATIN CAPITAL LETTER I WITH GRAVE + 0xCD, "Í", # ISOlat1: LATIN CAPITAL LETTER I WITH ACUTE + 0xCE, "Î", # ISOlat1: LATIN CAPITAL LETTER I WITH + # CIRCUMFLEX + 0xCF, "Ï", # ISOlat1: LATIN CAPITAL LETTER I WITH + # DIAERESIS + 0xD0, "Ğ", # ISOlat2: LATIN CAPITAL LETTER G WITH BREVE + 0xD1, "Ñ", # ISOlat1: LATIN CAPITAL LETTER N WITH TILDE + 0xD2, "Ò", # ISOlat1: LATIN CAPITAL LETTER O WITH GRAVE + 0xD3, "Ó", # ISOlat1: LATIN CAPITAL LETTER O WITH ACUTE + 0xD4, "Ô", # ISOlat1: LATIN CAPITAL LETTER O WITH + # CIRCUMFLEX + 0xD5, "Õ", # ISOlat1: LATIN CAPITAL LETTER O WITH TILDE + 0xD6, "Ö", # ISOlat1: LATIN CAPITAL LETTER O WITH + # DIAERESIS + 0xD7, "×", # ISOnum : MULTIPLICATION SIGN + 0xD8, "Ø", # ISOlat1: LATIN CAPITAL LETTER O WITH STROKE + 0xD9, "Ù", # ISOlat1: LATIN CAPITAL LETTER U WITH GRAVE + 0xDA, "Ú", # ISOlat1: LATIN CAPITAL LETTER U WITH ACUTE + 0xDB, "Û", # ISOlat1: LATIN CAPITAL LETTER U WITH + # CIRCUMFLEX + 0xDC, "Ü", # ISOlat1: LATIN CAPITAL LETTER U WITH + # DIAERESIS + 0xDD, "İ", # ISOlat2: LATIN CAPITAL LETTER I WITH DOT + # ABOVE + 0xDE, "Ş", # ISOlat2: LATIN CAPITAL LETTER S WITH CEDILLA + 0xDF, "ß", # ISOlat1: LATIN SMALL LETTER SHARP S (German) + 0xE0, "à", # ISOlat1: LATIN SMALL LETTER A WITH GRAVE + 0xE1, "á", # ISOlat1: LATIN SMALL LETTER A WITH ACUTE + 0xE2, "â", # ISOlat1: LATIN SMALL LETTER A WITH CIRCUMFLEX + 0xE3, "ã", # ISOlat1: LATIN SMALL LETTER A WITH TILDE + 0xE4, "ä", # ISOlat1: LATIN SMALL LETTER A WITH DIAERESIS + 0xE5, "å", # ISOlat1: LATIN SMALL LETTER A WITH RING ABOVE + 0xE6, "æ", # ISOlat1: LATIN SMALL LETTER AE + 0xE7, "ç", # ISOlat1: LATIN SMALL LETTER C WITH CEDILLA + 0xE8, "è", # ISOlat1: LATIN SMALL LETTER E WITH GRAVE + 0xE9, "é", # ISOlat1: LATIN SMALL LETTER E WITH ACUTE + 0xEA, "ę", # ISOlat2: LATIN SMALL LETTER E WITH OGONEK + 0xEB, "ë", # ISOlat1: LATIN SMALL LETTER E WITH DIAERESIS + 0xEC, "ė", # ISOlat2: LATIN SMALL LETTER E WITH DOT ABOVE + 0xED, "í", # ISOlat1: LATIN SMALL LETTER I WITH ACUTE + 0xEE, "î", # ISOlat1: LATIN SMALL LETTER I WITH CIRCUMFLEX + 0xEF, "ī", # ISOlat2: LATIN SMALL LETTER I WITH MACRON + 0xF0, "ğ", # ISOlat2: LATIN SMALL LETTER G WITH BREVE + 0xF1, "ñ", # ISOlat1: LATIN SMALL LETTER N WITH TILDE + 0xF2, "ò", # ISOlat1: LATIN SMALL LETTER O WITH GRAVE + 0xF3, "ó", # ISOlat1: LATIN SMALL LETTER O WITH ACUTE + 0xF4, "ô", # ISOlat1: LATIN SMALL LETTER O WITH CIRCUMFLEX + 0xF5, "õ", # ISOlat1: LATIN SMALL LETTER O WITH TILDE + 0xF6, "ö", # ISOlat1: LATIN SMALL LETTER O WITH DIAERESIS + 0xF7, "÷", # ISOlat1: DIVISION SIGN + 0xF8, "ø", # ISOlat1: LATIN SMALL LETTER O WITH STROKE + 0xF9, "ù", # ISOlat1: LATIN SMALL LETTER U WITH GRAVE + 0xFA, "ú", # ISOlat1: LATIN SMALL LETTER U WITH ACUTE + 0xFB, "û", # ISOlat1: LATIN SMALL LETTER U WITH CIRCUMFLEX + 0xFC, "ü", # ISOlat1: LATIN SMALL LETTER U WITH DIAERESIS + 0xFD, "ı", # ISOlat2: LATIN SMALL LETTER I DOTLESS + 0xFE, "ş", # ISOlat2: LATIN SMALL LETTER S WITH CEDILLA + 0xFF, "ÿ", # ISOlat1: LATIN SMALL LETTER Y WITH DIAERESIS +); + +##--------------------------------------------------------------------------- +## ISO-8859-10: Latin-6 +##--------------------------------------------------------------------------- + +%ISO_8859_10_To_Ent = ( + #-------------------------------------------------------------------------- + # Hex Code Entity Ref # ISO external entity and description + #-------------------------------------------------------------------------- + 0xA1, "Ą", # ISOlat1: LATIN CAPITAL LETTER A WITH OGONEK + 0xA2, "Ē", # ISOlat2: LATIN CAPITAL LETTER E WITH MACRON + 0xA3, "Ģ", # ISOlat2: LATIN CAPITAL LETTER G WITH CEDILLA + 0xA4, "Ī", # ISOlat2: LATIN CAPITAL LETTER I WITH MACRON + 0xA5, "Ĩ", # ISOlat2: LATIN CAPITAL LETTER I WITH TILDE + 0xA6, "Ķ", # ISOlat2: LATIN CAPITAL LETTER K WITH CEDILLA + 0xA7, "Ļ", # ISOlat2: LATIN CAPITAL LETTER L WITH CEDILLA + 0xA8, "Ń", # ISOlat2: LATIN CAPITAL LETTER N WITH ACUTE + 0xA9, "Ŗ", # ISOlat2: LATIN CAPITAL LETTER R WITH CEDILLA + 0xAA, "Š", # ISOlat2: LATIN CAPITAL LETTER S WITH CARON + 0xAB, "Ŧ", # ISOlat2: LATIN CAPITAL LETTER T WITH STROKE + 0xAC, "Ž", # ISOlat2: LATIN CAPITAL LETTER Z WITH CARON + 0xAD, "­", # ISOnum : SOFT HYPHEN + 0xAE, "ĸ", # ISOlat2: LATIN SMALL LETTER KRA (Greenlandic) + 0xAF, "&end;", # ISOlat?: LATIN SMALL LETTER END (Lappish) + 0xB0, "đ", # ISOlat2: LATIN SMALL LETTER d WITH STROKE + 0xB1, "ą", # ISOlat2: LATIN SMALL LETTER a WITH OGONEK + 0xB2, "ē", # ISOlat2: LATIN SMALL LETTER e WITH MACRON + 0xB3, "&gcedil;", # ISOlat2: LATIN SMALL LETTER g WITH CEDILLA + 0xB4, "ī", # ISOlat2: LATIN SMALL LETTER i WITH MACRON + 0xB5, "ĩ", # ISOlat2: LATIN SMALL LETTER i WITH TILDE + 0xB6, "ķ", # ISOlat2: LATIN SMALL LETTER k WITH CEDILLA + 0xB7, "ļ", # ISOlat2: LATIN SMALL LETTER l WITH CEDILLA + 0xB8, "ń", # ISOlat2: LATIN SMALL LETTER n WITH ACUTE + 0xB9, "ŗ", # ISOlat2: LATIN SMALL LETTER r WITH CEDILLA + 0xBA, "š", # ISOlat2: LATIN SMALL LETTER s WITH CARON + 0xBB, "ŧ", # ISOlat2: LATIN SMALL LETTER t WITH STROKE + 0xBC, "ž", # ISOlat2: LATIN SMALL LETTER z WITH CARON + 0xBD, "§", # ISOnum : SECTION SIGN + 0xBE, "ß", # ISOlat1: LATIN SMALL LETTER SHARP s (German) + 0xBF, "ŋ", # ISOlat2: LATIN SMALL LETTER ENG (Lappish) + 0xC0, "Ā", # ISOlat2: LATIN CAPITAL LETTER A WITH MACRON + 0xC1, "Á", # ISOlat1: LATIN CAPITAL LETTER A WITH ACUTE + 0xC2, "Â", # ISOlat1: LATIN CAPITAL LETTER A WITH + # CIRCUMFLEX + 0xC3, "Ã", # ISOlat1: LATIN CAPITAL LETTER A WITH TILDE + 0xC4, "Ä", # ISOlat1: LATIN CAPITAL LETTER A WITH + # DIAERESIS + 0xC5, "Å", # ISOlat1: LATIN CAPITAL LETTER A WITH RING + # ABOVE + 0xC6, "Æ", # ISOlat1: LATIN CAPITAL LETTER AE + 0xC7, "Į", # ISOlat2: LATIN CAPITAL LETTER I WITH OGONEK + 0xC8, "Č", # ISOlat2: LATIN CAPITAL LETTER C WITH CARON + 0xC9, "É", # ISOlat1: LATIN CAPITAL LETTER E WITH ACUTE + 0xCA, "Ę", # ISOlat2: LATIN CAPITAL LETTER E WITH OGONEK + 0xCB, "Ë", # ISOlat1: LATIN CAPITAL LETTER E WITH + # DIAERESIS + 0xCC, "Ė", # ISOlat2: LATIN CAPITAL LETTER E WITH + # DOT ABOVE + 0xCD, "Í", # ISOlat1: LATIN CAPITAL LETTER I WITH ACUTE + 0xCE, "Î", # ISOlat1: LATIN CAPITAL LETTER I WITH + # CIRCUMFLEX + 0xCF, "Ï", # ISOlat1: LATIN CAPITAL LETTER I WITH + # DIAERESIS + 0xD0, "Đ", # ISOlat2: LATIN CAPITAL LETTER D WITH STROKE + 0xD1, "Ņ", # ISOlat2: LATIN CAPITAL LETTER N WITH CEDILLA + 0xD2, "Ō", # ISOlat2: LATIN CAPITAL LETTER O WITH MACRON + 0xD3, "Ó", # ISOlat1: LATIN CAPITAL LETTER O WITH ACUTE + 0xD4, "Ô", # ISOlat1: LATIN CAPITAL LETTER O WITH + # CIRCUMFLEX + 0xD5, "Õ", # ISOlat1: LATIN CAPITAL LETTER O WITH TILDE + 0xD6, "Ö", # ISOlat1: LATIN CAPITAL LETTER O WITH + # DIAERESIS + 0xD7, "Ũ", # ISOlat2: LATIN CAPITAL LETTER U WITH TILDE + 0xD8, "Ø", # ISOlat1: LATIN CAPITAL LETTER O WITH STROKE + 0xD9, "Ų", # ISOlat2: LATIN CAPITAL LETTER U WITH OGONEK + 0xDA, "Ú", # ISOlat1: LATIN CAPITAL LETTER U WITH ACUTE + 0xDB, "Û", # ISOlat1: LATIN CAPITAL LETTER U WITH + # CIRCUMFLEX + 0xDC, "Ü", # ISOlat1: LATIN CAPITAL LETTER U WITH + # DIAERESIS + 0xDD, "Ý", # ISOlat1: LATIN CAPITAL LETTER Y WITH ACUTE + 0xDE, "Þ", # ISOlat1: LATIN CAPITAL LETTER THORN + # (Icelandic) + 0xDF, "Ū", # ISOlat2: LATIN CAPITAL LETTER U WITH MACRON + 0xE0, "ā", # ISOlat2: LATIN SMALL LETTER a WITH MACRON + 0xE1, "á", # ISOlat1: LATIN SMALL LETTER a WITH ACUTE + 0xE2, "â", # ISOlat1: LATIN SMALL LETTER a WITH CIRCUMFLEX + 0xE3, "ã", # ISOlat1: LATIN SMALL LETTER a WITH TILDE + 0xE4, "ä", # ISOlat1: LATIN SMALL LETTER a WITH DIAERESIS + 0xE5, "å", # ISOlat1: LATIN SMALL LETTER a WITH RING ABOVE + 0xE6, "æ", # ISOlat1: LATIN SMALL LETTER ae + 0xE7, "į", # ISOlat2: LATIN SMALL LETTER i WITH OGONEK + 0xE8, "č", # ISOlat2: LATIN SMALL LETTER c WITH CARON + 0xE9, "é", # ISOlat1: LATIN SMALL LETTER e WITH ACUTE + 0xEA, "ę", # ISOlat2: LATIN SMALL LETTER e WITH OGONEK + 0xEB, "ë", # ISOlat1: LATIN SMALL LETTER e WITH DIAERESIS + 0xEC, "ė", # ISOlat2: LATIN SMALL LETTER e WITH DOT ABOVE + 0xED, "í", # ISOlat1: LATIN SMALL LETTER i WITH ACUTE + 0xEE, "î", # ISOlat1: LATIN SMALL LETTER i WITH CIRCUMFLEX + 0xEF, "ï", # ISOlat1: LATIN SMALL LETTER i WITH DIAERESIS + 0xF0, "ð", # ISOlat1: LATIN SMALL LETTER ETH (Icelandic) + 0xF1, "ņ", # ISOlat2: LATIN SMALL LETTER n WITH CEDILLA + 0xF2, "ō", # ISOlat2: LATIN SMALL LETTER o WITH MACRON + 0xF3, "ó", # ISOlat1: LATIN SMALL LETTER o WITH ACUTE + 0xF4, "ô", # ISOlat1: LATIN SMALL LETTER o WITH CIRCUMFLEX + 0xF5, "õ", # ISOlat1: LATIN SMALL LETTER o WITH TILDE + 0xF6, "ö", # ISOlat1: LATIN SMALL LETTER o WITH DIAERESIS + 0xF7, "ũ", # ISOlat2: LATIN SMALL LETTER u WITH TILDE + 0xF8, "ø", # ISOlat1: LATIN SMALL LETTER o WITH STROKE + 0xF9, "ų", # ISOlat2: LATIN SMALL LETTER u WITH OGONEK + 0xFA, "ú", # ISOlat1: LATIN SMALL LETTER u WITH ACUTE + 0xFB, "û", # ISOlat1: LATIN SMALL LETTER u WITH CIRCUMFLEX + 0xFC, "ü", # ISOlat1: LATIN SMALL LETTER u WITH DIAERESIS + 0xFD, "ý", # ISOlat1: LATIN SMALL LETTER y WITH ACUTE + 0xFE, "þ", # ISOlat1: LATIN SMALL LETTER THORN (Icelandic) + 0xFF, "ū", # ISOlat2: LATIN SMALL LETTER u WITH MACRON +); + +############################################################################### +## Routines +############################################################################### + +##---------------------------------------------------------------------------## +## str2sgml converts a string encoded by $charset to an sgml +## string where special characters are converted to entity +## references. +## +## $return_data = iso_8859'str2sgml($data, $charset); +## +sub str2sgml { + local($data, $charset) = ($_[0], $_[1]); + local($ret, $offset, $len) = ('', 0, 0); + + # Get mapping (this method works for Perl 4 and 5) + $charset =~ tr/a-z/A-Z/; + $charset =~ tr/-/_/; + local(*map) = ("${charset}_To_Ent"); + + # Convert string + $len = length($data); + while ($offset < $len) { + $char = unpack("C", substr($data, $offset++, 1)); + $ret .= ($map{$char} || $US_ASCII_To_Ent{$char} || pack("C", $char)); + } + $ret; +} +##---------------------------------------------------------------------------## + +1; diff --git a/lib/mhdb.pl b/lib/mhdb.pl index ffa3d3b..2681b2e 100644 --- a/lib/mhdb.pl +++ b/lib/mhdb.pl @@ -1,15 +1,13 @@ ##---------------------------------------------------------------------------## ## File: -## mhdb.pl +## @(#) mhdb.pl 1.10 97/05/13 11:00:54 @(#) ## Author: -## Earl Hood ehood@isogen.com +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## MHonArc library defining routines for outputing database. -## Date: -## Tue Mar 12 13:07:30 CST 1996 ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -26,28 +24,25 @@ ## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ##---------------------------------------------------------------------------## -package main; - ##--------------------------------------------------------------------------- ## output_db() spits out the state of mhonarc to a file. This ## (database) file contains information to update mail threading ## when incremental adding is done. The actual database file ## is a Perl program defining all the internal data structures. All -## mhonarc does is 'require' it when updating. This is really +## mhonarc does is 'require' it when updating. This is ## fast and avoids storing mail threading info in the HTML message ## files -- which would require opening every file to perform ## updates. ## sub output_db { - if (open(DB, "> ${OUTDIR}${DIRSEP}${DBFILE}")) { + local($pathname) = shift; + if (open(DB, "> $pathname")) { - print DB "## MHonArc ($VERSION) database/state information\n", - "## This file is needed to perform updates to the archive\n", - "## DO NOT MODIFY.\n", - "##\n"; + print DB "## MHonArcDB\n"; &print_var(DB, 'DbVERSION', *VERSION); &print_assoc(DB, 'ContentType', *ContentType); + &print_assoc(DB, 'CustomRcVars', *CustomRcVars); &print_assoc(DB, 'Date', *Date); &print_assoc(DB, 'Derived', *Derived); &print_assoc(DB, 'FieldODefs', *FieldODefs); @@ -58,76 +53,226 @@ sub output_db { &print_assoc(DB, 'HeadHeads', *HeadHeads); &print_assoc(DB, 'Icons', *Icons); &print_assoc(DB, 'IndexNum', *IndexNum); - &print_assoc(DB, 'MIMEFilters', *MIMEFilters); - &print_assoc(DB, 'MIMEFiltersArgs', *MIMEFiltersArgs); + &print_assoc(DB, "main'MIMECharSetConverters", + *main'MIMECharSetConverters); + &print_assoc(DB, "main'MIMEFilters", *main'MIMEFilters); + &print_assoc(DB, "main'MIMEFiltersArgs", *main'MIMEFiltersArgs); &print_assoc(DB, 'MsgId', *MsgId); &print_assoc(DB, 'Refs', *Refs); &print_assoc(DB, 'Subject', *Subject); + &print_assoc(DB, 'UDerivedFile', *UDerivedFile); + &print_assoc(DB, 'Zone', *Zone); + &print_array(DB, 'CharSetRequires', *CharSetRequires); &print_array(DB, 'FieldOrder', *FieldOrder); + &print_array(DB, 'Months', *Months); + &print_array(DB, 'months', *months); &print_array(DB, 'OtherIdxs', *OtherIdxs); &print_array(DB, 'PerlINC', *PerlINC); &print_array(DB, 'Requires', *Requires); + &print_array(DB, 'TListOrder', *TListOrder); + &print_array(DB, 'Weekdays', *Weekdays); + &print_array(DB, 'weekdays', *weekdays); + + ## I should use a hash for this stuff instead of + ## individual variables - &print_var(DB, 'BOTLINKS', *BOTLINKS); &print_var(DB, 'DOCURL', *DOCURL); + &print_var(DB, 'DecodeHeads', *DecodeHeads); + &print_var(DB, 'DoFolRefs', *DoFolRefs); + &print_var(DB, 'ExpireDate', *ExpireDate); + &print_var(DB, 'ExpireTime', *ExpireTime); &print_var(DB, 'FROM', *FROM); - &print_var(DB, 'IDXNAME', *IDXNAME); - &print_var(DB, 'IDXPGBEG', *IDXPGBEG); - &print_var(DB, 'IDXPGEND', *IDXPGEND); + &print_var(DB, 'GMTDateFmt', *GMTDateFmt); &print_var(DB, 'IDXSIZE', *IDXSIZE); - &print_var(DB, 'LIBEG', *LIBEG); - &print_var(DB, 'LIEND', *LIEND); - &print_var(DB, 'LITMPL', *LITMPL); + &print_var(DB, 'LocalDateFmt', *LocalDateFmt); &print_var(DB, 'MAILTOURL', *MAILTOURL); + &print_var(DB, 'MAIN', *MAIN); &print_var(DB, 'MAXSIZE', *MAXSIZE); + &print_var(DB, 'MHPATTERN', *MHPATTERN); + &print_var(DB, 'MODTIME', *MODTIME); &print_var(DB, 'MSGFOOT', *MSGFOOT); + &print_var(DB, 'MsgGMTDateFmt', *MsgGMTDateFmt); &print_var(DB, 'MSGHEAD', *MSGHEAD); - &print_var(DB, 'MSGPGBEG', *MSGPGBEG); - &print_var(DB, 'MSGPGEND', *MSGPGEND); - &print_var(DB, 'NEXTBL', *NEXTBL); - &print_var(DB, 'NEXTBUTTON', *NEXTBUTTON); - &print_var(DB, 'NEXTBUTTONIA', *NEXTBUTTONIA); - &print_var(DB, 'NEXTFL', *NEXTFL); - &print_var(DB, 'NEXTLINK', *NEXTLINK); - &print_var(DB, 'NEXTLINKIA', *NEXTLINKIA); + &print_var(DB, 'MsgLocalDateFmt', *MsgLocalDateFmt); + &print_var(DB, 'MULTIIDX', *MULTIIDX); &print_var(DB, 'NOMAILTO', *NOMAILTO); &print_var(DB, 'NONEWS', *NONEWS); &print_var(DB, 'NOSORT', *NOSORT); &print_var(DB, 'NOURL', *NOURL); &print_var(DB, 'NumOfMsgs', *NumOfMsgs); - &print_var(DB, 'PREVBUTTON', *PREVBUTTON); - &print_var(DB, 'PREVBUTTONIA', *PREVBUTTONIA); - &print_var(DB, 'PREVLINK', *PREVLINK); - &print_var(DB, 'PREVLINKIA', *PREVLINKIA); - &print_var(DB, 'REVSORT', *REVSORT); - &print_var(DB, 'SUBSORT', *SUBSORT); - &print_var(DB, 'TFOOT', *TFOOT); - &print_var(DB, 'THEAD', *THEAD); + &print_var(DB, 'NumOfPages', *NumOfPages); &print_var(DB, 'THREAD', *THREAD); - &print_var(DB, 'TIDXNAME', *TIDXNAME); - &print_var(DB, 'TIDXPGBEG', *TIDXPGBEG); - &print_var(DB, 'TIDXPGEND', *TIDXPGEND); - &print_var(DB, 'TITLE', *TITLE); - &print_var(DB, 'TLEVELS', *TLEVELS); - &print_var(DB, 'TLITXT', *TLITXT); - &print_var(DB, 'TOPLINKS', *TOPLINKS); - &print_var(DB, 'TREVERSE', *TREVERSE); - &print_var(DB, 'TTITLE', *TTITLE); + + # Main index resources + if ($MAIN) { + &print_var(DB, 'AUTHSORT', *AUTHSORT); + &print_var(DB, 'IDXNAME', *IDXNAME); + &print_var(DB, 'IDXPREFIX', *IDXPREFIX); + &print_var(DB, 'REVSORT', *REVSORT); + &print_var(DB, 'SUBSORT', *SUBSORT); + &print_var(DB, 'TITLE', *TITLE); + + &print_var(DB, 'AUTHBEG', *AUTHBEG) + unless $IsDefault{'AUTHBEG'}; + &print_var(DB, 'AUTHEND', *AUTHEND) + unless $IsDefault{'AUTHEND'}; + &print_var(DB, 'DAYBEG', *DAYBEG) + unless $IsDefault{'DAYBEG'}; + &print_var(DB, 'DAYEND', *DAYEND) + unless $IsDefault{'DAYEND'}; + &print_var(DB, 'IDXLABEL', *IDXLABEL) + unless $IsDefault{'IDXLABEL'}; + &print_var(DB, 'IDXPGBEG', *IDXPGBEG) + unless $IsDefault{'IDXPGBEG'}; + &print_var(DB, 'IDXPGEND', *IDXPGEND) + unless $IsDefault{'IDXPGEND'}; + &print_var(DB, 'LIBEG', *LIBEG) + unless $IsDefault{'LIBEG'}; + &print_var(DB, 'LIEND', *LIEND) + unless $IsDefault{'LIEND'}; + &print_var(DB, 'LITMPL', *LITMPL) + unless $IsDefault{'LITMPL'}; + &print_var(DB, 'NEXTPGLINK', *NEXTPGLINK) + unless $IsDefault{'NEXTPGLINK'}; + &print_var(DB, 'NEXTPGLINKIA', *NEXTPGLINKIA) + unless $IsDefault{'NEXTPGLINKIA'}; + &print_var(DB, 'PREVPGLINK', *PREVPGLINK) + unless $IsDefault{'PREVPGLINK'}; + &print_var(DB, 'PREVPGLINKIA', *PREVPGLINKIA) + unless $IsDefault{'PREVPGLINKIA'}; + &print_var(DB, 'SUBJECTBEG', *SUBJECTBEG) + unless $IsDefault{'SUBJECTBEG'}; + &print_var(DB, 'SUBJECTEND', *SUBJECTEND) + unless $IsDefault{'SUBJECTEND'}; + } + + # Thread index resources + if ($THREAD) { + &print_var(DB, 'TIDXNAME', *TIDXNAME); + &print_var(DB, 'TIDXPREFIX', *TIDXPREFIX); + &print_var(DB, 'TLEVELS', *TLEVELS); + &print_var(DB, 'TREVERSE', *TREVERSE); + &print_var(DB, 'TTITLE', *TTITLE); + + &print_var(DB, 'TCONTBEG', *TCONTBEG) + unless $IsDefault{'TCONTBEG'}; + &print_var(DB, 'TCONTEND', *TCONTEND) + unless $IsDefault{'TCONTEND'}; + &print_var(DB, 'TFOOT', *TFOOT) + unless $IsDefault{'TFOOT'}; + &print_var(DB, 'THEAD', *THEAD) + unless $IsDefault{'THEAD'}; + &print_var(DB, 'TIDXLABEL', *TIDXLABEL) + unless $IsDefault{'TIDXLABEL'}; + &print_var(DB, 'TIDXPGBEG', *TIDXPGBEG) + unless $IsDefault{'TIDXPGBEG'}; + &print_var(DB, 'TIDXPGEND', *TIDXPGEND) + unless $IsDefault{'TIDXPGEND'}; + &print_var(DB, 'TINDENTBEG', *TINDENTBEG) + unless $IsDefault{'TINDENTBEG'}; + &print_var(DB, 'TINDENTEND', *TINDENTEND) + unless $IsDefault{'TINDENTEND'}; + &print_var(DB, 'TLIEND', *TLIEND) + unless $IsDefault{'TLIEND'}; + &print_var(DB, 'TLINONE', *TLINONE) + unless $IsDefault{'TLINONE'}; + &print_var(DB, 'TLINONEEND', *TLINONEEND) + unless $IsDefault{'TLINONEEND'}; + &print_var(DB, 'TLITXT', *TLITXT) + unless $IsDefault{'TLITXT'}; + &print_var(DB, 'TNEXTPGLINK', *TNEXTPGLINK) + unless $IsDefault{'TNEXTPGLINK'}; + &print_var(DB, 'TNEXTPGLINKIA', *TNEXTPGLINKIA) + unless $IsDefault{'TNEXTPGLINKIA'}; + &print_var(DB, 'TPREVPGLINK', *TPREVPGLINK) + unless $IsDefault{'TPREVPGLINK'}; + &print_var(DB, 'TPREVPGLINKIA', *TPREVPGLINKIA) + unless $IsDefault{'TPREVPGLINKIA'}; + &print_var(DB, 'TSINGLETXT', *TSINGLETXT) + unless $IsDefault{'TSINGLETXT'}; + &print_var(DB, 'TSUBJECTBEG', *TSUBJECTBEG) + unless $IsDefault{'TSUBJECTBEG'}; + &print_var(DB, 'TSUBJECTEND', *TSUBJECTEND) + unless $IsDefault{'TSUBJECTEND'}; + &print_var(DB, 'TSUBLISTBEG', *TSUBLISTBEG) + unless $IsDefault{'TSUBLISTBEG'}; + &print_var(DB, 'TSUBLISTEND', *TSUBLISTEND) + unless $IsDefault{'TSUBLISTEND'}; + &print_var(DB, 'TTOPBEG', *TTOPBEG) + unless $IsDefault{'TTOPBEG'}; + &print_var(DB, 'TTOPEND', *TTOPEND) + unless $IsDefault{'TTOPEND'}; + } + + &print_var(DB, 'BOTLINKS', *BOTLINKS) + unless $IsDefault{'BOTLINKS'}; + &print_var(DB, 'FIELDSBEG', *FIELDSBEG) + unless $IsDefault{'FIELDSBEG'}; + &print_var(DB, 'FIELDSEND', *FIELDSEND) + unless $IsDefault{'FIELDSEND'}; + &print_var(DB, 'FLDBEG', *FLDBEG) + unless $IsDefault{'FLDBEG'}; + &print_var(DB, 'FLDEND', *FLDEND) + unless $IsDefault{'FLDEND'}; + &print_var(DB, 'HEADBODYSEP ', *HEADBODYSEP) + unless $IsDefault{'HEADBODYSEP'}; + &print_var(DB, 'LABELBEG', *LABELBEG) + unless $IsDefault{'LABELBEG'}; + &print_var(DB, 'LABELEND', *LABELEND) + unless $IsDefault{'LABELEND'}; + &print_var(DB, 'MSGPGBEG', *MSGPGBEG) + unless $IsDefault{'MSGPGBEG'}; + &print_var(DB, 'MSGPGEND', *MSGPGEND) + unless $IsDefault{'MSGPGEND'}; + &print_var(DB, 'NEXTBUTTON', *NEXTBUTTON) + unless $IsDefault{'NEXTBUTTON'}; + &print_var(DB, 'NEXTBUTTONIA', *NEXTBUTTONIA) + unless $IsDefault{'NEXTBUTTONIA'}; + &print_var(DB, 'NEXTLINK', *NEXTLINK) + unless $IsDefault{'NEXTLINK'}; + &print_var(DB, 'NEXTLINKIA', *NEXTLINKIA) + unless $IsDefault{'NEXTLINKIA'}; + &print_var(DB, 'PREVBUTTON', *PREVBUTTON) + unless $IsDefault{'PREVBUTTON'}; + &print_var(DB, 'PREVBUTTONIA', *PREVBUTTONIA) + unless $IsDefault{'PREVBUTTONIA'}; + &print_var(DB, 'PREVLINK', *PREVLINK) + unless $IsDefault{'PREVLINK'}; + &print_var(DB, 'PREVLINKIA', *PREVLINKIA) + unless $IsDefault{'PREVLINKIA'}; + &print_var(DB, 'TNEXTBUTTON', *TNEXTBUTTON) + unless $IsDefault{'TNEXTBUTTON'}; + &print_var(DB, 'TNEXTBUTTONIA', *TNEXTBUTTONIA) + unless $IsDefault{'TNEXTBUTTONIA'}; + &print_var(DB, 'TNEXTLINK', *TNEXTLINK) + unless $IsDefault{'TNEXTLINK'}; + &print_var(DB, 'TNEXTLINKIA', *TNEXTLINKIA) + unless $IsDefault{'TNEXTLINKIA'}; + &print_var(DB, 'TOPLINKS', *TOPLINKS) + unless $IsDefault{'TOPLINKS'}; + &print_var(DB, 'TPREVBUTTON', *TPREVBUTTON) + unless $IsDefault{'TPREVBUTTON'}; + &print_var(DB, 'TPREVBUTTONIA', *TPREVBUTTONIA) + unless $IsDefault{'TPREVBUTTONIA'}; + &print_var(DB, 'TPREVLINK', *TPREVLINK) + unless $IsDefault{'TPREVLINK'}; + &print_var(DB, 'TPREVLINKIA', *TPREVLINKIA) + unless $IsDefault{'TPREVLINKIA'}; &print_var(DB, 'UMASK', *UMASK); - print DB "1;\n"; + print DB "1;\n"; # for require } else { - warn "Warning: Unable to create ${OUTDIR}${DIRSEP}${DBFILE}\n"; + warn "Warning: Unable to create database, $pathname\n"; } } ##--------------------------------------------------------------------------- sub print_assoc { local($handle, $name, *assoc) = @_; - print $handle "%$name = (\n"; + print $handle "%$name=(\n"; foreach (keys %assoc) { - print $handle qq{'}, &escape_str($_), qq{', '}, + print $handle qq{'}, &escape_str($_), qq{','}, &escape_str($assoc{$_}), qq{',\n}; } print $handle ");\n"; @@ -136,7 +281,7 @@ sub print_assoc { sub print_array { local($handle, $name, *array) = @_; - print $handle "\@$name = (\n"; + print $handle "\@$name=(\n"; foreach (@array) { print $handle qq{'}, &escape_str($_), qq{',\n}; } @@ -146,8 +291,8 @@ sub print_array { sub print_var { local($handle, $name, *var, $d) = @_; - print $handle qq{\$$name = '}, &escape_str($var), qq{'}; - print $handle qq{ unless defined(\$$name)} if $d; + print $handle qq{\$$name='}, &escape_str($var), qq{'}; + print $handle qq{ unless defined(\$$name)} if $d; print $handle qq{;\n}; } ##--------------------------------------------------------------------------- diff --git a/lib/mhdysub.pl b/lib/mhdysub.pl new file mode 100644 index 0000000..976f211 --- /dev/null +++ b/lib/mhdysub.pl @@ -0,0 +1,69 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) mhdysub.pl 1.2 97/02/17 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Definition of create_routines() that creates routines are +## runtime. +##---------------------------------------------------------------------------## +## MHonArc -- Internet mail-to-HTML converter +## Copyright (C) 1996 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +##--------------------------------------------------------------------------- +## create_routines is used to dynamically create routines that +## would benefit from being create at run-time. Routines +## that have to check against several regular expressions +## are candidates. +## +sub create_routines { + local($sub) = ''; + + ##----------------------------------------------------------------------- + ## exclude_field: Used to determine if field should be excluded from + ## message header + ## + $sub =<<'EndOfRoutine'; + sub exclude_field { + local($f) = shift; + local($pat, $ret); + $ret = 0; + EXC_FIELD_SW: { +EndOfRoutine + + # Create switch block for checking field against regular + # expressions (a large || statement could also work). + foreach $pat (keys %HFieldsExc) { + $sub .= join('', + 'if ($f =~ /^', + $pat, + '/i) { $ret = 1; last EXC_FIELD_SW; }', + "\n"); + } + + $sub .=<<'EndOfRoutine'; + } + $ret; + } +EndOfRoutine + + eval $sub; + die("ERROR: Unable to create exclude_field routine:\n$@\n") if $@; +} +##---------------------------------------------------------------------------## +1; diff --git a/lib/mhexternal.pl b/lib/mhexternal.pl index a7157d1..5a4b516 100644 --- a/lib/mhexternal.pl +++ b/lib/mhexternal.pl @@ -1,10 +1,8 @@ ##---------------------------------------------------------------------------## ## File: -## mhexternal.pl +## @(#) mhexternal.pl 1.11 97/05/13 11:23:46 @(#) ## Author: -## Earl Hood ehood@isogen.com -## Date: -## Fri Jul 12 08:34:55 CDT 1996 +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Library defines a routine for MHonArc to filter content-types ## that cannot be directly filtered into HTML, but a linked to an @@ -17,11 +15,11 @@ ## ## ## Where '*/*' represents various content-types. See code below for -## all subtypes. +## all types supported. ## ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -40,150 +38,144 @@ package m2h_external; -##--------------------------------------------------------------------------- -## Global variables - -$pre = ''; # Prefix to generated files -$ext = ''; # Extension for files -$ctype = ''; # Content-type of data -$TYPE = ''; # English name for data type %ExtCnt = (); # Array of filename counters for generated files -$inline = 0; # Can be changed by filter argument - -##--------------------------------------------------------------------------- -## All that should be required is to add to, or edit, the %AppExt and -## %AppType arrays for new, or changed, application suptypes. - -$UnknownExt = 'xxx'; +$UnknownExt = 'bin'; $UnknownType = 'Unrecognized Data'; +$SubDir = 0; %CTExt = ( -## Content-Type Filename extension -##--------------------------------------------------------- - 'application/mac-binhex40', 'hqx', - 'application/octet-stream', 'bin', - 'application/oda', 'oda', - 'application/pdf', 'pdf', - 'application/postscript', 'ps', - 'application/rtf', 'rtf', - 'application/x-bcpio', 'bcpio', - 'application/x-cpio', 'cpio', - 'application/x-csh', 'csh', - 'application/x-dvi', 'dvi', - 'application/x-gtar', 'gtar', - 'application/x-hdf', 'hdf', - 'application/x-latex', 'latex', - 'application/x-mif', 'mif', - 'application/x-netcdf', 'cdf', - 'application/x-sh', 'sh', - 'application/x-shar', 'shar', - 'application/x-sv4cpio', 'sv4cpio', - 'application/x-sv4crc', 'sv4crc', - 'application/x-tar', 'tar', - 'application/x-tcl', 'tcl', - 'application/x-tex', 'tex', - 'application/x-texinfo', 'texinfo', - 'application/x-troff', 'roff', - 'application/x-troff-man', 'man', - 'application/x-troff-me', 'me', - 'application/x-troff-ms', 'ms', - 'application/x-ustar', 'ustar', - 'application/x-wais-source', 'src', - 'application/zip', 'zip', - 'audio/basic', 'snd', - 'audio/x-aiff', 'aif', - 'audio/x-wav', 'wav', - 'image/gif', 'gif', - 'image/ief', 'ief', - 'image/jpeg', 'jpg', - 'image/tiff', 'tif', - 'image/x-bmp', 'bmp', - 'image/x-cmu-raster', 'ras', - 'image/x-pict', 'pict', - 'image/x-portable-anymap', 'pnm', - 'image/x-pnm', 'pnm', - 'image/x-portable-bitmap', 'pbm', - 'image/x-pbm', 'pbm', - 'image/x-portable-graymap', 'pgm', - 'image/x-pcx', 'pcx', - 'image/x-pgm', 'pgm', - 'image/x-portable-pixmap', 'ppm', - 'image/x-ppm', 'ppm', - 'image/x-rgb', 'rgb', - 'image/x-xbitmap', 'xbm', - 'image/x-xbm', 'xbm', - 'image/x-xpixmap', 'xpm', - 'image/x-xpm', 'xpm', - 'image/x-xwindowdump', 'xwd', - 'image/x-xwd', 'xwd', - 'video/mpeg', 'mpg', - 'video/quicktime', 'mov', - 'video/x-msvideo', 'avi', - 'video/x-sgi-movie', 'movie', -); -%CTType = ( -## Content-Type English name -##--------------------------------------------------------- - 'application/mac-binhex40', 'Mac BinHex file', - 'application/octet-stream', 'Binary data', - 'application/oda', 'ODA file', - 'application/pdf', 'PDF file', - 'application/postscript', 'PostScript file', - 'application/rtf', 'RTF file', - 'application/x-bcpio', 'BCPIO file', - 'application/x-cpio', 'CPIO file', - 'application/x-csh', 'Csh script', - 'application/x-dvi', 'TeX dvi file', - 'application/x-gtar', 'Gtar file', - 'application/x-hdf', 'HDF file', - 'application/x-latex', 'LaTex document', - 'application/x-mif', 'Frame MIF', - 'application/x-netcdf', 'Cdf file', - 'application/x-sh', 'Sh script', - 'application/x-shar', 'Shar file', - 'application/x-sv4cpio', 'SV4Cpio file', - 'application/x-sv4crc', 'SV4Crc file', - 'application/x-tar', 'Tar file', - 'application/x-tcl', 'Tcl script', - 'application/x-tex', 'TeX document', - 'application/x-texinfo', 'TeXInfo file', - 'application/x-troff', 'Troff', - 'application/x-troff-man', 'Troff Man', - 'application/x-troff-me', 'Troff ME', - 'application/x-troff-ms', 'Troff MS', - 'application/x-ustar', 'UStar file', - 'application/x-wais-source', 'WAIS Source', - 'application/zip', 'Zip file', - 'audio/basic', 'Basic audio', - 'audio/x-aiff', 'AIF audio', - 'audio/x-wav', 'WAV audio', - 'image/gif', 'GIF image', - 'image/ief', 'IEF image', - 'image/jpeg', 'JPEG image', - 'image/tiff', 'TIFF image', - 'image/x-bmp', 'Windows bitmap', - 'image/x-cmu-raster', 'CMU raster', - 'image/x-pict', 'Mac PICT image', - 'image/x-portable-anymap', 'Portable anymap', - 'image/x-pnm', 'Portable anymap', - 'image/x-portable-bitmap', 'Portable bitmap', - 'image/x-pbm', 'Portable bitmap', - 'image/x-portable-graymap', 'Portable graymap', - 'image/x-pcx', 'PCX image', - 'image/x-pgm', 'Portable graymap', - 'image/x-portable-pixmap', 'Portable pixmap', - 'image/x-ppm', 'Portable pixmap', - 'image/x-rgb', 'RGB image', - 'image/x-xbitmap', 'X bitmap', - 'image/x-xbm', 'X bitmap', - 'image/x-xpixmap', 'X pixmap', - 'image/x-xpm', 'X pixmap', - 'image/x-xwindowdump', 'X window dump', - 'image/x-xwd', 'X window dump', - 'video/mpeg', 'MPEG movie', - 'video/quicktime', 'QuickTime movie', - 'video/x-msvideo', 'MS video', - 'video/x-sgi-movie', 'SGI Movie', +##----------------------------------------------------------------------- +## Content-Type Extension:Description +##----------------------------------------------------------------------- + 'application/astound', 'asd:Astound presentation', + 'application/fastman', 'lcc:fastman file', + 'application/mac-binhex40', 'hqx:Mac BinHex file', + 'application/mbedlet', 'mbd:mbedlet file', + 'application/msword', 'doc:MS-Word document', + 'application/octet-stream', 'bin:Binary data', + 'application/oda', 'oda:ODA file', + 'application/pdf', 'pdf:PDF file', + 'application/pgp', 'pgp:PGP message', + 'application/pgp-signature', 'pgp:PGP signature', + 'application/postscript', 'ps:PostScript document', + 'application/rtf', 'rtf:RTF file', + 'application/sgml', 'sgml:SGML document', + 'application/studiom', 'smp:Studio M file', + 'application/timbuktu', 'tbt:timbuktu file', + 'application/vnd.ms-excel', 'xls:MS-Excel file', + 'application/vnd.ms-powerpoint', 'ppt:MS-Powerpoint file', + 'application/vnd.ms-project', 'mpp:MS-Project file', + 'application/winhlp', 'hlp:WinHelp document', + 'application/wordperfect5.1', 'hlp:WordPerfect 5.1 document', + 'application/x-NET-Install', 'ins:Net Install file', + 'application/x-asap', 'asp:asap file', + 'application/x-bcpio', 'bcpio:BCPIO file', + 'application/x-cpio', 'cpio:CPIO file', + 'application/x-csh', 'csh:C-Shell script', + 'application/x-dot', 'dot:dot file', + 'application/x-dvi', 'dvi:TeX dvi file', + 'application/x-earthtime', 'etc:Earthtime file', + 'application/x-envoy', 'evy:Envoy file', + 'application/x-excel', 'xls:MS-Excel Spreadsheet', + 'application/x-gtar', 'gtar:GNU tar file', + 'application/x-hdf', 'hdf:HDF file', + 'application/x-javascript', 'js:JavaScript source', + 'application/x-ksh', 'ksh:Korn Shell script', + 'application/x-latex', 'latex:LaTex document', + 'application/x-maker', 'fm:FrameMake document', + 'application/x-mif', 'mif:Frame MIF document', + 'application/x-mocha', 'moc:mocha file', + 'application/x-msaccess', 'mdb:MS-Access database', + 'application/x-mscardfile', 'crd:MS-CardFile', + 'application/x-msclip', 'clp:MS-Clip file', + 'application/x-msmediaview', 'm14:MS-Media View file', + 'application/x-msmetafile', 'wmf:MS-Metafile', + 'application/x-msmoney', 'mny:MS-Money file', + 'application/x-mspublisher', 'pub:MS-Publisher document', + 'application/x-msschedule', 'scd:MS-Schedule file', + 'application/x-msterminal', 'trm:MS-Terminal', + 'application/x-mswrite', 'wri:MS-Write document', + 'application/x-netcdf', 'cdf:Cdf file', + 'application/x-ns-proxy-autoconfig','proxy:Netscape Proxy Auto Config', + 'application/x-patch', 'patch:Patch file', + 'application/x-perl', 'pl:Perl source', + 'application/x-pointplus', 'css:pointplus file', + 'application/x-salsa', 'slc:salsa file', + 'application/x-script', 'script:A script file', + 'application/x-sh', 'sh:Bourne shell script', + 'application/x-shar', 'shar:Shar file', + 'application/x-sprite', 'spr:sprite file', + 'application/x-sv4cpio', 'sv4cpio:SV4Cpio file', + 'application/x-sv4crc', 'sv4crc:SV4Crc file', + 'application/x-tar', 'tar:Tar file', + 'application/x-tcl', 'tcl:Tcl script', + 'application/x-tex', 'tex:TeX document', + 'application/x-texinfo', 'texinfo:TeXInfo document', + 'application/x-timbuktu', 'tbp:timbuktu file', + 'application/x-tkined', 'tki:tkined file', + 'application/x-troff', 'roff:Troff document', + 'application/x-troff-man', 'man:Troff manpage', + 'application/x-troff-me', 'me:Troff ME', + 'application/x-troff-ms', 'ms:Troff MS', + 'application/x-ustar', 'ustar:UStar file', + 'application/x-wais-source', 'src:WAIS Source', + 'application/zip', 'zip:Zip archive', + 'audio/basic', 'snd:Basic audio', + 'audio/echospeech', 'es:Echospeech audio', + 'audio/midi', 'midi:MIDI audio', + 'audio/x-aiff', 'aif:AIF audio', + 'audio/x-epac', 'pae:epac audio', + 'audio/x-midi', 'midi:MIDI audio', + 'audio/x-pac', 'pac:pac audio', + 'audio/x-pn-realaudio', 'ra:PN Realaudio', + 'audio/x-wav', 'wav:Wave audio', + 'image/bmp', 'bmp:Window bitmap', + 'image/cgm', 'cgm:Computer Graphics Metafile', + 'image/fif', 'fif:FIF image', + 'image/gif', 'gif:GIF image', + 'image/ief', 'ief:IEF image', + 'image/ifs', 'ifs:IFS image', + 'image/jpeg', 'jpg:JPEG image', + 'image/png', 'png:PNG image', + 'image/tiff', 'tif:TIFF image', + 'image/vnd', 'dwg:VND image', + 'image/wavelet', 'wi:Wavelet image', + 'image/x-bmp', 'bmp:Windows bitmap', + 'image/x-cmu-raster', 'ras:CMU raster', + 'image/x-pbm', 'pbm:Portable bitmap', + 'image/x-pcx', 'pcx:PCX image', + 'image/x-pgm', 'pgm:Portable graymap', + 'image/x-pict', 'pict:Mac PICT image', + 'image/x-pnm', 'pnm:Portable anymap', + 'image/x-portable-anymap', 'pnm:Portable anymap', + 'image/x-portable-bitmap', 'pbm:Portable bitmap', + 'image/x-portable-graymap', 'pgm:Portable graymap', + 'image/x-portable-pixmap', 'ppm:Portable pixmap', + 'image/x-ppm', 'ppm:Portable pixmap', + 'image/x-rgb', 'rgb:RGB image', + 'image/x-xbitmap', 'xbm:X bitmap', + 'image/x-xbm', 'xbm:X bitmap', + 'image/x-xpixmap', 'xpm:X pixmap', + 'image/x-xpm', 'xpm:X pixmap', + 'image/x-xwd', 'xwd:X window dump', + 'image/x-xwindowdump', 'xwd:X window dump', + 'text/html', 'html:HTML document', + 'text/plain', 'txt:Text document', + 'text/richtext', 'rtx:Richtext document', + 'text/setext', 'stx:Setext document', + 'text/sgml', 'sgml:SGML document', + 'text/x-html', 'html:HTML document', + 'text/x-setext', 'stx:Setext document', + 'text/x-speech', 'talk:Speech document', + 'video/isivideo', 'fvi:isi video', + 'video/mpeg', 'mpg:MPEG movie', + 'video/msvideo', 'avi:MS Video', + 'video/quicktime', 'mov:QuickTime movie', + 'video/vivo', 'viv:vivo video', + 'video/wavelet', 'wv:Wavelet video', + 'video/x-msvideo', 'avi:MS video', + 'video/x-sgi-movie', 'movie:SGI movie', + ); ##--------------------------------------------------------------------------- @@ -192,82 +184,126 @@ package m2h_external; ## Argument string may contain the following values. Each value ## should be separated by a space: ## -## inline => Inline image data with IMG element. -## usename => Use name attribute for determining name -## of derived file. Use this option with caution -## since it can lead to filename conflicts and -## security problems. +## inline Inline image data by default if +## content-disposition not defined. +## +## usename Use (file)name attribute for determining name +## of derived file. Use this option with caution +## since it can lead to filename conflicts and +## security problems. +## +## ext=ext Use `ext' as the filename extension. +## +## type="description" +## Use "description" as type description of the +## data. The double quotes are required. +## +## subdir Place derived files in a subdirectory ## sub filter { local($header, *fields, *data, $isdecode, $args) = @_; - local($ret, $filename, $nameparm); + local($ret, + $filename, + $name, + $nameparm, + $path, + $disp, + $ctype, + $type, + $ext, + $inline, + $inext, + $intype); ## Init variables - $name = ''; - $ctype = ''; - $TYPE = ''; - $ext = ''; - $inline = 0; + $name = ''; + $ctype = ''; + $type = ''; + $ext = ''; + $inline = 0; + $inext = ''; + $intype = ''; ## Get content-type - ($ctype) = $fields{'content-type'} =~ m%^\s*([\w-/]+)%; + ($ctype) = $fields{'content-type'} =~ m%^\s*([\w-\./]+)%; $ctype =~ tr/A-Z/a-z/; - ## See if name argument is to be used - ($nameparm) = $fields{'content-type'} =~ /name=(\S+)/i; - $nameparm =~ s/['";]//g; - $nameparm =~ s/.*[\/\\:]//; # Remove path component + ## Get disposition + ($disp, $nameparm) = &'MAILhead_get_disposition(*fields); + + ## Check if using name if ($args =~ /usename/i) { $name = $nameparm; + } else { + $name = ''; } - ## Check if image inlining - $inline = ($args =~ /inline/i); + ## Chech if file goes in a subdirectory + if ($args =~ /subdir/i) { + $path = join('', 'msg', $'MHAmsgnum, '.dir'); + } else { + $path = ''; + } - ## Determine filename extension - $pre = $ext = $CTExt{$ctype}; $TYPE = $CTType{$ctype}; + ## Check if inlining (images only) + if ($disp) { + $inline = ($disp =~ /inline/i); + } else { + $inline = ($args =~ /inline/i); + } + + ## Check if extension and type description passed in + if ($args =~ /ext=(\S+)/i) { $inext = $1; } + if ($args =~ /type="([^"]+)"/i) { $intype = $1; } + + ## Determine default filename extension + ($ext, $type) = split(/:/, $CTExt{$ctype}, 2); + $ext = $inext if $inext; + $type = $intype if $intype; if (!$ext) { $ext = $UnknownExt; - $TYPE = $UnknownType; + $type = "$UnknownType: $ctype"; } + $pre = $ext; + substr($pre, 3) = "" if length($pre) > 3; # Prune prefix to 3 chars ## Write file - $filename = &write_file(*data); + $filename = &write_file(*data, $path, $name, $pre, $ext); ## Create HTML markup if ($inline && ($ctype =~ /image/i)) { - $ret = join('', "

    ", - &htmlize($fields{'content-description'}), - "\n

    \n", - qq|\n|, - "

    \n"); + $ret = "

    " . &htmlize($fields{'content-description'}) . "

    \n" + if ($fields{'content-description'}); + $ret .= qq{

    \n}; + } else { - $ret = join('', "

    \n", - qq||, - &htmlize($fields{'content-description'}) || - $nameparm || $TYPE, - "

    \n"); + $ret = qq{

    } . + (&htmlize($fields{'content-description'}) || + $nameparm || $type) . + qq{

    \n}; } - ($ret, $filename); + ($ret, $path || $filename); } sub write_file { - local(*stuff) = shift; - local($fname, $tmp, $cnt) = ('', ''); + local(*stuff, $path, $fname, $pre, $ext) = @_; + local($tmp, $cnt) = ('', ''); - if ($name) { - $fname = $name; - } else { - if (!$ExtCnt{$ext}) { &set_cnt(); } + $tmp = $'OUTDIR; + if ($path) { + $tmp .= $'DIRSEP . $path; + mkdir($tmp, 0777); + } + + if (!$fname) { + if (!$ExtCnt{$ext}) { &set_cnt($tmp); } $cnt = $ExtCnt{$ext}++; $fname = $pre . sprintf("%05d.",$cnt) . $ext; + $ExtCnt{$ext} = 0 if $path; } - $tmp = $'OUTDIR . $'DIRSEP . $fname; + $tmp .= $'DIRSEP . $fname; - ## $'OUTDIR is set by MHonArc that specifies destination path - ## of filtered mail. - ## if (open(OUTFILE, "> $tmp")) { binmode(OUTFILE); # For MS-DOS print OUTFILE $stuff; @@ -275,17 +311,20 @@ sub write_file { } else { warn "Warning: Unable to create $tmp\n"; } - $fname; + $path ? $path.$'DIRSEP.$fname : $fname; } sub set_cnt { local(@files) = (); - opendir(DIR, $'OUTDIR); - @files = sort numerically grep(/^$pre\d+\.$ext$/i, readdir(DIR)); - close(DIR); - if (@files) { - ($ExtCnt{$ext}) = $files[$#files] =~ /(\d+)/; - $ExtCnt{$ext}++; + if (opendir(DIR, $_[0])) { + @files = sort numerically grep(/^$pre\d+\.$ext$/i, readdir(DIR)); + close(DIR); + if (@files) { + ($ExtCnt{$ext}) = $files[$#files] =~ /(\d+)/; + $ExtCnt{$ext}++; + } else { + $ExtCnt{$ext} = 0; + } } else { $ExtCnt{$ext} = 0; } @@ -305,4 +344,10 @@ sub htmlize { $txt; } +sub dump_ctext_hash { + foreach (sort keys %CTExt) { + print STDERR $_,":",$CTExt{$_},"\n"; + } +} + 1; diff --git a/lib/mhidxrc.pl b/lib/mhidxrc.pl new file mode 100644 index 0000000..ca57ae1 --- /dev/null +++ b/lib/mhidxrc.pl @@ -0,0 +1,430 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) mhidxrc.pl 1.5 97/05/13 11:24:35 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## MHonArc library defining values for various index resources +##---------------------------------------------------------------------------## +## MHonArc -- Internet mail-to-HTML converter +## Copyright (C) 1996,1997 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +##-----------------## +## Index resources ## +##-----------------## + +$IdxTypeStr = $NOSORT ? 'Message' : + $SUBSORT ? 'Subject' : + $AUTHSORT ? 'Author' : + 'Date'; +if ($MAIN) { + + ## Label for main index + unless ($IDXLABEL) { + $IDXLABEL = $IdxTypeStr . ' Index'; + $IsDefault{'IDXLABEL'} = 1; + } + + ## Beginning of main index page + unless ($IDXPGBEG) { + $IDXPGBEG =<<'EndOfStr'; + + + +$IDXTITLE$ + + +

    $IDXTITLE$

    +EndOfStr + $IsDefault{'IDXPGBEG'} = 1; + } + + ## End of main index page + unless ($IDXPGEND) { + $IDXPGEND = "\n\n"; + $IsDefault{'IDXPGEND'} = 1; + } + + ## Beginning of main index list + unless ($LIBEG) { + $LIBEG = ''; + $LIBEG .= "\n" if $THREAD; + $LIBEG .= '$PREVPGLINK$$NEXTPGLINK$' . "\n" if $MULTIIDX; + $LIBEG .= "
    \n
      \n"; + $IsDefault{'LIBEG'} = 1; + } + + ## End of main index list + unless ($LIEND) { + $LIEND = "
    \n"; + $IsDefault{'LIEND'} = 1; + } + + ## Main index entry (start, content, and end) + unless ($LITMPL) { + $LITMPL =<<'EndOfStr'; +
  • $SUBJECT$ +
    • From: $FROM$
    +
  • +EndOfStr + $IsDefault{'LITMPL'} = 1; + } + + ## Main list group resources + unless ($AUTHBEG) { + $AUTHBEG = ''; $IsDefault{'AUTHBEG'} = 1; + } + unless ($AUTHEND) { + $AUTHEND = ''; $IsDefault{'AUTHEND'} = 1; + } + unless ($DAYBEG) { + $DAYBEG = ''; $IsDefault{'DAYBEG'} = 1; + } + unless ($DAYEND) { + $DAYEND = ''; $IsDefault{'DAYEND'} = 1; + } + unless ($SUBJECTBEG) { + $SUBJECTBEG = ''; $IsDefault{'SUBJECTBEG'} = 1; + } + unless ($SUBJECTEND) { + $SUBJECTEND = ''; $IsDefault{'SUBJECTEND'} = 1; + } +} + +if ($THREAD) { + + ## Label for thread index + unless ($TIDXLABEL) { + $TIDXLABEL = 'Thread Index'; + $IsDefault{'TIDXLABEL'} = 1; + } + + ## Beginning of thread index page + unless ($TIDXPGBEG) { + $TIDXPGBEG =<<'EndOfStr'; + + + +$TIDXTITLE$ + + +

    $TIDXTITLE$

    +EndOfStr + $IsDefault{'TIDXPGBEG'} = 1; + } + ## End of thread index page + unless ($TIDXPGEND) { + $TIDXPGEND = "\n\n"; + $IsDefault{'TIDXPGEND'} = 1; + } + + ## Head of thread index page (also contains list start markup) + unless ($THEAD) { + $THEAD = ''; + $THEAD .= "\n" if $MAIN; + $THEAD .= '$TPREVPGLINK$$TNEXTPGLINK$' . "\n" if $MULTIIDX; + $THEAD .= "
    \n
      \n"; + $IsDefault{'THEAD'} = 1; + } + ## Foot of thread index page (also contains list end markup) + unless ($TFOOT) { + $TFOOT = "
    \n"; + $IsDefault{'TFOOT'} = 1; + } + + ## Template for thread entry with no follow-ups + unless ($TSINGLETXT) { + $TSINGLETXT =<<'EndOfStr'; +
  • $SUBJECT$, +$FROMNAME$
  • +EndOfStr + $IsDefault{'TSINGLETXT'} = 1; + } + + ## Template for thread entry that is the start of a thread + unless ($TTOPBEG) { + $TTOPBEG =<<'EndOfStr'; +
  • $SUBJECT$, +$FROMNAME$ +EndOfStr + $IsDefault{'TTOPBEG'} = 1; + } + ## Template for end of a thread + unless ($TTOPEND) { + $TTOPEND = "
  • \n"; + $IsDefault{'TTOPEND'} = 1; + } + + ## Template for the start of a sub-thread + unless ($TSUBLISTBEG) { + $TSUBLISTBEG = "
      \n"; + $IsDefault{'TSUBLISTBEG'} = 1; + } + ## Template for the end of a sub-thread + unless ($TSUBLISTEND) { + $TSUBLISTEND = "
    \n"; + $IsDefault{'TSUBLISTEND'} = 1; + } + + ## Template for the start and content of a regular thread entry + unless ($TLITXT) { + $TLITXT =<<'EndOfStr'; +
  • $SUBJECT$, +$FROMNAME$ +EndOfStr + $IsDefault{'TLITXT'} = 1; + } + ## Template for end of a regular thread entry + unless ($TLIEND) { + $TLIEND = "
  • \n"; + $IsDefault{'TLIEND'} = 1; + } + + ## Template for the start of subject based section + unless ($TSUBJECTBEG) { + $TSUBJECTBEG = "<Possible follow-up(s)>
    \n"; + $IsDefault{'TSUBJECTBEG'} = 1; + } + ## Template for the end of subject based section + unless ($TSUBJECTEND) { + $TSUBJECTEND = ""; + $IsDefault{'TSUBJECTEND'} = 1; + } + + ## Template for start and content of missing message in thread + unless ($TLINONE) { + $TLINONE = "
  • Message not available"; + $IsDefault{'TLINONE'} = 1; + } + ## Template for end of missing message in thread + unless ($TLINONEEND) { + $TLINONEEND = "
  • \n"; + $IsDefault{'TLINONEEND'} = 1; + } + + ## Template for opening an indent (for cross-page threads) + unless ($TINDENTBEG) { + $TINDENTBEG = "
      \n"; + $IsDefault{'TINDENTBEG'} = 1; + } + ## Template for closing an indent (for cross-page threads) + unless ($TINDENTEND) { + $TINDENTEND = "
    \n"; + $IsDefault{'TINDENTEND'} = 1; + } + + ## Template for start of a continued thread (for cross-page threads) + unless ($TCONTBEG) { + $TCONTBEG = '
  • $SUBJECTNA$, ' . + "(continued)\n"; + $IsDefault{'TCONTBEG'} = 1; + } + ## Template for end of a continued thread (for cross-page threads) + unless ($TCONTEND) { + $TCONTEND = "
  • \n"; + $IsDefault{'TCONTEND'} = 1; + } + + $DoMissingMsgs = $TLINONE =~ /\S/; + +} + +##-------------------## +## Message resources ## +##-------------------## + +## Beginning of message page +unless ($MSGPGBEG) { + $MSGPGBEG =<<'EndOfStr'; + + + +$SUBJECTNA:72$ + + + +EndOfStr + $IsDefault{'MSGPGBEG'} = 1; +} + +## End of message page +unless ($MSGPGEND) { + $MSGPGEND = "\n\n"; + $IsDefault{'MSGPGEND'} = 1; +} + +## Subject header +unless ($SUBJECTHEADER) { + $SUBJECTHEADER = '

    $SUBJECTNA$

    ' . "\n
    \n"; + $IsDefault{'SUBJECTHEADER'} = 1; +} + +## Separator between message data head and message data body +unless ($HEADBODYSEP) { + $HEADBODYSEP = "
    \n"; + $IsDefault{'HEADBODYSEP'} = 1; +} + +##---------------------------------## +## Mail header formating resources ## +##---------------------------------## + +$FIELDSBEG = "
      \n", $IsDefault{'FIELDSBEG'} = 1 unless $FIELDSBEG; +$FIELDSEND = "
    \n", $IsDefault{'FIELDSEND'} = 1 unless $FIELDSEND; +$LABELBEG = "
  • ", $IsDefault{'LABELBEG'} = 1 unless $LABELBEG; +$LABELEND = ":", $IsDefault{'LABELEND'} = 1 unless $LABELEND; +$FLDBEG = " ", $IsDefault{'FLDBEG'} = 1 unless $FLDBEG; +$FLDEND = "
  • ", $IsDefault{'FLDEND'} = 1 unless $FLDEND; + +##-----------------------------------## +## Next/prev message link resources ## +##-----------------------------------## + +## Next/prev buttons +$NEXTBUTTON = '['.$IdxTypeStr.' Next]', + $IsDefault{'NEXTBUTTON'} = 1 unless $NEXTBUTTON; +$PREVBUTTON = '['.$IdxTypeStr.' Prev]', + $IsDefault{'PREVBUTTON'} = 1 unless $PREVBUTTON; +$NEXTBUTTONIA = "[$IdxTypeStr Next]", + $IsDefault{'NEXTBUTTONIA'} = 1 unless $NEXTBUTTONIA; +$PREVBUTTONIA = "[$IdxTypeStr Prev]", + $IsDefault{'PREVBUTTONIA'} = 1 unless $PREVBUTTONIA; + +## Next message link +unless ($NEXTLINK) { + $NEXTLINK =<Next by $IdxTypeStr: +\$NEXTSUBJECT\$ + +EndOfStr + $IsDefault{'NEXTLINK'} = 1; +} + +## Inactive next message link +$NEXTLINKIA = '', $IsDefault{'NEXTLINKIA'} = 1 unless $NEXTLINKIA; + +## Previous message link +unless ($PREVLINK) { + $PREVLINK =<Prev by $IdxTypeStr: +\$PREVSUBJECT\$ + +EndOfStr + $IsDefault{'PREVLINK'} = 1; +} + +## Inactive previous message link +$PREVLINKIA = '', $IsDefault{'PREVLINKIA'} = 1 unless $PREVLINKIA; + +## Thread next/previous buttons +$TNEXTBUTTON = '[Thread Next]', + $IsDefault{'TNEXTBUTTON'} = 1 unless $TNEXTBUTTON; +$TPREVBUTTON = '[Thread Prev]', + $IsDefault{'TPREVBUTTON'} = 1 unless $TPREVBUTTON; +$TNEXTBUTTONIA = '[Thread Next]', + $IsDefault{'TNEXTBUTTONIA'} = 1 unless $TNEXTBUTTONIA; +$TPREVBUTTONIA = '[Thread Prev]', + $IsDefault{'TPREVBUTTONIA'} = 1 unless $TPREVBUTTONIA; + +## Next message in thread link +unless ($TNEXTLINK) { + $TNEXTLINK =<<'EndOfStr'; +
  • Next by thread: +$TNEXTSUBJECT$ +
  • +EndOfStr + $IsDefault{'TNEXTLINK'} = 1; +} + +## Inactive next message in thread link +$TNEXTLINKIA = '', $IsDefault{'TNEXTLINKIA'} = 1 unless $TNEXTLINKIA; + +## Previous message in thread link +unless ($TPREVLINK) { + $TPREVLINK =<<'EndOfStr'; +
  • Prev by thread: +$TPREVSUBJECT$ +
  • +EndOfStr + $IsDefault{'TPREVLINK'} = 1; +} + +## Inactive previous message in thread link +$TPREVLINKIA = '', $IsDefault{'TPREVLINKIA'} = 1 unless $TPREVLINKIA; + +## Top links in message +if (!$TOPLINKS) { + $TOPLINKS = "
    \n"; + $TOPLINKS .= '$PREVBUTTON$$NEXTBUTTON$' + if $MAIN; + $TOPLINKS .= '$TPREVBUTTON$$TNEXTBUTTON$' + if $THREAD; + $TOPLINKS .= '[$IDXLABEL$]' + if $MAIN; + $TOPLINKS .= '[$TIDXLABEL$]' + if $THREAD; + $IsDefault{'TOPLINKS'} = 1; +} + +## Bottom links in message +if (!$BOTLINKS) { + $BOTLINKS = "
    \n
      \n"; + $BOTLINKS .= '$PREVLINK$$NEXTLINK$' if $MAIN; + $BOTLINKS .= '$TPREVLINK$$TNEXTLINK$' if $THREAD; + if ($MAIN || $THREAD) { + $BOTLINKS .= "
    • Index(es):\n\n
    • \n
    \n"; + $IsDefault{'BOTLINKS'} = 1; +} + +##--------------------------------------------## +## Next/previous main/thread index page links ## +##--------------------------------------------## + +$NEXTPGLINK = '[Next Page]', + $IsDefault{'NEXTPGLINK'} = 1 unless $NEXTPGLINK; +$PREVPGLINK = '[Prev Page]', + $IsDefault{'PREVPGLINK'} = 1 unless $PREVPGLINK; +$TNEXTPGLINK = '[Next Page]', + $IsDefault{'TNEXTPGLINK'} = 1 unless $TNEXTPGLINK; +$TPREVPGLINK = '[Prev Page]', + $IsDefault{'TPREVPGLINK'} = 1 unless $TPREVPGLINK; + +$NEXTPGLINKIA = '[Next Page]', + $IsDefault{'NEXTPGLINKIA'} = 1 unless $NEXTPGLINKIA; +$PREVPGLINKIA = '[Prev Page]', + $IsDefault{'PREVPGLINKIA'} = 1 unless $PREVPGLINKIA; +$TNEXTPGLINKIA = '[Next Page]', + $IsDefault{'TNEXTPGLINKIA'} = 1 unless $TNEXTPGLINKIA; +$TPREVPGLINKIA = '[Prev Page]', + $IsDefault{'TPREVPGLINKIA'} = 1 unless $TPREVPGLINKIA; + +## Set unknown icon +$Icons{'unknown'} = $Icons{'text/plain'} unless $Icons{'unknown'}; + +##---------------------------------------------------------------------------## +1; diff --git a/lib/mhinit.pl b/lib/mhinit.pl index 7655e2f..a6ffd8c 100644 --- a/lib/mhinit.pl +++ b/lib/mhinit.pl @@ -1,15 +1,13 @@ ##---------------------------------------------------------------------------## ## File: -## mhinit.pl +## @(#) mhinit.pl 1.18 97/05/13 11:25:03 @(#) ## Author: -## Earl Hood ehood@isogen.com -## Date: -## Fri Jul 12 08:13:02 CDT 1996 +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Initialization stuff for MHonArc. ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995,1996 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -26,12 +24,13 @@ ## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ##---------------------------------------------------------------------------## -package main; - ##---------------------------------------------------------------------------## + ## The %Zone array should be augmented to contain all timezone ## specifications with the positive/negative hour offset from UTC ## (GMT). (There has got to be a better way to handle timezones) +## Array can be augmented/overridden via the resource file. + %Zone = ( "UTC", 0, # Universal Coordinated Time "GMT", 0, # Greenwich Mean Time @@ -46,76 +45,110 @@ package main; "PST", 8, # Pacific Standard Time "PDT", 7, # Pacific Daylight Time ); + ## Assoc array listing mail header fields to exclude in output. ## Each key is treated as a regular expression with '^' prepended ## to it. + %HFieldsExc = ( 'content-', 1, # Mime headers 'errors-to', 1, 'forward', 1, # Forward lines (MH may add these) 'lines', 1, 'message-id', 1, - 'mime-', 1, # Mime headers + 'mime-', 1, # Mime headers 'nntp-', 1, 'originator', 1, 'path', 1, 'precedence', 1, 'received', 1, # MTA added headers - 'replied', 1, - 'return-path', 1, # MH creates this during inc + 'replied', 1, # Replied lines (MH may add these) + 'return-path', 1, # MH/MTA header 'status', 1, 'via', 1, - 'x-', 1, # Non-standard headers + 'x-', 1, # Non-standard headers ); + ## Asocc arrays defining HTML formats to apply to header fields + %HeadFields = ( - "-default-", "", + "-default-", "", # Nothing ); %HeadHeads = ( - "-default-", "em", + "-default-", "em", # Empasize field labels ); -@FieldOrder = ( +@FieldOrder = ( # Order fields are listed 'to', 'subject', 'from', 'date', '-extra-', ); -%FieldODefs = ( +%FieldODefs = ( # Fields not to slurp up in "-extra-" 'to', 1, 'subject', 1, 'from', 1, 'date', 1, ); + +## Message information variables + $NumOfMsgs = 0; # Total number of messages $LastMsgNum = -1; # Message number of last message -%Message = (); # Message bodies -%MsgHead = (); # Message heads +%Message = (); # Message indexes to bodies +%MsgHead = (); # Message indexes to heads %MsgHtml = (); # Flag if message is html -%Subject = (); # Message subjects -%From = (); # Message froms -%Date = (); # Message dates -%MsgId = (); # Message Ids to indexes +%Subject = (); # Message indexes to subjects +%From = (); # Message indexes to froms +%Date = (); # Message indexes to dates +%MsgId = (); # Message ids to indexes +%NewMsgId = (); # New message ids to indexes %IndexNum = (); # Index key to message number -%Derived = (); # Derived files for messages -%Refs = (); # Message references -%Follow = (); # Message follow-ups -%FolCnt = (); # Number of follow-ups -%ContentType = (); # Base content-type of messages -%Icons = (); # Icon URLs for content-types +%Derived = (); # Index key to derived files for message +%Refs = (); # Index key to message references +%Follow = (); # Index key to follow-ups +%FolCnt = (); # Index key to number of follow-ups +%ContentType = (); # Index key to base content-type of message +%Icons = (); # Index key to icon URL for content-type %AddIndex = (); # Flags for messages that must be written -$bs = "\b"; -$Url = '(http://|ftp://|afs://|wais://|telnet://|gopher://|' . - 'news:|nntp:|mid:|cid:|mailto:|prospero:)'; -$MLCP = 0; -$ISLOCK = 0; -$SLOW = 0; -## Get date -$curdate = &getdate(0); -$locdate = &getdate(1); +@MListOrder = (); # List of indexes in order printed on main index +@TListOrder = (); # List of indexes in order printed on thread index +%Index2Tloc = (); # Map index to position in thread index +%Index2Mloc = (); # Map index to position in main index + +%UDerivedFile = (); # Key = filename template. Value = content template + +## Following variables used in thread computation + +@ThreadList = (); # List of messages visible in thread index +@NotIdxThreadList + = (); # List of messages not visible in index +%HasRef = (); # Flags if message has references (Keys = indexes) + # (Values = reference message indexes) +%HasRefDepth = (); # Depth of reference from HasRef value +%Replies = (); # Msg-ids of explicit replies (Keys = indexes) +%SReplies = (); # Msg-ids of subject-based replies (Keys = indexes) +%TVisible = (); # Message visible in thread index (Keys = indexes) +$DoMissingMsgs = 0; # Flag is missing messages should be noted in index + +## Some miscellaneous variables + +%IsDefault = (); # Flags if certain resources are the default + +$bs = "\b"; # Used as a separator +$Url = '(http://|https://|ftp://|afs://|wais://|telnet://|' . + 'gopher://|news:|nntp:|mid:|cid:|mailto:|prospero:)'; +$MLCP = 0; # Main index contains included files flag +$SLOW = 0; # Save memory flag +$NumOfPages = 0; # Number of index pages +$IdxMinPg = -1; # Starting page of index for updating +$TIdxMinPg = -1; # Starting page of thread index for updating +$DBPathName = ''; # Full pathname of database file +$DefRcName = ($MSDOS ? "mhonarc.rc" : ".mhonarc.rc"); ## Set default filter libraries + @Requires = ( "mhexternal.pl", @@ -125,66 +158,22 @@ package main; ); +@CharSetRequires = ( + + "iso8859.pl", + +); + +##---------------------------------------------------------------------- +## BEGIN readmail.pl variable settings +##---------------------------------------------------------------------- ## Default filters -%MIMEFilters = ( - - "application/mac-binhex40", "m2h_external'filter", - "application/octet-stream", "m2h_external'filter", - "application/oda", "m2h_external'filter", - "application/pdf", "m2h_external'filter", - "application/postscript", "m2h_external'filter", - "application/rtf", "m2h_external'filter", - "application/x-bcpio", "m2h_external'filter", - "application/x-cpio", "m2h_external'filter", - "application/x-csh", "m2h_external'filter", - "application/x-dvi", "m2h_external'filter", - "application/x-gtar", "m2h_external'filter", - "application/x-hdf", "m2h_external'filter", - "application/x-latex", "m2h_external'filter", - "application/x-mif", "m2h_external'filter", - "application/x-netcdf", "m2h_external'filter", +## +%main'MIMEFilters = ( + + # Content-type Filter + #------------------------------------------------------------------- "application/x-patch", "m2h_text_plain'filter", - "application/x-sh", "m2h_external'filter", - "application/x-shar", "m2h_external'filter", - "application/x-sv4cpio", "m2h_external'filter", - "application/x-sv4crc", "m2h_external'filter", - "application/x-tar", "m2h_external'filter", - "application/x-tcl", "m2h_external'filter", - "application/x-tex", "m2h_external'filter", - "application/x-texinfo", "m2h_external'filter", - "application/x-troff", "m2h_external'filter", - "application/x-troff-man", "m2h_external'filter", - "application/x-troff-me", "m2h_external'filter", - "application/x-troff-ms", "m2h_external'filter", - "application/x-ustar", "m2h_external'filter", - "application/x-wais-source", "m2h_external'filter", - "application/zip", "m2h_external'filter", - "audio/basic", "m2h_external'filter", - "audio/x-aiff", "m2h_external'filter", - "audio/x-wav", "m2h_external'filter", - "image/gif", "m2h_external'filter", - "image/ief", "m2h_external'filter", - "image/jpeg", "m2h_external'filter", - "image/tiff", "m2h_external'filter", - "image/x-bmp", "m2h_external'filter", - "image/x-cmu-raster", "m2h_external'filter", - "image/x-pbm", "m2h_external'filter", - "image/x-pcx", "m2h_external'filter", - "image/x-pgm", "m2h_external'filter", - "image/x-pict", "m2h_external'filter", - "image/x-pnm", "m2h_external'filter", - "image/x-portable-anymap", "m2h_external'filter", - "image/x-portable-bitmap", "m2h_external'filter", - "image/x-portable-graymap", "m2h_external'filter", - "image/x-portable-pixmap", "m2h_external'filter", - "image/x-ppm", "m2h_external'filter", - "image/x-rgb", "m2h_external'filter", - "image/x-xbitmap", "m2h_external'filter", - "image/x-xbm", "m2h_external'filter", - "image/x-xpixmap", "m2h_external'filter", - "image/x-xpm", "m2h_external'filter", - "image/x-xwd", "m2h_external'filter", - "image/x-xwindowdump", "m2h_external'filter", "message/partial", "m2h_text_plain'filter", "text/html", "m2h_text_html'filter", "text/plain", "m2h_text_plain'filter", @@ -193,60 +182,188 @@ package main; "text/tab-separated-values", "m2h_text_plain'filter", "text/x-html", "m2h_text_html'filter", "text/x-setext", "m2h_text_setext'filter", - "video/mpeg", "m2h_external'filter", - "video/quicktime", "m2h_external'filter", - "video/x-msvideo", "m2h_external'filter", - "video/x-sgi-movie", "m2h_external'filter", + + "application/*", "m2h_external'filter", + "audio/*", "m2h_external'filter", + "image/*", "m2h_external'filter", + "text/*", "m2h_text_plain'filter", + "video/*", "m2h_external'filter", + + # Nead to add to list if more base types are registered. ); ## Default filter arguments -%MIMEFiltersArgs = ( +## +%main'MIMEFiltersArgs = ( + + # Content-type Arguments + #------------------------------------------------------------------- + "image/gif", "inline", + "image/jpeg", "inline", + "image/x-xbitmap", "inline", + "image/x-xbm", "inline", - "image/gif", "inline", - "image/x-xbitmap", "inline", - "image/x-xbm", "inline", ); +## Charset filters +## +%main'MIMECharSetConverters = ( + + # Character set Converter Function + #------------------------------------------------------------------- + "plain", "main'convert_line", + "us-ascii", "main'convert_line", + "iso-8859-1", "iso_8859'str2sgml", + "iso-8859-2", "iso_8859'str2sgml", + "iso-8859-3", "iso_8859'str2sgml", + "iso-8859-4", "iso_8859'str2sgml", + "iso-8859-5", "iso_8859'str2sgml", + "iso-8859-6", "iso_8859'str2sgml", + "iso-8859-7", "iso_8859'str2sgml", + "iso-8859-8", "iso_8859'str2sgml", + "iso-8859-9", "iso_8859'str2sgml", + "iso-8859-10", "iso_8859'str2sgml", + + "default", "-ignore-", + +); +##------------------------------------------------------------------------ +## END readmail.pl variable settings +##------------------------------------------------------------------------ + +## Variable to hold function for converting message header text. +$MHeadCnvFunc = "convert_line"; + +## Regexp for variable detection +$VarExp = '\$([^\$]*)\$'; + +## Regexp for address/msg-id detection +$AddrExp = q%[^()<>@,;:\/\s"'&|]+@[^()<>@,;:\/\s"'&|]+%; + ## Grab environment variable settings ## -$DBFILE = ($ENV{'M2H_DBFILE'} ? $ENV{'M2H_DBFILE'} : - ($MSDOS ? "mhonarc.db" : ".mhonarc.db")); -$DOCURL = ($ENV{'M2H_DOCURL'} ? $ENV{'M2H_DOCURL'} : - 'http://www.oac.uci.edu/indiv/ehood/mhonarc.html'); -$FOOTER = ($ENV{'M2H_FOOTER'} ? $ENV{'M2H_FOOTER'} : ""); -$HEADER = ($ENV{'M2H_HEADER'} ? $ENV{'M2H_HEADER'} : ""); -$IDXNAME = ($ENV{'M2H_IDXFNAME'} ? $ENV{'M2H_IDXFNAME'} : - "maillist.html"); -$IDXSIZE = ($ENV{'M2H_IDXSIZE'} ? $ENV{'M2H_IDXSIZE'} : ""); -$TIDXNAME = ($ENV{'M2H_TIDXFNAME'} ? $ENV{'M2H_TIDXFNAME'} : - "threads.html"); -$OUTDIR = ($ENV{'M2H_OUTDIR'} ? $ENV{'M2H_OUTDIR'} : $CURDIR); -$FMTFILE = ($ENV{'M2H_RCFILE'} ? $ENV{'M2H_RCFILE'} : ""); -$TTITLE = ($ENV{'M2H_TTITLE'} ? $ENV{'M2H_TTITLE'} : - "Mail Thread Index"); -$TITLE = ($ENV{'M2H_TITLE'} ? $ENV{'M2H_TITLE'} : "Mail Index"); -$MAILTOURL = ($ENV{'M2H_MAILTOURL'} ? $ENV{'M2H_MAILTOURL'} : ""); -$FROM = ($ENV{'M2H_MSGSEP'} ? $ENV{'M2H_MSGSEP'} : '^From '); -$LOCKFILE = ($ENV{'M2H_LOCKFILE'} ? $ENV{'M2H_LOCKFILE'} : - ($MSDOS ? "mhonarc.lck" : ".mhonarc.lck")); -$LOCKTRIES = ($ENV{'M2H_LOCKTRIES'} ? $ENV{'M2H_LOCKTRIES'} : 10); -$LOCKDELAY = ($ENV{'M2H_LOCKDELAY'} ? $ENV{'M2H_LOCKDELAY'} : 3); -$MAXSIZE = ($ENV{'M2H_MAXSIZE'} ? $ENV{'M2H_MAXSIZE'} : ""); -$THREAD = (defined($ENV{'M2H_THREAD'}) ? $ENV{'M2H_THREAD'} : 1); -$TLEVELS = ($ENV{'M2H_TLEVELS'} ? $ENV{'M2H_TLEVELS'} : 3); +$DBFILE = $ENV{'M2H_DBFILE'} || ($MSDOS? "mhonarc.db": ".mhonarc.db"); +$DOCURL = $ENV{'M2H_DOCURL'} || + 'http://www.oac.uci.edu/indiv/ehood/mhonarc.html'; +$FOOTER = $ENV{'M2H_FOOTER'} || ""; +$HEADER = $ENV{'M2H_HEADER'} || ""; +$IDXNAME = $ENV{'M2H_IDXFNAME'} || "maillist.html"; +$IDXPREFIX = $ENV{'M2H_IDXPREFIX'} || "mail"; +$TIDXPREFIX= $ENV{'M2H_TIDXPREFIX'} || "thrd"; +$IDXSIZE = $ENV{'M2H_IDXSIZE'} || ""; +$TIDXNAME = $ENV{'M2H_TIDXFNAME'} || "threads.html"; +$OUTDIR = $ENV{'M2H_OUTDIR'} || $CURDIR; +$FMTFILE = $ENV{'M2H_RCFILE'} || ""; +$TTITLE = $ENV{'M2H_TTITLE'} || "Mail Thread Index"; +$TITLE = $ENV{'M2H_TITLE'} || "Mail Index"; +$MAILTOURL = $ENV{'M2H_MAILTOURL'} || ""; +$FROM = $ENV{'M2H_MSGSEP'} || '^From '; +$LOCKFILE = $ENV{'M2H_LOCKFILE'} || ($MSDOS? "mhonarc.lck": ".mhonarc.lck"); +$LOCKTRIES = $ENV{'M2H_LOCKTRIES'} || 10; +$LOCKDELAY = $ENV{'M2H_LOCKDELAY'} || 3; +$MAXSIZE = $ENV{'M2H_MAXSIZE'} || ""; +$TLEVELS = $ENV{'M2H_TLEVELS'} || 3; +$MHPATTERN = $ENV{'M2H_MHPATTERN'} || '^\d+$'; +$DefRcFile = $ENV{'M2H_DEFRCFILE'} || ''; + +$GMTDateFmt = $ENV{'M2H_GMTDATEFMT'} || ''; +$LocalDateFmt = $ENV{'M2H_LOCALDATEFMT'} || ''; +$ExpireDate = $ENV{'M2H_EXPIREDATE'} || ''; + $ExpireDateTime = 0; +$ExpireTime = $ENV{'M2H_EXPIREAGE'} || 0; + +$MsgGMTDateFmt = $ENV{'M2H_MSGGMTDATEFMT'} || ''; +$MsgLocalDateFmt= $ENV{'M2H_MSGLOCALDATEFMT'} || ''; + +$CONLEN = defined($ENV{'M2H_CONLEN'}) ? $ENV{'M2H_CONLEN'} : 0; +$MAIN = defined($ENV{'M2H_MAIN'}) ? $ENV{'M2H_MAIN'} : 1; +$MULTIIDX = defined($ENV{'M2H_MULTIPG'}) ? $ENV{'M2H_MULTIPG'} : 0; +$MODTIME = defined($ENV{'M2H_MODTIME'}) ? $ENV{'M2H_MODTIME'} : 0; +$NODOC = defined($ENV{'M2H_DOC'}) ? !$ENV{'M2H_DOC'} : 0; +$NOMAILTO = defined($ENV{'M2H_MAILTO'}) ? !$ENV{'M2H_MAILTO'} : 0; +$NONEWS = defined($ENV{'M2H_NEWS'}) ? !$ENV{'M2H_NEWS'} : 0; +$NOSORT = defined($ENV{'M2H_SORT'}) ? !$ENV{'M2H_SORT'} : 0; +$NOURL = defined($ENV{'M2H_URL'}) ? !$ENV{'M2H_SORT'} : 0; +$REVSORT = defined($ENV{'M2H_REVSORT'}) ? $ENV{'M2H_REVSORT'} : 0; +$SUBSORT = defined($ENV{'M2H_SUBSORT'}) ? $ENV{'M2H_SUBSORT'} : 0; +$AUTHSORT = defined($ENV{'M2H_AUTHSORT'}) ? $ENV{'M2H_AUTHSORT'} : 0; +$THREAD = defined($ENV{'M2H_THREAD'}) ? $ENV{'M2H_THREAD'} : 1; +$TREVERSE = defined($ENV{'M2H_TREVERSE'}) ? $ENV{'M2H_TREVERSE'} : 0; + +if ($UNIX) { + eval q/ + $UMASK = defined($ENV{'M2H_UMASK'}) ? + $ENV{'M2H_UMASK'} : sprintf("%o",umask); + /; +} +$DecodeHeads = defined($ENV{'M2H_DECODEHEADS'}) ? $ENV{'M2H_DECODEHEADS'} : 0; +$DoFolRefs = defined($ENV{'M2H_FOLREFS'}) ? $ENV{'M2H_FOLREFS'} : 1; + +@OtherIdxs = defined($ENV{'M2H_OTHERINDEXES'}) ? + split(/:/, $ENV{'M2H_OTHERINDEXES'}) : (); +@PerlINC = defined($ENV{'M2H_PERLINC'}) ? + split(/:/, $ENV{'M2H_PERLINC'}) : (); + +## Arrays for months and weekdays. If empty, the default settings +## in mhtime.pl are used. + +@Months = $ENV{'M2H_MONTHS'} ? split(/:/, $ENV{'M2H_MONTHS'}) : (); +@months = $ENV{'M2H_MONTHSABR'} ? split(/:/, $ENV{'M2H_MONTHSABR'}) : (); +@Weekdays = $ENV{'M2H_WEEKDAYS'} ? split(/:/, $ENV{'M2H_WEEKDAYS'}) : (); +@weekdays = $ENV{'M2H_WEEKDAYSABR'} ? split(/:/, $ENV{'M2H_WEEKDAYSABR'}) : (); + +## Many of the following are set during runtime after the +## database has been read. The variables are listed here +## as a quick reference. +## +$IDXLABEL = ''; # Label for main index $LIBEG = ''; # List open template for main index $LIEND = ''; # List close template for main index $LITMPL = ''; # List item template -$TFOOT = ''; # Thread index footer +$AUTHBEG = ''; # Begin of author group +$AUTHEND = ''; # End of author group +$DAYBEG = ''; # Begin of a day group +$DAYEND = ''; # End of a day group +$SUBJECTBEG = ''; # Begin of subject group +$SUBJECTEND = ''; # End of subject group + +$TIDXLABEL = ''; # Label for thread index $THEAD = ''; # Thread index header -$TLITXT = ''; # Thread index list item template +$TFOOT = ''; # Thread index footer +$TLISTBEG = ''; # Thread list open +$TLISTEND = ''; # Thread list close +$TSINGLETXT = ''; # Single/lone thread entry template +$TTOPBEG = ''; # Top of a thread begin template +$TTOPEND = ''; # Top of a thread end template +$TSUBLISTBEG = ''; # Sub-thread list open +$TSUBLISTEND = ''; # Sub-thread list close +$TLITXT = ''; # Thread list item text +$TLIEND = ''; # Thread list item end +$TLINONE = ''; # List item for missing message in thread +$TLINONEEND = ''; # List item end for missing message in thread +$TSUBJECTBEG = ''; # Pre-text for subject-based items +$TSUBJECTEND = ''; # Post-text for subject-based items +$TINDENTBEG = ''; # Thread indent open +$TINDENTEND = ''; # Thread indent close +$TCONTBEG = ''; # Thread continue open +$TCONTEND = ''; # Thread continue close $MSGFOOT = ''; # Message footer $MSGHEAD = ''; # Message header $TOPLINKS = ''; # Message links at top of message $BOTLINKS = ''; # Message links at bottom of message +$SUBJECTHEADER = ''; # Markup for message main subject line +$HEADBODYSEP = ''; # Markup between mail header and body + +$FIELDSBEG = ''; # Beginning markup for mail header +$FIELDSEND = ''; # End markup for mail header +$FLDBEG = ''; # Beginning markup for field text +$FLDEND = ''; # End markup for field text +$LABELBEG = ''; # Beginning markup for field label +$LABELEND = ''; # End markup for field label + $NEXTBUTTON = ''; # Next button template $NEXTBUTTONIA = ''; # Next inactive button template $PREVBUTTON = ''; # Previous button template @@ -256,6 +373,15 @@ package main; $PREVLINK = ''; # Previous link template $PREVLINKIA = ''; # Previous inactive link template +$TNEXTBUTTON = ''; # Thread Next button template +$TNEXTBUTTONIA = ''; # Thread Next inactive button template +$TPREVBUTTON = ''; # Thread Previous button template +$TPREVBUTTONIA = ''; # Thread Previous inactive button template +$TNEXTLINK = ''; # Thread Next link template +$TNEXTLINKIA = ''; # Thread Next inactive link template +$TPREVLINK = ''; # Thread Previous link template +$TPREVLINKIA = ''; # Thread Previous inactive link template + $IDXPGBEG = ''; # Beginning of main index page $IDXPGEND = ''; # Ending of main index page $TIDXPGBEG = ''; # Beginning of thread index page @@ -264,27 +390,24 @@ package main; $MSGPGBEG = ''; # Beginning of message page $MSGPGEND = ''; # Ending of message page -# $PREVBL = '[Prev]'; # No longer used -# $NEXTBL = '[Next]'; # No longer used -# $IDXBL = '[Index]'; # No longer used -# $TIDXBL = '[Thread]'; # No longer used +$NEXTPGLINK = ''; # Next page link template +$NEXTPGLINKIA = ''; # Next page inactive link template +$PREVPGLINK = ''; # Previous page link template +$PREVPGLINKIA = ''; # Previous page inactive link template -# $PREVFL = 'Prev'; # No longer used -# $NEXTFL = 'Next'; # No longer used -# $IDXFL = 'Index'; # No longer used -# $TIDXFL = 'Thread'; # No longer used +$TNEXTPGLINK = ''; # Thread next page link template +$TNEXTPGLINKIA = ''; # Thread next page inactive link template +$TPREVPGLINK = ''; # Thread previous page link template +$TPREVPGLINKIA = ''; # Thread previous page inactive link template -## Init some flags -## -$NOSORT = 0; $REVSORT = 0; $NONEWS = 0; $TREVERSE = 0; -$NOMAILTO = 0; $NOURL = 0; $SUBSORT = 0; $NODOC = 0; -$TSUBSORT = 0; -$UMASK = sprintf("%o",umask) if $UNIX; +## The following associative array if for defining custom +## resource variables +%CustomRcVars = (); $X = "\034"; # Value separator (should equal $;) # NOTE: Older versions used this variable for # the multiple field separator in parsed - # message headers. $'FieldSep should + # message headers. $readmail'FieldSep should # now be used (readmail.pl). ##---------------------------------------------------------------------------## diff --git a/lib/mhrcfile.pl b/lib/mhrcfile.pl new file mode 100644 index 0000000..2e48811 --- /dev/null +++ b/lib/mhrcfile.pl @@ -0,0 +1,817 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) mhrcfile.pl 1.12 97/05/13 11:25:35 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Routines for parsing resource files +##---------------------------------------------------------------------------## +## MHonArc -- Internet mail-to-HTML converter +## Copyright (C) 1996 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +$RcFileHandleCnt = 0; + +##--------------------------------------------------------------------------- +## read_fmt_file() parses the resource file. The name is misleading. +## (The code for this routine could probably be simplified). +## +sub read_fmt_file { + local($file) = shift; + local($line, $tag, $label, $acro, $hr, $type, $routine, $plfile, + $url, $arg, $tmp, @a); + local($elem, $attr, $override, $handle, $pathhead, $chop); + + $handle = 'FMT' . $RcFileHandleCnt++; + if (!open($handle, $file)) { + warn "Warning: Unable to open resource file: $file\n"; + return 0; + } + if ($file =~ m%(.*[$'DIRSEPREX])%o) { + $pathhead = $1; + } else { + $pathhead = ''; + } + + print STDOUT "Reading resource file: $file ...\n" unless $QUIET; + while ($line = <$handle>) { + next unless $line =~ /^\s*<([^>]+)>/; + ($elem, $attr) = split(' ', $1, 2); + $elem =~ tr/A-Z/a-z/; + $override = ($attr =~ /override/i); + $chop = ($attr =~ /chop/i); + + FMTSW: { + if ($elem eq "authorbegin") { # Begin for author group + $AUTHBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "authorend") { # End for author group + $AUTHEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "authsort") { # Sort msgs by author + $AUTHSORT = 1; + $NOSORT = 0; $SUBSORT = 0; + last FMTSW; + } + if ($elem eq "botlinks") { # Bottom links in message + $BOTLINKS = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "charsetconverters") { # Charset filters + @CharSetRequires = (), %'MIMECharSetConverters = () + if $override; + while ($line = <$handle>) { + last if $line =~ /^\s*<\/charsetconverters\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; + ($type,$routine,$plfile) = split(/:/,$line,3); + $type =~ tr/A-Z/a-z/; + $'MIMECharSetConverters{$type} = $routine; + push(@CharSetRequires, $plfile) if $plfile =~ /\S/; + } + last FMTSW; + } + if ($elem eq "conlen") { + $CONLEN = 1; last FMTSW; + } + if ($elem eq "daybegin") { # Begin for day group + $DAYBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "dayend") { # End for day group + $DAYEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "decodeheads") { + $DecodeHeads = 1; last FMTSW; + } + if ($elem eq "definederived") { # Custom derived file + %UDerivedFile = () if $override; + $line = <$handle>; + last FMTSW if $line =~ /^\s*<\/definederived\s*>/i; + $line =~ s/\s//g; + $UDerivedFile{$line} = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "definevar") { # Custom resource variable + @CustomRcVars = () if $override; + $line = <$handle>; + last FMTSW if $line =~ /^\s*<\/definevar\s*>/i; + $line =~ s/\s//g; + $CustomRcVars{$line} = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "doc") { # Link to documentation + $NODOC = 0; last FMTSW; + } + if ($elem eq "docurl") { # Doc URL + if ($line = &get_elem_last_line($handle, $elem)) { + $DOCURL = $line; + } + last FMTSW; + } + if ($elem eq "dbfile") { # Database file + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $DBFILE = $line; + } + last FMTSW; + } + if ($elem eq "excs") { # Exclude header fields + %HFieldsExc = () if $override; + while ($line = <$handle>) { + last if $line =~ /^\s*<\/excs\s*>/i; + $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; + $HFieldsExc{$line} = 1 if $line; + } + last FMTSW; + } + if ($elem eq "expireage") { # Time in seconds until expire + if (($tmp = &get_elem_int($handle, $elem, 1)) ne '') { + $ExpireTime = $tmp; + } + last FMTSW; + } + if ($elem eq "expiredate") { # Expiration date + if ($line = &get_elem_last_line($handle, $elem)) { + $ExpireDate = $line; + } + last FMTSW; + } + if ($elem eq "fieldstyles") { # Field text style + while ($line = <$handle>) { + last if $line =~ /^\s*<\/fieldstyles\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; + ($label, $tag) = split(/:/,$line); + $HeadFields{$label} = $tag; + } + last FMTSW; + } + if ($elem eq "fieldorder") { # Field order + @FieldOrder = (); %FieldODefs = (); + while ($line = <$handle>) { + last if $line =~ /^\s*<\/fieldorder\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; + push(@FieldOrder, $line); + $FieldODefs{$line} = 1; + } + # push(@FieldOrder,'-extra-') if (!$FieldODefs{'-extra-'}); + last FMTSW; + } + if ($elem eq "fieldsbeg") { # Begin markup of mail head + $FIELDSBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "fieldsend") { # End markup of mail head + $FIELDSEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "fldbeg") { # Begin markup of field text + $FLDBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "fldend") { # End markup of field text + $FLDEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "folrefs") { + $DoFolRefs = 1; last FMTSW; + } + if ($elem eq "footer") { # Footer file + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $FOOTER = $line; + } + last FMTSW; + } + if ($elem eq "gmtdatefmt") { # GMT date format + if ($line = &get_elem_last_line($handle, $elem)) { + $GMTDateFmt = $line; + } + last FMTSW; + } + if ($elem eq "headbodysep") { + $HEADBODYSEP = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "header") { # Header file + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $HEADER = $line; + } + last FMTSW; + } + if ($elem eq "icons") { # Icons + %Icons = () if $override; + while ($line = <$handle>) { + last if $line =~ /^\s*<\/icons\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; + ($type, $url) = split(/:/,$line,2); + $type =~ tr/A-Z/a-z/; + $Icons{$type} = $url; + } + last FMTSW; + } + if ($elem eq "idxfname") { # Index filename + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $IDXNAME = $line; + } + last FMTSW; + } + if ($elem eq "idxlabel") { # Index label + $IDXLABEL = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "idxpgbegin") { # Opening markup of index + $IDXPGBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "idxpgend") { # Closing markup of index + $IDXPGEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "idxprefix") { # Prefix for main idx pages + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $IDXPREFIX = $line; + } + last FMTSW; + } + if ($elem eq "idxsize") { # Size of index + if (($tmp = &get_elem_int($handle, $elem, 1)) ne '') { + $IDXSIZE = $tmp; + } + last FMTSW; + } + if ($elem eq "include") { # Include other rc files + while ($line = <$handle>) { + last if $line =~ /^\s*<\/include\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s+$//; + $line = $pathhead . $line if ($line !~ /$'DIRSEPREX/o); + &read_fmt_file($line); + } + last FMTSW; + } + if ($elem eq "labelbeg") { # Begin markup of label + $LABELBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "labelend") { # End markup of label + $LABELEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "labelstyles") { # Field label style + while ($line = <$handle>) { + last if $line =~ /^\s*<\/labelstyles\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; + ($label, $tag) = split(/:/,$line); + $HeadHeads{$label} = $tag; + } + last FMTSW; + } + if ($elem eq "listbegin") { # List begin + $LIBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "listend") { # List end + $LIEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "litemplate") { # List item template + $LITMPL = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "localdatefmt") { # Local date format + if ($line = &get_elem_last_line($handle, $elem)) { + $LocalDateFmt = $line; + } + last FMTSW; + } + if ($elem eq "mailto") { # Convert e-mail addrs + $NOMAILTO = 0; last FMTSW; + } + if ($elem eq "mailtourl") { # mailto URL + while ($line = <$handle>) { + last if $line =~ /^\s*<\/mailtourl\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; + $MAILTOURL = $line; + } + last FMTSW; + } + if ($elem eq "main") { + $MAIN = 1; last FMTSW; + } + if ($elem eq "maxsize") { # Size of archive + if (($tmp = &get_elem_int($handle, $elem, 1)) ne '') { + $MAXSIZE = $tmp; + } + last FMTSW; + } + if ($elem eq "mhpattern") { # File pattern MH-like dirs + if ($line = &get_elem_last_line($handle, $elem)) { + $MHPATTERN = $line; + } + last FMTSW; + } + if ($elem eq "mimefilters") { # Mime filters + @Requires = (), %'MIMEFilters = () if $override; + while ($line = <$handle>) { + last if $line =~ /^\s*<\/mimefilters\s*>/i; + next if $line =~ /^\s*$/; + $line =~ s/\s//g; + ($type,$routine,$plfile) = split(/:/,$line,3); + $type =~ tr/A-Z/a-z/; + $'MIMEFilters{$type} = $routine; + push(@Requires, $plfile) if $plfile =~ /\S/; + } + last FMTSW; + } + if ($elem eq "mimeargs") { # Mime arguments + %'MIMEFiltersArgs = () if $override; + while ($line = <$handle>) { + last if $line =~ /^\s*<\/mimeargs\s*>/i; + next if $line =~ /^\s*$/; + ($type,$arg) = split(/:/,$line,2); + $type =~ tr/A-Z/a-z/ if $type =~ m%/%; + $'MIMEFiltersArgs{$type} = $arg; + } + last FMTSW; + } + if ($elem eq "months") { # Full month names + @a = &get_list_content($handle, $elem); + if (scalar(@a)) { + @Months = @a; + } + last FMTSW; + } + if ($elem eq "monthsabr") { # Abbreviated month names + @a = &get_list_content($handle, $elem); + if (scalar(@a)) { + @months = @a; + } + last FMTSW; + } + if ($elem eq "modtime") { # Mod time same as msg date + $MODTIME = 1; last FMTSW; + } + if ($elem eq "msgfoot") { # Message footer text + $MSGFOOT = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "msggmtdatefmt") { # Message GMT date format + if ($line = &get_elem_last_line($handle, $elem)) { + $MsgGMTDateFmt = $line; + } + last FMTSW; + } + if ($elem eq "msghead") { # Message header text + $MSGHEAD = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "msglocaldatefmt") { # Message local date format + if ($line = &get_elem_last_line($handle, $elem)) { + $MsgLocalDateFmt = $line; + } + last FMTSW; + } + if ($elem eq "msgpgbegin") { # Opening markup of message + $MSGPGBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "msgpgend") { # Closing markup of message + $MSGPGEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "msgsep") { # Message separator + if ($line = &get_elem_last_line($handle, $elem)) { + $FROM = $line; + } + last FMTSW; + } + if ($elem eq "multipg") { + $MULTIIDX = 1; last FMTSW; + } + if ($elem eq "nextbutton") { # Next button link in message + $NEXTBUTTON = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "nextbuttonia") { + $NEXTBUTTONIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "nextlink") { # Next link in message + $NEXTLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "nextlinkia") { + $NEXTLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "nextpglink") { # Next page link in index + $NEXTPGLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "nextpglinkia") { + $NEXTPGLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "news") { # News for linking + $NONEWS = 0; last FMTSW; + } + if ($elem eq "noauthsort") { # Do not sort msgs by author + $AUTHSORT = 0; + last FMTSW; + } + if ($elem eq "noconlen") { # Ignore content-length + $CONLEN = 0; last FMTSW; + } + if ($elem eq "nodecodeheads") { + $DecodeHeads = 0; last FMTSW; + } + if ($elem eq "nodoc") { # Do not link to docs + $NODOC = 1; last FMTSW; + } + if ($elem eq "nofolrefs") { + $DoFolRefs = 0; last FMTSW; + } + if ($elem eq "nomailto") { # Do not convert e-mail addrs + $NOMAILTO = 1; last FMTSW; + } + if ($elem eq "nomain") { # No main index + $MAIN = 0; last FMTSW; + } + if ($elem eq "nomodtime") { # Do not change mod times + $MODTIME = 0; last FMTSW; + } + if ($elem eq "nomultipg") { # Single page index + $MULTIIDX = 0; last FMTSW; + } + if ($elem eq "nonews") { # Ignore news for linking + $NONEWS = 1; last FMTSW; + } + if ($elem eq "noreverse") { # Sort in normal order + $REVSORT = 0; last FMTSW; + } + if ($elem eq "nosort") { # Do not sort messages + $NOSORT = 1; + last FMTSW; + } + if ($elem eq "nosubsort") { # Do not sort msgs by subject + $SUBSORT = 0; + last FMTSW; + } + if ($elem eq "nothread") { # No thread index + $THREAD = 0; last FMTSW; + } + if ($elem eq "notreverse") { # Thread sort in normal order + $TREVERSE = 0; last FMTSW; + } + if ($elem eq "nourl") { # Ignore URLs + $NOURL = 1; last FMTSW; + } + if ($elem eq "otherindexes") { # Other indexes + @OtherIdxs = () if $override; + unshift(@OtherIdxs, &get_list_content($handle, $elem, $'PATHSEP)); + last FMTSW; + } + if ($elem eq "perlinc") { # Define perl search paths + @PerlINC = () if $override; + unshift(@PerlINC, &get_list_content($handle, $elem, $'PATHSEP)); + last FMTSW; + } + if ($elem eq "prevbutton") { # Prev button link in message + $PREVBUTTON = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "prevbuttonia") { + $PREVBUTTONIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "prevlink") { # Prev link in message + $PREVLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "prevlinkia") { + $PREVLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "prevpglink") { # Prev page link for index + $PREVPGLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "prevpglinkia") { + $PREVPGLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "reverse") { # Reverse sort + $REVSORT = 1; + last FMTSW; + } + if ($elem eq "sort") { # Sort messages by date + $NOSORT = 0; + $AUTHSORT = 0; $SUBSORT = 0; + last FMTSW; + } + if ($elem eq "subsort") { # Sort messages by subject + $SUBSORT = 1; + $AUTHSORT = 0; $NOSORT = 0; + last FMTSW; + } + if ($elem eq "subjectbegin") { # Begin for subject group + $SUBJECTBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "subjectend") { # End for subject group + $SUBJECTEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "subjectheader") { + $SUBJECTHEADER = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tcontbegin") { # Thread cont. start + $TCONTBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tcontend") { # Thread cont. end + $TCONTEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "thead") { # Thread idx head + $THEAD = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tfoot") { # Thread idx foot + $TFOOT = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tidxfname") { # Threaded idx filename + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $TIDXNAME = $line; + } + last FMTSW; + } + if ($elem eq "tidxlabel") { # Thread index label + $TIDXLABEL = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tidxpgbegin") { # Opening markup of thread idx + $TIDXPGBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tidxpgend") { # Closing markup of thread idx + $TIDXPGEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tidxprefix") { # Prefix for thread idx pages + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $TIDXPREFIX = $line; + } + last FMTSW; + } + if ($elem eq "timezones") { # Time zones + %Zone = () if $override; + while ($line = <$handle>) { + last if $line =~ /^\s*<\/timezones\s*>/i; + $line =~ s/\s//g; $line =~ tr/a-z/A-Z/; + ($acro,$hr) = split(/:/,$line); + $Zone{$acro} = $hr; + } + last FMTSW; + } + if ($elem eq "tindentbegin") { # Thread indent start + $TINDENTBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tindentend") { # Thread indent end + $TINDENTEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "title") { # Title of index page + $TITLE = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tlevels") { # Level of threading + if (($tmp = &get_elem_int($handle, $elem, 1)) ne '') { + $TLEVELS = $tmp; + } + last FMTSW; + } + if ($elem eq "tsublistbeg") { # List begin in sub-thread + $TSUBLISTBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tsublistend") { # List end in sub-thread + $TSUBLISTEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tsubjectbeg") { # Begin markup for sub thread + $TSUBJECTBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tsubjectend") { # End markup for sub thread + $TSUBJECTEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tsingletxt") { # Markup for single msg + $TSINGLETXT = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "ttopbegin") { # Begin for top of a thread + $TTOPBEG = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "ttopend") { # End for a thread + $TTOPEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tlinone") { # Markup for missing message + $TLINONE = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tlinoneend") { # End markup for missing msg + $TLINONEEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tlitxt") { # Thread idx list item + $TLITXT = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tliend") { # Thread idx list item end + $TLIEND = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "toplinks") { # Top links in message + $TOPLINKS = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "ttitle") { # Title of threaded idx + $TTITLE = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "thread") { # Create thread index + $THREAD = 1; last FMTSW; + } + if ($elem eq "treverse") { # Reverse order of threads + $TREVERSE = 1; last FMTSW; + } + if ($elem eq "tnextbutton") { # Thread Next button link + $TNEXTBUTTON = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tnextbuttonia") { + $TNEXTBUTTONIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tnextlink") { # Thread Next link + $TNEXTLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tnextlinkia") { + $TNEXTLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tnextpglink") { # Thread next page link + $TNEXTPGLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tnextpglinkia") { + $TNEXTPGLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tprevbutton") { # Thread Prev button link + $TPREVBUTTON = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tprevbuttonia") { + $TPREVBUTTONIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tprevlink") { # Thread Prev link in message + $TPREVLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tprevlinkia") { + $TPREVLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tprevpglink") { # Thread previous page link + $TPREVPGLINK = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "tprevpglinkia") { + $TPREVPGLINKIA = &get_elem_content($handle, $elem, $chop); + last FMTSW; + } + if ($elem eq "umask") { # Umask of process + if ($line = &get_elem_last_line($handle, $elem)) { + $line =~ s/\s//g; + $UMASK = $line; + } + last FMTSW; + } + if ($elem eq "weekdays") { # Full weekday name + @a = &get_list_content($handle, $elem); + if (scalar(@a)) { + @Weekdays = @a; + } + last FMTSW; + } + if ($elem eq "weekdaysabr") { # Abbreviated weekday name + @a = &get_list_content($handle, $elem); + if (scalar(@a)) { + @weekdays = @a; + } + last FMTSW; + } + + } ## End FMTSW + } + close($handle); + 1; +} + +##---------------------------------------------------------------------- +sub get_elem_content { + local($filehandle, $gi, $chop) = ($_[0], $_[1], $_[2]); + local($ret) = ''; + + while (<$filehandle>) { + last if /^\s*<\/$gi\s*>/i; + $ret .= $_; + } + $ret =~ s/\r?\n?$// if $chop; + $ret; +} + +##---------------------------------------------------------------------- +sub get_elem_int { + local($filehandle, $gi, $abs) = ($_[0], $_[1], $_[2]); + local($ret) = ''; + + while (<$filehandle>) { + last if /^\s*<\/$gi\s*>/i; + next unless /^\s*[-+]?\d+\s*$/; + s/[+\s]//g; + s/-// if $abs; + $ret = $_; + } + $ret; +} + +##---------------------------------------------------------------------- +sub get_elem_last_line { + local($filehandle, $gi) = ($_[0], $_[1]); + local($ret) = ''; + + while (<$filehandle>) { + last if /^\s*<\/$gi\s*>/i; + next unless /\S/; + $ret = $_; + } + $ret =~ s/\r?\n?$//; + $ret; +} + +##---------------------------------------------------------------------- +sub get_list_content { + local($filehandle, $gi, $sep) = ($_[0], $_[1], $_[2]); + local(@items) = (); + $sep = ':' unless $sep; + + while (<$filehandle>) { + last if /^\s*<\/$gi\s*>/i; + next unless /\S/; + s/\r?\n?$//; + push(@items, split(/$sep/, $_)); + } + @items; +} + +##---------------------------------------------------------------------------## +1; diff --git a/lib/mhrcvars.pl b/lib/mhrcvars.pl new file mode 100644 index 0000000..31d6b36 --- /dev/null +++ b/lib/mhrcvars.pl @@ -0,0 +1,548 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) mhrcvars.pl 1.7 97/05/13 11:28:21 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Defines routine for expanding resource variables. +##---------------------------------------------------------------------------## +## MHonArc -- Internet mail-to-HTML converter +## Copyright (C) 1996,1997 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +##--------------------------------------------------------------------------- +## replace_li_var() is used to substitute vars to current +## values. This routine relies on some variables being set by the +## calling routine or as globals. +## +sub replace_li_var { + local($val, $index) = ($_[0], $_[1]); + local($var,$len,$canclip,$raw,$isurl,$tmp,$ret) = ('',0,0,0,0,'',''); + local($expand) = (0); + local($n) = (0); + local($pi, $ni, $tni, $tpi, + $isfirst, $islast, $tisfirst, $tislast); + + ## Get length specifier (if defined) + ($var, $len) = split(/:/, $val, 2); + + ## Check if variable in a URL string + $isurl = 1 if ($len =~ s/u//ig); + + ## Set index related variables + if ($index ne '') { + if ($REVSORT) { + $ni = $MListOrder[$Index2MLoc{$index}-1]; + $pi = $MListOrder[$Index2MLoc{$index}+1]; + $isfirst = ($Index2MLoc{$index} == $#MListOrder); + $islast = ($Index2MLoc{$index} == 0); + } else { + $ni = $MListOrder[$Index2MLoc{$index}+1]; + $pi = $MListOrder[$Index2MLoc{$index}-1]; + $isfirst = ($Index2MLoc{$index} == 0); + $islast = ($Index2MLoc{$index} == $#MListOrder); + } + $tni = $TListOrder[$Index2TLoc{$index}+1]; + $tpi = $TListOrder[$Index2TLoc{$index}-1]; + $tisfirst = ($Index2TLoc{$index} == 0); + $tislast = ($Index2TLoc{$index} == $#TListOrder); + } + + ## Do variable replacement + REPLACESW: { + if ($var eq 'SUBJECT') { + $canclip = 1; $raw = 1; $isurl = 0; + $tmp = $Subject{$index}; + last REPLACESW; + } + if ($var eq 'SUBJECTNA') { + $canclip = 1; $raw = 1; + $tmp = $Subject{$index}; + last REPLACESW; + } + if ($var eq 'A_ATTR') { + $isurl = 0; + $tmp = qq{NAME="} . &fmt_msgnum($IndexNum{$index}) . + qq{" HREF="} . + &msgnum_filename($IndexNum{$index}) . + qq{"}; + last REPLACESW; + } + if ($var eq 'A_NAME') { + $isurl = 0; + $tmp = qq{NAME="} . &fmt_msgnum($IndexNum{$index}) . qq{"}; + last REPLACESW; + } + if ($var eq 'A_HREF') { + $isurl = 0; + $tmp = qq{HREF="} . &msgnum_filename($IndexNum{$index}) . qq{"}; + last REPLACESW; + } + if ($var eq 'DATE') { + $tmp = $Date{$index}; + last REPLACESW; + } + if ($var eq 'DDMMYY') { + $tmp = &time2mmddyy((split(/$X/o, $index))[0], 'ddmmyy'); + last REPLACESW; + } + if ($var eq 'DOCURL') { + $isurl = 0; + $tmp = $DOCURL; + last REPLACESW; + } + if ($var eq 'FROM') { + $canclip = 1; $raw = 1; + $tmp = $From{$index}; + last REPLACESW; + } + if ($var eq 'FROMADDR') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_address($From{$index}); + last REPLACESW; + } + if ($var eq 'FROMNAME') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_name($From{$index}); + last REPLACESW; + } + if ($var eq 'GMTDATE') { + $tmp = &time2str($GMTDateFmt, time, 0); + last REPLACESW; + } + if ($var eq 'ICON') { + if ($Icons{$ContentType{$index}}) { + $tmp = qq||; + } else { + $tmp = qq|[unknown]|; + } + last REPLACESW; + } + if ($var eq 'ICONURL') { + $isurl = 0; + if ($Icons{$ContentType{$index}}) { + $tmp = $Icons{$ContentType{$index}}; + } else { + $tmp = $Icons{'unknown'}; + } + last REPLACESW; + } + if ($var eq 'IDXFNAME') { + if ($MULTIIDX && + ($n = int($Index2MLoc{$index}/$IDXSIZE)+1) > 1) { + + $tmp = sprintf("%s%d.html", + $IDXPREFIX, $index ne '' ? $n : 1); + + } else { + $tmp = $IDXNAME; + } + last REPLACESW; + } + if ($var eq 'IDXLABEL') { + $tmp = $IDXLABEL; + last REPLACESW; + } + if ($var eq 'IDXSIZE') { + $tmp = $IDXSIZE; + last REPLACESW; + } + if ($var eq 'IDXTITLE') { + $canclip = 1; $expand = 1; + $tmp = $TITLE; + last REPLACESW; + } + if ($var eq 'LOCALDATE') { + $tmp = &time2str($LocalDateFmt, time, 1); + last REPLACESW; + } + if ($var eq 'MMDDYY') { + $tmp = &time2mmddyy((split(/$X/o, $index))[0], 'mmddyy'); + last REPLACESW; + } + if ($var eq 'MSGGMTDATE') { + $tmp = &time2str($MsgGMTDateFmt, &get_time_from_index($index), 0); + last REPLACESW; + } + if ($var eq 'MSGID') { + &defineIndex2MsgId(); + $tmp = $Index2MsgId{$index}; + last REPLACESW; + } + if ($var eq 'MSGLOCALDATE') { + $tmp = &time2str($MsgLocalDateFmt, &get_time_from_index($index), 1); + last REPLACESW; + } + if ($var eq 'MSGNUM') { + $tmp = &fmt_msgnum($IndexNum{$index}); + last REPLACESW; + } + if ($var eq 'NEXTFROM') { + $canclip = 1; $raw = 1; + $tmp = $From{$ni}; + last REPLACESW; + } + if ($var eq 'NEXTFROMADDR') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_address($From{$ni}); + last REPLACESW; + } + if ($var eq 'NEXTFROMNAME') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_name($From{$ni}); + last REPLACESW; + } + if ($var eq 'NEXTMSG') { + $tmp = &msgnum_filename($IndexNum{$ni}); + last REPLACESW; + } + if ($var eq 'NEXTMSGNUM') { + $tmp = &fmt_msgnum($IndexNum{$ni}); + last REPLACESW; + } + if ($var eq 'NEXTSUBJECT') { + $canclip = 1; $raw = 1; + $tmp = $Subject{$ni}; + last REPLACESW; + } + if ($var eq 'NUMFOLUP') { + $tmp = $FolCnt{$index}; + last REPLACESW; + } + if ($var eq 'NUMOFIDXMSG') { + $tmp = ($NumOfMsgs > $IDXSIZE ? $IDXSIZE : $NumOfMsgs); + last REPLACESW; + } + if ($var eq 'NUMOFMSG') { + $tmp = $NumOfMsgs; + last REPLACESW; + } + if ($var eq 'ORDNUM') { + $tmp = $i+1; + last REPLACESW; + } + if ($var eq 'OUTDIR') { + $tmp = $OUTDIR; + last REPLACESW; + } + if ($var eq 'PREVFROM') { + $canclip = 1; $raw = 1; + $tmp = $From{$pi}; + last REPLACESW; + } + if ($var eq 'PREVFROMADDR') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_address($From{$pi}); + last REPLACESW; + } + if ($var eq 'PREVFROMNAME') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_name($From{$pi}); + last REPLACESW; + } + if ($var eq 'PREVMSG') { + $tmp = &msgnum_filename($IndexNum{$pi}); + last REPLACESW; + } + if ($var eq 'PREVMSGNUM') { + $tmp = &fmt_msgnum($IndexNum{$pi}); + last REPLACESW; + } + if ($var eq 'PREVSUBJECT') { + $canclip = 1; $raw = 1; + $tmp = $Subject{$pi}; + last REPLACESW; + } + if ($var eq 'PROG') { + $tmp = $PROG; + last REPLACESW; + } + if ($var eq 'TIDXFNAME') { + if ($MULTIIDX && + ($n = int($Index2TLoc{$index}/$IDXSIZE)+1) > 1) { + + $tmp = sprintf("%s%d.html", + $TIDXPREFIX, $index ne '' ? $n : 1); + + } else { + $tmp = $TIDXNAME; + } + last REPLACESW; + } + if ($var eq 'TIDXLABEL') { + $tmp = $TIDXLABEL; + last REPLACESW; + } + if ($var eq 'TIDXTITLE') { + $canclip = 1; $expand = 1; + $tmp = $TTITLE; + last REPLACESW; + } + if ($var eq 'VERSION') { + $tmp = $VERSION; + last REPLACESW; + } + if ($var eq 'YYMMDD') { + $tmp = &time2mmddyy((split(/$X/o, $index))[0], 'yymmdd'); + last REPLACESW; + } + if ($var eq '') { + $tmp = '$'; + last REPLACESW; + } + + ## + ## Next/Prev buttons/links + ## + if ($var eq 'NEXTBUTTON') { + $expand = 1; + $tmp = (!$islast) ? $NEXTBUTTON : $NEXTBUTTONIA; + last REPLACESW; + } + if ($var eq 'NEXTLINK') { + $expand = 1; + $tmp = (!$islast) ? $NEXTLINK : $NEXTLINKIA; + last REPLACESW; + } + if ($var eq 'PREVBUTTON') { + $expand = 1; + $tmp = (!$isfirst) ? $PREVBUTTON : $PREVBUTTONIA; + last REPLACESW; + } + if ($var eq 'PREVLINK') { + $expand = 1; + $tmp = (!$isfirst) ? $PREVLINK : $PREVLINKIA; + last REPLACESW; + } + + ## + ## Thread Next/Prev buttons/links + ## + if ($var eq 'TNEXTBUTTON') { + $expand = 1; + $tmp = (!$tislast) ? $TNEXTBUTTON : $TNEXTBUTTONIA; + last REPLACESW; + } + if ($var eq 'TNEXTLINK') { + $expand = 1; + $tmp = (!$tislast) ? $TNEXTLINK : $TNEXTLINKIA; + last REPLACESW; + } + if ($var eq 'TPREVBUTTON') { + $expand = 1; + $tmp = (!$tisfirst) ? $TPREVBUTTON : $TPREVBUTTONIA; + last REPLACESW; + } + if ($var eq 'TPREVLINK') { + $expand = 1; + $tmp = (!$tisfirst) ? $TPREVLINK : $TPREVLINKIA; + last REPLACESW; + } + + ## + ## Thread related variables + ## + if ($var eq 'TNEXTFROM') { + $canclip = 1; $raw = 1; + $tmp = $From{$tni}; + last REPLACESW; + } + if ($var eq 'TNEXTFROMADDR') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_address($From{$tni}); + last REPLACESW; + } + if ($var eq 'TNEXTFROMNAME') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_name($From{$tni}); + last REPLACESW; + } + if ($var eq 'TNEXTMSG') { + $tmp = &msgnum_filename($IndexNum{$tni}); + last REPLACESW; + } + if ($var eq 'TNEXTMSGNUM') { + $tmp = &fmt_msgnum($IndexNum{$tni}); + last REPLACESW; + } + if ($var eq 'TNEXTSUBJECT') { + $canclip = 1; $raw = 1; + $tmp = $Subject{$tni}; + last REPLACESW; + } + if ($var eq 'TPREVFROM') { + $canclip = 1; $raw = 1; + $tmp = $From{$tpi}; + last REPLACESW; + } + if ($var eq 'TPREVFROMADDR') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_address($From{$tpi}); + last REPLACESW; + } + if ($var eq 'TPREVFROMNAME') { + $canclip = 1; $raw = 1; + $tmp = &extract_email_name($From{$tpi}); + last REPLACESW; + } + if ($var eq 'TPREVMSG') { + $tmp = &msgnum_filename($IndexNum{$tpi}); + last REPLACESW; + } + if ($var eq 'TPREVMSGNUM') { + $tmp = &fmt_msgnum($IndexNum{$tpi}); + last REPLACESW; + } + if ($var eq 'TPREVSUBJECT') { + $canclip = 1; $raw = 1; + $tmp = $Subject{$tpi}; + last REPLACESW; + } + + ## + ## Multi-page index variables + ## + if ($var eq 'NEXTPGLINK') { + $expand = 1; + $tmp = $PageNum < $NumOfPages ? $NEXTPGLINK : $NEXTPGLINKIA; + last REPLACESW; + } + if ($var eq 'PREVPGLINK') { + $expand = 1; + $tmp = $PageNum > 1 ? $PREVPGLINK : $PREVPGLINKIA; + last REPLACESW; + } + if ($var eq 'TNEXTPGLINK') { + $expand = 1; + $tmp = $PageNum < $NumOfPages ? $TNEXTPGLINK : $TNEXTPGLINKIA; + last REPLACESW; + } + if ($var eq 'TPREVPGLINK') { + $expand = 1; + $tmp = $PageNum > 1 ? $TPREVPGLINK : $TPREVPGLINKIA; + last REPLACESW; + } + if ($var eq 'PAGENUM') { + $tmp = $PageNum; + last REPLACESW; + } + if ($var eq 'NUMOFPAGES') { + $tmp = $NumOfPages; + last REPLACESW; + } + if ($var eq 'NEXTPG') { + $tmp = sprintf("%s%d.html", $IDXPREFIX, $PageNum+1); + last REPLACESW; + } + if ($var eq 'PREVPG') { + $tmp = $PageNum > 2 ? + sprintf("%s%d.html", $IDXPREFIX, $PageNum-1) : + $IDXNAME; + last REPLACESW; + } + if ($var eq 'TNEXTPG') { + $tmp = sprintf("%s%d.html", $TIDXPREFIX, $PageNum+1); + last REPLACESW; + } + if ($var eq 'TPREVPG') { + $tmp = $PageNum > 2 ? + sprintf("%s%d.html", $TIDXPREFIX, $PageNum-1) : + $TIDXNAME; + last REPLACESW; + } + if ($var eq 'FIRSTPG') { + $tmp = $IDXNAME; + last REPLACESW; + } + if ($var eq 'LASTPG') { + $tmp = ($MULTIIDX && $NumOfPages > 1 ? sprintf("%s%d.html", + $IDXPREFIX, $NumOfPages) : + $IDXNAME); + last REPLACESW; + } + if ($var eq 'TFIRSTPG') { + $tmp = $TIDXNAME; + last REPLACESW; + } + if ($var eq 'TLASTPG') { + $tmp = ($MULTIIDX && $NumOfPages > 1 ? sprintf("%s%d.html", + $TIDXPREFIX, $NumOfPages) : + $TIDXNAME); + last REPLACESW; + } + if ($var eq 'IDXPREFIX') { + $tmp = $IDXPREFIX; + last REPLACESW; + } + if ($var eq 'TIDXPREFIX') { + $tmp = $TIDXPREFIX; + last REPLACESW; + } + + ## + ## User defined variable check + ## + if ($CustomRcVars{$var}) { + $expand = 1; + $tmp = $CustomRcVars{$var}; + last REPLACESW; + } + + warn qq{Warning: Unrecognized variable: "$val"\n}; + return "\$$val\$"; + } + + ## Check if string needs to be expanded again + if ($expand) { + $tmp =~ s/\$([^\$]*)\$/&replace_li_var($1,$index)/ge; + } + + ## Check if URL text specifier is set + if ($isurl) { + $ret = &urlize($tmp); + + } else { + if ($raw) { + $ret = &$MHeadCnvFunc($tmp) if $raw; + } else { + $ret = $tmp; + } + + # Check for clipping + if ($len > 0 && $canclip) { + # Check for entity refs and modify clip length accordingly + foreach ($ret =~ /(\&[^;\s]*;)/g) { + $len += length($_) -1; + } + $ret = substr($ret, 0, $len); + } + } + + ## Check for subject link + $ret = qq{$ret} + if $var eq 'SUBJECT'; + + $ret; +} + +##---------------------------------------------------------------------------## +1; diff --git a/lib/mhtime.pl b/lib/mhtime.pl new file mode 100644 index 0000000..5cbd971 --- /dev/null +++ b/lib/mhtime.pl @@ -0,0 +1,294 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) mhtime.pl 1.7 97/05/13 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Time related routines for mhonarc +##---------------------------------------------------------------------------## +## Copyright (C) 1996 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +##---------------------------------------------------------------------------## +## Date variables for date routines +## +{ +package mhtime; + +%Month2Num = ( + 'jan', 0, 'feb', 1, 'mar', 2, 'apr', 3, 'may', 4, 'jun', 5, 'jul', 6, + 'aug', 7, 'sep', 8, 'oct', 9, 'nov', 10, 'dec', 11, +); +%WDay2Num = ( + 'sun', 0, 'mon', 1, 'tue', 2, 'wed', 3, 'thu', 4, 'fri', 5, 'sat', 6, +); + +@weekdays = ('Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'); +@Weekdays = ('Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', + 'Friday', 'Saturday'); +@months = ('Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', + 'Sep', 'Oct', 'Nov', 'Dec'); +@Months = ('January', 'Febuary', 'March', 'April', 'May', 'June', + 'July', 'August', 'September', 'October', 'November', + 'December'); +} + +##--------------------------------------------------------------------------- +## Set weekday and month names. This allows localization of +## names. +## +sub set_date_names { + package mhtime; + + local(*in_wd, *in_Wd, *in_m, *in_M) = @_; + @weekdays = @in_wd if scalar(@in_wd); + @Weekdays = @in_Wd if scalar(@in_Wd); + @months = @in_m if scalar(@in_m); + @Months = @in_M if scalar(@in_M); +} + +##--------------------------------------------------------------------------- +## Get date in date(1)-like format. $local flag is if local time +## should be used. +## +sub getdate { + &time2str('', time, $_[0]); +} + +##--------------------------------------------------------------------------- +## Convert a calander time to a string. Similar to strftime(3). +## +sub time2str { + package mhtime; + + local($fmt, $time, $local) = @_ ; + local($date) = "" ; + + ## Get current date/time + local($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = + ($local ? localtime($time) : gmtime($time)); + + ## Format output + if ($fmt =~ /\S/) { + local($yearfull, $hour12); + $yearfull = $year + 1900; + $hour12 = $hour > 12 ? $hour-12 : $hour; + + $fmt =~ s/\%a/$weekdays[$wday]/g; + $fmt =~ s/\%A/$Weekdays[$wday]/g; + $fmt =~ s/\%b/$months[$mon]/g; + $fmt =~ s/\%B/$Months[$mon]/g; + + $sec = sprintf("%02d", $sec); + $min = sprintf("%02d", $min); + $hour = sprintf("%02d", $hour); + $hour12 = sprintf("%02d", $hour12); + $mday = sprintf("%02d", $mday); + $mon = sprintf("%02d", $mon+1); + $year = sprintf("%02d", $year); + $yearfull = sprintf("%04d", $yearfull); + $wday = sprintf("%02d", $wday+1); + $yday = sprintf("%03d", $yday); + + $fmt =~ s/\%d/$mday/g; + $fmt =~ s/\%H/$hour/g; + $fmt =~ s/\%I/$hour12/g; + $fmt =~ s/\%j/$yday/g; + $fmt =~ s/\%m/$mon/g; + $fmt =~ s/\%M/$min/g; + $fmt =~ s/\%n/\n/g; + $fmt =~ s/\%p/am/g if ($hour < 12); + $fmt =~ s/\%p/pm/g if ($hour >= 12); + $fmt =~ s/\%P/AM/g if ($hour < 12); + $fmt =~ s/\%P/PM/g if ($hour >= 12); + $fmt =~ s/\%S/$sec/eg ; + $fmt =~ s/\%w/$wday/g ; + $fmt =~ s/\%y/$year/g ; + $fmt =~ s/\%Y/$year+1900/ge ; + + $fmt =~ s/\%\%/\%/g ; + + $date = $fmt ; + + } else { + $date = sprintf("%s %s %02d %02d:%02d:%02d ". + ($local ? "%s" : "GMT %s"), + $weekdays[$wday], $months[$mon], + $mday, $hour, $min, $sec, $year); + } + $date ; +} + +##--------------------------------------------------------------------------- +## parse_date takes a string date specified like the output of +## date(1) into its components. Parsing a string for a date is +## ugly since we have to watch out for differing formats. +## +## The following date formats are looked for: +## +## Wdy DD Mon YY HH:MM:SS Zone +## DD Mon YY HH:MM:SS Zone +## Wdy Mon DD HH:MM:SS Zone YYYY +## Wdy Mon DD HH:MM:SS YYYY +## +## The routine keys off of the day of time field "HH:MM:SS" and +## scans realtive to its location. +## +## If the parse fails, a null array is returned. Thus the routine +## may be used as follows: +## +## if ( (@x = &parse_date($date)) ) { Success } +## else { Fail } +## +## If success the array contents are as follows: +## +## (Weekday (0-6), Day of the month (1-31), Month (0-11), +## Year, Hour, Minutes, Seconds, Time Zone) +## +## Contributer(s): Frank J. Manion +## +sub parse_date { + package mhtime; + + local($date) = $_[0]; + local($wday, $mday, $mon, $yr, $time, $hr, $min, $sec, $zone); + local(@array); + local($start, $rest); + + local($p_weekdays) = "Mon|Tue|Wed|Thu|Fri|Sat|Sun"; + local($p_months) = "Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec"; + local($p_hrminsec) = '\d{1,2}:\d\d:\d\d'; + local($p_hrmin) = '\d{1,2}:\d\d'; + local($p_day) = '\d{1,2}'; + local($p_year) = '\d\d\d\d|\d\d'; + + # Try to find the date by focusing on the "\d\d:\d\d" field. + # All parsing is then done relative to this location. + # + $date =~ s/^\s*//; + if ( $date =~ /\b($p_hrminsec)/o ) { + ($start, $time, $rest) = ($`, $1, $'); + } elsif ( $date =~ /\b($p_hrmin)/o ) { + ($start, $time, $rest) = ($`, $1, $'); + } else { + return (); # no time here ! + } + ($hr, $min, $sec) = split(/:/, $time); + $sec = 0 unless $sec; # Sometime seconds not defined + + # Strip $start of all but the last 4 tokens, + # and stuff all tokens in $rest into @array + # + @array = split(' ', $start); + $start = join(' ', ($#array-3 < 0) ? @array[0..$#array] : + @array[$#array-3..$#array]); + @array = split(' ', $rest); + $rest = join(' ', ($#array >= 1) ? @array[0..1] : + @array[0]); + # Wdy DD Mon YY HH:MM:SS Zone + if ( $start =~ + /($p_weekdays),*\s+($p_day)\s+($p_months)\s+($p_year)$/io ) { + + ($wday, $mday, $mon, $yr, $zone) = ($1, $2, $3, $4, $array[0]); + + # DD Mon YY HH:MM:SS Zone + } elsif ( $start =~ /($p_day)\s+($p_months)\s+($p_year)$/io ) { + ($mday, $mon, $yr, $zone) = ($1, $2, $3, $array[0]); + + # Wdy Mon DD HH:MM:SS Zone YYYY + # Wdy Mon DD HH:MM:SS YYYY + } elsif ( $start =~ /($p_weekdays),?\s+($p_months)\s+($p_day)$/io ) { + ($wday, $mon, $mday) = ($1, $2, $3); + if ( $rest =~ /^(\S+)\s+($p_year)/o ) { # Zone YYYY + ($zone, $yr) = ($1, $2); + } elsif ( $rest =~ /^($p_year)/o ) { # YYYY + ($yr) = ($1); + } else { # zilch, use current year + warn "Warning: No year in date, using current\n"; + $yr = (localtime(time))[5]; + } + + # All else fails! + } else { + return (); + } + + # Modify month and weekday for lookup + $mon =~ tr/A-Z/a-z/; $wday =~ tr/A-Z/a-z/; + + ($WDay2Num{$wday}, $mday, $Month2Num{$mon}, $yr, $hr, $min, $sec, $zone); +} + +##--------------------------------------------------------------------------- +## Routine to convert time in seconds to a month, day, and year +## format. The format can be "mmddyy", "yymmdd", "ddmmyy". The +## year can be specifed as "yyyy" if a 4 digit year is needed. +## +sub time2mmddyy { + package mhtime; + + local($time, $fmt) = ($_[0], $_[1]); + local($day,$mon,$year,$ylen); + if ($time) { + ($day,$mon,$year) = (localtime($time))[3,4,5]; + $year += 1900; + + ## Compute length for year field + $ylen = $fmt =~ s/y/y/g; + substr($year, 0, 4 - $ylen) = ''; + + ## Create string + if ($fmt =~ /ddmmyy/i) { # DDMMYY + $tmp = sprintf("%02d/%02d/%0${ylen}d", $day, $mon+1, $year); + + } elsif ($fmt =~ /yymmdd/i) { # YYMMDD + $tmp = sprintf("%0${ylen}d/%02d/%02d", $year, $mon+1, $day); + + } else { # MMDDYY + $tmp = sprintf("%02d/%02d/%0${ylen}d", $mon+1, $day, $year); + } + + } else { + $tmp = "--/--/--"; + } +} + +##--------------------------------------------------------------------------- +## zone_offset_to_secs translates a [+-]HHMM zone offset to +## seconds. +## +sub zone_offset_to_secs { + local($off) = shift; + local($sign, $min); + + if (length($off) < 4) { + warn qq{Warning: "$off" not a valid timezone offset\n}; + return 0; + } + if ($off =~ s/-//) { # Check for sign + $sign = -1; + } else { + $sign = 1; s/\+//; + } + $min = substr($off, -2, 2); # Extract minutes + substr($off, -2, 2) = ""; # Just leave hour in $off + $sign * (($off * 3600) + ($min * 60)); + +} + +##---------------------------------------------------------------------------## +1; diff --git a/lib/mhtxt2022.pl b/lib/mhtxt2022.pl deleted file mode 100644 index 3246df7..0000000 --- a/lib/mhtxt2022.pl +++ /dev/null @@ -1,159 +0,0 @@ -##---------------------------------------------------------------------------## -## File: -## mhtxt2022.pl -## Author: -## NIIBE Yutaka gniibe@mri.co.jp -## (adapted from mhtxtplain.pl by Earl Hood ) -## Date: -## Fri Jul 12 08:21:16 CDT 1996 -## Change: Escaped '@' in expression for use in Perl 5. -## (1996/07/12, ehood@isogen.com) -## Description: -## Library defines routine to filter text/plain body parts that -## use the ISO-2022 Japanese character sets into HTML for MHonArc. -## Filter routine can be registered with the following: -## -## -## text/plain:m2h_text_plain_iso2022'filter:mhtxt2022.pl -## -## -## This will override the default text/plain filter used by -## MHonArc. -## -## Filter is based on the following RFCs: -## -## RFC-1468 I -## J. Murai, M. Crispin, E. van der Poel, "Japanese Character -## Encoding for Internet Messages", 06/04/1993. (Pages=6) -## -## RFC-1554 I -## M. Ohta, K. Handa, "ISO-2022-JP-2: Multilingual Extension of -## ISO-2022-JP", 12/23/1993. (Pages=6) -## -##---------------------------------------------------------------------------## -## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995 NIIBE Yutaka, gniibe@mri.co.jp -## Earl Hood, ehood@isogen.com -## -## This program is free software; you can redistribute it and/or modify -## it under the terms of the GNU General Public License as published by -## the Free Software Foundation; either version 2 of the License, or -## (at your option) any later version. -## -## This program is distributed in the hope that it will be useful, -## but WITHOUT ANY WARRANTY; without even the implied warranty of -## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -## GNU General Public License for more details. -## -## You should have received a copy of the GNU General Public License -## along with this program; if not, write to the Free Software -## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -##---------------------------------------------------------------------------## - -package m2h_text_plain_iso2022; - -$Url = '(http://|ftp://|afs://|wais://|telnet://|gopher://|' . - 'news:|nntp:|mid:|cid:|mailto:|prospero:)'; -$UrlExp = $Url . q%[^\s\(\)\|<>"']*[^\.;,"'\|\[\]\(\)\s<>]%; -$HUrlExp = $Url . q%[^\s\(\)\|<>"'\&]*[^\.;,"'\|\[\]\(\)\s<>\&]%; - -##--------------------------------------------------------------------------- -## Filter entitizes special characters, and converts URLs to -## hyperlinks. -## -sub filter { - local($header, *fields, *body) = @_; - local(@data) = split(/\n/,$body); - - $ret = "
    \n";
    -    for ($i = 0; $i <= $#data; $i++) {
    -        $_ = $data[$i];
    -
    -	# Process preceding ASCII text
    -	while(1) {
    -	    if (/^[^\033]+/) {	# ASCII plain text
    -		$ascii_text = $&;
    -		$_ = $';
    -
    -		# Replace meta characters in ASCII plain text
    -		$ascii_text =~ s%\&%\&%g;
    -		$ascii_text =~ s%<%\<%g;
    -		$ascii_text =~ s%>%\>%g;
    -		## Convert URLs to hyperlinks
    -		$ascii_text =~ s%($HUrlExp)%$1%gio
    -		    unless $'NOURL;
    -
    -		$ret .= $ascii_text;
    -	    } elsif (/\033\.[A-F]/) { # G2 Designate Sequence
    -		$_ = $';
    -		$ret .= $&;
    -	    } elsif (/\033N[ -]/) { # Single Shift Sequence
    -		$_ = $';
    -		$ret .= $&;
    -	    } else {
    -		last;
    -	    }
    -	}
    -
    -	# Process Each Segment
    -	while(1) {
    -	    if (/^\033\([BJ]/) { # Single Byte Segment
    -		$_ = $';
    -		$ret .= $&;
    -		while(1) {
    -		    if (/^[^\033]+/) {	# ASCII plain text
    -			$ascii_text = $&;
    -			$_ = $';
    -
    -			# Replace meta characters in ASCII plain text
    -			$ascii_text =~ s%\&%\&%g;
    -			$ascii_text =~ s%<%\<%g;
    -			$ascii_text =~ s%>%\>%g;
    -			## Convert URLs to hyperlinks
    -			$ascii_text =~ s%($HUrlExp)%$1%gio
    -			    unless $'NOURL;
    -
    -			$ret .= $ascii_text;
    -		    } elsif (/\033\.[A-F]/) { # G2 Designate Sequence
    -			$_ = $';
    -			$ret .= $&;
    -		    } elsif (/\033N[ -]/) { # Single Shift Sequence
    -			$_ = $';
    -			$ret .= $&;
    -		    } else {
    -			last;
    -		    }
    -		}
    -	    } elsif (/^\033\$[\@AB]|\033\$\([CD]/) { # Double Byte Segment
    -		$_ = $';
    -		$ret .= $&;
    -		while(1) {
    -		    if (/^([!-~][!-~])+/) { # Double Char plain text
    -			$_ = $';
    -			$ret .= $&;
    -		    } elsif (/\033\.[A-F]/) { # G2 Designate Sequence
    -			$_ = $';
    -			$ret .= $&;
    -		    } elsif (/\033N[ -]/) { # Single Shift Sequence
    -			$_ = $';
    -			$ret .= $&;
    -		    } else {
    -			last;
    -		    }
    -		}
    -	    } else {
    -		# Something wrong in text
    -		$ret .= $_;
    -		last;
    -	    }
    -	}
    -
    -	$ret .= "\n";
    -    }
    -
    -    $ret .= "
    \n"; - - ($ret); -} - -1; diff --git a/lib/mhtxthtml.pl b/lib/mhtxthtml.pl index 2f01233..bc3c71a 100644 --- a/lib/mhtxthtml.pl +++ b/lib/mhtxthtml.pl @@ -1,10 +1,8 @@ ##---------------------------------------------------------------------------## ## File: -## mhtxthtml.pl +## @(#) mhtxthtml.pl 1.1 96/09/17 @(#) ## Author: -## Earl Hood ehood@isogen.com -## Date: -## Fri Jan 19 16:12:01 CST 1996 +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Library defines routine to filter text/html body parts ## for MHonArc. @@ -14,7 +12,7 @@ ## ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by diff --git a/lib/mhtxtplain.pl b/lib/mhtxtplain.pl index 29b493a..3342339 100644 --- a/lib/mhtxtplain.pl +++ b/lib/mhtxtplain.pl @@ -1,10 +1,8 @@ ##---------------------------------------------------------------------------## ## File: -## mhtxtplain.pl +## @(#) mhtxtplain.pl 1.8 97/05/13 11:29:12 @(#) ## Author: -## Earl Hood ehood@isogen.com -## Date: -## Fri Jan 19 17:22:27 CST 1996 +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Library defines routine to filter text/plain body parts to HTML ## for MHonArc. @@ -14,7 +12,7 @@ ## ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -34,26 +32,296 @@ package m2h_text_plain; -$Url = '(http://|ftp://|afs://|wais://|telnet://|gopher://|' . - 'news:|nntp:|mid:|cid:|mailto:|prospero:)'; -$UrlExp = $Url . q%[^\s\(\)\|<>"']*[^\.;,"'\|\[\]\(\)\s<>]%; -$HUrlExp = $Url . q%[^\s\(\)\|<>"'\&]*[^\.;,"'\|\[\]\(\)\s<>\&]%; +$Url = '(http://|https://|ftp://|afs://|wais://|telnet://' . + '|gopher://|news:|nntp:|mid:|cid:|mailto:|prospero:)'; +$UrlExp = $Url . q%[^\s\(\)\|<>"']*[^\.;,"'\|\[\]\(\)\s<>]%; +$HUrlExp = $Url . q%[^\s\(\)\|<>"'\&]*[^\.;,"'\|\[\]\(\)\s<>\&]%; +$QuoteChars = '>|[\|\]+:]'; +$HQuoteChars = '>|[\|\]+:]'; -##--------------------------------------------------------------------------- -## Filter entitizes special characters, and converts URLs to -## hyperlinks. +##---------------------------------------------------------------------------## +## Text/plain filter for mhonarc. The following filter arguments +## are recognized ($args): +## +## nourl -- Do hyperlink URLs +## quote -- Italicize quoted message text +## nonfixed -- Use normal typeface +## keepspace -- Preserve whitespace if nonfixed +## maxwidth=# -- Set the maximum width of lines. Lines +## exceeding the maxwidth will be broken +## up across multiple lines. +## asis=set1:set2:... -- Colon separated lists of charsets +## to leave as-is. Only HTML special +## characters will be converted into +## entities. +## +## All arguments should be separated by at least one space ## sub filter { local($header, *fields, *data, $isdecode, $args) = @_; - local($nourl) = ($'NOURL || ($args =~ /nourl/i)); + local($ctype, $charset, $nourl, $doquote, $igncharset, $nonfixed, + $keepspace, $maxwidth); + local(%asis) = (); + + $nourl = ($'NOURL || ($args =~ /nourl/i)); + $doquote = ($args =~ /quote/i); + $nonfixed = ($args =~ /nonfixed/i); + $keepspace = ($args =~ /keepspace/i); + if ($args =~ /maxwidth=(\d+)/) { + $maxwidth = $1; + } else { + $maxwidth = 0; + } + + ## Grab charset parameter (if defined) + $ctype = $fields{'content-type'}; + ($charset) = $ctype =~ /charset=(\S+)/; + $charset =~ s/['"]//g; $charset =~ tr/A-Z/a-z/; + + ## Check if certain charsets should be left alone + if ($args =~ /asis=(\S+)/i) { + local(@a) = split(':', $1); + foreach (@a) { + tr/A-Z/a-z/; + $asis{$_} = 1; + } + } + + ## Check MIMECharSetConverters if charset should be left alone + if ($main'MIMECharSetConverters{$charset} eq "-decode-") { + $asis{$charset} = 1; + } - $data =~ s%\&%\&%g; - $data =~ s%<%\<%g; - $data =~ s%>%\>%g; + ## Check if max-width set + if ($maxwidth) { + $* = 1; + $data =~ s/^(.*)$/&break_line($1, $maxwidth)/ge; + $* = 0; + } + + ## Convert data according to charset + if (!$asis{$charset}) { + ## Japanese message + if ($charset =~ /iso-2022-jp/i) { + return (&jp2022(*data)); + + ## Latin 2-6, Greek, Hebrew, Arabic + } elsif ($charset =~ /iso-8859-([2-9]|10)/i) { + $data = &iso_8859'str2sgml($data, $charset); + + ## ASCII, Latin 1, Other + } else { + &esc_chars_inplace(*data); + } + } else { + &esc_chars_inplace(*data); + } + + ## Check for quoting + if ($doquote) { + $* = 1; + $data =~ s@^( ?${HQuoteChars})(.*)$@$1$2@go; + $* = 0; + } + + ## Check if using nonfixed font + if ($nonfixed) { + $data =~ s/(\r?\n)/
    $1/g; + if ($keepspace) { + $* = 1; + $data =~ s/^(.*)$/&preserve_space($1)/ge; + $* = 0; + } + } else { + $data = "
    \n" . $data . "
    \n"; + } ## Convert URLs to hyperlinks - $data =~ s%($HUrlExp)%$1%gio unless $nourl; - ("
    \n" . $data . "
    \n"); + $data =~ s@($HUrlExp)@$1@gio unless $nourl; + + ($data); +} + +##---------------------------------------------------------------------------## +## Function to convert ISO-2022-JP data into HTML. Function is based +## on the following RFCs: +## +## RFC-1468 I +## J. Murai, M. Crispin, E. van der Poel, "Japanese Character +## Encoding for Internet Messages", 06/04/1993. (Pages=6) +## +## RFC-1554 I +## M. Ohta, K. Handa, "ISO-2022-JP-2: Multilingual Extension of +## ISO-2022-JP", 12/23/1993. (Pages=6) +## +## Author of function: +## NIIBE Yutaka gniibe@mri.co.jp +## (adapted for mhtxtplain.pl by Earl Hood ) +## +sub jp2022 { + local(*body) = shift; + local(@lines) = split(/\r?\n/,$body); + local($ret, $ascii_text); + + $ret = "
    \n";
    +    for ($i = 0; $i <= $#lines; $i++) {
    +        $_ = $lines[$i];
    +
    +	# Process preceding ASCII text
    +	while(1) {
    +	    if (/^[^\033]+/) {	# ASCII plain text
    +		$ascii_text = $&;
    +		$_ = $';
    +
    +		# Replace meta characters in ASCII plain text
    +		$ascii_text =~ s%\&%\&%g;
    +		$ascii_text =~ s%<%\<%g;
    +		$ascii_text =~ s%>%\>%g;
    +		## Convert URLs to hyperlinks
    +		$ascii_text =~ s%($HUrlExp)%$1%gio
    +		    unless $'NOURL;
    +
    +		$ret .= $ascii_text;
    +	    } elsif (/\033\.[A-F]/) { # G2 Designate Sequence
    +		$_ = $';
    +		$ret .= $&;
    +	    } elsif (/\033N[ -]/) { # Single Shift Sequence
    +		$_ = $';
    +		$ret .= $&;
    +	    } else {
    +		last;
    +	    }
    +	}
    +
    +	# Process Each Segment
    +	while(1) {
    +	    if (/^\033\([BJ]/) { # Single Byte Segment
    +		$_ = $';
    +		$ret .= $&;
    +		while(1) {
    +		    if (/^[^\033]+/) {	# ASCII plain text
    +			$ascii_text = $&;
    +			$_ = $';
    +
    +			# Replace meta characters in ASCII plain text
    +			$ascii_text =~ s%\&%\&%g;
    +			$ascii_text =~ s%<%\<%g;
    +			$ascii_text =~ s%>%\>%g;
    +			## Convert URLs to hyperlinks
    +			$ascii_text =~ s%($HUrlExp)%$1%gio
    +			    unless $'NOURL;
    +
    +			$ret .= $ascii_text;
    +		    } elsif (/\033\.[A-F]/) { # G2 Designate Sequence
    +			$_ = $';
    +			$ret .= $&;
    +		    } elsif (/\033N[ -]/) { # Single Shift Sequence
    +			$_ = $';
    +			$ret .= $&;
    +		    } else {
    +			last;
    +		    }
    +		}
    +	    } elsif (/^\033\$[\@AB]|\033\$\([CD]/) { # Double Byte Segment
    +		$_ = $';
    +		$ret .= $&;
    +		while(1) {
    +		    if (/^([!-~][!-~])+/) { # Double Char plain text
    +			$_ = $';
    +			$ret .= $&;
    +		    } elsif (/\033\.[A-F]/) { # G2 Designate Sequence
    +			$_ = $';
    +			$ret .= $&;
    +		    } elsif (/\033N[ -]/) { # Single Shift Sequence
    +			$_ = $';
    +			$ret .= $&;
    +		    } else {
    +			last;
    +		    }
    +		}
    +	    } else {
    +		# Something wrong in text
    +		$ret .= $_;
    +		last;
    +	    }
    +	}
    +
    +	$ret .= "\n";
    +    }
    +
    +    $ret .= "
    \n"; + + ($ret); +} + +##---------------------------------------------------------------------------## + +sub esc_chars_inplace { + local(*foo) = shift; + $foo =~ s@\&@\&@g; + $foo =~ s@<@\<@g; + $foo =~ s@>@\>@g; + 1; +} + +##---------------------------------------------------------------------------## + +sub preserve_space { + local($str) = shift; + + 1 while $str =~ s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e; + # $str =~ s/ {2,}/' ' x length($&)/ge; + $str =~ s/ /\ /g; + $str; } +##---------------------------------------------------------------------------## + +sub break_line { + local($str) = shift; + local($width) = shift; + local($q, $new) = ('', ''); + local($try, $trywidth); + + ## Translate tabs to spaces + 1 while $str =~ s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e; + + ## Do nothing if str <= width + return $str if length($str) <= $width; + + ## See if str begins with a quote char + if ($str =~ s/^($QuoteChars)//) { + $q = $1; + --$width; + } + + ## Create new string by breaking up str + while ($str) { + + # handle case where no-whitespace line larger than width + if (($str =~ /^\S+/) && (length($&) >= $width)) { + $new .= $q . $&; + $str = $'; + next; + } + + $try = ''; + $trywidth = $width; + $try = substr($str, 0, $trywidth); + + if ($try =~ /\S+$/) { + $trywidth -= length($&); + $new .= $q . substr($str, 0, $trywidth); + } else { + $new .= $q . $try; + } + substr($str, 0, $trywidth) = ''; + + } continue { + $new .= "\n" if $str; + } + $new; +} + +##---------------------------------------------------------------------------## 1; diff --git a/lib/mhtxtsetext.pl b/lib/mhtxtsetext.pl index 454a438..854bd2b 100644 --- a/lib/mhtxtsetext.pl +++ b/lib/mhtxtsetext.pl @@ -1,6 +1,7 @@ ##---------------------------------------------------------------------------## +## @(#) mhtxtsetext.pl 1.1 96/09/17 @(#) ## Library to convert text/setext to HTML. Adapted for use in MHonArc -## by ehood@isogen.com, Sept 1994. +## by ehood@medusa.acs.uci.edu, Sept 1994. ## Filter routine can be registered with the following: ## ## text/setext:m2h_text_setext'filter:mhtxtsetext.pl diff --git a/lib/mhusage.pl b/lib/mhusage.pl new file mode 100644 index 0000000..e4a6b07 --- /dev/null +++ b/lib/mhusage.pl @@ -0,0 +1,136 @@ +##---------------------------------------------------------------------------## +## File: +## @(#) mhusage.pl 1.1 97/02/06 19:14:31 @(#) +## Author: +## Earl Hood ehood@medusa.acs.uci.edu +## Description: +## Usage output. +##---------------------------------------------------------------------------## +## MHonArc -- Internet mail-to-HTML converter +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu +## +## This program is free software; you can redistribute it and/or modify +## it under the terms of the GNU General Public License as published by +## the Free Software Foundation; either version 2 of the License, or +## (at your option) any later version. +## +## This program is distributed in the hope that it will be useful, +## but WITHOUT ANY WARRANTY; without even the implied warranty of +## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +## GNU General Public License for more details. +## +## You should have received a copy of the GNU General Public License +## along with this program; if not, write to the Free Software +## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +##---------------------------------------------------------------------------## + +select(STDOUT); +print <] ... + $PROG [] -rmm ... +Options: + -add : Add message(s) to archive + -authsort : Sort messages by author + -conlen : Honor Content-Length fields + -decodeheads : Decode 1522 decode-only data when reading mail + -definevars : Define custom resource variables + -dbfile : Name of MHonArc database file + (def: ".mhonarc.db") + -doc : Print link to doc at end of index page + -docurl : URL to MHonArc documentation + (def: "http://www.oac.uci.edu/indiv/ehood/ + mhonarc.html") + -editidx : Only edit/change index page and messages + -expiredate : Message cut-off date + -expireage : Time in seconds from current if message expires + -folrefs : Print links to explicit follow-ups/references + -force : Perform archive operation even if unable to lock + -footer : File containing user text for bottom of index page + -genidx : Output index to stdout based upon archive contents + -gmtdatefmt : Format for GMT date + -header : User text to include at top of index page + -help : This message + -idxfname : Name of index page + (def: "maillist.html") + -idxprefix : Filename prefix for multi-page main index + (def: "mail") + -idxsize <#> : Maximum number of messages shown in indexes + -localdatefmt : Format for local date + -lockdelay <#> : Time delay, in seconds, between lock tries + (def: "3") + -locktries <#> : Maximum number of tries in locking an archive + (def: "10") + -mailtourl : URL to use for e-mail address hyperlinks + (def: "mailto:\$TO\$") + -main : Create a main index + -maxsize <#> : Maximum number of messages allowed in archive + -mhpattern : Perl expression for message files in a directory + (def: "^\\d+$") + -modtime : Set modification time on files to message date + -months : Month names + -monthsabr : Abbreviated month names + -msgsep : Message separator (Perl) expression for mbox files + (def: "^From ") + -multipg : Generate multi-page indexes + -news : Add links to newsgroups + -noauthsort : Do not sort messages by author + -noconlen : Ignore Content-Length fields + -nodecodeheads : Leave message headers "as is" when read + -nodoc : Do not print link to doc at end of index page + -nofolrefs : Do not print links to explicit follow-ups/references + -nomailto : Do not add in mailto links for e-mail addresses + -nomain : Do not create a main index + -nomodtime : Do not set mod time on files to message date + -nomultipg : Do not generate multi-page indexes + -nonews : Do not add links to newsgroups + -noreverse : List messages in normal order + -nosort : Do not sort messages + -nosubsort : Do not sort messages by subject + -nothread : Do not create threaded index + -nourl : Do not make URL hyperlinks + -otherindexes : List of other rcfiles for extra indexes + -outdir : Destination/location of HTML mail archive + (def: ".") + -perlinc : List of paths to search for MIME filters + -quiet : Suppress status messages during execution + -rcfile : Resource file for MHonArc + -reverse : List messages in reverse order + -rmm : Remove messages from archive + -savemem : Write message data while processing + -scan : List out archive contents to stdout + -single : Convert a single message to HTML + -sort : Sort messages by date (this is the default) + -subsort : Sort message by subject + -thread : Create threaded index + -tidxfname : Filename of threaded index page + (def: "threads.html") + -tidxprefix : Filename prefix for multi-page thread index + (def: "thrd") + -time : Print to stderr CPU time used to process mail + -title : Title of main index page + (def: "Mail Index") + -tlevels <#> : Maximum # of nested lists in threaded index + (def: "3") + -treverse : List threads with newest thread first + -ttitle : Title of thread index page + (def: "Mail Thread Index") + -umask : Umask of MHonArc process (Unix only) + -url : Make URL hyperlinks + -v : Print version information + -weekdays : Weekday names + -weekdaysabr : Abbreviated weekday names + +Description: + MHonArc is a highly customizable Perl program for converting e-mail, + encoded with MIME, into HTML. MHonArc supports the conversion of UUCP + style mailbox files or MH mail folders into HTML with an index linking + to each mail message. The -single option can be used to convert a + single mail message. + + Read the documentation for more complete usage information. + +Version: +$VINFO +EndOfUsage + +1; diff --git a/lib/mhutil.pl b/lib/mhutil.pl index f5a6b0e..b1a5d75 100644 --- a/lib/mhutil.pl +++ b/lib/mhutil.pl @@ -1,15 +1,13 @@ ##---------------------------------------------------------------------------## ## File: -## mhutil.pl +## @(#) mhutil.pl 1.11 97/05/13 @(#) ## Author: -## Earl Hood ehood@isogen.com -## Date: -## Wed Apr 17 00:46:26 CDT 1996 +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Utility routines for MHonArc ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995,1996 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -26,516 +24,44 @@ ## Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ##---------------------------------------------------------------------------## -package main; +## Regular expression variables for sorting routines +$PreSubjectStripExp = q{^\s*(re|sv|fwd|fw)(\[[\d+]\])?[:>-]+\s*}; +$ArtSubjectStripExp = q{^(the|a|an)\s+}; -%Month2Num = ( - 'Jan', 0, 'Feb', 1, 'Mar', 2, 'Apr', 3, 'May', 4, 'Jun', 5, 'Jul', 6, - 'Aug', 7, 'Sep', 8, 'Oct', 9, 'Nov', 10, 'Dec', 11, -); -%WDay2Num = ( - 'Sun', 0, 'Mon', 1, 'Tue', 2, 'Wed', 3, 'Thu', 4, 'Fri', 5, 'Sat', 6, -); - -##---------------------------------------------------------------------------## -## MHonArc based routines -##---------------------------------------------------------------------------## ##--------------------------------------------------------------------------- -## read_fmt_file() parses the resource file. The name is misleading. -## (The code for this routine could probably be simplified). +## convert_line() translates a line to HTML. Checks are made for +## embedded URLs. ## -sub read_fmt_file { - local($file) = shift; - local($line, $tag, $label, $acro, $hr, $type, $routine, $plfile, - $url, $arg); - local($elem, $attr, $override); - - if (!open(FMT, $file)) { - warn "Warning: Unable to open resource file: $file\n"; - return 0; - } - print STDOUT "Reading resource file: $file ...\n" unless $QUIET; - while ($line = ) { - next unless $line =~ /^\s*<([^>]+)>/; - ($elem, $attr) = split(' ', $1, 2); - $elem =~ tr/A-Z/a-z/; - $override = ($attr =~ /override/i); - FMTSW: { - if ($elem eq "botlinks") { # Bottom links in message - $BOTLINKS = ''; - while ($line = ) { - last if $line =~ /^\s*<\/botlinks\s*>/i; - $BOTLINKS .= $line; - } - last FMTSW; - } - if ($elem eq "docurl") { # Doc URL - while ($line = ) { - last if $line =~ /^\s*<\/docurl\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; $DOCURL = $line; - } - last FMTSW; - } - if ($elem eq "dbfile") { # Database file - while ($line = ) { - last if $line =~ /^\s*<\/dbfile\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; $DBFILE = $line; - } - last FMTSW; - } - if ($elem eq "excs") { # Exclude header fields - %HFieldsExc = () if $override; - while ($line = ) { - last if $line =~ /^\s*<\/excs\s*>/i; - $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; - $HFieldsExc{$line} = 1 if $line; - } - last FMTSW; - } - if ($elem eq "fieldstyles") { # Field text style - while ($line = ) { - last if $line =~ /^\s*<\/fieldstyles\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; - ($label, $tag) = split(/:/,$line); - $HeadFields{$label} = $tag; - } - last FMTSW; - } - if ($elem eq "fieldorder") { # Field order - @FieldOrder = (); %FieldODefs = (); - while ($line = ) { - last if $line =~ /^\s*<\/fieldorder\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; - push(@FieldOrder, $line); - $FieldODefs{$line} = 1; - } - push(@FieldOrder,'-extra-') if (!$FieldODefs{'-extra-'}); - last FMTSW; - } - if ($elem eq "footer") { # Footer file - while ($line = ) { - last if $line =~ /^\s*<\/footer\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $FOOTER = $line; - } - last FMTSW; - } - if ($elem eq "header") { # Header file - while ($line = ) { - last if $line =~ /^\s*<\/header\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $HEADER = $line; - } - last FMTSW; - } - if ($elem eq "icons") { # Icons - %Icons = () if $override; - while ($line = ) { - last if $line =~ /^\s*<\/icons\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - ($type, $url) = split(/:/,$line,2); - $type =~ tr/A-Z/a-z/; - $Icons{$type} = $url; - } - last FMTSW; - } - if ($elem eq "idxfname") { # Index filename - while ($line = ) { - last if $line =~ /^\s*<\/idxfname\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $IDXNAME = $line; - } - last FMTSW; - } - if ($elem eq "idxpgbegin") { # Opening markup of index - $IDXPGBEG = ''; - while ($line = ) { - last if $line =~ /^\s*<\/idxpgbegin\s*>/i; - $IDXPGBEG .= $line; - } - last FMTSW; - } - if ($elem eq "idxpgend") { # Closing markup of index - $IDXPGEND = ''; - while ($line = ) { - last if $line =~ /^\s*<\/idxpgend\s*>/i; - $IDXPGEND .= $line; - } - last FMTSW; - } - if ($elem eq "idxsize") { # Size of index - while ($line = ) { - last if $line =~ /^\s*<\/idxsize\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $IDXSIZE = $line if ($line =~ /^\d+$/); - } - last FMTSW; - } - if ($elem eq "labelstyles") { # Field label style - while ($line = ) { - last if $line =~ /^\s*<\/labelstyles\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; $line =~ tr/A-Z/a-z/; - ($label, $tag) = split(/:/,$line); - $HeadHeads{$label} = $tag; - } - last FMTSW; - } - if ($elem eq "listbegin") { # List begin - $LIBEG = ''; - while ($line = ) { - last if $line =~ /^\s*<\/listbegin\s*>/i; - $LIBEG .= $line; - } - last FMTSW; - } - if ($elem eq "listend") { # List end - $LIEND = ''; - while ($line = ) { - last if $line =~ /^\s*<\/listend\s*>/i; - $LIEND .= $line; - } - last FMTSW; - } - if ($elem eq "litemplate") { # List item template - $LITMPL = ''; - while ($line = ) { - last if $line =~ /^\s*<\/litemplate\s*>/i; - $LITMPL .= $line; - } - last FMTSW; - } - if ($elem eq "mailtourl") { # mailto URL - while ($line = ) { - last if $line =~ /^\s*<\/mailtourl\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $MAILTOURL = $line; - } - last FMTSW; - } - if ($elem eq "maxsize") { # Size of archive - while ($line = ) { - last if $line =~ /^\s*<\/maxsize\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $MAXSIZE = $line if ($line =~ /^\d+$/); - } - last FMTSW; - } - if ($elem eq "mimefilters") { # Mime filters - @Requires = (), %MIMEFilters = () if $override; - while ($line = ) { - last if $line =~ /^\s*<\/mimefilters\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - ($type,$routine,$plfile) = split(/:/,$line,3); - $type =~ tr/A-Z/a-z/; - $MIMEFilters{$type} = $routine; - push(@Requires, $plfile); - } - last FMTSW; - } - if ($elem eq "mimeargs") { # Mime arguments - %MIMEFiltersArgs = () if $override; - while ($line = ) { - last if $line =~ /^\s*<\/mimeargs\s*>/i; - next if $line =~ /^\s*$/; - ($type,$arg) = split(/:/,$line,2); - $type =~ tr/A-Z/a-z/ if $type =~ m%/%; - $MIMEFiltersArgs{$type} = $arg; - } - last FMTSW; - } - if ($elem eq "msgfoot") { # Message footer text - $MSGFOOT = ''; - while ($line = ) { - last if $line =~ /^\s*<\/msgfoot\s*>/i; - $MSGFOOT .= $line; - } - last FMTSW; - } - if ($elem eq "msghead") { # Message header text - $MSGHEAD = ''; - while ($line = ) { - last if $line =~ /^\s*<\/msghead\s*>/i; - $MSGHEAD .= $line; - } - last FMTSW; - } - if ($elem eq "msgpgbegin") { # Opening markup of message - $MSGPGBEG = ''; - while ($line = ) { - last if $line =~ /^\s*<\/msgpgbegin\s*>/i; - $MSGPGBEG .= $line; - } - last FMTSW; - } - if ($elem eq "msgpgend") { # Closing markup of message - $MSGPGEND = ''; - while ($line = ) { - last if $line =~ /^\s*<\/msgpgend\s*>/i; - $MSGPGEND .= $line; - } - last FMTSW; - } - if ($elem eq "msgsep") { # Message separator - while ($line = ) { - last if $line =~ /^\s*<\/msgsep\s*>/i; - next if $line =~ /^\s*$/; - chop $line; - $FROM = $line; - } - last FMTSW; - } - if ($elem eq "nextbutton") { # Next button link in message - $NEXTBUTTON = ''; - while ($line = ) { - last if $line =~ /^\s*<\/nextbutton\s*>/i; - $NEXTBUTTON .= $line; - } - chop $NEXTBUTTON; - last FMTSW; - } - if ($elem eq "nextbuttonia") { - $NEXTBUTTONIA = ''; - while ($line = ) { - last if $line =~ /^\s*<\/nextbuttonia\s*>/i; - $NEXTBUTTONIA .= $line; - } - chop $NEXTBUTTONIA; - last FMTSW; - } - if ($elem eq "nextlink") { # Next link in message - $NEXTLINK = ''; - while ($line = ) { - last if $line =~ /^\s*<\/nextlink\s*>/i; - $NEXTLINK .= $line; - } - last FMTSW; - } - if ($elem eq "nextlinkia") { - $NEXTLINKIA = ''; - while ($line = ) { - last if $line =~ /^\s*<\/nextlinkia\s*>/i; - $NEXTLINKIA .= $line; - } - last FMTSW; - } - if ($elem eq "nodoc") { - $NODOC = 1; last FMTSW; - } - if ($elem eq "nonews") { - $NONEWS = 1; last FMTSW; - } - if ($elem eq "nomailto") { - $NOMAILTO = 1; last FMTSW; - } - if ($elem eq "noreverse") { - $REVSORT = 0; last FMTSW; - } - if ($elem eq "nosort") { - $NOSORT = 1; $SUBSORT = 0; last FMTSW; - } - if ($elem eq "nothread") { - $THREAD = 0; last FMTSW; - } - if ($elem eq "notreverse") { - $TREVERSE = 0; last FMTSW; - } - if ($elem eq "notsubsort") { - $TSUBSORT = 0; last FMTSW; - } - if ($elem eq "nourl") { - $NOURL = 1; last FMTSW; - } - if ($elem eq "otherindexes") { # Other indexes - @OtherIdxs = (); - while ($line = ) { - last if $line =~ /^\s*<\/otherindexes\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - push(@OtherIdxs, $line); - } - last FMTSW; - } - if ($elem eq "perlinc") { # Message separator - @PerlINC = () if $override; - while ($line = ) { - last if $line =~ /^\s*<\/perlinc\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - unshift(@PerlINC, $line); - } - last FMTSW; - } - if ($elem eq "prevbutton") { # Prev button link in message - $PREVBUTTON = ''; - while ($line = ) { - last if $line =~ /^\s*<\/prevbutton\s*>/i; - $PREVBUTTON .= $line; - } - chop $PREVBUTTON; - last FMTSW; - } - if ($elem eq "prevbuttonia") { - $PREVBUTTONIA = ''; - while ($line = ) { - last if $line =~ /^\s*<\/prevbuttonia\s*>/i; - $PREVBUTTONIA .= $line; - } - chop $PREVBUTTONIA; - last FMTSW; - } - if ($elem eq "prevlink") { # Prev link in message - $PREVLINK = ''; - while ($line = ) { - last if $line =~ /^\s*<\/prevlink\s*>/i; - $PREVLINK .= $line; - } - last FMTSW; - } - if ($elem eq "prevlinkia") { - $PREVLINKIA = ''; - while ($line = ) { - last if $line =~ /^\s*<\/prevlinkia\s*>/i; - $PREVLINKIA .= $line; - } - last FMTSW; - } - if ($elem eq "reverse") { - $REVSORT = 1; last FMTSW; - } - if ($elem eq "sort") { - $NOSORT = 0; $SUBSORT = 0; last FMTSW; - } - if ($elem eq "subsort") { - $NOSORT = 0; $SUBSORT = 1; last FMTSW; - } - if ($elem eq "thead") { # Thread idx head - $THEAD = ''; - while ($line = ) { - last if $line =~ /^\s*<\/thead\s*>/i; - $THEAD .= $line; - } - last FMTSW; - } - if ($elem eq "tfoot") { # Thread idx foot - $TFOOT = ''; - while ($line = ) { - last if $line =~ /^\s*<\/tfoot\s*>/i; - $TFOOT .= $line; - } - last FMTSW; - } - if ($elem eq "tidxfname") { # Threaded idx filename - while ($line = ) { - last if $line =~ /^\s*<\/tidxfname\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $TIDXNAME = $line; - } - last FMTSW; - } - if ($elem eq "tidxpgbegin") { # Opening markup of thread idx - $TIDXPGBEG = ''; - while ($line = ) { - last if $line =~ /^\s*<\/tidxpgbegin\s*>/i; - $TIDXPGBEG .= $line; - } - last FMTSW; - } - if ($elem eq "tidxpgend") { # Closing markup of thread idx - $TIDXPGEND = ''; - while ($line = ) { - last if $line =~ /^\s*<\/tidxpgend\s*>/i; - $TIDXPGEND .= $line; - } - last FMTSW; - } - if ($elem eq "timezones") { # Time zones - %Zone = () if $override; - while ($line = ) { - last if $line =~ /^\s*<\/timezones\s*>/i; - $line =~ s/\s//g; $line =~ tr/a-z/A-Z/; - ($acro,$hr) = split(/:/,$line); - $Zone{$acro} = $hr; - } - last FMTSW; - } - if ($elem eq "title") { # Title of index page - $TITLE = ''; - while ($line = ) { - last if $line =~ /^\s*<\/title\s*>/i; - $TITLE .= $line; - } - last FMTSW; - } - if ($elem eq "tlevels") { # Level of threading - while ($line = ) { - last if $line =~ /^\s*<\/tlevels\s*>/i; - next if $line =~ /^\s*$/; - $line =~ s/\s//g; - $TLEVELS = $line if ($line =~ /^\d+$/); - } - last FMTSW; - } - if ($elem eq "tlitxt") { # Thread idx
  • txt - $TLITXT = ''; - while ($line = ) { - last if $line =~ /^\s*<\/tlitxt\s*>/i; - $TLITXT .= $line; - } - last FMTSW; - } - if ($elem eq "toplinks") { # Top links in message - $TOPLINKS = ''; - while ($line = ) { - last if $line =~ /^\s*<\/toplinks\s*>/i; - $TOPLINKS .= $line; - } - last FMTSW; - } - if ($elem eq "tsubsort") { - $TSUBSORT = 1; last FMTSW; - } - if ($elem eq "ttitle") { # Title of threaded idx - $TTITLE = ''; - while ($line = ) { - last if $line =~ /^\s*<\/ttitle\s*>/i; - $TTITLE .= $line; - } - last FMTSW; - } - if ($elem eq "thread") { - $THREAD = 1; last FMTSW; - } - if ($elem eq "treverse") { - $TREVERSE = 1; last FMTSW; - } - if ($elem eq "umask") { # Umask of process - while ($line = ) { - last if $line =~ /^\s*<\/umask\s*>/i; - next if $line =~ /^\s*$/; - chop $line; - $UMASK = $line; - } - last FMTSW; - } +sub convert_line { + local($str, $charset) = ($_[0], $_[1]); + local($item, $item2, $item2h, @array); - } ## End FMTSW + if (!$NOURL && + (@array = split(m%($Url[^\s\(\)\|<>"']*[^\.\?;,"'\|\[\]\(\)\s<>])%o, + $str)) + ) { + $str = ''; + while($#array > 0) { + $item = &entify(shift @array); # Get non-URL text + $item2 = shift @array; # Get URL + $item2h = &entify($item2); # Variable for content + + $str .= join('', + $item, + '', $item2h, ''); + + # The next line is needed since Perl's split function also + # returns extra entries for nested ()'s in the split pattern. + shift @array if $array[0] =~ m%^$Url$%o; + } + $item = &entify(shift @array); # Last item in array + $str .= $item; + } else { + $str = &htmlize($str); } - close(FMT); - 1; + $str; } + ##--------------------------------------------------------------------------- ## Get an e-mail address from (HTML) $str. ## @@ -543,7 +69,7 @@ sub extract_email_address { local($str) = shift; local($ret); - if ($str =~ /\<(\S+)\>/) { + if ($str =~ /<(\S+)>/) { $ret = $1; } elsif ($str =~ s/\([^\)]+\)//) { $str =~ /\s*(\S+)\s*/; $ret = $1; @@ -552,14 +78,15 @@ sub extract_email_address { } $ret; } + ##--------------------------------------------------------------------------- -## Get an e-mail name from (HTML) $str. +## Get an e-mail name from $str. ## sub extract_email_name { local($str) = shift; local($ret); - if ($str =~ s/\<(\S+)\>//) { # Check for: name + if ($str =~ s/<(\S+)>//) { # Check for: name $ret = $1; if ($str !~ /^\s*$/) { # strip extra whitespace ($ret = $str) =~ s/\s+/ /g; @@ -577,237 +104,291 @@ sub extract_email_name { } $ret; } + ##--------------------------------------------------------------------------- ## Routine to sort messages ## sub sort_messages { - local(@a); - if ($NOSORT) { # Message processed order - if ($REVSORT) { @a = sort decrease_msgnum keys %Subject; } - else { @a = sort increase_msgnum keys %Subject; } + if ($NOSORT) { # Processed order + if ($REVSORT) { return sort decrease_msgnum keys %Subject; } + else { return sort increase_msgnum keys %Subject; } } elsif ($SUBSORT) { # Subject order - if ($REVSORT) { @a = sort decrease_subject keys %Subject; } - else { @a = sort increase_subject keys %Subject; } + if ($REVSORT) { return sort decrease_subject keys %Subject; } + else { return sort increase_subject keys %Subject; } + + } elsif ($AUTHSORT) { # Author order + if ($REVSORT) { return sort decrease_author keys %Subject; } + else { return sort increase_author keys %Subject; } } else { # Date order - if ($REVSORT) { @a = sort decrease_index keys %Subject; } - else { @a = sort increase_index keys %Subject; } + if ($REVSORT) { return sort decrease_index keys %Subject; } + else { return sort increase_index keys %Subject; } } - @a; } + ##--------------------------------------------------------------------------- ## Message-sort routines for sort_messages ## sub increase_msgnum { - local(@A) = split(/$'X/o, $a); - local(@B) = split(/$'X/o, $b); - local($sret); - $sret = $A[1] <=> $B[1]; - ($sret == 0 ? $A[0] <=> $B[0] : $sret); + $IndexNum{$a} <=> $IndexNum{$b}; } sub decrease_msgnum { - local(@A) = split(/$'X/o, $a); - local(@B) = split(/$'X/o, $b); - local($sret); - $sret = $B[1] <=> $A[1]; - ($sret == 0 ? $B[0] <=> $A[0] : $sret); + $IndexNum{$b} <=> $IndexNum{$a}; } sub increase_index { - local(@A) = split(/$'X/o, $a); - local(@B) = split(/$'X/o, $b); - local($sret); - $sret = $A[0] <=> $B[0]; - ($sret == 0 ? $A[1] <=> $B[1] : $sret); + (&get_time_from_index($a) <=> &get_time_from_index($b)) || + ($IndexNum{$a} <=> $IndexNum{$b}); } sub decrease_index { - local(@A) = split(/$'X/o, $a); - local(@B) = split(/$'X/o, $b); - local($sret); - $sret = $B[0] <=> $A[0]; - ($sret == 0 ? $B[1] <=> $A[1] : $sret); + (&get_time_from_index($b) <=> &get_time_from_index($a)) || + ($IndexNum{$b} <=> $IndexNum{$a}); } sub increase_subject { local($A, $B) = ($Subject{$a}, $Subject{$b}); - local($at, $bt) = ((split(/$'X/o, $a))[0], (split(/$'X/o, $b))[0]); $A =~ tr/A-Z/a-z/; $B =~ tr/A-Z/a-z/; - 1 while $A =~ s/^\s*(re|sv|fwd|fw)[:>-]+\s*//i; - 1 while $B =~ s/^\s*(re|sv|fwd|fw)[:>-]+\s*//i; - $A =~ s/^(the|a|an)\s+//i; $B =~ s/^(the|a|an)\s+//i; - local($sret) = ($A cmp $B); - ($sret == 0 ? $at <=> $bt : $sret); + 1 while $A =~ s/$PreSubjectStripExp//io; + 1 while $B =~ s/$PreSubjectStripExp//io; + $A =~ s/$ArtSubjectStripExp//io; $B =~ s/$ArtSubjectStripExp//io; + ($A cmp $B) || (&get_time_from_index($a) <=> &get_time_from_index($b)); } sub decrease_subject { local($A, $B) = ($Subject{$a}, $Subject{$b}); - local($at, $bt) = ((split(/$'X/o, $a))[0], (split(/$'X/o, $b))[0]); $A =~ tr/A-Z/a-z/; $B =~ tr/A-Z/a-z/; - 1 while $A =~ s/^\s*(re|sv|fwd|fw)[:>-]+\s*//i; - 1 while $B =~ s/^\s*(re|sv|fwd|fw)[:>-]+\s*//i; - $A =~ s/^(the|a|an)\s+//i; $B =~ s/^(the|a|an)\s+//i; - local($sret) = ($B cmp $A); - ($sret == 0 ? $bt <=> $at : $sret); + 1 while $A =~ s/$PreSubjectStripExp//io; + 1 while $B =~ s/$PreSubjectStripExp//io; + $A =~ s/$ArtSubjectStripExp//io; $B =~ s/$ArtSubjectStripExp//io; + ($A cmp $B) || (&get_time_from_index($b) <=> &get_time_from_index($a)); +} +sub increase_author { + local($A, $B) = (&extract_email_name($From{$a}), + &extract_email_name($From{$b})); + $A =~ tr/A-Z/a-z/; $B =~ tr/A-Z/a-z/; + ($A cmp $B) || (&get_time_from_index($a) <=> &get_time_from_index($b)); +} +sub decrease_author { + local($A, $B) = (&extract_email_name($From{$a}), + &extract_email_name($From{$b})); + $A =~ tr/A-Z/a-z/; $B =~ tr/A-Z/a-z/; + ($A cmp $B) || (&get_time_from_index($b) <=> &get_time_from_index($a)); } + ##--------------------------------------------------------------------------- ## Routine to determine last message number in use. ## sub get_last_msg_num { - local(@files) = (); - local($n); - opendir(DIR, $'OUTDIR) || &error("ERROR: Unable to open $'OUTDIR"); - @files = sort by_msgnum grep(/^msg\d+\.html?$/i, readdir(DIR)); - grep(s/msg0+(\d)/msg$1/i, @files); - close(DIR); - if (@files) { - ($n) = $files[$#files] =~ /(\d+)/; - } else { - $n = -1; + opendir(DIR, $'OUTDIR) || die("ERROR: Unable to open $'OUTDIR\n"); + local($max) = -1; + foreach (readdir(DIR)) { + if (/^msg0*(\d+).htm/i) { + $max = $1 if $1 > $max; + } } - $n; -} -sub by_msgnum { - ($A) = $a =~ /(\d+)/; - ($B) = $b =~ /(\d+)/; - $A <=> $B; + close(DIR); + $max; } + ##--------------------------------------------------------------------------- ## Routine for formating a message number for use in filenames or links. ## sub fmt_msgnum { - local($num) = $_[0]; - sprintf("%05d", $num); + sprintf("%05d", $_[0]); } + ##--------------------------------------------------------------------------- ## Routine to get filename of a message number. ## sub msgnum_filename { - local($num) = $_[0]; - sprintf("msg%05d.html", $num); + sprintf("msg%05d.html", $_[0]); } -##---------------------------------------------------------------------------## -## MHonArc independent routines -##---------------------------------------------------------------------------## -##--------------------------------------------------------------------------- -## parse_date takes a string date specified like the output of -## date(1) into its components. -## -sub parse_date { - local($date) = $_[0]; - local($wday, $mday, $mon, $yr, $time, $hr, $min, $sec, $zone); - local(@array); - - $date =~ s/^\s*//; - @array = split(' ', $date); - if ($array[0] =~ /\d/) { # DD Mon YY HH:MM:SS Zone - ($mday, $mon, $yr, $time, $zone) = @array; - } elsif ($array[1] =~ /\d/) { # Wdy DD Mon YY HH:MM:SS Zone - ($wday, $mday, $mon, $yr, $time, $zone) = @array; - } else { # Wdy Mon DD HH:MM:SS Zone YYYY - ($wday, $mon, $mday, $time, $zone, $yr) = @array; - if ($zone =~ /\d/) { # No zone - $yr = $zone; - $zone = ''; - } - } - ($hr, $min, $sec) = split(/:/, $time); - $sec = 0 unless $sec; # Sometime seconds not defined - ($WDay2Num{$wday}, $mday, $Month2Num{$mon}, $yr, $hr, $min, $sec, $zone); -} ##--------------------------------------------------------------------------- +## Routine to get filename of an index ## -sub time2mmddyy { - local($time, $fmt) = ($_[0], $_[1]); - local($day,$mon,$year); - if ($time) { - ($day,$mon,$year) = (localtime($time))[3,4,5]; - if ($fmt =~ /ddmmyy/i) { - $tmp = sprintf("%02d/%02d/%02d", $day, $mon+1, $year); - } elsif ($fmt =~ /yymmdd/i) { - $tmp = sprintf("%02d/%02d/%02d", $year, $mon+1, $day); - } else { - $tmp = sprintf("%02d/%02d/%02d", $mon+1, $day, $year); - } - } else { - $tmp = "--/--/--"; - } +sub get_filename_from_index { + sprintf("msg%05d.html", $IndexNum{$_[0]}); } + ##--------------------------------------------------------------------------- -## Remove duplicates in an array. +## Routine to get time component from index ## -sub remove_dups { - local(*array) = shift; - local(%dup); - @array = grep($dup{$_}++ < 1, @array); - %dup = (); +sub get_time_from_index { + (split(/$'X/o, $_[0]))[0]; } + ##--------------------------------------------------------------------------- -## numerically() is used to tell 'sort' to sort by numbers. +## Routine to get lc author name from index ## -sub numerically { - $a <=> $b; +sub get_base_author { + local($ret) = (&extract_email_name($From{$_[0]})); + $ret =~ tr/A-Z/a-z/; + $ret; } + ##--------------------------------------------------------------------------- -## "Entify" special characters +## Routine to get base subject text from index ## -sub htmlize { # Older name, variable passed by reference - local(*txt) = $_[0]; - $txt =~ s/&/\&/g; - $txt =~ s/>/>/g; - $txt =~ s//>/g; - $txt =~ s/ $dst") || &error("ERROR: Unable to create $dst"); - print DST ; - close(SRC); - close(DST); +sub get_time_from_date { + local($mday, $mon, $yr, $hr, $min, $sec, $zone) = @_; + local($time) = 0; + + ## If $zone, grab gmt time, else grab local + if ($zone) { + $time = &timegm($sec,$min,$hr,$mday,$mon, + ($yr > 1900 ? $yr-1900 : $yr)); + + # try to modify time/date based on timezone + if ($zone =~ /^[\+-]\d+$/) { # numeric timezone + $time -= &zone_offset_to_secs($zone); + + # timezone abbrev + } elsif (defined($Zone{$zone})) { + $time += ($Zone{$zone}*3600); + + # undefined timezone + } else { + warn qq|Warning: Unrecognized time zone, "$zone"\n|; + } + + } else { + $time = &timelocal($sec,$min,$hr,$mday,$mon, + ($yr > 1900 ? $yr-1900 : $yr)); + } + $time; } + ##--------------------------------------------------------------------------- -## Get date in date(1)-like format. $local flag is if local time -## should be used. +## Routine to check if time has expired. ## -sub getdate { - local($local) = $_[0]; - local($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst); - local($curtime) = (time()); - - ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = - ($local ? localtime($curtime) : gmtime($curtime)); - sprintf("%s %s %02d %02d:%02d:%02d " . ($local ? "%s" : "GMT %s"), - (Sun,Mon,Tue,Wed,Thu,Fri,Sat)[$wday], - (Jan,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec)[$mon], - $mday, $hour, $min, $sec, $year); +sub expired_time { + ($ExpireTime && (time - $_[0] > $ExpireTime)) || + ($_[0] < $ExpireDateTime); } + ##--------------------------------------------------------------------------- -## Translate html string back to regular string +## Get HTML tags for formatting message headers ## -sub dehtmlize { - local($str) = shift; - $str =~ s/\<//g; - $str =~ s/\&/\&/g; - $str; +sub get_header_tags { + local($f) = shift; + local($ftago, $ftagc, $tago, $tagc); + + ## Get user specified tags (this is one funcky looking code) + $tag = (defined($HeadHeads{$f}) ? + $HeadHeads{$f} : $HeadHeads{"-default-"}); + $ftag = (defined($HeadFields{$f}) ? + $HeadFields{$f} : $HeadFields{"-default-"}); + if ($tag) { $tago = "<$tag>"; $tagc = ""; } + else { $tago = $tagc = ''; } + if ($ftag) { $ftago = "<$ftag>"; $ftagc = ""; } + else { $ftago = $ftagc = ''; } + + ($tago, $tagc, $ftago, $ftagc); } + ##--------------------------------------------------------------------------- -## Escape special characters in string for URL use. +## Format message headers in HTML. ## -sub urlize { - local($url) = shift; - $url =~ s/([{}\[\]\\^~<>\?%=\+ \t])/sprintf("%%%X",unpack("C",$1))/ge; - $url; +sub htmlize_header { + local(*fields, *l2o) = @_; + local($tmp, + $key, + $tago, + $tagc, + $ftago, + $ftagc, + $mesg, + $item, + @array, + %hf); + + %hf = %fields; + foreach $item (@FieldOrder) { + if ($item eq '-extra-') { + foreach $key (sort keys %hf) { + next if $FieldODefs{$key}; + delete $hf{$key}, next if &exclude_field($key); + + @array = split(/$readmail'FieldSep/o, $hf{$key}); + foreach $tmp (@array) { + $tmp = &$MHeadCnvFunc($tmp); + &field_add_links($key, *tmp); + ($tago, $tagc, $ftago, $ftagc) = &get_header_tags($key); + $mesg .= join('', $LABELBEG, + $tago, $l2o{$key}, $tagc, $LABELEND, + $FLDBEG, $ftago, $tmp, $ftagc, $FLDEND, + "\n"); + } + delete $hf{$key}; + } + } else { + if (!&exclude_field($item) && $hf{$item}) { + @array = (split(/$readmail'FieldSep/o, $hf{$item})); + foreach $tmp (@array) { + $tmp = &$MHeadCnvFunc($tmp); + &field_add_links($item, *tmp); + ($tago, $tagc, $ftago, $ftagc) = &get_header_tags($item); + $mesg .= join('', $LABELBEG, + $tago, $l2o{$item}, $tagc, $LABELEND, + $FLDBEG, $ftago, $tmp, $ftagc, $FLDEND, + "\n"); + } + } + delete $hf{$item}; + } + } + if ($mesg) { $mesg = $FIELDSBEG . $mesg . $FIELDSEND; } + $mesg; } + ##---------------------------------------------------------------------------## +## Routine to parse variable definitions in a string. The +## function returns a list of variable/value pairs. The format of +## the string is similiar to attribute specification lists in +## SGML, but NAMEs are any non-whitespace character. +## +sub parse_vardef_str { + local($org) = shift; + local(%hash) = (); + + ($str = $org) =~ s/^\s+//; + while ($str =~ /^([^=\s]+)\s*=\s*/) { + $var = $1; + $str = $'; + if ($str =~ s/^(['"])//) { + $q = $1; + if (!($q eq "'" ? $str =~ s/^([^']*)'// : + $str =~ s/^([^"]*)"//)) { + warn "Warning: Unclosed quote in: $org\n"; + return (); + } + $value = $1; + } else { + if ($str =~ s/^(\S+)//) { + $value = $1; + } else { + warn "Warning: No value after $var in: $org\n"; + return (); + } + } + $str =~ s/^\s+//; + $hash{$var} = $value; + } + if ($str =~ /\S/) { + warn "Warning: Illegal variable definition syntax in: $org\n"; + return (); + } + %hash; +} + +##---------------------------------------------------------------------------## 1; diff --git a/lib/osinit.pl b/lib/osinit.pl index cbe0d6c..971dee9 100644 --- a/lib/osinit.pl +++ b/lib/osinit.pl @@ -1,16 +1,14 @@ ##---------------------------------------------------------------------------## ## File: -## osinit.pl +## @(#) osinit.pl 1.2 97/01/28 12:19:10 @(#) ## Author: -## Earl Hood ehood@isogen.com +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## A library for setting up a script based upon the OS the script ## is running under. The main routine defined is OSinit. See ## the routine for specific information. -## Date: -## Mon Mar 11 15:52:12 CST 1996 ##---------------------------------------------------------------------------## -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -40,6 +38,9 @@ package os_init; ## $'MACOS => Set to 1 if running under Mac ## $'UNIX => Set to 1 if running under Unix ## $'DIRSEP => Directory separator character +## $'DIRSEPREX => Directory separator character for use in +## regular expressions. +## $'PATHSEP => Recommend path list separator ## $'CURDIR => Current working directory ## $'PROG => Program name with leading pathname component ## stripped off. @@ -56,16 +57,19 @@ sub main'OSinit { if (($tmp = $ENV{'COMSPEC'}) && ($tmp =~ /[a-zA-Z]:\\/) && (-e $tmp)) { $'MSDOS = 1; $'MACOS = 0; $'UNIX = 0; $'DIRSEP = '\\'; $'CURDIR = '.'; + $'PATHSEP = ';'; } elsif (defined($MacPerl'Version)) { $'MSDOS = 0; $'MACOS = 1; $'UNIX = 0; $'DIRSEP = ':'; $'CURDIR = ':'; + $'PATHSEP = ';'; } else { $'MSDOS = 0; $'MACOS = 0; $'UNIX = 1; $'DIRSEP = '/'; $'CURDIR = '.'; + $'PATHSEP = ':'; } ## Store name of program - ($tmp = $'DIRSEP) =~ s/(\W)/\\$1/g; - ($'PROG = $0) =~ s%.*[$tmp]%%o; + ($'DIRSEPREX = $'DIRSEP) =~ s/(\W)/\\$1/g; + ($'PROG = $0) =~ s%.*[$'DIRSEPREX]%%o; ## Ask for command-line options if script is a Mac droplet ## Code taken from the MacPerl FAQ diff --git a/lib/qprint.pl b/lib/qprint.pl index 2913e9b..b093639 100644 --- a/lib/qprint.pl +++ b/lib/qprint.pl @@ -1,8 +1,8 @@ ##---------------------------------------------------------------------------## ## File: -## quoted_printable.pl +## @(#) qprint.pl 1.1 96/09/17 @(#) ## Authors: -## Earl Hood ehood@isogen.com +## Earl Hood ehood@medusa.acs.uci.edu ## Alan Barrett barrett@daisy.ee.und.ac.za ## Description: ## This library defines the routine to decode "quoted-printable" @@ -12,7 +12,7 @@ ## $text = "ed_printable'qprdecode($data); ## ##---------------------------------------------------------------------------## -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1995 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by diff --git a/lib/readmail.pl b/lib/readmail.pl index bd02bb3..f932200 100644 --- a/lib/readmail.pl +++ b/lib/readmail.pl @@ -1,18 +1,31 @@ ##---------------------------------------------------------------------------## ## File: -## readmail.pl +## @(#) readmail.pl 1.8 97/02/12 18:12:30 @(#) ## Author: -## Earl Hood ehood@isogen.com +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## Library defining routines to parse MIME e-mail messages. The ## library is designed so it may be reused for other e-mail ## filtering programs. The default behavior is for mail->html ## filtering, however, the defaults can be overridden to allow ## mail->whatever filtering. -## Date: -## Thu Mar 21 13:31:27 CST 1996 +## +## Public Functions: +## ---------------- +## ($data) = +## &main'MAILdecode_1522_str($str); +## ($data, @files) = +## &main'MAILread_body($header, $body, $ctypeArg, $encodingArg); +## ($header) = +## &main'MAILread_file_header($handle, *fields, *l2o); +## ($header) = +## &main'MAILread_header(*mesg, *fields, *l2o); +## +## ($disposition, $filename) = +## &main'MAILhead_get_disposition(*fields); +## ##---------------------------------------------------------------------------## -## Copyright (C) 1995 Earl Hood, ehood@isogen.com +## Copyright (C) 1996,1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -40,67 +53,130 @@ package readmail; ## Variable storing the mulitple fields separator value for the ## the read header routines. + +$FieldSep = "\034"; + +## Flag if message headers are decoded in the parse header routines: +## MAILread_header, MAILread_file_header. This only affects the +## values of the field hash created. The original header is still +## passed as the return value. ## -$main'FieldSep = "\034"; +## The only 1522 data that will be decoded is data encoded with charsets +## set to "-decode-" in the %MIMECharSetConverters hash. + +$DecodeHeader = 0; ##---------------------------------------------------------------------------## ## Variables for folding information related to the functions used ## for processing MIME data. Variables are defined in the scope ## of main. -## MIMEFilters is the associative array for storing functions that -## process various content-types in the MAILread_body routine. +## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +## MIMEDecoders is the associative array for storing functions for +## decoding mime data. ## -## Keys => Content-type (should be in lowercase) +## Keys => content-transfer-encoding (should be in lowercase) ## Values => function name. ## ## Function names should be qualified with package identifiers. ## Functions are called as follows: ## -## $converted_data = &function($header, *parsed_header_assoc_array, -## *message_data, $decoded_flag, -## $optional_filter_arguments); +## $decoded_data = &function($data); ## -## Functions can be registered for base types. Example: +## The value "as-is" may be used to allow the data to be passed without +## decoding to the registered filter, but the decoded flag will be +## set to true. + +%main'MIMEDecoders = () + unless defined(%main'MIMEDecoders); + +## Default settings: + +$main'MIMEDecoders{"7bit"} = "as-is" + unless defined($main'MIMEDecoders{"7bit"}); +$main'MIMEDecoders{"8bit"} = "as-is" + unless defined($main'MIMEDecoders{"8bit"}); +$main'MIMEDecoders{"binary"} = "as-is" + unless defined($main'MIMEDecoders{"binary"}); +$main'MIMEDecoders{"base64"} = "base64'b64decode" + unless defined($main'MIMEDecoders{"base64"}); +$main'MIMEDecoders{"quoted-printable"} = "quoted_printable'qprdecode" + unless defined($main'MIMEDecoders{"quoted-printable"}); +$main'MIMEDecoders{"x-uuencode"} = "base64'uudecode" + unless defined($main'MIMEDecoders{"x-uuencode"}); +$main'MIMEDecoders{"x-uue"} = "base64'uudecode" + unless defined($main'MIMEDecoders{"x-uue"}); +$main'MIMEDecoders{"uuencode"} = "base64'uudecode" + unless defined($main'MIMEDecoders{"uuencode"}); + +## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +## MIMECharSetConverters is the associative array for storing functions +## for converting data in a particular charset to a destination format +## within the MAILdecode_1522_str() routine. Destination format is defined +## by the function. +## +## Keys => charset (should be in lowercase) +## Values => function name. ## -## $MIMEFilters{"image/*"} = "mypackage'function"; +## Charset values take on a form like "iso-8859-1" or "us-ascii". +## NOTE: Values need to be in lower-case. ## -## To register a fallback function to be called if no function is -## defined for a specific content-type, do something like the -## following: +## The key "default" can be assigned to define the default function +## to call if no explicit charset function is defined. ## -## $MIMEFilters{"*/*"} = "mypackage'function"; +## The key "plain" can be set to a function for decoded regular text not +## encoded in 1522 format. ## -## IMPORTANT: If a function specified is not defined when MAILread_body -## tries to invoke it, MAILread_body will silently ignore. Make sure -## that all functions are defined before invoking MAILread_body. +## Function names are name of defined perl function and should be +## qualified with package identifiers. Functions are called as follows: +## +## $converted_data = &function($data, $charset); +## +## A function called "-pass-:function" implies that the data should be +## passed to the converter "function" but not decoded. ## -%main'MIMEFilters = (); +## A function called "-decode-" implies that the data should be +## decoded, but no converter is to be invoked. +## +## A function called "-ignore-" implies that the data should +## not be decoded and converted. Ie. For the specified charset, +## the encoding will stay unprocessed and passed back in the return +## string. -## MIMEDecoders is the associative array for storing functions for -## decoding mime data. +%'MIMECharSetConverters = () + unless defined(%main'MIMECharSetConverters); + +## Default settings: + +$main'MIMECharSetConverters{"default"} = "-ignore-" + unless defined($main'MIMECharSetConverters{"default"}); + +## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +## MIMEFilters is the associative array for storing functions that +## process various content-types in the MAILread_body routine. ## -## Keys => content-transfer-encoding (should be in lowercase) +## Keys => Content-type (should be in lowercase) ## Values => function name. ## ## Function names should be qualified with package identifiers. ## Functions are called as follows: ## -## $decoded_data = &function($data); +## $converted_data = &function($header, *parsed_header_assoc_array, +## *message_data, $decoded_flag, +## $optional_filter_arguments); ## -## The value "as-is" may be used to allow the data to be passed without -## decoding to the registered filter, but the decoded flag will be -## set to true. +## Functions can be registered for base types. Example: ## -%main'MIMEDecoders = (); -## Default settings: -$main'MIMEDecoders{"7bit"} = "as-is"; -$main'MIMEDecoders{"8bit"} = "as-is"; -$main'MIMEDecoders{"binary"} = "as-is"; -$main'MIMEDecoders{"base64"} = "base64'b64decode"; -$main'MIMEDecoders{"quoted-printable"} = "quoted_printable'qprdecode"; -$main'MIMEDecoders{"x-uuencode"} = "base64'uudecode"; +## $MIMEFilters{"image/*"} = "mypackage'function"; +## +## IMPORTANT: If a function specified is not defined when MAILread_body +## tries to invoke it, MAILread_body will silently ignore. Make sure +## that all functions are defined before invoking MAILread_body. +%main'MIMEFilters = () + unless defined(%main'MIMEFilters); + +## - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ## MIMEFiltersArgs is the associative array for storing any optional ## arguments to functions specified in MIMEFilters (the ## $optional_filter_arguments from above). @@ -110,8 +186,9 @@ package readmail; ## ## Arguments listed for a content-type will be used over arguments ## listed for a function if both are applicable. -## -%main'MIMEFiltersArgs = (); + +%main'MIMEFiltersArgs = () + unless defined(%main'MIMEFiltersArgs); ##--------------------------------------------------------------------------- ## Variables holding functions for generating processed output @@ -125,26 +202,30 @@ package readmail; ## Function that returns a message when failing to process a part of a ## a multipart message. The content-type of the message is passed ## as an argument. -## -$CantProcessPartFunc = "cantProcessPart"; + +$CantProcessPartFunc = "cantProcessPart" + unless(defined($CantProcessPartFunc)); ## Function that returns a message when a part is unrecognized in a ## multipart/alternative message. I.e. No part could be processed. ## No arguments are passed to function. -## -$UnrecognizedAltPartFunc = "unrecognizedAltPart"; + +$UnrecognizedAltPartFunc = "unrecognizedAltPart" + unless(defined($UnrecognizedAltPartFunc)); ## Function that returns a string to go before any data generated generating ## from processing an embedded message (message/rfc822 or message/news). ## No arguments are passed to function. -## -$BeginEmbeddedMesgFunc = "beginEmbeddedMesg"; + +$BeginEmbeddedMesgFunc = "beginEmbeddedMesg" + unless(defined($BeginEmbeddedMesgFunc)); ## Function that returns a string to go after any data generated generating ## from processing an embedded message (message/rfc822 or message/news). ## No arguments are passed to function. -## -$EndEmbeddedMesgFunc = "endEmbeddedMesg"; + +$EndEmbeddedMesgFunc = "endEmbeddedMesg" + unless(defined($EndEmbeddedMesgFunc)); ## Function to return a string that is a result of the functions ## processing of a message header. The function is called for @@ -159,13 +240,122 @@ package readmail; ## argument 1 to original case. ## ## Prototype: $return_data = &function(*fields, *lower2orig_fields); -## -$FormatHeaderFunc = ""; + +$FormatHeaderFunc = "" + unless(defined($FormatHeaderFunc)); ############################################################################### ## Public Routines ## ############################################################################### -##--------------------------------------------------------------------------- +##---------------------------------------------------------------------------## +## MAILdecode_1522_str() decodes a string encoded in a format +## specified by RFC 1522. The decoded string is the return value. +## If no MIMECharSetConverters is registered for a charset, then +## the decoded data is returned "as-is". +## +## Usage: +## +## $ret_data = &'MAILdecode_1522_str($str, $justdecode); +## +## If $justdecode is non-zero, $str will be decoded for only +## the charsets specified as "-decode-". +## +sub main'MAILdecode_1522_str { + local($str) = shift; + local($justdecode) = shift; + local($charset, + $lcharset, + $encoding, + $dec, + $charcnv, + $defcharcnv, + $plaincnv, + $strtxt, + $str_before + ); + local($ret) = (''); + + $defcharcnv = '-bogus-'; + + # Get default converter + $defcharcnv = $'MIMECharSetConverters{"default"}; + + # Get plain converter + $plaincnv = $'MIMECharSetConverters{"plain"}; + $plaincnv = $defcharcnv unless $plaincnv; + + # Decode string + while ($str =~ /=\?([^?]+)\?(.)\?([^?]*)\?=/) { + + # Grab components + ($charset, $encoding) = ($1, $2); + $strtxt = $3; $str_before = $`; $str = $'; + + # Check encoding method and grab proper decoder + if ($encoding =~ /b/i) { + $dec = $'MIMEDecoders{"base64"}; + } else { + $dec = $'MIMEDecoders{"quoted-printable"}; + } + + # Convert before (unencoded) text + if ($justdecode) { # ignore if just decode + $ret .= $str_before; + } elsif (defined(&$plaincnv)) { # decode and convert + $ret .= &$plaincnv($str_before,''); + } elsif (($plaincnv =~ /-pass-:(.*)/) && # pass + (defined(&${1}))) { + $ret .= &${1}($str_before,''); + } else { # ignore + $ret .= $str_before; + } + + # Convert encoded text + ($lcharset = $charset) =~ tr/A-Z/a-z/; + $charcnv = $'MIMECharSetConverters{$lcharset}; + $charcnv = $defcharcnv unless $charcnv; + + # Decode only + if ($charcnv eq "-decode-") { + $strtxt =~ s/_/ /g; + $ret .= &$dec($strtxt); + + # Ignore if just decoding + } elsif ($justdecode) { + $ret .= "=?$charset?$encoding?$strtxt?="; + + # Decode and convert + } elsif (defined(&$charcnv)) { + $strtxt =~ s/_/ /g; + $ret .= &$charcnv(&$dec($strtxt),$lcharset); + + # Do not decode, but convert + } elsif (($charcnv =~ /-pass-:(.*)/) && + (defined(&${1}))) { + $ret .= &${1}($str_before,$lcharset); + + # Fallback is to ignore + } else { + $ret .= "=?$charset?$encoding?$strtxt?="; + } + } + + # Convert left-over unencoded text + if ($justdecode) { # ignore if just decode + $ret .= $str; + } elsif (defined(&$plaincnv)) { # decode and convert + $ret .= &$plaincnv($str,''); + } elsif (($plaincnv =~ /-pass-:(.*)/) && # pass + (defined(&${1}))) { + $ret .= &${1}($str,''); + } else { # ignore + $ret .= $str; + } + + $ret; +} + +##---------------------------------------------------------------------------## ## MAILread_body() parses a MIME message body. $header is the ## header of the message. $body is the actual message body. ## $ctypeArg is the value of the Content-Type field and $encodingArg @@ -187,11 +377,11 @@ sub main'MAILread_body { ## Get type/subtype $content = $ctypeArg || 'text/plain'; # Default to text/plain # if no content-type - ($ctype) = $content =~ m%^\s*([\w-/]+)%; # Extract content-type + ($ctype) = $content =~ m%^\s*([\w-\./]+)%; # Extract content-type $ctype =~ tr/A-Z/a-z/; # Convert to lowercase if ($ctype =~ m%/%) { # Extract base and sub types ($type,$subtype) = split(/\//, $ctype, 2); - } elsif ($ctype =~ /text/) { + } elsif ($ctype =~ /text/i) { $ctype = 'text/plain'; $type = 'text'; $subtype = 'plain'; } else { @@ -199,9 +389,9 @@ sub main'MAILread_body { } ## Process message - $filter = $'MIMEFilters{$ctype}; # Specific filter - $filter = $'MIMEFilters{"$type/*"} unless $filter; # Base type filter - $filter = $'MIMEFilters{"*/*"} unless $filter; # Last resort + $filter = $main'MIMEFilters{$ctype}; # Specific filter + $filter = $main'MIMEFilters{"$type/*"} unless $filter; # Base type filter + $filter = $main'MIMEFilters{"*/*"} unless $filter; # Last resort ## A filter is defined for given content-type if ($filter && defined(&$filter)) { @@ -210,16 +400,16 @@ sub main'MAILread_body { local($decodefunc, $decoded, $args) = ('', '', ''); ## Check for filter arguments - $args = $'MIMEFiltersArgs{$ctype}; - $args = $'MIMEFiltersArgs{"$type/*"} if $args eq ''; - $args = $'MIMEFiltersArgs{$filter} if $args eq ''; + $args = $main'MIMEFiltersArgs{$ctype}; + $args = $main'MIMEFiltersArgs{"$type/*"} if $args eq ''; + $args = $main'MIMEFiltersArgs{$filter} if $args eq ''; ## Parse message header for filter - &'MAILread_header(*tmphead, *partfields, *partl2o); + &main'MAILread_header(*tmphead, *partfields, *partl2o); ## Check encoding and decode data $encoding =~ s/\s//g; $encoding =~ tr/A-Z/a-z/; - $decodefunc = $'MIMEDecoders{$encoding}; + $decodefunc = $main'MIMEDecoders{$encoding}; if (defined(&$decodefunc)) { $decoded = &$decodefunc($body); @array = &$filter($header, *partfields, *decoded, 1, $args); @@ -241,7 +431,7 @@ sub main'MAILread_body { if ($content =~ m%boundary\s*=\s*"([^"]*)"%i) { $boundary = $1; } else { - ($boundary) = $content =~ m%boundary\s*=\s*(\S+)%; + ($boundary) = $content =~ m%boundary\s*=\s*(\S+)%i; } $boundary =~ s/(\W)/\\$1/g; @@ -264,7 +454,7 @@ sub main'MAILread_body { $part =~ s/^\r?\n//; # Drop begining newline ## Read header to get content-type - $parthead = &'MAILread_header(*part, *partfields, *partl2o); + $parthead = &main'MAILread_header(*part, *partfields, *partl2o); $partcontent = $partfields{'content-type'}; $partencoding = $partfields{'content-transfer-encoding'}; @@ -280,7 +470,7 @@ sub main'MAILread_body { } ## Process part - @array = &'MAILread_body($parthead, $part, + @array = &main'MAILread_body($parthead, $part, $partcontent, $partencoding); ## Only use last filterable part in alternate @@ -305,7 +495,7 @@ sub main'MAILread_body { ## Else if message/rfc822 or message/news } elsif ($ctype =~ m%message/(rfc822|news)%i) { - $parthead = &'MAILread_header(*body, *partfields, *partl2o); + $parthead = &main'MAILread_header(*body, *partfields, *partl2o); $partcontent = $partfields{'content-type'}; $partencoding = $partfields{'content-transfer-encoding'}; @@ -316,7 +506,7 @@ sub main'MAILread_body { warn "WARNING: readmail.pl: No message header formatting ", "function defined\n"; } - @array = &'MAILread_body($parthead, $body, + @array = &main'MAILread_body($parthead, $body, $partcontent, $partencoding); $ret .= shift @array || &$CantProcessPartFunc($partfields{'content-type'}); @@ -331,14 +521,15 @@ sub main'MAILread_body { } ($ret, @files); } -##--------------------------------------------------------------------------- + +##---------------------------------------------------------------------------## ## MAILread_header reads (and strips) a mail message header from the ## variable *mesg. *mesg is a pointer to the mail message. ## ## *fields is a pointer to an associative array to put field ## values indexed by field labels that have been converted to all ## lowercase. If a field repeats (eg Received fields), then each -## value in $fields{$fieldname} will be a $'FieldSep separated +## value in $fields{$fieldname} will be a $FieldSep separated ## string representing the multiple values. ## ## *l2o is an associative array to get the original label text @@ -347,20 +538,24 @@ sub main'MAILread_body { ## The return value is the original (extracted) header text. ## sub main'MAILread_header { - local(*mesg, *fields, *l2o) = @_; local($label, $olabel, $value, - $tmp, $header); + local(*mesg, *fields, *l2o) = @_; + local($label, $olabel, $value, $tmp, $header); $header = ''; %fields = (); %l2o = (); $label = ''; ## Read a line at a time. while ($mesg =~ s/^([^\n]*\n)//) { - $tmp = $1; + $tmp = $1; # Save off match last if $tmp =~ /^[\r]?$/; # Done if blank line - $header .= $tmp; - $tmp =~ s/\n/ /g; + + $header .= $tmp; # Store original text + $tmp =~ s/[\r\n]//g; # Delete eol characters + + ## Decode text if requested + $tmp = &'MAILdecode_1522_str($tmp,1) if $DecodeHeader; ## Check for continuation of a field - if ($tmp =~ /^\s/) { + if ($tmp =~ s/^\s//) { $fields{$label} .= $tmp if $label; next; } @@ -371,7 +566,7 @@ sub main'MAILread_header { ($label = $olabel) =~ tr/A-Z/a-z/; $l2o{$label} = $olabel; if ($fields{$label}) { - $fields{$label} .= $'FieldSep . $value; + $fields{$label} .= $FieldSep . $value; } else { $fields{$label} = $value; } @@ -379,7 +574,8 @@ sub main'MAILread_header { } $header; } -##--------------------------------------------------------------------------- + +##---------------------------------------------------------------------------## ## MAILread_file_header reads (and strips) a mail message header ## from the filehandle $handle. The routine behaves in the ## same manner as MAILread_header; @@ -392,11 +588,18 @@ sub main'MAILread_file_header { $/ = "\n"; $label = ''; $header = ''; %fields = (); %l2o = (); while (($tmp = <$handle>) !~ /^[\r]?$/) { + + ## Store original header $header .= $tmp; - $tmp =~ s/\n/ /g; + + ## Delete eol characters + $tmp =~ s/[\r\n]//g; + + ## Decode text if requested + $tmp = &'MAILdecode_1522_str($tmp,1) if $DecodeHeader; ## Check for continuation of a field - if ($tmp =~ /^\s/) { + if ($tmp =~ s/^\s//) { $fields{$label} .= $tmp if $label; next; } @@ -407,7 +610,7 @@ sub main'MAILread_file_header { ($label = $olabel) =~ tr/A-Z/a-z/; $l2o{$label} = $olabel; if ($fields{$label}) { - $fields{$label} .= $'FieldSep . $value; + $fields{$label} .= $FieldSep . $value; } else { $fields{$label} = $value; } @@ -417,6 +620,29 @@ sub main'MAILread_file_header { $header; } +##---------------------------------------------------------------------------## +## MAILhead_get_disposition gets the content disposition and +## filename from *hfields, *hfields is a hash produced by the +## MAILread_head* routines. +## +sub main'MAILhead_get_disposition { + local(*hfields) = shift; + local($disp, $filename) = ('', ''); + + if ($_ = $hfields{'content-disposition'}) { + ($disp) = /^\s*(\S+)/; + ($filename) = /filename=(\S+)/i; + $disp =~ s%;%%g; # Remove semi-colon if grabbed + } + if (!$filename) { + $_ = $hfields{'content-type'}; + ($filename) = /name=(\S+)/i; + } + $filename =~ s%["']%%g; # Remove quotes + $filename =~ s%.*[/\\:]%%; # Remove any path component + ($disp, $filename); +} + ############################################################################### ## Private Routines ############################################################################### diff --git a/logo/mhonarc_t.gif b/logo/mhonarc_t.gif new file mode 100644 index 0000000..1065715 Binary files /dev/null and b/logo/mhonarc_t.gif differ diff --git a/logo/monicon.gif b/logo/monicon.gif new file mode 100644 index 0000000..a0a9161 Binary files /dev/null and b/logo/monicon.gif differ diff --git a/logo/small.gif b/logo/monsmall.gif similarity index 100% rename from logo/small.gif rename to logo/monsmall.gif diff --git a/logo/monsmall_t.gif b/logo/monsmall_t.gif new file mode 100644 index 0000000..b96ad35 Binary files /dev/null and b/logo/monsmall_t.gif differ diff --git a/logo/stamp.gif b/logo/monstamp.gif similarity index 100% rename from logo/stamp.gif rename to logo/monstamp.gif diff --git a/logo/stamp_t.gif b/logo/monstamp_t.gif similarity index 100% rename from logo/stamp_t.gif rename to logo/monstamp_t.gif diff --git a/mhonarc b/mhonarc index 8ee4b4c..36507d8 100755 --- a/mhonarc +++ b/mhonarc @@ -1,19 +1,15 @@ -#! /usr/local/bin/perl +#!/usr/local/bin/perl ##---------------------------------------------------------------------------## ## File: -## MHonArc +## @(#) mhonarc 1.31 97/05/22 18:54:39 @(#) ## Author: -## Earl Hood ehood@isogen.com -## Contributers: -## Steve Pacenka , -## Achim Bohnet , -## Achille Petrilli +## Earl Hood ehood@medusa.acs.uci.edu ## Description: ## MHonArc is a Perl program to convert mail to HTML. See ## accompany documentation for full details. ##---------------------------------------------------------------------------## ## MHonArc -- Internet mail-to-HTML converter -## Copyright (C) 1995,1996 Earl Hood, ehood@isogen.com +## Copyright (C) 1995-1997 Earl Hood, ehood@medusa.acs.uci.edu ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -32,21 +28,34 @@ ############################################################################# ############################################################################# + package main; -$VERSION = "1.2.3"; # Version number +$VERSION = "2.0.1"; # Version number + +$VINFO =<= 0) || $ADD || $SINGLE || $EDITIDX || $SCAN || $IDXONLY; - $FMTFILE = $opt_rcfile if $opt_rcfile; + + ## Require needed libraries + require 'timelocal.pl' || die("ERROR: Unable to require timelocal.pl\n"); + require 'ewhutil.pl' || die("ERROR: Unable to require ewhutil.pl\n"); + require 'mhtime.pl' || die("ERROR: Unable to require mhtime.pl\n"); + require 'mhutil.pl' || die("ERROR: Unable to require mhutil.pl\n"); + require 'mhinit.pl' || die("ERROR: Unable to require mhinit.pl\n"); + + ## Load default resource file + require 'mhrcfile.pl' || die("ERROR: Unable to require mhrcfile.pl\n"); + + if ($DefRcFile) { + &read_fmt_file($DefRcFile); + } else { + $tmp = $ENV{'HOME'} . $DIRSEP . $DefRcName; + $tmp = $INC[0] . $DIRSEP . $DefRcName unless (-e $tmp); + &read_fmt_file($tmp) if (-e $tmp); + } + + ## Grab a few options + $FMTFILE = $opt_rcfile if $opt_rcfile; $LOCKTRIES = $opt_locktries if ($opt_locktries > 0); $LOCKDELAY = $opt_lockdelay if ($opt_lockdelay > 0); $FORCELOCK = defined($opt_force); @@ -156,8 +218,9 @@ sub get_cli_opts { ## since these options may tells us where the database file is. ## $OUTDIR = $opt_outdir if $opt_outdir; - if (!(-r $OUTDIR) || !(-w $OUTDIR) || !(-x $OUTDIR)) { - &error("ERROR: Unable to access $OUTDIR"); + if (!$SINGLE && + (!(-r $OUTDIR) || !(-w $OUTDIR) || !(-x $OUTDIR))) { + die("ERROR: Unable to access $OUTDIR\n"); } $DBFILE = $opt_dbfile if $opt_dbfile; @@ -171,9 +234,10 @@ sub get_cli_opts { $LOCKTRIES-1, $LOCKDELAY, $FORCELOCK)) { - &error("ERROR: Unable to create $LOCKFILE after $LOCKTRIES tries"); + die("ERROR: Unable to create $LOCKFILE after $LOCKTRIES tries\n"); } } + ## Race condition exists: if process is terminated before termination ## handlers set, lock file will not get removed. ## @@ -185,10 +249,12 @@ sub get_cli_opts { $DBFILE = ".mail2html.db" unless (-e "${OUTDIR}${DIRSEP}${DBFILE}") || (!-e "${OUTDIR}${DIRSEP}.mail2html.db"); - if (-e "${OUTDIR}${DIRSEP}${DBFILE}") { - eval q%require "${OUTDIR}${DIRSEP}${DBFILE}"%; - &error("ERROR: Database read error of ", - "${OUTDIR}${DIRSEP}${DBFILE}:\n\t$@") if $@; + $DBPathName = "${OUTDIR}${DIRSEP}${DBFILE}"; + if (-e $DBPathName) { + print STDOUT "Reading database ...\n" unless $QUIET; + require "$DBPathName" || + die("ERROR: Database read error of $DBPathName\n"); + $OldAUTHSORT = $AUTHSORT; $OldNOSORT = $NOSORT; $OldSUBSORT = $SUBSORT; $OldREVSORT = $REVSORT; @@ -196,6 +262,13 @@ sub get_cli_opts { warn "Warning: Database ($DbVERSION) != ", "program ($VERSION) version.\n"; } + + ## Check for 1.x archive, and update data as needed + if ($DbVERSION =~ /^1\./) { + print STDOUT "Updating database data to 2.0 ...\n" + unless $QUIET; + &update_data_1_to_2(); + } } if ($#ARGV < 0) { $ADDSINGLE = 1; } # See if adding single mesg else { $ADDSINGLE = 0; } @@ -204,6 +277,7 @@ sub get_cli_opts { $OldTITLE = $TITLE; $OldTHREAD = $THREAD; $OldTTITLE = $TTITLE; + $OldMULTIIDX = $MULTIIDX; ## Get highest message number if ($ADD) { @@ -228,51 +302,119 @@ sub get_cli_opts { &read_fmt_file($FMTFILE); } + $RFC1522 = 1; # Always True + + unshift(@OtherIdxs, split(/$'PATHSEP/o, $opt_otherindexes)) + if defined($opt_otherindexes); + unshift(@PerlINC, split(/$'PATHSEP/o, $opt_perlinc)) + if defined($opt_perlinc); + &remove_dups(*OtherIdxs); + &remove_dups(*PerlINC); + ## Require MIME filters and other libraries ## unshift(@INC, @PerlINC); - if (!$EDITIDX && !$SCAN && !$RMM) { - &remove_dups(*Requires); - print STDOUT "Requiring MIME filter libraries ...\n" unless $QUIET; - foreach (@Requires) { - print STDOUT "\t$_\n" unless $QUIET; - eval qq{require "$_"}; - &error("ERROR: Unable to require ${_}:\n\t$@") if $@; + if (!$SCAN && !$RMM) { + + ## Require readmail library + require 'readmail.pl' || die("ERROR: Unable to require readmail.pl\n"); + + ## Require MIME filters + if (!$EDITIDX) { + &remove_dups(*Requires); + print STDOUT "Requiring content filter libraries ...\n" + unless $QUIET; + foreach (@Requires) { + print STDOUT "\t$_\n" unless $QUIET; + require $_ || die("ERROR: Unable to require ${_}\n"); + } } - ## Register message header formatter to readmail library + + ## Register functions to readmail.pl $readmail'FormatHeaderFunc = "main'htmlize_header"; + + ## Check for 1522 processing + if ($RFC1522) { + &remove_dups(*CharSetRequires); + print STDOUT "Requiring charset filter libraries ...\n" + unless $QUIET; + foreach (@CharSetRequires) { + print STDOUT "\t$_\n" unless $QUIET; + require $_ || die("ERROR: Unable to require ${_}\n"); + } + $MHeadCnvFunc = "main'MAILdecode_1522_str"; + } else { + $MHeadCnvFunc = "convert_line"; + } } ## Get other command-line options ## $DBFILE = $opt_dbfile if $opt_dbfile; # Set again to override db + $DBPathName = "${OUTDIR}${DIRSEP}${DBFILE}"; $DOCURL = $opt_docurl if $opt_docurl; $FOOTER = $opt_footer if $opt_footer; $FROM = $opt_msgsep if $opt_msgsep; $HEADER = $opt_header if $opt_header; $IDXNAME = $opt_idxfname if $opt_idxfname; - $IDXSIZE = $opt_idxsize if $opt_idxsize; + $IDXPREFIX = $opt_idxprefix if $opt_idxprefix; + $IDXSIZE = $opt_idxsize if defined($opt_idxsize); $IDXSIZE *= -1 if $IDXSIZE < 0; $OUTDIR = $opt_outdir if $opt_outdir; # Set again to override db $MAILTOURL = $opt_mailtourl if $opt_mailtourl; - $MAXSIZE = $opt_maxsize if $opt_maxsize; - $MAXSIZE = "" if $MAXSIZE < 0; + $MAXSIZE = $opt_maxsize if defined($opt_maxsize); + $MAXSIZE = 0 if $MAXSIZE < 0; + $MHPATTERN = $opt_mhpattern if $opt_mhpattern; $TIDXNAME = $opt_tidxfname if $opt_tidxfname; + $TIDXPREFIX = $opt_tidxprefix if $opt_tidxprefix; $TITLE = $opt_title if $opt_title; $TLEVELS = $opt_tlevels if $opt_tlevels; $TTITLE = $opt_ttitle if $opt_ttitle; + $ExpireDate = $opt_expiredate if $opt_expiredate; + $ExpireTime = $opt_expireage if $opt_expireage; + $ExpireTime *= -1 if $ExpireTime < 0; + + $GMTDateFmt = $opt_gmtdatefmt if $opt_gmtdatefmt; + $LocalDateFmt = $opt_localdatefmt if $opt_localdatefmt; + + ## Parse any rc variable definition from command-line + %CustomRcVars = (%CustomRcVars, &parse_vardef_str($opt_definevars)) + if ($opt_definevars); + + $CONLEN = 1 if defined($opt_conlen); + $CONLEN = 0 if defined($opt_noconlen); + $MAIN = 1 if defined($opt_main); + $MAIN = 0 if defined($opt_nomain); + $MODTIME = 1 if defined($opt_modtime); + $MODTIME = 0 if defined($opt_nomodtime); + $MULTIIDX = 1 if defined($opt_multipg); + $MULTIIDX = 0 if defined($opt_nomultipg); + $NODOC = 0 if defined($opt_doc); $NODOC = 1 if defined($opt_nodoc); $NOMAILTO = 1 if defined($opt_nomailto); + $NONEWS = 0 if defined($opt_news); $NONEWS = 1 if defined($opt_nonews); + $NOURL = 0 if defined($opt_url); $NOURL = 1 if defined($opt_nourl); $SLOW = 1 if defined($opt_savemem); $THREAD = 1 if defined($opt_thread); $THREAD = 0 if defined($opt_nothread); $TREVERSE = 1 if defined($opt_treverse); $TREVERSE = 0 if defined($opt_notreverse); - $TSUBSORT = 1 if defined($opt_tsubsort); - $TSUBSORT = 0 if defined($opt_notsubsort); + $DoFolRefs = 1 if defined($opt_folrefs); + $DoFolRefs = 0 if defined($opt_nofolrefs); + + $DecodeHeads = 1 if defined($opt_decodeheads); + $DecodeHeads = 0 if defined($opt_nodecodeheads); + $readmail'DecodeHeader = $DecodeHeads; + + @Months = split(/:/, $opt_months) if defined($opt_months); + @months = split(/:/, $opt_monthsabr) if defined($opt_monthsabr); + @Weekdays = split(/:/, $opt_weekdays) if defined($opt_weekdays); + @weekdays = split(/:/, $opt_weekdaysabr) if defined($opt_weekdaysabr); + + $MULTIIDX = 0 if $IDXONLY || !$IDXSIZE; ## Set umask if ($UNIX) { @@ -283,13 +425,18 @@ sub get_cli_opts { ## Get sort method ## $SORTCHNG = 0; - if (defined($opt_nosort)) { # No sorting takes highest precedence - $NOSORT = 1; $SUBSORT = 0; - } elsif (defined($opt_subsort)) { # Subject sort - $SUBSORT = 1; $NOSORT = 0; - } elsif (defined($opt_sort)) { # Regular sort is last - $NOSORT = 0; $SUBSORT = 0; + $AUTHSORT = 1 if defined($opt_authsort); + $AUTHSORT = 0 if defined($opt_noauthsort); + $SUBSORT = 1 if defined($opt_subsort); + $SUBSORT = 0 if defined($opt_nosubsort); + $NOSORT = 1 if defined($opt_nosort); + $NOSORT = 0 if defined($opt_sort); + if ($NOSORT) { + $SUBSORT = 0; $AUTHSORT = 0; + } elsif ($SUBSORT) { + $AUTHSORT = 0; } + ## Check for listing order ## if (defined($opt_noreverse)) { @@ -299,6 +446,7 @@ sub get_cli_opts { } $SORTCHNG = 1 if (($OldNOSORT != $NOSORT) || ($OldSUBSORT != $SUBSORT) || + ($OldAUTHSORT != $AUTHSORT) || ($OldREVSORT != $REVSORT)); ## Check if all messages must be updated @@ -306,153 +454,71 @@ sub get_cli_opts { if ($SORTCHNG || $RMM || $EDITIDX || ($OldTITLE ne $TITLE) || ($OldTTITLE ne $TTITLE) || + ($OldMULTIIDX != $MULTIIDX) || ($THREAD != $OldTHREAD)) { $UPDATE_ALL = 1; } else { $UPDATE_ALL = 0; } - ## Check index resources - $IDXPGBEG = join('', - '', - "\n", - "\n", - "\n", - '$IDXTITLE$', "\n", - "\n", - "\n", - '

    $IDXTITLE$

    ', "\n") - unless $IDXPGBEG; - $IDXPGEND = join('', - "\n", - "\n") - unless $IDXPGEND; - - if ($THREAD) { - $LIBEG = join('', "\n
    \n
      \n") - unless $LIBEG; - $THEAD = join('', "\n
      \n") - unless $THEAD; - $TLITXT = '($NUMFOLUP$) $SUBJECT:40$, ' . - '$FROMNAME$' - unless $TLITXT; - $TIDXPGBEG = join('', - "\n}, - "\n", - "\n", - '$TIDXTITLE$', "\n", - "\n", - "\n", - '

      $TIDXTITLE$

      ', "\n") - unless $TIDXPGBEG; - $TIDXPGEND = join('', - "\n", - "\n") - unless $TIDXPGEND; + ## Set date names + ## + &set_date_names(*weekdays, *Weekdays, *months, *Months); - } else { - $LIBEG = "
      \n
        \n" unless $LIBEG; - } - $LIEND = "
      \n" - unless $LIEND; - $LITMPL = join('', '
    • $SUBJECT$', "\n", - '
      • From: $FROM$
      ' , "\n", - "
    • \n") - unless $LITMPL; - - ## Message resources - $MSGPGBEG = join('', - '', - "\n", - "\n", - "\n", - '$SUBJECTNA:72$', "\n", - '', "\n", - "\n", - "\n") - unless $MSGPGBEG; - $MSGPGEND = join('', - "\n", - "\n") - unless $MSGPGEND; - - # Check for next/prev message link resources. Must check for - # older variables to preserve capatibility. - $PREVBL = '[Prev]' unless $PREVBL; - $NEXTBL = '[Next]' unless $NEXTBL; - $IDXBL = '[Index]' unless $IDXBL; - $TIDXBL = '[Thread]' unless $TIDXBL; - $NEXTFL = 'Next' unless $NEXTFL; - $PREVFL = 'Prev' unless $PREVFL; - - $NEXTBUTTON = '' . $NEXTBL . '' - unless $NEXTBUTTON; - $PREVBUTTON = '' . $PREVBL . '' - unless $PREVBUTTON; - $NEXTBUTTONIA = '' - unless $PREVBUTTONIA; - $PREVBUTTONIA = '' - unless $PREVBUTTONIA; - - $NEXTLINK = join('', - "
    • $NEXTFL: ", - '$NEXTSUBJECT$', - "
    • \n") unless $NEXTLINK; - $NEXTLINKIA = '' unless $NEXTLINKIA; - $PREVLINK = join('', - "
    • $PREVFL: ", - '$PREVSUBJECT$', - "
    • \n") unless $PREVLINK; - $PREVLINKIA = '' unless $PREVLINKIA; - - if (!$TOPLINKS) { - $TOPLINKS = join('', - "
      \n", - '$PREVBUTTON$$NEXTBUTTON$', - '', $IDXBL, ''); - $TOPLINKS .= join('', - '', $TIDXBL, '') - if $THREAD; - } - - if (!$BOTLINKS) { - $BOTLINKS = join('', - "
      \n", - "
        \n", - '$PREVLINK$', - '$NEXTLINK$', - "
      • Index(es):\n", - "\n
      • \n
      \n"; - } - - ## Set unknown icon - $Icons{'unknown'} = $Icons{'text/plain'} unless $Icons{'unknown'}; - - ## Set some other variables - $IDXPATHNAME = "${OUTDIR}${DIRSEP}${IDXNAME}"; - $TIDXPATHNAME = "${OUTDIR}${DIRSEP}${TIDXNAME}"; - - ## Create dynamic subroutines. + ## Require some more libaries + ## + ## Set index resources. + ## + require 'mhidxrc.pl' || die("ERROR: Unable to require mhidxrc.pl\n"); + ## + ## Create dynamic subroutines. + ## + require 'mhdysub.pl' || die("ERROR: Unable to require mhdysub.pl\n"); &create_routines(); + ## + ## Require library for expanding resource variables + ## + require 'mhrcvars.pl' || die("ERROR: Unable to require mhrcvars.pl\n"); + ## + ## Require database write library if needed + ## + if (!($SCAN || $IDXONLY)) { + require 'mhdb.pl' || die("ERROR: Unable to require mhdb.pl\n"); + } + + ## Predefine %Index2TLoc in case of message deletion + if (@TListOrder) { + @Index2TLoc{@TListOrder} = (0 .. $#TListOrder); + } + + ## Set $ExpireDateTime from $ExpireDate + if ($ExpireDate) { + if (@array = &parse_date($ExpireDate)) { + $ExpireDateTime = &get_time_from_date(@array[1..$#array]); + } else { + warn qq|Warning: Unable to parse EXPIREDATE, "$ExpireDate"\n|; + } + } + + ## Delete bogus empty entries in hashes due to bug in earlier + ## versions to avoid any future problems. + + delete($IndexNum{''}); + delete($Subject{''}); + delete($From{''}); + delete($MsgId{''}); + delete($FollowOld{''}); + delete($ContentType{''}); + delete($Refs{''}); + ## Check if printing process time $TIME = defined($opt_time); $StartTime = (times)[0] if ($TIME); } + ##--------------------------------------------------------------------------- +## Main routine that does the work +## sub doit { ## Check for non-archive modification modes. if ($SCAN) { @@ -464,8 +530,9 @@ sub doit { } ## Following causes changes to an archive - local($mesg, $tmp, $index, $sub, $from, $i, $date, @array, - @array2, $tmp2, %fields); + local($mesg, $tmp, $index, $sub, $from, $i, $date, $fh, $tmp2); + local(@array, @array2); + local(%fields); $i = $NumOfMsgs; ##-------------------## @@ -479,7 +546,7 @@ sub doit { unless $QUIET; &rmm(*ARGV); - } elsif ($ADDSINGLE) { ## Adding single message + } elsif ($ADDSINGLE) { ## Adding single message print STDOUT "Adding message to $OUTDIR\n" unless $QUIET; $handle = $ADD; @@ -495,7 +562,6 @@ sub doit { $IndexNum{$index} = &getNewMsgNum(); $MsgHead{$index} = $mesg; - $MsgHead{$index} .= "
      \n" unless $mesg =~ /^\s*$/; ## Read rest of message $Message{$index} = &read_mail_body( @@ -517,7 +583,8 @@ sub doit { } $MBOX = 0; $MH = 1; print STDOUT "\nReading $mbox " unless $QUIET; - @files = sort numerically grep(/^\d+$/, readdir(MAILDIR)); + @files = sort numerically grep(/$MHPATTERN/o, + readdir(MAILDIR)); closedir(MAILDIR); foreach (@files) { $mesgfile = "${mbox}${DIRSEP}${_}"; @@ -535,7 +602,6 @@ sub doit { ($From{$index},$Date{$index},$Subject{$index}) = ($from,$date,$sub); $MsgHead{$index} = $mesg; - $MsgHead{$index} .= "
      \n" unless $mesg =~ /^\s*$/; if ($ADD && !$SLOW) { $AddIndex{$index} = 1; } $IndexNum{$index} = &getNewMsgNum(); @@ -547,7 +613,7 @@ sub doit { *fields); # Check if conserving memory if ($SLOW) { - &output_mail($index, 0, 0, *bogus, 1, 1); + &output_mail($index, 1, 1); $Update{$IndexNum{$index}} = 1; undef $MsgHead{$index}; undef $Message{$index}; @@ -556,44 +622,47 @@ sub doit { close(FILE); } } else { # UUCP mail box file - if (!open(FILE, $mbox)) { + if ($mbox eq "-") { + $fh = 'STDIN'; + } elsif (!open(FILE, $mbox)) { warn "\nWarning: Unable to open $mbox\n"; next; + } else { + $fh = 'FILE'; } $MBOX = 1; $MH = 0; print STDOUT "\nReading $mbox " unless $QUIET; - while () { last if /$FROM/o; } - MBOX: while (!eof(FILE)) { + while (<$fh>) { last if /$FROM/o; } + MBOX: while (!eof($fh)) { print STDOUT "." unless $QUIET; $mesg = ''; ($index,$from,$date,$sub,$header) = - &read_mail_header(FILE, *mesg, *fields); + &read_mail_header($fh, *mesg, *fields); if ($index ne '') { ($From{$index},$Date{$index},$Subject{$index}) = ($from,$date,$sub); $MsgHead{$index} = $mesg; - $MsgHead{$index} .= "
      \n" unless $mesg =~ /^\s*$/; if ($ADD && !$SLOW) { $AddIndex{$index} = 1; } $IndexNum{$index} = &getNewMsgNum(); $Message{$index} = &read_mail_body( - FILE, + $fh, $index, $header, *fields); if ($SLOW) { - &output_mail($index, 0, 0, *bogus, 1, 1); + &output_mail($index, 1, 1); $Update{$IndexNum{$index}} = 1; undef $MsgHead{$index}; undef $Message{$index}; } } else { - &read_mail_body(FILE, $index, $header, *fields, 1); + &read_mail_body($fh, $index, $header, *fields, 1); } } - close(FILE); + close($fh); } } } @@ -608,29 +677,43 @@ sub doit { ## Setup data structures for final HTML output ## ##---------------------------------------------## - ## Remove old message if hit maximum size - if (!$IDXONLY && $MAXSIZE && ($NumOfMsgs > $MAXSIZE)) { + ## Remove old message if hit maximum size or expiration + if (!$IDXONLY && (($MAXSIZE && ($NumOfMsgs > $MAXSIZE)) || + $ExpireTime || $ExpireDateTime)) { if ($REVSORT) { @array = reverse &sort_messages(); } else { @array = &sort_messages(); } &ign_signals(); # Ignore termination signals - while ($NumOfMsgs > $MAXSIZE) { - $index = shift @array; + + while ($index = shift(@array)) { + last unless + ($MAXSIZE && ($NumOfMsgs > $MAXSIZE)) || + (&expired_time(&get_time_from_index($index))); + &delmsg($index); + $IdxMinPg = 0; + $TIdxMinPg = 0; $Update{$IndexNum{$array[0]}} = 1; # Update next foreach (split(/$bs/o, $FollowOld{$index})) { # Update any replies $Update{$IndexNum{$_}} = 1; } + $Update{$IndexNum{$TListOrder[$Index2TLoc{$index}-1]}} = 1; + $Update{$IndexNum{$TListOrder[$Index2TLoc{$index}+1]}} = 1; } } - @array = &sort_messages(); - ## Compute follow up messages - foreach $index (@array) { + ## Set MListOrder + @MListOrder = &sort_messages(); + + ## Compute follow up messages with side-effect of setting %Index2MLoc + $i = 0; + foreach $index (@MListOrder) { + $Index2MLoc{$index} = $i; $i++; + $FolCnt{$index} = 0 unless $FolCnt{$index}; - if (@array2 = split(/$'X/o, $Refs{$index})) { + if (@array2 = split(/$X/o, $Refs{$index})) { $tmp2 = $array2[$#array2]; next unless defined($IndexNum{$MsgId{$tmp2}}); $tmp = $MsgId{$tmp2}; @@ -640,24 +723,41 @@ sub doit { } } + ## Compute thread information (sets ThreadList, TListOrder, Index2TLoc) + &compute_threads(); + ## Check for which messages to update when adding to archive if (!$IDXONLY && $ADD) { if ($UPDATE_ALL) { - foreach $index (@array) { $Update{$IndexNum{$index}} = 1; } + foreach $index (@MListOrder) { $Update{$IndexNum{$index}} = 1; } + $IdxMinPg = 0; + $TIdxMinPg = 0; + } else { $i = 0; - foreach $index (@array) { + foreach $index (@MListOrder) { ## Check for New follow-up links if ($FollowOld{$index} ne $Follow{$index}) { $Update{$IndexNum{$index}} = 1; } - ## Check if new message; must update links in prev/next mesgs + ## Check if new message; must update links in prev/next msgs if ($AddIndex{$index}) { - $Update{$IndexNum{$array[$i-1]}} = 1 if $i > 0; - $Update{$IndexNum{$array[$i+1]}} = 1 if $i < $#array; + + # Mark where main index page updates start + if ($MULTIIDX) { + $tmp = int($Index2MLoc{$index}/$IDXSIZE)+1; + $IdxMinPg = $tmp + if ($tmp < $IdxMinPg || $IdxMinPg < 0); + } + + # Mark previous/next messages + $Update{$IndexNum{$MListOrder[$i-1]}} = 1 + if $i > 0; + $Update{$IndexNum{$MListOrder[$i+1]}} = 1 + if $i < $#MListOrder; } ## Check for New reference links - foreach (split(/$'X/o, $Refs{$index})) { + foreach (split(/$X/o, $Refs{$index})) { $tmp = $MsgId{$_}; if (defined($IndexNum{$tmp}) && $AddIndex{$tmp}) { $Update{$IndexNum{$index}} = 1; @@ -665,46 +765,87 @@ sub doit { } $i++; } + $i = 0; + foreach $index (@TListOrder) { + ## Check if new message; must update links in prev/next msgs + if ($AddIndex{$index}) { + + # Mark where thread index page updates start + if ($MULTIIDX) { + $tmp = int($Index2TLoc{$index}/$IDXSIZE)+1; + $TIdxMinPg = $tmp + if ($tmp < $TIdxMinPg || $TIdxMinPg < 0); + } + + # Mark previous/next message in thread + $Update{$IndexNum{$TListOrder[$i-1]}} = 1 + if $i > 0; + $Update{$IndexNum{$TListOrder[$i+1]}} = 1 + if $i < $#TListOrder; + } + $i++; + } } } + ## Compute total number of pages + $i = $NumOfPages; + if ($MULTIIDX && $IDXSIZE) { + $NumOfPages = int($NumOfMsgs/$IDXSIZE); + ++$NumOfPages if ($NumOfMsgs/$IDXSIZE) > $NumOfPages; + $NumOfPages = 1 if $NumOfPages == 0; + } else { + $NumOfPages = 1; + } + if ($i != $NumOfPages) { # Update all pages for $LASTPG$ + $IdxMinPg = 0; + $TIdxMinPg = 0; + } + ##------------## - ## Write HTML ## + ## Write Data ## ##------------## &ign_signals(); # Ignore termination signals print STDOUT "\n" unless $QUIET; + + ## Write indexes and mail if (!$IDXONLY) { - &write_mail(*array); - &write_main_index(); + &write_mail(); + &write_main_index() if $MAIN; &write_thread_index() if $THREAD; } elsif ($THREAD) { &write_thread_index(); - } else { + } elsif ($MAIN) { &write_main_index(); } - ## Save archive state + ## Write any alternate indexes if (!$IDXONLY) { - &output_db(); + ## Write database + print STDOUT "Writing database ...\n" unless $QUIET; + &output_db($DBPathName); + + $IdxMinPg = 0; $TIdxMinPg = 0; + foreach $tmp (@OtherIdxs) { $THREAD = 0; $tmp = "${OUTDIR}${DIRSEP}$tmp" unless ($tmp =~ m%^/%) || (-e $tmp); if (&read_fmt_file($tmp)) { if ($THREAD) { - $TIDXPATHNAME = "${OUTDIR}${DIRSEP}${TIDXNAME}"; &write_thread_index(); } else { - $IDXPATHNAME = "${OUTDIR}${DIRSEP}${IDXNAME}"; &write_main_index(); } } } + print STDOUT "$NumOfMsgs messages\n" unless $QUIET; } &quit(0); } + ##--------------------------------------------------------------------------- ## Function to do scan feature. ## @@ -713,21 +854,22 @@ sub scan { $subject, $time, @array); print STDOUT "$NumOfMsgs messages in $OUTDIR:\n\n"; - print STDOUT sprintf("%5s %s %-15s %-45s\n", - "Msg #", "YY/MM/DD", "From", "Subject"); - print STDOUT sprintf("%5s %s %-15s %-45s\n", - "-" x 5, "--------", "-" x 15, "-" x 45); + print STDOUT sprintf("%5s %s %-15s %-43s\n", + "Msg #", "YYYY/MM/DD", "From", "Subject"); + print STDOUT sprintf("%5s %s %-15s %-43s\n", + "-" x 5, "----------", "-" x 15, "-" x 43); @array = &sort_messages(); foreach $index (@array) { - $date = &time2mmddyy((split(/$X/o, $index))[0], 'yymmdd'); + $date = &time2mmddyy((split(/$X/o, $index))[0], 'yyyymmdd'); $num = $IndexNum{$index}; - $from = substr(&dehtmlize(&extract_email_name($From{$index})), 0, 15); - $subject = substr(&dehtmlize($Subject{$index}), 0, 45); - print STDOUT sprintf("%5d %s %-15s %-45s\n", + $from = substr(&extract_email_name($From{$index}), 0, 15); + $subject = substr($Subject{$index}, 0, 43); + print STDOUT sprintf("%5d %s %-15s %-43s\n", $num, $date, $from, $subject); } } + ##--------------------------------------------------------------------------- ## Routine to perform conversion of a single mail message to ## HTML. @@ -741,7 +883,7 @@ sub single { ## See where input is coming from if ($ARGV[0]) { - open(SINGLE, $ARGV[0]) || &error("ERROR: Unable to open $ARGV[0]"); + open(SINGLE, $ARGV[0]) || die("ERROR: Unable to open $ARGV[0]\n"); $handle = 'SINGLE'; $filename = $ARGV[0]; } else { @@ -753,35 +895,15 @@ sub single { &read_mail_header($handle, *mhead, *fields); ($From{$index},$Date{$index},$Subject{$index}) = ($from,$date,$sub); + $MsgHead{$index} = $mhead; ## Read rest of message - $mesg = &read_mail_body($handle, $index, $header, *fields); + $Message{$index} = &read_mail_body($handle, $index, $header, *fields); - ## Output to stdout - $template = $MSGPGBEG; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print STDOUT $template; - - $template = $MSGHEAD; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print STDOUT $template; - - print STDOUT "

      $sub

      \n", - "
      \n", - $mhead; - - print STDOUT "
      \n" unless $mhead =~ /^\s*$/; - print STDOUT $mesg, - "
      \n"; - - $template = $MSGFOOT; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print STDOUT $template; - - $template = $MSGPGEND; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print STDOUT $template; + ## Output mail + &output_mail($index, 1, 0); } + ##--------------------------------------------------------------------------- ## Function for removing messages. *numbers points to an array ## of message numbers to delete @@ -791,7 +913,7 @@ sub rmm { local($key, %Num2Index, $num, $didrmm, $filename); if ($#numbers < 0) { - &error("Error: No message numbers specified"); + die("ERROR: No message numbers specified\n"); } $didrmm = 0; @@ -802,8 +924,9 @@ sub rmm { ## Remove messages foreach $num (@numbers) { if ($num !~ /^\d+$/) { - print STDERR "`$num' is not a legal message number\n"; + warn "`$num' is not a legal message number\n"; } + $num =~ s/^0+// unless $num eq '0'; if ($key = $Num2Index{$num}) { print STDOUT "\tRemoving message $num\n" unless $QUIET; &delmsg($key); @@ -813,13 +936,15 @@ sub rmm { } } if (!$didrmm) { - &error("ERROR: Messages specified do not exist"); + die("ERROR: Messages specified do not exist\n"); } } + ##--------------------------------------------------------------------------- sub delmsg { local($key) = @_; local($filename); + local($pathname); &defineIndex2MsgId(); $msgnum = $IndexNum{$key}; return 0 if ($msgnum eq ''); @@ -832,122 +957,317 @@ sub delmsg { delete $Subject{$key}; delete $MsgId{$Index2MsgId{$key}}; unlink $filename; - foreach $filename (split(/$'X/o, $Derived{$key})) { - unlink "${OUTDIR}${DIRSEP}${filename}"; + foreach $filename (split(/$X/o, $Derived{$key})) { + $pathname = "${OUTDIR}${DIRSEP}${filename}"; + if (-d $pathname) { + &rmdir($pathname); + } else { + unlink "${OUTDIR}${DIRSEP}${filename}"; + } } delete $Derived{$key}; $NumOfMsgs--; 1; } + ##--------------------------------------------------------------------------- ## write_mail outputs converted mail. It takes a reference to an ## array containing indexes of messages to output. ## sub write_mail { - local(*idxarray) = $_[0]; - local($max, $hack) = ($#idxarray, 0); - print STDOUT "Writing mail ...\n" unless $QUIET; - if ($SLOW && !$ADD) { $ADD = 1; $hack = 1; } - $i = 0; - foreach $index (@idxarray) { - &output_mail($index, $i, $max, *idxarray, $AddIndex{$index}, 0); - $i++; + local($hack) = (0); + print STDOUT "Writing mail " unless $QUIET; + + if ($SLOW && !$ADD) { + $ADD = 1; + $hack = 1; } - if ($hack) { $ADD = 0; } + + foreach $index (@MListOrder) { + print STDOUT "." unless $QUIET; + &output_mail($index, $AddIndex{$index}, 0); + } + + if ($hack) { + $ADD = 0; + } + + print STDOUT "\n" unless $QUIET; } + ##--------------------------------------------------------------------------- ## write_main_index outputs main index of archive ## sub write_main_index { - local(@array) = &sort_messages(); - local($outhandle, $i, $i_p0, $filename, $tmpl); + local(@array) = (); + local($outhandle, $i, $i_p0, $filename, $tmpl, $isfirst, $tmp); + local(@a, $PageNum); - ## Set messages that are shown in index - if ($IDXSIZE && (($i = ($#array+1) - $IDXSIZE) > 0)) { - if ($REVSORT) { - splice(@array, $IDXSIZE); - } else { - splice(@array, 0, $i); + @array = &sort_messages(); + + for ($PageNum = 1; $PageNum <= $NumOfPages; $PageNum++) { + if ($MULTIIDX) { + @a = splice(@array, 0, $IDXSIZE); } - } + next if $PageNum < $IdxMinPg; - ## Open/create index file - if ($ADD) { - if (-e $IDXPATHNAME) { - &cp($IDXPATHNAME, "${OUTDIR}${DIRSEP}tmp.$$"); - open(MAILLISTIN, "${OUTDIR}${DIRSEP}tmp.$$") - || &error("ERROR: Unable to open ${OUTDIR}${DIRSEP}tmp.$$"); - $MLCP = 1; + $isfirst = 1; + + if ($MULTIIDX) { + if ($PageNum > 1) { + $IDXPATHNAME = ${OUTDIR} . ${DIRSEP} . + ${IDXPREFIX} . $PageNum . ".html"; + } else { + $IDXPATHNAME = ${OUTDIR} . ${DIRSEP} . ${IDXNAME}; + } } else { - $MLCP = 0; + if ($IDXSIZE && (($i = ($#array+1) - $IDXSIZE) > 0)) { + if ($REVSORT) { + splice(@array, $IDXSIZE); + } else { + splice(@array, 0, $i); + } + } + $IDXPATHNAME = ${OUTDIR} . ${DIRSEP} . ${IDXNAME}; + *a = *array; + } + + ## Open/create index file + if ($ADD) { + if (-e $IDXPATHNAME) { + &cp($IDXPATHNAME, "${OUTDIR}${DIRSEP}tmp.$$"); + open(MAILLISTIN, "${OUTDIR}${DIRSEP}tmp.$$") + || die("ERROR: Unable to open ${OUTDIR}${DIRSEP}tmp.$$\n"); + $MLCP = 1; + } else { + $MLCP = 0; + } } - } - if ($IDXONLY) { - $outhandle = STDOUT; - } else { - open(MAILLIST, "> $IDXPATHNAME") || - &error("ERROR: Unable to create $IDXPATHNAME"); - $outhandle = 'MAILLIST'; - } - print STDOUT "Writing $IDXPATHNAME ...\n" unless $QUIET; + if ($IDXONLY) { + $outhandle = STDOUT; + } else { + open(MAILLIST, "> $IDXPATHNAME") || + die("ERROR: Unable to create $IDXPATHNAME\n"); + $outhandle = 'MAILLIST'; + } + print STDOUT "Writing $IDXPATHNAME ...\n" unless $QUIET; - ## Print top part of index - &output_maillist_head($outhandle, MAILLISTIN); + ## Print top part of index + &output_maillist_head($outhandle, MAILLISTIN); - ## Output messages to HTML - $i = 0; - foreach $index (@array) { - $msgnum = $IndexNum{$index}; - $i_p0 = &fmt_msgnum($msgnum); # Var for replace_li_var - $filename = &msgnum_filename($msgnum); # Var for replace_li_var - $tmpl = $LITMPL; - $tmpl =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print $outhandle $tmpl; - $i++; - } - - ## Print bottom part of index - &output_maillist_foot($outhandle, MAILLISTIN); - close($outhandle) unless $IDXONLY; - close(MAILLISTIN), unlink("${OUTDIR}${DIRSEP}tmp.$$") if $MLCP; + ## Output links to messages + + if ($NOSORT) { + foreach $index (@a) { + ($tmpl = $LITMPL) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + + } elsif ($SUBSORT) { + local($prevsub) = ''; + foreach $index (@a) { + if (($tmp = &get_base_subject($index)) ne $prevsub) { + $prevsub = $tmp; + if (!$isfirst) { + ($tmpl = $SUBJECTEND) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } else { + $isfirst = 0; + } + ($tmpl = $SUBJECTBEG) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + ($tmpl = $LITMPL) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + ($tmpl = $SUBJECTEND) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + + } elsif ($AUTHSORT) { + local($prevauth) = ''; + foreach $index (@a) { + if (($tmp = &get_base_author($index)) ne $prevauth) { + $prevauth = $tmp; + if (!$isfirst) { + ($tmpl = $AUTHEND) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } else { + $isfirst = 0; + } + ($tmpl = $AUTHBEG) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + ($tmpl = $LITMPL) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + ($tmpl = $AUTHEND) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + + } else { + local($prevdate) = ''; + local($time); + foreach $index (@a) { + $time = &get_time_from_index($index); + $tmp = join("", (localtime($time))[3,4,5]); + if ($tmp ne $prevdate) { + $prevdate = $tmp; + if (!$isfirst) { + ($tmpl = $DAYEND) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } else { + $isfirst = 0; + } + ($tmpl = $DAYBEG) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + ($tmpl = $LITMPL) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + ($tmpl = $DAYEND) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $outhandle $tmpl; + } + + ## Print bottom part of index + &output_maillist_foot($outhandle, MAILLISTIN); + close($outhandle) unless $IDXONLY; + close(MAILLISTIN), unlink("${OUTDIR}${DIRSEP}tmp.$$") if $MLCP; + } } + ##--------------------------------------------------------------------------- ## write_thread_index outputs the thread index ## sub write_thread_index { local($tmpl, $handle); + local($index) = (""); + local(*a, $PageNum, %Printed); + local($lastlevel, $tlevel, $iscont, $i); - if ($IDXONLY) { - $handle = 'STDOUT'; - } else { - open(THREAD, "> $TIDXPATHNAME") || - &error("ERROR: Unable to create $TIDXPATHNAME"); - $handle = 'THREAD'; - } - print STDOUT "Writing $TIDXPATHNAME ...\n" unless $QUIET; + local($level) = 0; ## !!!Used in print_thread!!! + local($last0index) = ''; - $tmpl = $TIDXPGBEG; - $tmpl =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print $handle $tmpl; + for ($PageNum = 1; $PageNum <= $NumOfPages; $PageNum++) { + if ($MULTIIDX) { + @a = splice(@TListOrder, 0, $IDXSIZE); + } + next if $PageNum < $TIdxMinPg; - $tmpl = $THEAD; - $tmpl =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print $handle $tmpl; + if ($MULTIIDX) { + if ($PageNum > 1) { + $TIDXPATHNAME = ${OUTDIR} . ${DIRSEP} . + ${TIDXPREFIX} . $PageNum . ".html"; + } else { + $TIDXPATHNAME = ${OUTDIR} . ${DIRSEP} . ${TIDXNAME}; + } + } else { + $TIDXPATHNAME = ${OUTDIR} . ${DIRSEP} . ${TIDXNAME}; + if ($IDXSIZE && (($i = ($#ThreadList+1) - $IDXSIZE) > 0)) { + if ($TREVERSE) { + @NotIdxThreadList = splice(@ThreadList, $IDXSIZE); + } else { + @NotIdxThreadList = splice(@ThreadList, 0, $i); + } + } + *a = *ThreadList; + } + - &output_thread_index($handle); + if ($IDXONLY) { + $handle = 'STDOUT'; + } else { + open(THREAD, "> $TIDXPATHNAME") || + die("ERROR: Unable to create $TIDXPATHNAME\n"); + $handle = 'THREAD'; + } + print STDOUT "Writing $TIDXPATHNAME ...\n" unless $QUIET; - $tmpl = $TFOOT; - $tmpl =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print $handle $tmpl; + ($tmpl = $TIDXPGBEG) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; - &output_doclink($handle); + ($tmpl = $THEAD) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; - $tmpl = $TIDXPGEND; - $tmpl =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print $handle $tmpl; + ## Flag visible messages for use in printing thread index page + foreach $index (@a) { $TVisible{$index} = 1; } + + ## Print index. Print unless message has been printed, or + ## unless it has reference that is visible. + $level = 0; # Used in print_thread!!! + $lastlevel = $ThreadLevel{$a[0]}; - close($handle) unless $IDXONLY; + # check if continuing a thread + if ($lastlevel > 0) { + ($tmpl = $TCONTBEG) =~ s/$VarExp/&replace_li_var($1,$a[0])/geo; + print $handle $tmpl; + } + # perform any indenting + for ($i=0; $i < $lastlevel; ++$i) { + ++$level; + if ($level <= $TLEVELS) { + ($tmpl = $TINDENTBEG) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + } + } + # print index listing + foreach $index (@a) { + $tlevel = $ThreadLevel{$index}; + if (($lastlevel > 0) && ($tlevel < $lastlevel)) { + for ($i=$tlevel; $i < $lastlevel; ++$i) { + if ($level <= $TLEVELS) { + ($tmpl = $TINDENTEND) =~ + s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + } + --$level; + } + $lastlevel = $tlevel; + if ($lastlevel < 1) { # Check if continuation done + ($tmpl = $TCONTEND) =~ + s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + } + } + unless ($Printed{$index} || + ($HasRef{$index} && $TVisible{$HasRef{$index}})) { + &print_thread($handle, $index, + ($lastlevel > 0) ? 0 : 1); + } + } + # unindent if required + for ($i=0; $i < $lastlevel; ++$i) { + if ($level <= $TLEVELS) { + ($tmpl = $TINDENTEND) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + } + --$level; + } + # close continuation if required + if ($lastlevel > 0) { + ($tmpl = $TCONTEND) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + } + + ## Reset visibility flags + foreach $index (@a) { $TVisible{$index} = 0; } + + ($tmpl = $TFOOT) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + + &output_doclink($handle); + + ($tmpl = $TIDXPGEND) =~ s/$VarExp/&replace_li_var($1,'')/geo; + print $handle $tmpl; + + close($handle) unless $IDXONLY; + } } + ##--------------------------------------------------------------------------- ## read_mail_header() is responsible for parsing the header of ## a mail message. @@ -969,8 +1289,7 @@ sub read_mail_header { $msgid =~ s/\s*$//; } - # Return if message already exists in archive - # + ## Return if message already exists in archive ## if ($msgid && defined($MsgId{$msgid})) { return ("", "", "", "", ""); } @@ -979,53 +1298,47 @@ sub read_mail_header { ## Get date ## ##----------## $date = ''; - if ($fields{'received'}) { - @array = split(/$'FieldSep/o, $fields{'received'}); + + ## Extract date from Date: or Received: fields + if ($fields{'date'}) { + @array = split(/$readmail'FieldSep/o, $fields{'date'}); + $date = shift @array; + + } elsif ($fields{'received'}) { + @array = split(/$readmail'FieldSep/o, $fields{'received'}); $tmp = shift @array; @array = split(/;/, $tmp); $date = pop @array; - } elsif ($fields{'date'}) { - @array = split(/$'FieldSep/o, $fields{'date'}); - $date = shift @array; } - if ($date =~ /\w/) { - local($wday, $mday, $mon, $yr, $hr, $min, $sec, $zone) = - &parse_date($date); - if ($zone) { - $index = &timegm($sec,$min,$hr,$mday,$mon, - ($yr > 1900 ? $yr-1900 : $yr)); - } else { - $index = &timelocal($sec,$min,$hr,$mday,$mon, - ($yr > 1900 ? $yr-1900 : $yr)); - } - ## Try to modify time/date based on timezone ## - if ($zone =~ /^[\+-]\d+$/) {# Numeric timezone - $zone =~ s/0//g; - $index -= ($zone*3600); - } else { # Timezone abbrev - warn qq|Warning: Undefined time zone: "$zone", Line $.\n| - if $zone && !defined($Zone{$zone}); - $index += ($Zone{$zone}*3600); # %Zone defined above - } + ## Parse date ## + if (($date =~ /\w/) && (@array = &parse_date($date))) { + $index = &get_time_from_date(@array[1..$#array]); } else { - warn "Warning: Could not find date for message\n"; - $date = ''; $index = 0; + warn "Warning: Could not parse date for message\n"; + $date = '' unless $date =~ /\S/; + $index = time; # Use current time + } + + ## Return if message to old to add ## + if (&expired_time($index)) { + return ("", "", "", "", ""); } + ##-------------## ## Get Subject ## ##-------------## if ($fields{'subject'} !~ /^\s*$/) { ($sub = $fields{'subject'}) =~ s/\s*$//; - &htmlize(*sub); } else { $sub = 'No Subject'; } + ##----------## ## Get From ## ##----------## - $tmp = $fields{'from'} || $fields{'apparently-from'}; - $from = &convert_line($tmp); + $from = $fields{'from'} || $fields{'apparently-from'}; + ##----------------## ## Get References ## ##----------------## @@ -1037,16 +1350,17 @@ sub read_mail_header { if ($tmp =~ s/^[^<]*<([^>]*)>.*$/$1/) { push(@refs, $tmp) unless $tmp =~ /^\s*$/; } + ##------------------------## ## Create HTML for header ## ##------------------------## $mesg .= &htmlize_header(*fields, *l2o); ## Insure uniqueness of msg-id - $index .= $'X . sprintf("%d",$LastMsgNum+1); + $index .= $X . sprintf("%d",$LastMsgNum+1); if ($fields{'content-type'}) { - ($tmp = $fields{'content-type'}) =~ m%^\s*([\w-/]+)%; + ($tmp = $fields{'content-type'}) =~ m%^\s*([\w-\./]+)%; $tmp = $1 || 'text/plain'; $tmp =~ tr/A-Z/a-z/; } else { @@ -1054,24 +1368,63 @@ sub read_mail_header { } $ContentType{$index} = $tmp; - $MsgId{$msgid} = $index; + if ($msgid) { + $MsgId{$msgid} = $index; + $NewMsgId{$msgid} = $index; # Track new message-ids + } &remove_dups(*refs); # Remove duplicate msg-ids - $Refs{$index} = join($'X, @refs) if (@refs); + $Refs{$index} = join($X, @refs) if (@refs); ($index,$from,$date,$sub,$header); } + ##--------------------------------------------------------------------------- ## read_mail_body() reads in the body of a message. The returned ## filtered body is in $ret. ## sub read_mail_body { local($handle, $index, $header, *fields, $skip) = @_; - local($ret, $data, @files); + local($ret, $data) = ('', ''); + local(@files) = (); - while (<$handle>) { - last if $MBOX && /$FROM/o; - $data .= $_; + ## Define "globals" for use by filters + ## NOTE: This stuff can be handled better, and will be done + ## when/if I get around to rewriting mhonarc in Perl 5. + ## + $'MHAmsgnum = &fmt_msgnum($IndexNum{$index}) unless $skip; + + ## Slurp of message body + ## UUCP mailbox + if ($MBOX) { + if ($CONLEN && $fields{"content-length"}) { # Check for content-length + local($len, $cnt) = ($fields{"content-length"}, 0); + if ($len) { + while (<$handle>) { + $cnt += length($_); # Increment byte count + $data .= $_; # Save data + last if $cnt >= $len # Last if hit length + } + } + # Slurp up bogus data if required (should I do this?) + while (!/$FROM/o && !eof($handle)) { + $_ = <$handle>; + } + + } else { # No content-length + while (<$handle>) { + last if /$FROM/o; + $data .= $_; + } + } + + ## MH message file + } else { + while (<$handle>) { + $data .= $_; + } } + + ## Filter data return '' if $skip; $fields{'content-type'} = 'text/plain' if $fields{'content-type'} =~ /^\s*$/; @@ -1087,42 +1440,24 @@ sub read_mail_body { "\n" ) unless $ret; if (@files) { - $Derived{$index} = join($'X, @files); + $Derived{$index} = join($X, @files); } $ret; } + ##--------------------------------------------------------------------------- ## Output/edit a mail message. ## $index => current index (== $array[$i]) -## $i => current index into *array -## $maxnum => size of *array -## *array => reference to array of indexes ## $force => flag if mail is written and not editted, regardless ## $nocustom => ignore sections with user customization -## ($i, $maxnum, *array ignored if true) ## sub output_mail { - local($index, $i, $maxnum, *array, $force, $nocustom) = @_; - local($msgi,$tmp,$tmp2,$template,@array2); - local($filepathname, $tmppathname); - local($adding) = ($ADD && !$force); - - # Variables for replace_li_var - local($i_p0,$i_p1,$i_m1,$filename,$nextindex,$previndex); - - if (!$nocustom) { - $nextindex = $array[$i+1]; - $previndex = $array[$i-1]; - } - - # Here $i is the current message count and not necessarily the - # message number in the filename. + local($index, $force, $nocustom) = @_; + local($msgi, $tmp, $tmp2, $template, @array2); + local($filepathname, $tmppathname, $i_p0, $filename, $msghandle); + local($adding) = ($ADD && !$force && !$SINGLE); $i_p0 = &fmt_msgnum($IndexNum{$index}); - if (!$nocustom) { - $i_p1 = &fmt_msgnum($IndexNum{$nextindex}); - $i_m1 = &fmt_msgnum($IndexNum{$previndex}); - } $filename = &msgnum_filename($IndexNum{$index}); $filepathname = $OUTDIR . $DIRSEP . $filename; @@ -1132,10 +1467,15 @@ sub output_mail { return ($i_p0,$filename) unless $Update{$IndexNum{$index}}; &cp($filepathname, $tmppathname); open(MSGFILEIN, $tmppathname) - || &error("ERROR: Unable to open $tmppathname"); + || die("ERROR: Unable to open $tmppathname\n"); + } + if ($SINGLE) { + $msghandle = 'STDOUT'; + } else { + open(MSGFILE, "> $filepathname") + || die("ERROR: Unable to create $filepathname\n"); + $msghandle = 'MSGFILE'; } - open(MSGFILE, "> $filepathname") - || &error("ERROR: Unable to create $filepathname"); ## Output HTML header if ($adding) { @@ -1146,23 +1486,27 @@ sub output_mail { # Output comments -- more informative, but can be used for # error recovering. - print MSGFILE "\n", - "\n", - "\n", - "\n", - "\n"; - foreach (split(/$'X/o, $Refs{$index})) { - print MSGFILE - "\n"; - } - print MSGFILE "\n"; + print $msghandle "\n", + "\n", + "\n", + "\n", + "\n"; + foreach (split(/$X/o, $Refs{$index})) { + print $msghandle + "\n"; + } + print $msghandle "\n"; # Add in user defined markup - $template = $MSGPGBEG; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print MSGFILE $template; + ($template = $MSGPGBEG) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; } - print MSGFILE "\n"; + print $msghandle "\n"; ## Output header if ($adding) { @@ -1170,26 +1514,23 @@ sub output_mail { last if /\n"; + print $msghandle "\n"; if (!$nocustom) { - $template = $MSGHEAD; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print MSGFILE $template; + ($template = $MSGHEAD) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; } - print MSGFILE "\n"; + print $msghandle "\n"; ## Output Prev/Next/Index links at top if ($adding) { while () { last if /\n"; - if (!$nocustom) { - $template = $TOPLINKS; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print MSGFILE $template; + print $msghandle "\n"; + if (!$nocustom && !$SINGLE) { + ($template = $TOPLINKS) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; } - print MSGFILE qq|\n|; - print MSGFILE "\n"; + print $msghandle "\n\n"; ## Output message body if ($adding) { @@ -1198,106 +1539,106 @@ sub output_mail { $tmp2 .= $_; last if /\n"; - print MSGFILE "

      ", $Subject{$index}, "

      \n"; - print MSGFILE "
      \n"; - foreach (split(/$'X/o, $Refs{$index})) {# Convert msg-ids to hyperlinks - ($tmp = $_) =~ s/(\W)/\\$1/g; - if (defined($IndexNum{$MsgId{$_}}) && - $IndexNum{$MsgId{$_}} != $IndexNum{$index}) { - - $msgi = &fmt_msgnum($IndexNum{$MsgId{$_}}); - $MsgHead{$index} =~ - s/$tmp/$_<\/A>/g; - $Message{$index} =~ - s/$tmp/$_<\/A>/g; - } - } + $tmp2 =~ s%($AddrExp)%&link_refmsgid($1,1)%geo; + print $msghandle $tmp2; - print MSGFILE $MsgHead{$index}; - print MSGFILE $Message{$index}; - print MSGFILE "\n"; + } else { + print $msghandle "\n"; + print $msghandle "\n"; + ($template = $SUBJECTHEADER) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; + print $msghandle "\n"; + + $MsgHead{$index} =~ s%($AddrExp)%&link_refmsgid($1)%geo; + $Message{$index} =~ s%($AddrExp)%&link_refmsgid($1)%geo; + + print $msghandle $MsgHead{$index}; + print $msghandle "\n"; + ($template = $HEADBODYSEP) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; + print $msghandle "\n"; + print $msghandle "\n"; + print $msghandle $Message{$index}; + print $msghandle "\n"; } ## Output any followup messages if ($adding) { while () { last if /\n"; - if (!$nocustom) { + print $msghandle "\n"; + if (!$nocustom && $DoFolRefs) { @array2 = split(/$bs/o, $Follow{$index}); if ($#array2 >= 0) { $tmp = 1; # Here, $tmp a flag if
      printed - print MSGFILE "
      \n", + print $msghandle "
      \n", "Follow-Ups:\n", "
      \n"; } - print MSGFILE "
    \n"; + print $msghandle "\n"; } else { $tmp = 0; } } - print MSGFILE "\n"; + print $msghandle "\n"; ## Output any references if ($adding) { while () { last if /\n"; - if (!$nocustom) { - @array2 = split(/$'X/o, $Refs{$index}); $tmp2 = 0; + print $msghandle "\n"; + if (!$nocustom && $DoFolRefs) { + @array2 = split(/$X/o, $Refs{$index}); $tmp2 = 0; if ($#array2 >= 0) { foreach (@array2) { if (defined($IndexNum{$MsgId{$_}})) { - if (!$tmp) { print MSGFILE "
    \n"; $tmp = 1; } + if (!$tmp) { print $msghandle "
    \n"; $tmp = 1; } if (!$tmp2) { - print MSGFILE "References:\n", + print $msghandle "References:\n", "
      \n"; $tmp2 = 1; } - print MSGFILE "
    • ", - qq|", + qq{$Subject{$MsgId{$_}}
    • \n|, + qq{">}, + &$MHeadCnvFunc($Subject{$MsgId{$_}}), + qq{\n}, "
        \n", - "
      • From: $From{$MsgId{$_}}
      • \n", + "
      • From: ", + &$MHeadCnvFunc($From{$MsgId{$_}}), + "
      • \n", "
      \n"; } } - print MSGFILE "
    \n" if $tmp2; + print $msghandle "\n" if $tmp2; } } - print MSGFILE "\n"; + print $msghandle "\n"; ## Output verbose links to prev/next message in list if ($adding) { while () { last if /\n"; - if (!$nocustom) { - $template = $BOTLINKS; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print MSGFILE $template; - print MSGFILE qq|\n|; + print $msghandle "\n"; + if (!$nocustom && !$SINGLE) { + ($template = $BOTLINKS) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; } - print MSGFILE "\n"; + print $msghandle "\n\n"; ## Output footer if ($adding) { @@ -1305,35 +1646,81 @@ sub output_mail { last if /\n"; + print $msghandle "\n"; if (!$nocustom) { - $template = $MSGFOOT; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print MSGFILE $template; + ($template = $MSGFOOT) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; } - print MSGFILE "\n"; + print $msghandle "\n"; if (!$nocustom) { - $template = $MSGPGEND; - $template =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print MSGFILE $template; + ($template = $MSGPGEND) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $msghandle $template; } - close(MSGFILE); + close($msghandle) if (!$SINGLE); close(MSGFILEIN), unlink($tmppathname) if ($adding); + ## Create user defined files + foreach (keys %UDerivedFile) { + ($tmp = $_) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + $tmp2 = $OUTDIR . $DIRSEP . $tmp; + if (open(DERIVED, "> $tmp2")) { + ($template = $UDerivedFile{$_}) =~ + s/$VarExp/&replace_li_var($1,$index)/geo; + print DERIVED $template; + close(DERIVED); + if ($Derived{$index}) { + $Derived{$index} .= $X . $tmp; + } else { + $Derived{$index} = $tmp; + } + } else { + warn "Warning: Unable to create $tmp2\n"; + } + } + if (@array2 = split(/$X/o, $Derived{$index})) { + &remove_dups(*array2); + $Derived{$index} = join($X, @array2); + } + + ## Set modification times -- Use eval incase OS does not support utime. + if ($MODTIME && !$SINGLE) { + eval q% + $tmp = &get_time_from_index($index); + @array2 = split(/$X/o, $Derived{$index}); + grep($_ = $OUTDIR . $DIRSEP . $_, @array2); + unshift(@array2, $filepathname); + utime($tmp, $tmp, @array2); + %; + } + ($i_p0, $filename); } + +##--------------------------------------------------------------------------- +## Routine to convert a msgid to an anchor +## +sub link_refmsgid { + local($refmsgid, $onlynew) = @_; + + defined($IndexNum{$MsgId{$refmsgid}}) && + (!$onlynew || $NewMsgId{$refmsgid}) ? + join("", '', $refmsgid, '') : + $refmsgid; +} + ##--------------------------------------------------------------------------- ## output_maillist_head() outputs the beginning of the index page. ## sub output_maillist_head { local($handle, $cphandle) = @_; - local($tmp); + local($tmp, $index); + $index = ""; ## Output title - $tmp = $IDXPGBEG; - $tmp =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; + ($tmp = $IDXPGBEG) =~ s/$VarExp/&replace_li_var($1,'')/geo; print $handle $tmp; print $handle "\n"; @@ -1364,19 +1751,19 @@ sub output_maillist_head { } print $handle "\n"; - $tmp = $LIBEG; - $tmp =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; + ($tmp = $LIBEG) =~ s/$VarExp/&replace_li_var($1,'')/geo; print $handle $tmp; } + ##--------------------------------------------------------------------------- ## output_maillist_foot() outputs the end of the index page. ## sub output_maillist_foot { local($handle, $cphandle) = @_; - local($tmp); + local($tmp, $index); + $index = ""; - $tmp = $LIEND; - $tmp =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; + ($tmp = $LIEND) =~ s/$VarExp/&replace_li_var($1,'')/geo; print $handle $tmp; print $handle "\n"; @@ -1410,10 +1797,10 @@ sub output_maillist_foot { &output_doclink($handle); ## Close document - $tmp = $IDXPGEND; - $tmp =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; + ($tmp = $IDXPGEND) =~ s/$VarExp/&replace_li_var($1,'')/geo; print $handle $tmp; } + ##--------------------------------------------------------------------------- ## Output link to documentation, if specified ## @@ -1428,6 +1815,7 @@ sub output_doclink { "\n"; } } + ############################################################################# ## Miscellaneous routines ############################################################################# @@ -1436,225 +1824,7 @@ sub getNewMsgNum { $NumOfMsgs++; $LastMsgNum++; $LastMsgNum; } -##--------------------------------------------------------------------------- -## replace_li_var() is used to substitute vars to current -## values. This routine relies on dynamic linking for $i, -## $i_{p0,p1,m1}, $index, $maxnum and $filename. -## -sub replace_li_var { - local($val) = $_[0]; - local($var,$len,$canclip,$raw,$isurl,$tmp,$ret) = ('',0,0,0,0,'',''); - local($expand) = (0); - - ## Get length specifier (if defined) - ($var, $len) = split(/:/, $val, 2); - - ## Check if variable in a URL string - $isurl = 1 if ($len =~ s/u//ig); - - REPLACESW: { - if ($var eq 'SUBJECT') { - $canclip = 1; $raw = 1; $isurl = 0; - $tmp = &dehtmlize($Subject{$index}); - last REPLACESW; - } - if ($var eq 'SUBJECTNA') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize($Subject{$index}); - last REPLACESW; - } - if ($var eq 'A_ATTR') { - $isurl = 0; $tmp = qq|NAME="$i_p0" HREF="$filename"|; - last REPLACESW; - } - if ($var eq 'A_NAME') - { $isurl = 0; $tmp = qq|NAME="$i_p0"|; last REPLACESW; } - if ($var eq 'A_HREF') - { $isurl = 0; $tmp = qq|HREF="$filename"|; last REPLACESW; } - if ($var eq 'DATE') - { $tmp = $Date{$index}; last REPLACESW; } - if ($var eq 'DDMMYY') { - $tmp = &time2mmddyy((split(/$X/o, $index))[0], 'ddmmyy'); - last REPLACESW; - } - if ($var eq 'DOCURL') - { $isurl = 0; $tmp = $DOCURL; last REPLACESW; } - if ($var eq 'FROM') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize($From{$index}); - last REPLACESW; - } - if ($var eq 'FROMADDR') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize(&extract_email_address($From{$index})); - last REPLACESW; - } - if ($var eq 'FROMNAME') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize(&extract_email_name($From{$index})); - last REPLACESW; - } - if ($var eq 'GMTDATE') - { $tmp = $curdate; last REPLACESW; } - if ($var eq 'ICON') { - if ($Icons{$ContentType{$index}}) { - $tmp = qq||; - } else { - $tmp = qq|[unknown]|; - } - last REPLACESW; - } - if ($var eq 'ICONURL') { - $isurl = 0; - if ($Icons{$ContentType{$index}}) { - $tmp = $Icons{$ContentType{$index}}; - } else { - $tmp = $Icons{'unknown'}; - } - last REPLACESW; - } - if ($var eq 'IDXFNAME') - { $tmp = $IDXNAME; last REPLACESW; } - if ($var eq 'IDXSIZE') - { $tmp = $IDXSIZE; last REPLACESW; } - if ($var eq 'IDXTITLE') - { $canclip = 1; $tmp = $TITLE; last REPLACESW; } - if ($var eq 'LOCALDATE') - { $tmp = $locdate; last REPLACESW; } - if ($var eq 'MMDDYY') { - $tmp = &time2mmddyy((split(/$X/o, $index))[0], 'mmddyy'); - last REPLACESW; - } - if ($var eq 'MSGID') { - &defineIndex2MsgId(); - $tmp = $Index2MsgId{$index}; - last REPLACESW; - } - if ($var eq 'MSGNUM') - { $tmp = $i_p0; last REPLACESW; } - if ($var eq 'NEXTFROM') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize($From{$nextindex}); - last REPLACESW; - } - if ($var eq 'NEXTFROMADDR') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize(&extract_email_address($From{$nextindex})); - last REPLACESW; - } - if ($var eq 'NEXTFROMNAME') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize(&extract_email_name($From{$nextindex})); - last REPLACESW; - } - if ($var eq 'NEXTMSG') - { $tmp = "msg${i_p1}.html"; last REPLACESW; } - if ($var eq 'NEXTMSGNUM') - { $tmp = $i_p1; last REPLACESW; } - if ($var eq 'NEXTSUBJECT') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize($Subject{$nextindex}); - last REPLACESW; - } - if ($var eq 'NUMFOLUP') - { $tmp = $FolCnt{$index}; last REPLACESW; } - if ($var eq 'NUMOFIDXMSG') { - $tmp = ($NumOfMsgs > $IDXSIZE ? $IDXSIZE : $NumOfMsgs); - last REPLACESW; - } - if ($var eq 'NUMOFMSG') - { $tmp = $NumOfMsgs; last REPLACESW; } - if ($var eq 'ORDNUM') - { $tmp = $i+1; last REPLACESW; } - if ($var eq 'OUTDIR') - { $tmp = $OUTDIR; last REPLACESW; } - if ($var eq 'PREVFROM') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize($From{$previndex}); - last REPLACESW; - } - if ($var eq 'PREVFROMADDR') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize(&extract_email_address($From{$previndex})); - last REPLACESW; - } - if ($var eq 'PREVFROMNAME') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize(&extract_email_name($From{$previndex})); - last REPLACESW; - } - if ($var eq 'PREVMSG') - { $tmp = "msg${i_m1}.html"; last REPLACESW; } - if ($var eq 'PREVMSGNUM') - { $tmp = $i_m1; last REPLACESW; } - if ($var eq 'PREVSUBJECT') { - $canclip = 1; $raw = 1; - $tmp = &dehtmlize($Subject{$previndex}); - last REPLACESW; - } - if ($var eq 'PROG') - { $tmp = $PROG; last REPLACESW; } - if ($var eq 'TIDXFNAME') - { $tmp = $TIDXNAME; last REPLACESW; } - if ($var eq 'TIDXTITLE') - { $canclip = 1; $tmp = $TTITLE; last REPLACESW; } - if ($var eq 'VERSION') - { $tmp = $VERSION; last REPLACESW; } - if ($var eq '') - { $tmp = '$'; last REPLACESW; } - if ($var eq 'NEXTBUTTON') { - $expand = 1; - $tmp = (($i < $maxnum) ? $NEXTBUTTON : $NEXTBUTTONIA); - last REPLACESW; - } - if ($var eq 'NEXTLINK') { - $expand = 1; - $tmp = (($i < $maxnum) ? $NEXTLINK : $NEXTLINKIA); - last REPLACESW; - } - if ($var eq 'PREVBUTTON') { - $expand = 1; - $tmp = (($i > 0) ? $PREVBUTTON : $PREVBUTTONIA); - last REPLACESW; - } - if ($var eq 'PREVLINK') { - $expand = 1; - $tmp = (($i > 0) ? $PREVLINK : $PREVLINKIA); - last REPLACESW; - } - if ($var eq 'YYMMDD') { - $tmp = &time2mmddyy((split(/$X/o, $index))[0], 'yymmdd'); - last REPLACESW; - } - warn qq|Warning: Unrecognized variable: "$val"\n|; - return ''; - } - - ## Check if string needs to expanded again - if ($expand) { - $tmp =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - } - - ## Check if clipping string - if ($len > 0 && $canclip) { - $ret = substr($tmp, 0, $len); - } else { - $ret = $tmp; - } - - ## Check if URL text specifier is set - if ($isurl) { - $ret = &urlize($ret); - } else { - &htmlize(*ret) if $raw; - } - - ## Check for subject link - $ret = qq|$ret| if $var eq 'SUBJECT'; - $ret; -} ##--------------------------------------------------------------------------- ## Add mailto URLs to $str. ## @@ -1666,6 +1836,7 @@ sub mailto { $str =~ s|([\!\%\w\.\-+=/]+@[\w\.\-]+)|$1|g; } } + ##--------------------------------------------------------------------------- ## $sub, $msgid, $from come from read_mail_header() (ugly!!!!) ## @@ -1681,6 +1852,7 @@ sub mailUrl { $url =~ s/\$TO\$/$to/g; qq|$to|; } + ##--------------------------------------------------------------------------- sub newsurl { local(*str) = shift; @@ -1693,66 +1865,20 @@ sub newsurl { } $str = $h . join(', ', @groups); # Rejoin string } + ##--------------------------------------------------------------------------- -sub get_header_tags { - local($f) = shift; - local($ftago, $ftagc, $tago, $tagc); - - ## Get user specified tags (this is one funcky looking code) - $tag = (defined($HeadHeads{$f}) ? - $HeadHeads{$f} : $HeadHeads{"-default-"}); - $ftag = (defined($HeadFields{$f}) ? - $HeadFields{$f} : $HeadFields{"-default-"}); - if ($tag) { $tago = "<$tag>"; $tagc = ""; } - else { $tago = $tagc = ''; } - if ($ftag) { $ftago = "<$ftag>"; $ftagc = ""; } - else { $ftago = $ftagc = ''; } - - ($tago, $tagc, $ftago, $ftagc); -} -##--------------------------------------------------------------------------- +## Routine to add mailto/news links to a message header string. +## sub field_add_links { local($label, *fld_text) = @_; &mailto(*fld_text) if !$NOMAILTO && - $label =~ /^(to|from|cc|sender|reply-to)/i; + $label =~ /^(to|from|cc|sender|reply-to|resent-to|resent-cc)/i; &newsurl(*fld_text) if !$NONEWS && $label =~ /^newsgroup/i; } -##--------------------------------------------------------------------------- -## convert_line() translates a line to HTML. Checks are made for -## embedded URLs. -## -sub convert_line { - local($str) = $_[0]; - local($item, $item2, $item2h, @array); - - if (!$NOURL && - (@array = split(m%($Url[^\s\(\)\|<>"']*[^\.\?;,"'\|\[\]\(\)\s<>])%o, - $str)) - ) { - $str = ''; - while($#array > 0) { - $item = &entify(shift @array); # Get non-URL text - $item2 = shift @array; # Get URL - $item2h = &entify($item2); # Variable for content - - $str .= join('', - $item, - '', $item2h, ''); - - # The next line is needed since Perl's split function also - # returns extra entries for nested ()'s in the split pattern. - shift @array if $array[0] =~ m%^$Url$%o; - } - $item = &entify(shift @array); # Last item in array - $str .= $item; - } else { - &htmlize(*str); - } - $str; -} + ##--------------------------------------------------------------------------- ## ign_signals() sets mhonarc to ignore termination signals. This ## routine is called right before an archive is written/editted to @@ -1766,9 +1892,11 @@ sub ign_signals { $SIG{'QUIT'} = 'IGNORE'; $SIG{'TERM'} = 'IGNORE'; } + ##--------------------------------------------------------------------------- ## set_handler() sets up the quit() routine to be called when ## a termination signal is sent to mhonarc. +## sub set_handler { $SIG{'ABRT'} = 'quit'; $SIG{'HUP'} = 'quit'; @@ -1777,22 +1905,16 @@ sub set_handler { $SIG{'QUIT'} = 'quit'; $SIG{'TERM'} = 'quit'; } + ##--------------------------------------------------------------------------- -## create_lock_file() creates a file with zero permissions to act -## as a lock. Thanks to Walter_Hobbs@rand.org (Walt Hobbs) for -## giving me a way to achieve this in Perl without possible race -## conditions or the use of syscall. -## -## Note: There is yet to be a way to a single locking capability -## that works across mutliple operating systems: Unix, DOS, etc. +## create_lock_file() creates a directory to act as a lock. ## sub create_lock_file { local($file, $tries, $sleep, $force) = @_; local($umask, $ret); $ret = 0; - eval '$umask = umask(0777)' if $UNIX; while ($tries > 0) { - if (open(LCK_FILE, "> $file")) { + if (mkdir($file, 0777)) { $ISLOCK = 1; $ret = 1; last; @@ -1800,25 +1922,37 @@ sub create_lock_file { sleep($sleep) if $sleep > 0; $tries--; } - if ($force) { # Set lock files if force option set + if ($force) { $ISLOCK = 1; $ret = 1; } - eval 'umask($umask)' if $UNIX; $ret; } + ##--------------------------------------------------------------------------- +## Routine to clean up stuff +## sub clean_up { if ($ISLOCK) { - unlink ($LOCKFILE); + if (-d $LOCKFILE) { + rmdir($LOCKFILE); + } else { + unlink($LOCKFILE); + } $ISLOCK = 0; } } + ##--------------------------------------------------------------------------- +## Error routine. Clean up stuff and die. +## sub error { &clean_up(); - die @_, "\n"; + die @_; } + ##--------------------------------------------------------------------------- +## Quit execution +## sub quit { local($status) = shift; &clean_up(); @@ -1828,128 +1962,238 @@ sub quit { } exit $status; } + ##--------------------------------------------------------------------------- -## Create HTML for header -sub htmlize_header { - local(*fields, *l2o) = @_; - local($tmp, $key, $tago, $tagc, $ftago, $ftagc, $mesg, $item, @array, %hf); - %hf = %fields; - foreach $item (@FieldOrder) { - if ($item eq '-extra-') { - foreach $key (sort keys %hf) { - next if $FieldODefs{$key}; - delete $hf{$key}, next if &exclude_field($key); - - @array = split(/$'FieldSep/o, $hf{$key}); - foreach $tmp (@array) { - $tmp = &convert_line($tmp); - &field_add_links($key, *tmp); - ($tago, $tagc, $ftago, $ftagc) = &get_header_tags($key); - $mesg .= join('', "
  • \n", - $tago, $l2o{$key}, $tagc, ": ", - $ftago, $tmp, $ftagc, "\n", - "
  • \n"); +## Routine to compute the order messages are listed by thread. +## Main use is to provide the ability to correctly define +## values for resource variables related to next/prev thread +## message. +## +## NOTE: Thread order is determined by all the messages in an +## archive, and not by what is visible in the thread index page. +## Hence, if the thread index page size is less than number of +## messages, the next/prev messages of thread (accessible via +## resource variables) will not necessarily correspond to the +## actual physical next/prev message listed in the thread index. +## +## The call to do_thread() defines the TListOrder array for use +## in expanding thread related resource variables. +## +sub compute_threads { + local(%FirstSub2Index) = (); + local(%Counted) = (); + local(%stripsub) = (); + local(@refs); + local($index, $msgid, $refindex, $depth, $tmp); + + @TListOrder = (); # reset + %Index2TLoc = (); # reset + + @ThreadList = sort increase_index keys %Subject; + + ## Find first occurrances of subjects + foreach $index (@ThreadList) { + $tmp = $Subject{$index}; + 1 while (($tmp =~ s/^re[\[\]\d]*:\s*//i) || + ($tmp =~ s/\s*-\s*re[ply|sponse]\s*$//i)); + + $stripsub{$index} = $tmp; + $FirstSub2Index{$tmp} = $index + unless $FirstSub2Index{$tmp} || + grep($MsgId{$_}, split(/$X/o, $Refs{$index})); + } + + ## Compute thread data + TCOMP: foreach $index (@ThreadList) { + + # Check for explicit threading + if (@refs = split(/$X/o, $Refs{$index})) { + $depth = 0; + while ($msgid = pop(@refs)) { + if (($refindex = $MsgId{$msgid})) { + + $HasRef{$index} = $refindex; + $HasRefDepth{$index} = $depth; + if ($Replies{$refindex}) { + $Replies{$refindex} .= $bs . $index; + } else { + $Replies{$refindex} = $index; + } + next TCOMP; } - delete $hf{$key}; + ++$depth; } - } else { - if (!&exclude_field($item) && $hf{$item}) { - @array = (split(/$'FieldSep/o, $hf{$item})); - foreach $tmp (@array) { - $tmp = &convert_line($tmp); - &field_add_links($item, *tmp); - ($tago, $tagc, $ftago, $ftagc) = &get_header_tags($item); - $mesg .= join('', "
  • \n", - $tago, $l2o{$item}, $tagc, ": ", - $ftago, $tmp, $ftagc, "\n", - "
  • \n"); + } + } continue { + # Check for subject-based threading + if (!$HasRef{$index}) { + if (($refindex = $FirstSub2Index{$stripsub{$index}}) && + ($refindex ne $index)) { + + $HasRef{$index} = $refindex; + $HasRefDepth{$index} = 0; + if ($SReplies{$refindex}) { + $SReplies{$refindex} .= $bs . $index; + } else { + $SReplies{$refindex} = $index; } } - delete $hf{$item}; } } - if ($mesg) { $mesg = "
      \n" . $mesg . "
    \n"; } - $mesg; + + ## Calculate thread listing order + ## + if ($TREVERSE) { + @ThreadList = sort decrease_index keys %Subject; + } + foreach $index (@ThreadList) { + unless ($Counted{$index} || $HasRef{$index}) { + &do_thread($index, 0); + } + } } + ##--------------------------------------------------------------------------- -sub output_thread_index { - local($handle) = $_[0]; - local(%HasRef, %Replies, %Printed); - local(@array, @refs); - local($index, $msgid, $refindex, $level); +## do_thread() computes the order messages are listed by thread. +## Uses %Counted defined locally in compute_thread_from_list(). +## do_thread() main purpose is to set the TListOrder array and +## Index2TLoc assoc array. +## +sub do_thread { + local($idx, $level) = ($_[0], $_[1]); + local(@repls, @srepls); - ## Routine to print thread - ## - sub print_thread { - local($i) = @_; - local(@repls); - - &print_thread_entry($handle, $i); - $Printed{$i} = 1; - if (@repls = sort increase_index split(/$bs/o, $Replies{$i})) { - $level++; - print $handle "
      \n" if $level <= $TLEVELS; - foreach (@repls) { - &print_thread($_); - } - print $handle "
    \n" if $level <= $TLEVELS; - $level--; + ## Get replies + @repls = sort increase_index split(/$bs/o, $Replies{$idx}); + @srepls = sort increase_index split(/$bs/o, $SReplies{$idx}); + + ## Add index to printed order list (IMPORTANT SIDE-EFFECT) + push(@TListOrder, $idx); + $Index2TLoc{$idx} = $#TListOrder; + + ## Mark message + $Counted{$idx} = 1; + $ThreadLevel{$idx} = $level; + + if (@repls) { + foreach (@repls) { + &do_thread($_, $level + 1 + $HasRefDepth{$_}); } } + if (@srepls) { + foreach (@srepls) { + &do_thread($_, $level + 1 + $HasRefDepth{$_}); + } + } +} - ## Compute threads - ## - foreach $index (keys %Subject) { - next unless $Refs{$index}; - @refs = split(/$X/o, $Refs{$index}); - $msgid = $refs[$#refs]; ## get last (rfc1036) - if ($refindex = $MsgId{$msgid}) { - $HasRef{$index} = 1; - if ($Replies{$refindex}) { - $Replies{$refindex} .= $bs . $index; - } else { - $Replies{$refindex} = $index; +##--------------------------------------------------------------------------- +## Routine to print thread. +## Uses %Printed defined by caller. +## +sub print_thread { + local($handle, $idx, $top) = ($_[0], $_[1], $_[2]); + local(@repls, @srepls); + local($attop, $haverepls, $hvnirepls, $single, $depth, $i); + + ## Get replies + @repls = sort increase_index split(/$bs/o, $Replies{$idx}); + @srepls = sort increase_index split(/$bs/o, $SReplies{$idx}); + $depth = $HasRefDepth{$idx}; + $hvnirepls = (@repls || @srepls); + + @repls = grep($TVisible{$_}, @repls); + @srepls = grep($TVisible{$_}, @srepls); + $haverepls = (@repls || @srepls); + + ## $hvnirepls is a flag if the message has replies, but they are + ## not visible. $haverepls is a flag if the message has visible + ## replies. $hvnirepls is used to determine the $attop and + ## $single flags. $haverepls is used for determine recursive + ## calls and level. + + ## Print entry + #$attop = ($top && $haverepls); + #$single = ($top && !$haverepls); + $attop = ($top && $hvnirepls); + $single = ($top && !$hvnirepls); + + if ($attop) { + &print_thread_var($handle, $idx, *TTOPBEG); + } elsif ($single) { + &print_thread_var($handle, $idx, *TSINGLETXT); + } else { + ## Check for missing messages + if ($DoMissingMsgs) { + for ($i = $depth; $i > 0; $i--) { + $level++; + &print_thread_var($handle, $idx, *TLINONE); + &print_thread_var($handle, $idx, *TSUBLISTBEG) + if $level <= $TLEVELS; } } + &print_thread_var($handle, $idx, *TLITXT); } - ## Print index - ## - if ($TREVERSE) { - @array = sort decrease_index keys %Subject; - } else { - @array = sort increase_index keys %Subject; + ## Increment level count if their are replies + if ($haverepls) { + $level++; } - # Set messages that are shown in index - if ($IDXSIZE && (($i = ($#array+1) - $IDXSIZE) > 0)) { - if ($TREVERSE) { - splice(@array, $IDXSIZE); - } else { - splice(@array, 0, $i); + + ## Mark message printed + $Printed{$idx} = 1; + + ## Print sub-threads + if (@repls) { + &print_thread_var($handle, $idx, *TSUBLISTBEG) if $level <= $TLEVELS; + foreach (@repls) { + &print_thread($handle, $_); } + &print_thread_var($handle, $idx, *TSUBLISTEND) if $level <= $TLEVELS; } - if ($TSUBSORT) { - @array = sort increase_subject @array; + if (@srepls) { + &print_thread_var($handle, $idx, *TSUBLISTBEG) if $level <= $TLEVELS; + &print_thread_var($handle, $idx, *TSUBJECTBEG); + foreach (@srepls) { + &print_thread($handle, $_); + } + &print_thread_var($handle, $idx, *TSUBJECTEND); + &print_thread_var($handle, $idx, *TSUBLISTEND) if $level <= $TLEVELS; } - print $handle "
      \n"; - foreach $index (@array) { - &print_thread($index) unless $Printed{$index} || $HasRef{$index}; + + ## Decrement level count if their were replies + if ($haverepls) { + $level--; + } + ## Check for missing messages + if ($DoMissingMsgs && !($attop || $single)) { + for ($i = $depth; $i > 0; $i--) { + &print_thread_var($handle, $idx, *TLINONEEND); + &print_thread_var($handle, $idx, *TSUBLISTEND) + if $level <= $TLEVELS; + $level--; + } + } + + ## Close entry text + if ($attop) { + &print_thread_var($handle, $idx, *TTOPEND); + } elsif (!$single) { + &print_thread_var($handle, $idx, *TLIEND); } - print $handle "
    \n"; } + ##--------------------------------------------------------------------------- -sub print_thread_entry { - local($handle, $index) = @_; +## Print out text based upon resource variable referenced by *tvar. +## +sub print_thread_var { + local($handle, $index, *tvar) = @_; local($i_p0, $filename, $tmpl, $msgnum); - $msgnum = $IndexNum{$index}; - $i_p0 = &fmt_msgnum($msgnum); # Var for replace_li_var - $filename = &msgnum_filename($msgnum); # Var for replace_li_var - - $tmpl = $TLITXT; - $tmpl =~ s/\$([^\$]*)\$/&replace_li_var($1)/ge; - print $handle "
  • ", $tmpl, "
  • \n"; + ($tmpl = $tvar) =~ s/$VarExp/&replace_li_var($1,$index)/geo; + print $handle $tmpl; } + ##--------------------------------------------------------------------------- ## Create Index2MsgId if not defined ## @@ -1960,126 +2204,54 @@ sub defineIndex2MsgId { } } } + ##--------------------------------------------------------------------------- -## create_routines is used to dynamically create routines that -## would benefit from being create at run-time. Routines -## that have to check against several regular expressions -## are candidates. +## Version routine ## -sub create_routines { - local($sub) = ''; - - ##----------------------------------------------------------------------- - ## exclude_field: Used to determine if field should be excluded from - ## message header - ## - $sub =<<'EndOfRoutine'; - sub exclude_field { - local($f) = shift; - local($pat, $ret); - $ret = 0; - EXC_FIELD_SW: { -EndOfRoutine - - # Create switch block for checking field against regular - # expressions (an large || statement could also work). - foreach $pat (keys %HFieldsExc) { - $sub .= join('', - 'if ($f =~ /^', - $pat, - '/i) { $ret = 1; last EXC_FIELD_SW; }', - "\n"); - } +sub version { + select(STDOUT); + print $VINFO; + exit 0; +} - $sub .=<<'EndOfRoutine'; - } - $ret; +##--------------------------------------------------------------------------- +## Routine to update 1.x data structures to 2.0. +## +sub update_data_1_to_2 { + local(%EntName2Char) = ( + 'lt', '<', + 'gt', '>', + 'amp', '&', + ); + #-------------------------------------- + sub entname_to_char { + local($name) = shift; + local($ret) = $EntName2Char{$name}; + if (!$ret) { + $ret = "&$name;"; } -EndOfRoutine - - eval $sub; - &error("ERROR: Unable to create exclude_field routine:\n\t$@") if $@; + $ret; + } + #-------------------------------------- + local($index); + foreach $index (keys %From) { + $From{$index} =~ s/\&([\w-.]+);/&entname_to_char($1)/ge; + } + foreach $index (keys %Subject) { + $Subject{$index} =~ s/\&([\w-.]+);/&entname_to_char($1)/ge; + } + delete $IndexNum{''}; + $TLITXT = '
  • ' . $TLITXT unless ($TLITXT) && ($TLITXT =~ /
  • /i); + $THEAD .= "
      \n" unless ($THEAD) && ($THEAD =~ m%
        \s*$%i); + $TFOOT = "
      \n" unless ($TFOOT) && ($TFOOT =~ m%^\s*
    %i); } + ##--------------------------------------------------------------------------- ## Usage routine ## sub usage { - select(STDOUT); - print <] ... - $PROG [] -rmm ... -Options: - -add : Add message(s) to archive - -dbfile : Name of MHonArc database file - (def: ".mhonarc.db") - -docurl : URL to MHonArc documentation - (def: "http://www.oac.uci.edu/indiv/ehood/ - mhonarc.html") - -editidx : Only edit/change index page and messages - -force : Perform archive operation even if unable to lock - -footer : File containing user text for bottom of index page - -genidx : Output index to stdout based upon archive contents - -header : User text to include at top of index page - -help : This message - -idxfname : Name of index page - (def: "maillist.html") - -idxsize <#> : Maximum number of messages shown in indexes - -lockdelay <#> : Time delay, in seconds, between lock tries - (def: "3") - -locktries <#> : Maximum number of tries in locking an archive - (def: "10") - -mailtourl : URL to use for e-mail address hyperlinks - (def: "mailto:\$TO\$") - -maxsize <#> : Maximum number of messages allowed in archive - -msgsep : Message separator expression for mailbox files - (def: "^From ") - -nodoc : Do not print link to doc at end of index page - -nomailto : Do not add in mailto links for e-mail addresses - -nonews : Do not add links to newsgroups - -noreverse : List messages in normal order - -nosort : Do not sort messages - -nothread : Do not create threaded index - -notsubsort : Do not sort threads by subject - -outdir : Destination/location of HTML mail archive - (def: ".") - -quiet : Suppress status messages during execution - -rcfile : Resource file for MHonArc - -reverse : List messages in reverse order - -rmm : Remove messages from archive - -savemem : Write message data while processing - -scan : List out archive contents to stdout - -single : Convert a single message to HTML - -sort : Sort by dates (this is the default) - -subsort : Sort message by subject - -thread : Create threaded index - -tidxfname : File name of threaded index page - (def: "threads.html") - -time : Print to stderr CPU time used to process mail - -title : Title of main index page - (def: "Mail Index") - -tlevels <#> : Maximum # of nested lists in threaded index - (def: "3") - -treverse : List threads with newest thread first - -tsubsort : Sort threads by subject - -ttitle : Title of thread index page - (def: "Mail Thread Index") - -umask : Umask of MHonArc process - -Description: - MHonArc is a highly customizable Perl program for converting e-mail into - HTML. MHonArc will convert UUCP style mailbox files or MH mail folders - into HTML with an index linking to each mail message. The -single option - can be used to convert a single mail message. - - Read the documentation for more complete usage information. - -Version: - $VERSION - Copyright (C) 1995,1996 Earl Hood, ehood\@isogen.com - MHonArc comes with ABSOLUTELY NO WARRANTY and MHonArc may be copied only - under the terms of the GNU General Public License, which may be found in - the MHonArc distribution. - -EndOfUsage - exit 0; + require 'mhusage.pl' || + die("ERROR: Unable to require mhusage.pl.\n", + "Did you install MHonArc properly?\n"); + &quit(0); }