$content=fread($fp,filesize($file_dir));//读文件
用了,为何下面不调用它呢
已经帮你修改好了[*]header("Content-type:image/png");
[*]$file_dir="verchk.txt";
[*]$fp=fopen($file_dir,"r");
[*]$content=fread($fp,filesize($file_dir));//读文件
[*]fclose($fp);
[*]$fplen=strlen($content);
[*]//计算字符字数
[*]$mailaddressimages=imagecreate($fplen*10,25);
[*]//获得文件名图片信息。
[*]$lenadd=$fplen;
[*]$fontsize="4";
[*]$center=(imagesx($mailaddressimages)-8.3*strlen($content))/2;
[*]$mailimagesbackground=ImageColorAllocate($mailaddressimages,231,196,43);
[*]$mailimagesfacecolor=ImageColorAllocate($mailaddressimages,0,0,0);
[*]ImageString($mailaddressimages,$fontsize,$center,5,$content,$mailimagesfacecolor);
[*]Imagepng($mailaddressimages);
[*]ImageDestroy($mailaddressimages);复制代码
页:
1
[2]