www.pudn.com > bbs3000afree.zip > reply.cgi


#------------------------------------------------------# 
#         本程序为Yuzi工作室提供        # 
#        Yuzi论坛3000(BBS3000)v4.00      # 
######################---------------------------------# 
## 以下部分不需修改 ## 
###################### 
&origin; 
if(length($username) > 20){&errorview("您的名字不能大于20个字符!");} 
open (FILE, "$filepath/data/prison"); 
@ips = ; 
close(FILE); 
foreach $prison(@ips) { 
($prison)=split(/\t/,$prison); 
if ($prison eq $username) {&errorview("您被抓进监狱,无法发表文章!");}} 
if($id eq ""){&errorview("不能回复公告!");} 
unless (( -e "$filepath/list/$id/$replytime")&&($replytime ne "")){&errorview("主题已经被删除!");} 
foreach (@badwords) {$comment =~s/$_/****/gi;} 
if ($FORM{'smilies'} ne "1"){$comment = &smilies("$comment");} 
if ($ybbcodeAllow eq "on" && $FORM{'ybbcode'} ne "1"){$comment = &ybbcode("$comment");} 
foreach (@badwords) {$retitles =~s/$_/****/gi;} 
if(($username eq "")||($userpsd eq "")||($retitles eq "")){&errorview("您的名字、密码、回复标题不能为空!");} 
if($comment eq ""){&errorview("文章内容不能为空!");} 
if(length($comment) > $restrictbyte){&errorview("文章内容不能大于$restrictbyte个字节!");} 
($ip1,$ip2,$ip3,$ip4)=split(/\./,$from);$badi="$ip1.$ip2.$ip3"; 
foreach $badip (@badip) {&errorview("对不起!此段IP被禁止发表文章!") if($badip eq $badi);exit if($badip eq $badi);} 
open(TITLES,"$filepath/list/$id/$replytime"); 
$m=; 
close(TITLES); 
($rtitles,$rthistime,$rusername,$rcomment,$rfrom,$rhasreply,$remote,$rlastname,$rlasttime,$re,$djj,$jing,$lock,$voteman,$votetol)=split(/\t/,$m); 
if ($lock eq "1"){&errorview("主题已经关闭,不再接受新的回复!");} 
if($Cookies{lasttxt} > $ftime-30){&errorview("为防止有人用程序灌水,本BBS限制一个人两次发帖间隔必须大于30秒!");} 
print "Set-Cookie:lasttxt=$ftime\n"; 
&repeat; 
open(NU,"$filepath/guest/2$username.cgi"); 
$NU=; 
close(NU); 
($lysy,$oldlysy,$moneyy,$charmy)=split(/\t/,$NU); 
if($charmy < 0){&errorview("您的魅力太低,不能回复文章!请联系社区区长。");} 
$moneyy=$moneyy+3;$charmy=$charmy+0.1; 
open(NU,">$filepath/guest/2$username.cgi"); 
print NU "$lysy"."\t"."$oldlysy"."\t"."$moneyy"."\t"."$charmy"; 
close(NU); 
if($emote eq ""){$emote="2"}; 
$rhasreply++; 
unless($rtitles && $emote){&errorview("此帖子已经被删除了!");exit;} 
open(TITLES,">$filepath/list/$id/$replytime"); 
print TITLES $rtitles."\t".$rthistime."\t".$rusername."\t".$rcomment."\t".$rfrom."\t".$rhasreply."\t".$remote."\t".$username."\t".$thistime."\t".$re."\t".$djj."\t".$jing."\t".$lock."\t".$voteman."\t".$votetol; 
close(TITLES); 
$addreply=$replytime."\t".$thistime."\t".$username."\t".$comment."\t".$from."\t".$emote."\t".$retitles."\t".0; 
$peo="$filepath/list/$id/$re"; 
open(REPLY,">>$peo"); 
print REPLY $addreply."\n"; 
close(REPLY); 
open(PSD,"$filepath/yhzl/$username.cgi"); 
$line=; 
close(PSD); 
($rdpassword,$rusername,$rdmail,$rdhome,$rlast,$rdqm,$rdsex,$rdwork,$rdcity,$rdlove,$rfy,$rhf,$tu,$jiao,$iewin,$QQ,$photo,$rating,$levelname,$level,$lastlytime,$lastlytopic,$realname,$birthday,$shengxiao,$blood,$constellation,$character,$belief,$marital,$education,$college,$oldrat)=split(/\t/,$line); 
if($oldrat){$rating=$oldrat;} 
unless($rdpassword){&errorview("密码不能为空!");} 
if($tu eq ""){$tu=$sec};$rhf++; 
do "$cgipa/sub/level.cgi"; 
($kkk)=split(/\)/,$ENV{'HTTP_USER_AGENT'}); 
($bzd,$ie,$win,$me)=split(/;/,$kkk); 
if($me eq " Win 9x 4.90"){$win=" Windows Me"} 
elsif($win eq " Windows NT 5.0"){$win=" Windows 2000"} 
elsif($win eq " Windows NT 5.1"){$win=" Windows XP"}; 
open(PSD,">$filepath/yhzl/$username.cgi"); 
print PSD $rdpassword."\t".$username."\t".$rdmail."\t".$rdhome."\t".$rlast."\t".$rdqm."\t".$rdsex."\t".$rdwork."\t".$rdcity."\t".$rdlove."\t".$rfy."\t".$rhf."\t".$tu."\t".$jiao."\t$ie$win\t".$QQ."\t".$photo."\t".$rating."\t".$levelname."\t".$level."\t".$thistime."\t"."$retitles\t".$realname."\t".$birthday."\t".$shengxiao."\t".$blood."\t".$constellation."\t".$character."\t".$belief."\t".$marital."\t".$education."\t".$college; 
close(PSD); 
if(($yjhf ne "")&&($FORM{'emailhf'} eq "1")){ 
$comment=~s/<([^>]|\n)*>/\n/g; 
($ename)=split(/\@/,$yjhf); 
$sendto="$yjhf"; 
$subject="$bbsname提醒邮件"; 
$message="\n亲爱的$ename,您好!\n\n  首先, 非常感谢您使用$zyname提供的服务!\n这是一封论坛系统自动生成的邮件,请不要回信。\n\n在$rthistime, 您在$bbsname\n发表过文章 <<$rtitles>>\n\n  后来, 在$thistime, 有位叫做$username\n的朋友回应了您的文章, 他来自$rdcity ($from) ,\n他的E-mail地址是 $rdmail , 主页是 $rdhome\n文章主题是 <<$retitles>>\n\nURL: $ym/bbs.cgi?menu=show&slttitle=$replytime&id=$id\n\n文章的详细内容如下:\n$comment\n\n  欢迎再次光临 $bbsname !\n$ym/bbs.cgi?id=$id\n\n免费论坛服务由 $zyname($zyurl) 提供 程序制作:Yuzi工作室(http://www.yuzi.net)\n\n\n"; 
if(-e $mailprg){&sendmail;}else{do "$cgipa/sub/smtp.cgi";} 
}; 
print "Set-Cookie:del=$thistime\n"; 
if (-e "$filepath/list/$id/top"){ 
open (FILE, "$filepath/list/$id/top"); 
@top= ; 
close(FILE); 
foreach $top(@top) { 
chomp($top); 
if ($top eq $replytime) { 
&win; 
}}} 
open (GUEST,"$filepath/list/$id/bbs") ; 
@lines=; 
close(GUEST); 
open (GUEST,">$filepath/list/$id/bbs") ; 
print GUEST "$replytime\n"; 
foreach $usersays (@lines) { 
chomp($usersays); 
if($replytime ne $usersays){ 
print GUEST "$usersays\n"; 
}} 
close(GUEST); 
open(NUMBER,"$filepath/data/count"); 
$NUMBER=; 
close(NUMBER); 
($riqi,$fa,$hui)=split(/\t/,$NUMBER); 
if ($riqi eq "$year$mon$mday"){$hui++;}else{$riqi="$year$mon$mday";$fa="0";$hui="1";} 
open(NUMBER,">$filepath/data/count"); 
print NUMBER "$riqi"."\t"."$fa"."\t"."$hui"; 
close(NUMBER); 
print "Content-type: text/html\n\n"; 
print " 
 
 
 
 
 
谢谢$username,您的信息已成功发出!

请等待系统将自动返回...

(如果您不愿意等待,请点击这里返回)
"; if($userpsd ne ""){&cookie;} exit; ######################### END OF SCRIPT #########################