Hay i am trying to use Hindi text in GD Library i call text from array but its Look like something this boxes [] [] [] [] [] [] [] [] []
This is my code have a look this
header ("Content-type: image/jpg");
$font='captcha/OpenSans-Regular.ttf';
$images2='http://graph.facebook.com/'.$user->id.'/picture?width=320';
$images='../../images/news.jpg';
$im = imagecreatefromjpeg("$images")or die("Cannot Initialize new GD image stream");
$im2 = imagecreatefromjpeg("$images2")or die("Cannot Initialize new GD image stream");
$newsText1 = "$user->first_name ने दुनिया को एलियंस से बचाया";
$newsText2 = "$user->first_name अब नजर आएंगे प्राइम मिनिस्टर की कुदसि पर ";
$newsText3 = "$user->first_name की निस्क्लि हज़ार करोड़ की लॉटरी";
$a=array($user1,"$newsText1","$newsText2","$newsText3");
$random_keys=array_rand($a,3);
$text=$a[$random_keys[0]];
$text_color = imagecolorallocate($im,255,255,255); //menentukan warna text
imagettftext ($im, 35, 0, 200, 550, $text_color, $font, $text);
imagecopy($final_img, $im, 0, 0, 0, 0, $x, $y);
imagecopy($final_img, $im2, 130, 115, -10, -10, 330, 330);
imagejpeg($final_img);
imagedestroy($final_img);