Php GD Library


GD is an open-source code library for the dynamic production of pictures by programmers. GD makes PNG, JPEG, and GIF pictures, among different image formats. GD is ordinarily used to create diagrams, illustrations, thumbnails, and most whatever else, on the fly. while not limited to use on the web, the most widely recognized utilization of GD include site advancement.

The GD library is utilized for dynamic picture creation, from PHP we use with the GD library to make GIF, PNG, or JPG pictures quickly from our code. This permits us to do things, for example, make outlines on the fly, made an enemy of robot security picture make thumbnail pictures, or even form pictures from different pictures. If you are unsure if you have a GD library, you can run phpinfo() to check that GD support is enabled.

Example

<?php

$handle = ImageCreate(130(width),50(height)) or die("Cannot Create Image");
$bg_color = ImageColorAllocate($handle,255,0,0);
$txt_color = ImageColorAllocate($handle,0,0,0);
ImageString($handle,5,5,18,"www.webprogrammingtutorials.com",$txt_color);
ImagePng($handle);

?>