<?php
$img=imagecreate(100,30);
$bg=imagecolorallocate($img,0,0,0);//背景
$te=imagecolorallocate($img,255,255,255);//字体颜色
imagestring($img,3,0,0,"egeryh",$te);
header("content-type:image/jpeg");
imagejpeg($img);
?>
浏览可以正常显示
修改成下面 的
<?php
$year="1,2,3,4,5,6,7,8,9,0,a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z";
$arr=explode(",",$arr);
for($i=0;$i<4;$i++){
$imgNum.=$arr[rand(0,35)];
}
$img=imagecreate(100,30);
$bg=imagecolorallocate($img,0,0,0);//背景
$te=imagecolorallocate($img,255,255,255);//字体颜色
imagestring($img,3,0,0,"egeryh",$te);
header("content-type:image/jpeg");
imagejpeg($img);
?>
还没把$imgnum加到图片上呢,却显示不出来图片
求帮助