|! Z' W# `; L% V. q0 e
出现在评论处,小问题。放出来怕笑话呢。。! o# `- L; [% _" T) r. R7 r1 _
01 }elseif($do == 'view'){
# B# I& z2 [, X- Q02
7 N( ]7 p) a- o$ R `5 n) I03 require_once(dirname(__FILE__)."/global.php");
2 \+ G% p; d- `+ l1 T04 require_once(MYMPS_INC."/member.class.php");; h. f- E0 y! k( h+ u/ y) N
05 require_once(MYMPS_INC."/ip.class.php");. d' K2 n2 M6 W# u
06
- m/ h7 Y' O# V07 if(!empty($part)&&$action == 'write'){3 ]- W6 A7 X C# w q' l
08 if(if_other_site_post()){; \, G+ W9 H2 \$ p- l9 s \
09 $msgs[]="请不要尝试从站外提交数据!";
) s. J. Q% B! l& G# f: q; N# Z10 show_msg($msgs);
0 R" @$ W8 u$ N0 t( `11 exit();
: w$ L3 g9 z/ W8 Z g12 }
- ? ]7 Z/ g4 }; B2 k13
& [' p7 J9 a% {3 s( p14
# i7 R6 T% M2 ?3 V! |$ z15 //mymps_chk_randcode();, A' P7 t" o3 w% @
16 + p: U& _( W! \: U2 Q0 q6 R% ?
17 $content = $_POST[content];
! v4 X3 b# J: v- t' f5 y18 if(empty($content)){write_msg("请填写评论内容!");exit();}
# w; v" x' N7 G6 ?7 I19 if(strlen($content)>255){write_msg("请不要填写超过127个汉字!");exit();}
( P2 k9 s+ x, {& {. u# E$ h7 D20 $result = verify_badwords_filter($mymps_global[cfg_if_comment_verify],'',$_POST[content]);, s- W4 H, ?2 X. a3 J" Q
21 $content = textarea_post_change($result[content]);
4 R* ~; u$ q6 H0 B22 $comment_level = $result[level];9 g8 D8 C3 f9 V" t r
23 $userid = $_GET['userid'];
0 f$ `# T& f+ {2 r5 Z24
8 c# x6 V! ^4 a. p" g5 ^8 b a25
6 G V$ Y. M- }$ T9 }( q9 H' s! Y! E/ U4 i
26 $db->query("INSERT INTO `{$db_mymps}".$part."_comment` (".$part."id,content,pubtime,ip,comment_level,userid)VALUES('$id','$content','".time()."','".GetIP()."','$comment_level','".$_POST[userid]."')");. D% E; |: A9 R
27 echo "INSERT INTO `{$db_mymps}".$part."_comment` (".$part."id,content,pubtime,ip,comment_level,userid)VALUES('$id','$content','".time()."','".GetIP()."','$comment_level','".$_POST[userid]."')";//userid和getip都没处理好。出现问题了。) v- O4 U+ Q3 S4 {
28 if($comment_level == '1'){5 N" r2 o" U+ l$ j) D5 z
29 write_msg("您的评论提交成功!","?part=".$part."&id=".$id);
3 j1 {5 `5 L* R2 g30 }
" s" q3 W) [% P W) L3 ?) H( E31 else{
- H. G+ W. v( G! I9 f1 X7 k' d4 m32 write_msg("您提交的留言可能含有违禁词语,审核通过后显示!","?part=".$part."&id=".$id);
% @) m- G( w* @; `; H+ L# V; w f33 }
2 e' Z( |9 ~: |, t5 o' F34 exit();) G& u- {! f$ a! a* H0 O( _$ [" W
35 }
' Y4 }" Q# L7 G- y; s+ ]$ @结果出现问题了,
1 Q7 q0 Y1 c, S+ n8 A. \8 f! {* W2 h% }$ s8 Q9 c) m
接下来就是
/ S, z0 ?2 B! n8 C: f
( {7 R% p+ U3 V5 _! a0 T1 G5 B直接爆出管理员账号加MD5…" L9 t* l1 O' o' e% ~2 E
|