#!/usr/bin/perl $dt = `date`; print < Jeff Foxworthy : Fan Message Boards

NAME:

E-MAIL:

Tell Redneck jokes and talk about Jeff!


Messages as of : $dt
Header print "

Archives of previous messages

\n"; open(AL,"<../cmp/archives.list"); while() { chop; $show = $_; $show =~ s/.html//; $show =~ s/archive_//; $rcnt++; if ($rcnt > 20) { $rcnt = 1; print "\n\n"; } print "
$show "; } close(AL); print "

\n"; read(STDIN,$in,$ENV{'CONTENT_LENGTH'}); if (length($in) > 10) { @f = split("&",$in); for ($i=0; $i<=$#f; $i++) { ($key,$val) = split("=",@f[$i],2); $val =~ s/%([\da-f]{1,2})/pack(C,hex($1))/eig; $val =~ s/\+/ /g; # Remove bad language $val =~ s/fuck/f--k/gi; $val =~ s/shit/s--t/gi; $val =~ s/pussy/p---y/gi; $val =~ s/ ass/ a--/gi; $val =~ s/ tit/ t-t/gi; $val =~ s/^ass/a--/gi; $val =~ s/^tit/t-t/gi; $val =~ s/cum/c-m/gi; $val =~ s/dick/d--k/gi; $val =~ s/twat/t--t/gi; $val =~ s/fart/f--t/gi; $val =~ s/cock/c--k/gi; $val =~ s/turd/t--d/gi; $val =~ s/vagina/v----a/gi; $val =~ s/piss/p--s/gi; $val =~ s/cunt/c--t/gi; # Strip out ANY HTML from $val $nval = ""; $html = 0; for ($j=0; $j") { $html = 0; } } $aa{$key} = $nval; } # Do file locking while ( -e "file.locked" ) { sleep 1; } open(LCK,">file.locked"); close(LCK); open(TXT,"<../cmp/txt.html"); $cc = 0; while() { $cnt++; @r[$cnt] = $_; $cc = $cc + length($_); } close(TXT); # check file size (> 1000 records) if ($cc > 50000) { $k = 1; $afn = "archive_" . $k . ".html"; while ( -f "../cmp/$afn" ) { $k++; $afn = "archive_" . $k . ".html"; } open(AL,">>../cmp/archives.list"); print AL "$afn\n"; close(AL); open (ARCH,">../cmp/$afn"); for ($kk=0; $kk<=$cnt; $kk++) { print ARCH @r[$kk]; } close (ARCH); $cnt = 0; } open(OUT,">../cmp/txt.html"); print OUT "\n
FROM: $aa{N}\n"; if (length($aa{E}) > 2) { print OUT "<$aa{E}>
\n"; } else { print OUT "
\n"; } print OUT "DATE: $dt
\n"; print OUT $aa{T}; print OUT "\n

\n"; for ($i=1; $i<=$cnt; $i++) { print OUT @r[$i]; } close(OUT); `rm file.locked`; # File Locking } open(TXT,"<../cmp/txt.html"); while() { print; } close(TXT);