. J4 p" t% d" W: I6 s
出现在评论处,小问题。放出来怕笑话呢。。! M' j3 p5 ^2 c) }8 D, x0 }2 C
01 }elseif($do == 'view'){
: N( H% c3 n& E; f. J M" ?02
0 ]! R# Z# J- B9 }03 require_once(dirname(__FILE__)."/global.php");3 N* p$ G: o6 `8 v! a( U) v
04 require_once(MYMPS_INC."/member.class.php");+ n1 ?9 \/ g. H
05 require_once(MYMPS_INC."/ip.class.php");$ y$ q: `2 G. ~
06 / E$ V1 r, i( J# }2 r
07 if(!empty($part)&&$action == 'write'){
, }( n9 Q, j4 A, B/ t( z/ f08 if(if_other_site_post()){
' P8 F7 {; M+ C6 t, c09 $msgs[]="请不要尝试从站外提交数据!";
! x) y) Q# W* K0 J# A10 show_msg($msgs);
+ o3 I/ X+ P) d* o# v3 W11 exit();
/ U: C! T5 B, O8 c12 }1 m. x* K9 F- Z# m! g
13
7 f7 z9 I1 H! G14 2 ]4 n/ R, _0 O9 `: x B1 Z
15 //mymps_chk_randcode();
" D9 K6 n* R4 Z: g- u16
. \- W$ K4 g( n5 l3 I& L f0 P+ d17 $content = $_POST[content];4 }0 |' C+ i$ X) M' t+ Z
18 if(empty($content)){write_msg("请填写评论内容!");exit();}* e7 M. `4 J2 w! m
19 if(strlen($content)>255){write_msg("请不要填写超过127个汉字!");exit();}
# f6 ^! s$ E- l4 ^: S3 m2 J! @20 $result = verify_badwords_filter($mymps_global[cfg_if_comment_verify],'',$_POST[content]);" _/ {- h" d( p* w4 `% p4 k, o
21 $content = textarea_post_change($result[content]);
# d/ @) `0 l I) s1 U- p/ R: H22 $comment_level = $result[level];/ _7 B! t; D0 P/ |
23 $userid = $_GET['userid'];8 y# ?% q0 g) O9 L3 n$ f: }' |0 \
24
) r5 B8 Y/ h1 e7 j- `! [) d25
0 ^& g- ]6 Z( r
4 z" I4 f A$ T# y26 $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]."')");
6 _5 \# [) b8 x8 {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都没处理好。出现问题了。
9 H4 b- U* t( z7 P2 c1 M28 if($comment_level == '1'){- g( N3 ^* K- \/ n o
29 write_msg("您的评论提交成功!","?part=".$part."&id=".$id);. j7 L" m7 {7 H* |9 E! [8 ~( Q
30 }
" N$ |! b+ n) a; N0 j8 `2 X31 else{5 C# ~: v- ]6 C- t
32 write_msg("您提交的留言可能含有违禁词语,审核通过后显示!","?part=".$part."&id=".$id);% s$ }4 c. M% `
33 }) L+ V9 c% G9 }
34 exit();
9 d1 R4 n: m. t; L( p. L5 t35 }
' ~7 H3 R+ x$ E0 n! Y. B结果出现问题了,
* w n. t0 b% e
+ i# J E$ D1 I接下来就是
7 ]7 }0 a% |# n1 l1 c
- I8 D' y- @! }直接爆出管理员账号加MD5…! I! U1 T8 b! L, g z
|