<?php
header ("Content-type: image/png");
$a = "";//在我的机子上加了这句就好了。
for ($i=0;$i<6;$i++)
{
$a.=rand(0,9);
}
$_SESSION['urvcode']=$a;
$im = imagecreate (50, 14) or die ("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate ($im, 255, 255, 255);
$text_color = imagecolorallocate ($im, 233, 14, 91);
imagestring ($im, 3, 5, 0, $a , $text_color);
imagepng($im);
imagedestroy ($im);
?>
header ("Content-type: image/png");
$a = "";//在我的机子上加了这句就好了。
for ($i=0;$i<6;$i++)
{
$a.=rand(0,9);
}
$_SESSION['urvcode']=$a;
$im = imagecreate (50, 14) or die ("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate ($im, 255, 255, 255);
$text_color = imagecolorallocate ($im, 233, 14, 91);
imagestring ($im, 3, 5, 0, $a , $text_color);
imagepng($im);
imagedestroy ($im);
?>
{
$usql="update uonline set flag='0' where onlineid='".$_SESSION['theonlineid']."'";
mssql_query($usql, $conn) or die(mssql_get_last_message ());
$upsql="update uinfo set isonline=0 where uid='".$_SESSION['uid']."'";
mssql_query($upsql, $conn) or die(mssql_get_last_message ().$upsql);
session_unset();
session_destroy();
}居然session不会消失,退出不了!!!!
我晕啊!!找个php5.0.3安装,结果把IIS整死了,重新启动IIS还是启动不了!!!!!!!救命啊………………
在注册表HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Security
下按如下格式加一项就好了
"BlockXBM"=dword:00000000
imagejpeg$im);就行了,只是质量很差。
extension=php_gd2.dll
嘿嘿验证码那里加上后面“(如果您看不到验证码,请刷新页面,再看不到请重装系统!)”