如何輸入漢字,和修改背景顏色,網(wǎng)上查了幾個(gè)不能用啊,
imagettftext();&
$bgcolor = imagecolorallocate($image, r,g,b);
imagefill($image, 0, 0, $bgcolor);
&imgfilledrectangle()。都不行啊~
imagettftext();&
$bgcolor = imagecolorallocate($image, r,g,b);
imagefill($image, 0, 0, $bgcolor);
&imgfilledrectangle()。都不行啊~
2016-03-24
舉報(bào)
2016-03-25
imagefill — 區(qū)域填充
imagestring($image,$fontsize,$x,$y,$string,$string_color);//設(shè)置輸入漢字的函數(shù)。
imagefill($image,0,0,$red);//從圖片Image(0,0)的位置以red顏色填充,看你的代碼上一行r,g,b應(yīng)該寫(xiě)成$r,$g,$b(或許你表示其他意思),實(shí)在不行可以試試用水印來(lái)修改背景顏色,用imagecopy這個(gè)函數(shù)設(shè)置水印,或者漢字都行。