Members

Technology Zones

Articles

Hosted By

MaximumASP

Info

Rated
Read 43,659 times

Contents

Downloads

Related Categories

Image Generation on the FLY using PHP - Introduction

jdk

Introduction

PHP, or PHP Hypertext Pre-processor, is one of the most popular scripting languages available to web developers. There are many reasons why PHP is now the most popular server-side scripting language for the Apache web server. Firstly, it supports database connectivity to a huge number of popular vendors, including Microsoft, Oracle and IBM. Secondly, with the correct libraries installed, PHP also supports real-time generation of images, PDF files, and even shockwave movie files! The only limit that bounds us when we’re developing with PHP is our imagination.

For developers like myself, one of the most popular features of PHP is real-time image generation. That is, we can create a new image canvas, “paint” it, and either save it to a file, or send it directly to the browser. In this article, I will show you how to create an image in real-time with PHP. The image will be similar to the ones used on yahoo.com and paypal.com, where a random number is generated inside of an image. That image is displayed in the browser, and you have to enter that random number into a text box to create a new account. This is a method that is becoming more popular, and it’s used to stop people from generating multiple user accounts in one go, which, is some cases, can crash the web server(s).

A fellow who believes in simple things, simple way.

Comments

  • dynamic image on the fly

    Posted by babulgogoi on 02 Apr 2005

    Hi

    I saw them using a image-on-the-fly script as (at www.worldspaceasia.com):
    Image Generation on the fly

    Posted by chukws on 06 Nov 2004

    Very good tutorial and useful. But am wondering, if it can be converted to be used as a counter in a website, to get the number of visitors to the site. It will then start from a certain number and co...

  • php_gd.dll

    Posted by altimastr on 03 Sep 2004

    after installing the gd.dll am i suppose to uncomment it in the php.ini file and if so do i restart my server to get it to load??? after putting it in my php.ini file and uncommenting it nothing came ...

  • Checking

    Posted by niceguy_reddy on 18 Aug 2004

    I used the script it was good. The random script is accessed as an image in another script, then how to access the number displayed on the image so that i can check that the user entered the correct d...

  • great tutorial, thanks

    Posted by Idea_Rat on 05 Aug 2004

    very well-written & useful javascript:smilie(':)')