MHonArc
view release on metacpan or search on metacpan
lib/mhrcfile.pl view on Meta::CPAN
$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 'lockmethod') { # Locking method
if ($line = &get_elem_last_line($handle, $elem)) {
$LockMethod = &set_lock_mode($line);
}
last FMTSW;
}
if ($elem eq 'mailto') { # Convert e-mail addrs
$NOMAILTO = 0;
last FMTSW;
}
if ($elem eq 'mailtourl') { # mailto URL
while (defined($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') { # Print main index
$MAIN = 1;
last FMTSW;
}
if ($elem eq 'maxpgs') { # Max number of index pages
if (($tmp = &get_elem_int($handle, $elem, 1)) ne '') {
$MAXPGS = $tmp;
}
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 'msgbodyend') { # Markup after message body
$MSGBODYEND = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'msgexcfilter') { # Code selectively exclude msgs
$MsgExcFilter = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'msgpgs') { # Output message pages
$NoMsgPgs = 0;
last FMTSW;
}
if ($elem eq 'msgprefix') { # Prefix for message files
if ($line = &get_elem_last_line($handle, $elem)) {
$line =~ s/\s//g;
$MsgPrefix = $line;
}
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 'mimealtprefs') { # Mime alternative prefs
$IsDefault{'MIMEALTPREFS'} = 0;
@MIMEAltPrefs = ();
while (defined($line = <$handle>)) {
last if $line =~ /^\s*<\/mimealtprefs\s*>/i;
$line =~ s/\s//g;
push(@MIMEAltPrefs, lc($line)) if $line;
}
last FMTSW;
}
if ($elem eq 'mimedecoders') { # Mime decoders
$IsDefault{'MIMEDECODERS'} = 0;
if ($override) {
%readmail::MIMEDecoders = ();
%readmail::MIMEDecodersSrc = ();
}
while (defined($line = <$handle>)) {
last if $line =~ /^\s*<\/mimedecoders\s*>/i;
next unless $line =~ /\S/;
$line =~ s/\s//g;
($type, $routine, $plfile) = split(/;/, $line, 3);
$type =~ tr/A-Z/a-z/;
$readmail::MIMEDecoders{$type} = $routine;
$readmail::MIMEDecodersSrc{$type} = $plfile
if $plfile =~ /\S/;
}
last FMTSW;
}
if ($elem eq 'mimefilters') { # Mime filters
$IsDefault{'MIMEFILTERS'} = 0;
if ($override) {
%readmail::MIMEFilters = ();
%readmail::MIMEFiltersSrc = ();
}
while (defined($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/;
$readmail::MIMEFilters{$type} = $routine;
$readmail::MIMEFiltersSrc{$type} = $plfile
if $plfile =~ /\S/;
}
lib/mhrcfile.pl view on Meta::CPAN
}
last FMTSW;
}
if ($elem eq 'mimeincs') { # Mime includes
$IsDefault{'MIMEINCS'} = 0;
%readmail::MIMEIncs = () if $override;
while (defined($line = <$handle>)) {
last if $line =~ /^\s*<\/mimeincs\s*>/i;
$line =~ s/\s//g;
$line =~ tr/A-Z/a-z/;
$readmail::MIMEIncs{$line} = 1 if $line;
}
last FMTSW;
}
if ($elem eq 'modifybodyaddresses') { # Modify addresses in bodies
$AddrModifyBodies = 1;
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 'msgidlink') {
$MSGIDLINK = &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'
|| $elem eq 'msgpgbeg') { # 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') { # Print multi-page indexes
$MULTIIDX = 1;
last FMTSW;
}
if ($elem eq 'newsurl') { # News URL
while (defined($line = <$handle>)) {
last if $line =~ /^\s*<\/newsurl\s*>/i;
next if $line =~ /^\s*$/;
$line =~ s/\s//g;
$NewsUrl = $line;
}
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 'nochecknoarchive') {
$CheckNoArchive = 0;
last FMTSW;
}
if ($elem eq 'noconlen') { # Ignore content-length
$CONLEN = 0;
last FMTSW;
}
if ($elem eq 'nodecodeheads') { # Don't decode charsets
$DecodeHeads = 0;
last FMTSW;
}
if ($elem eq 'nodoc') { # Do not link to docs
$NODOC = 1;
last FMTSW;
}
if ($elem eq 'nofasttempfiles') { # Random temp files
$FastTempFiles = 0;
last FMTSW;
}
if ($elem eq 'nofollowsymlinks') { # Do not allow/follow symlinks
$FollowSymlinks = 0;
last FMTSW;
}
if ($elem eq 'nofolrefs') { # Don't print explicit fol/refs
$DoFolRefs = 0;
last FMTSW;
}
if ($elem eq 'nomodifybodyaddresses') { # Don't modify addresses
$AddrModifyBodies = 0;
last FMTSW;
}
if ($elem eq 'nogzipfiles') { # Don't gzip files
$GzipFiles = 0;
last FMTSW;
}
if ($elem eq 'nogziplinks') { # Don't add ".gz" to links
$GzipLinks = 0;
last FMTSW;
}
if ($elem eq 'nokeeponrmm') { # Remove files on rmm
$KeepOnRmm = 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 'nomsgpgs') { # Do not print message pages
$NoMsgPgs = 1;
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 'noposixstrftime') { # Do not use POSIX::strftime()
$POSIXstrftime = 0;
last FMTSW;
}
if ($elem eq 'noreverse') { # Sort in normal order
$REVSORT = 0;
last FMTSW;
}
if ($elem eq 'nosaveresources') { # Do not save resources
$SaveRsrcs = 0;
last FMTSW;
}
if ($elem eq 'nosort') { # Do not sort messages
$NOSORT = 1;
last FMTSW;
}
if ($elem eq 'nospammode') { # Do not do anti-spam stuff
$SpamMode = 0;
last FMTSW;
}
if ($elem eq 'nosubjectthreads') { # No check subjects for threads
$NoSubjectThreads = 1;
last FMTSW;
}
if ($elem eq 'nosubjecttxt') { # Text to use if no subject
$NoSubjectTxt = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'nosubsort') { # Do not sort msgs by subject
$SUBSORT = 0;
last FMTSW;
}
if ($elem eq 'note') { # Annotation markup
$NOTE = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'notedir') { # Notes directory
if ($line = &get_elem_last_line($handle, $elem)) {
$NoteDir = $line;
}
last FMTSW;
}
if ($elem eq 'noteia') { # No Annotation markup
$NOTEIA = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'noteicon') { # Note icon
$NOTEICON = &get_elem_content($handle, $elem, $chop);
last FMTSW;
lib/mhrcfile.pl view on Meta::CPAN
}
if ($elem eq 'prevlink') { # Prev link in message
$PREVLINK = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'prevlinkia') { # Prev i/a link
$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 'printxcomments') { # Print info X- comments
$PrintXComments = 1;
last FMTSW;
}
if ($elem eq 'noprintxcomments') { # Don't print info X- comments
$PrintXComments = 0;
last FMTSW;
}
if ( $elem eq 'refsbegin'
|| $elem eq 'refsbeg') { # Explicit ref links begin
$REFSBEGIN = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'refsend') { # Explicit ref links end
$REFSEND = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'refslitxt') { # Explicit ref link
$REFSLITXT = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'reverse') { # Reverse sort
$REVSORT = 1;
last FMTSW;
}
if ($elem eq 'saveresources') { # Save resources in db
$SaveRsrcs = 1;
last FMTSW;
}
if ($elem eq 'sort') { # Sort messages by date
$NOSORT = 0;
$AUTHSORT = 0;
$SUBSORT = 0;
last FMTSW;
}
if ($elem eq 'spammode') { # Obfsucate/hide addresses
$SpamMode = 1;
last FMTSW;
}
if ($elem eq 'ssmarkup') { # Initial page markup
$SSMARKUP = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'msgpgssmarkup') { # Initial message page markup
$MSGPGSSMARKUP = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'idxpgssmarkup') { # Initial index page markup
$IDXPGSSMARKUP = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'tidxpgssmarkup') { # Initial thread idx page markup
$TIDXPGSSMARKUP = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'subjectarticlerxp') { # Regex for language articles
if ($line = &get_elem_last_line($handle, $elem)) {
$SubArtRxp = $line;
}
last FMTSW;
}
if ($elem eq 'subjectreplyrxp') { # Regex for reply text
if ($line = &get_elem_last_line($handle, $elem)) {
$SubReplyRxp = $line;
}
last FMTSW;
}
if ($elem eq 'subjectstripcode') { # Code to strip subjects
$SubStripCode = &get_elem_content($handle, $elem, $chop);
last FMTSW;
}
if ($elem eq 'subjectthreads') { # Check subjects for threads
$NoSubjectThreads = 0;
last FMTSW;
}
if ($elem eq 'subsort') { # Sort messages by subject
$SUBSORT = 1;
$AUTHSORT = 0;
$NOSORT = 0;
last FMTSW;
}
if ( $elem eq 'subjectbegin'
|| $elem eq 'subjectbeg') { # 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'
|| $elem eq 'tcontbeg') { # 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 'textclipfunc') { # Text clipping function
( run in 0.565 second using v1.01-cache-2.11-cpan-df04353d9ac )