" D9 Q* y* ]; |& f+ V+ I) |4 t2 E出现在评论处,小问题。放出来怕笑话呢。。' C6 p) V: \: ~4 a/ ^
01 }elseif($do == 'view'){* [' ~$ u/ Q4 |: Y5 L- N8 k
02
- a% B ]' w! R6 t" r03 require_once(dirname(__FILE__)."/global.php");
7 ]3 k* Q6 N! b( A5 e04 require_once(MYMPS_INC."/member.class.php");! b2 _7 s! u5 G" C7 F. Q" `9 K
05 require_once(MYMPS_INC."/ip.class.php");
3 i! ]$ h% z2 O06
. b5 ~$ ]6 {. a$ A' {! C6 T) a/ Q07 if(!empty($part)&&$action == 'write'){" ?' p' |2 \6 Y2 W$ U" O s, s
08 if(if_other_site_post()){, r7 `% y. J) d9 p
09 $msgs[]="请不要尝试从站外提交数据!";8 t& ^3 Q. N& y5 [$ M
10 show_msg($msgs);6 ?; V3 K8 H/ ~7 E$ F3 r
11 exit();
, C' N+ Y/ L/ Q4 P12 }
+ q9 Z$ ~+ H+ Z Q8 v( K13 2 `; j2 y5 |! h" @
14
) J5 I3 Y) F( }7 b- J9 H15 //mymps_chk_randcode();& [3 ~* H+ T: V3 v1 g
16
' b9 [8 O5 ^4 b* Q17 $content = $_POST[content];
. I& | `( {! Q18 if(empty($content)){write_msg("请填写评论内容!");exit();}
( K3 i6 d! H) m: u+ I19 if(strlen($content)>255){write_msg("请不要填写超过127个汉字!");exit();}
5 b8 L3 c+ m& Y6 L' d- A20 $result = verify_badwords_filter($mymps_global[cfg_if_comment_verify],'',$_POST[content]); C5 _6 }! x" Z d8 h$ F5 a
21 $content = textarea_post_change($result[content]);! s2 F9 D; b8 H O9 L
22 $comment_level = $result[level];( K4 _/ d9 d) Z* @4 Y7 s
23 $userid = $_GET['userid'];
c) |6 Z0 Q% b3 R7 }* {6 D# l24 6 `+ G* A( T: M/ [
25
( t0 b d( K6 {) k
$ W) _! I4 S' c9 X, `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]."')");# ^" T u V' |- ]
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都没处理好。出现问题了。
$ \* ?3 Q& Q8 o( `$ ?# v28 if($comment_level == '1'){
7 I, F6 F/ U, o0 e4 B29 write_msg("您的评论提交成功!","?part=".$part."&id=".$id);" f; t, f- F1 {: E6 ?# t
30 }
a% W; Y& c7 S% Z7 o9 G2 X31 else{
# P) n) w8 U) g, b+ J32 write_msg("您提交的留言可能含有违禁词语,审核通过后显示!","?part=".$part."&id=".$id);* Y. Y5 z, U& v0 J/ e
33 }. [! I2 ?# U/ Q+ X( `$ E% a
34 exit();
' z7 q3 y7 n3 {% x35 } }6 O9 M: L" Z
结果出现问题了,4 g" @4 ~0 M3 o& O
! j& d( i" h8 s接下来就是
" a: R$ g9 b. y# Y( u) Q% f. z! T( e* |9 f7 k! `) v
直接爆出管理员账号加MD5…! A% v+ v0 U0 Z9 f) Z
|