#!/usr/bin/perl print "Content-Type: text/html\n"; print "\n"; use CGI qw/:all/; use CGI::Carp(fatalsToBrowser); use Fcntl; #Web Forums #A Perl script to create an online bulletin/discussion board. #Copyright 2000 NPSIS #http://www.npsis.com #Last Modified August 20, 2000 #This is a free script. You may edit and alter it for personal #use as you see fit. You may not sell it or otherwise claim it #as your own, unless you have absolutely no morals. #See the enclosed readme file for complete instructions for #setting up the BBS. #####User Edits Here######################### $Username = 'motorowa'; my $HOME = 'http://www.motorowa.3.pl/'; my $EMAIL = 'serwis@3.pl'; my $YOURNAME = 'jaca'; my $BBS_TITLE = 'FORUM DYSKUSYJNE'; #set this to 1 to quote message when replying #set to 0 to not quote messages when replying my $quote = 1; my $BG = '#f6f6ed'; #background color my $TX = '#000000'; #text color my $LL = '#00008b'; #visited link color my $VL = '#00008b'; #link color my $BGIMG = ''; #background image url ############################################### $Loginfirstletter = substr($Username, 0, 1); #my $BBS_DIR = "/usr/home/users/$Loginfirstletter/$Username/public_html/bbs/"; my $BBS_DIR = "/home/$Username/www/bbs/"; #the path to a file containing directions, etc. that will be printed on forum list page #my $BBS_INFO = "/usr/home/users/$Loginfirstletter/$Username/public_html/bbs/info.txt"; #include trailing slash my $BBS_INFO = "/home/$Username/www/bbs/info.txt"; #include trailing slash my $BBJ_HEADER = "/home/motorowa/www/"; #my $STYLE=''; $ENV{'PATH'} = '/bin:/usr/bin:/usr/local/bin'; my $VERSION = '2.1'; my $script = url(); #opendir(DIR, $BBJ_HEADER) or die "Can't opendir $BBJ_HEADER: $!"; system "../concat_head.cgi"; system "../concat_mid_head.cgi"; print ' Forum Dyskusyjne
![]() |
Jeśli chcesz się wypowiedzieć, podyskutować,
podzielić uwagami z innym mieszkańcami naszego osiedla,
lub też przeczytać co piszą inni internauci -
to ta strona jest miejscem właśnie dla Ciebie.
Zapraszamy na Forum Dyskutyjne - osiedlowy Hyde Park.
', a({-href=>"$script?task=list&forum=$forum"},b('Message List')), ' | ', '', a({-href=>$script},b('Forum List')), ' | ', '
', a({-href=>"$script?task=list&forum=$forum"},b('Lista Wiadomości')), ' | ', '', a({-href=>$script},b('Lista Grup Dyskusyjnych')), ' | ', '
', a({-href=>"$script?forum=$forum&task=reply_form&msg=$msg"},b('Wyślij Odpowied')), ' | '; } if ($back_link) { print '', a({-href=>$back_link},b('Poprzednia wiadomość')), ' | '; } if ($next_link) { print '', a({-href=>$next_link},b('Następna Wiadomość')), ' | '; } if ($archive_flag) { print '', a({-href=>"$script?task=list&forum=$forum"},b('Zarchiwizowana Lista Wiadomości')), ' | '; print '', a({-href=>"$script?forum=$return_to&task=list"},b('Return to ', get_label($return_to))), ' | '; } else { print '', a({-href=>"$script?task=list&forum=$forum"},b('Lista Wiadomości')), ' | '; } print '', a({-href=>$script},b('Forum List')), ' | '; print '
', a({-href=>"$script?forum=$forum&task=new_thread_form"},b('Nowa Wiadomość')), ' | '; } print '', a({-href=>$script},b('Lista Grup Dyskusyjnych')), ' | '; #only show archive link if there is an archive for this forum #and we aren't already in archive view if ((-e $archive_path) && (!$archive_flag) ){ print '', a({-href=>"$script?forum=$archive&task=list_archive"},b('View ', get_label($archive))), ' | '; } elsif ($task eq 'list_archive') { print '', a({-href=>"$script?forum=$return_to&task=list"},b('Return to ', get_label($return_to))), ' | '; } if ( (!$archive_flag) && (@posts) ){ print '', a({-href=>"$script?forum=$forum&task=mark_read"},b('Oznacz Wszystkie Wiadomości Jako Przeczytane')), ' | '; } print '
/g;
$str =~ s/\n/
/g;
return $str;
}
sub clean {
#prevent any image tags, etc. used in subject and name fields
my $str = shift;
$str =~ s//g;
$str =~ s/>//g;
return $str;
}
sub check_required(){
my ($name,$subject,$message) = @_;
my @empty;
if (!$name) {
push @empty, 'Imię
';
}
if (!$subject) {
push @empty, 'Temat
';
}
if (!$message) {
push @empty, 'Wiadomość
';
}
if (@empty) {
print
start_html(-bgcolor=>$BG,-text=>$TX,-link=>$LL,-vlink=>$VL,
-background=>$BGIMG,-title=>"Form Error"),
h2('Puste Pola Formularza'),
'The following required fields were not filled in.',p,
@empty,p,
a({href=>'javascript:history.go(-1);'},'Spróbuj raz jeszcze.'),
end_html;
show_foot();
exit(0);
}
}
sub store_and_confirm {
my ($fh,$subject,$name,$email,$message) = @_;
my $time_stamp = time;
my $date = get_date($time_stamp);
print $fh $subject . "\n";
print $fh $name . "\n";
print $fh $email . "\n";
print $fh $time_stamp . "\n";
print $fh $message . "\n";
close($fh);
print
start_html(-bgcolor=>$BG,-text=>$TX,-link=>$LL,-vlink=>$VL,
-background=>$BGIMG,-title=>"$forum_label"),
h1({align=>'center'},"$forum_label"),
h2({align=>'center'},'Wiadomość została wysłana'),
'
', a({-href=>"$script?task=list&forum=$forum"},b('Lista Wiadomości')), ' | ', '', a({-href=>"$script"},b('Lista Grup Dyskusyjnych')), ' | ', '