查看文件: makeroadname.php
大小: 1.83 KB
类型: application/octet-stream
<? Header("Content-type: image/PNG"); $background="/www2/skybni/test007/bb.png"; //$myfont="/www2/skybni/fonts/kaiu.ttf"; $myfont="/www2/skybni/fonts/wt009.ttf"; $savepath='/www2/skybni/test007/tmpimgs/'; $im = imagecreatefrompng($background); //$im = imagecreate(300,300); //$black = ImageColorAllocate($im, 0,0,0); $white = ImageColorAllocate($im, 255,255,255); // imagefill($im,68,30,$gray); // //台北市 南港區 南港路1段 單號 // $orange = imagecolorallocate($im, 255, 0, 0); $point_y=array(105,165,225,285);//high $point_4x=40; // strlen2 40,200 // strlen3 40, 120, 200 // strlen4 x = 40 //$point_2x=40,120; //$point_3x=40,120,120; $word='南' ;//substr($authnum,$c,1); $white = imagecolorclosest($im, 255, 255, 255); ImageTTFText($im,40,0,40,$point_y[0], $white,$myfont,$word); $word='港' ;//substr($authnum,$c,1); $white = imagecolorclosest($im, 255, 255, 255); ImageTTFText($im,40,0,120,$point_y[0], $white,$myfont,$word); $word='路' ;//substr($authnum,$c,1); $white = imagecolorclosest($im, 255, 255, 255); ImageTTFText($im,40,0,200,$point_y[0], $white,$myfont,$word); $word='一段單號' ;//'南港路' ;//substr($authnum,$c,1); // ImageTTFText($im,40,0,40,$point_y[1], $white,$myfont,$word); $word='網路二城' ;//'南港路' ;//substr($authnum,$c,1); ImageTTFText($im,40,0,40,$point_y[2], $white,$myfont,$word); $word='單' ;//'南港路' ;//substr($authnum,$c,1); ImageTTFText($im,40,0,40,$point_y[3], $white,$myfont,$word); $word='號' ;//'南港路' ;//substr($authnum,$c,1); ImageTTFText($im,40,0,200,$point_y[3], $white,$myfont,$word); // len4 mb_strlen(string $string, ?string $encoding = null): int $f=date('Ymdhis',time()).'.png' ; ImagePNG($im, $savepath.$f); ImagePNG($im); ImageDestroy($im); ?>
保存
取消
返回文件列表