Generating Text Image Logo using PHP is quite simple and straight forward. May be the following code might help you to create logos, captcha, titles etc…
if (!(file_exists("logophilip.png"))) // Checks file exist or not
$imgvalue = "Philip Tiju Abraham"; // Assign some text for the logo
$font_file = 'font.ttf'; // font name/path
$pic=ImageCreate(500,70); // Define the size of the image a x b
$col1=ImageColorAllocate($pic,217,209,188); // Background
$col2=ImageColorAllocate($pic,79,79,79); // Fontcolor
ImageFtText($pic, 35, 0, 0, 50, $col2, $font_file, $imgvalue);
ImagePNG($pic,"logophilip.png"); // Thats it done...
I don’t think I need to explain how it works. Just place the code and enjoy. Make sure you have the font in the same folder or update $font_file with respective path.
Gravatar (an abbreviation for globally recognized avatar) is a service for providing globally unique avatars which was created by Tom Preston-Werner. On Gravatar, users can register an account based on their email address, and upload an avatar to be associated with the account. Gravatar plugins are available for popular blogging software; when the user posts a comment on such a blog that requires an e-mail address, the blogging software checks whether that e-mail address has an associated avatar at Gravatar.
$emailMD5 = md5($email);
$gravatarURL = "http://www.gravatar.com/avatar/" . $emailMD5 . ".jpg";
$html="<img src='$gravatarURL' />"; return $html;
public string GetAvatar(string Email)
string emailMd5 = Utilities.Encryption.MD5.ComputeHash(Email.Trim().ToLower()).ToLower();
string gravatarURL = "http://www.gravatar.com/avatar/" + emailMD5 + ".jpg";
string html = "<img src='" + $gravatarURL + "' />"; return html;