Another Captcha Library for CodeIgniter

One of our client wanted a different captcha in his website. We were using the default captcha plugin which bundles with CodeIgniter. I have used this script on a different project long ago and that one was a scratch coding. So, i took some of my time and ported it to CodeIgniter.


  • Change the Captcha Background Color
  • Choose Font / Random Font from fonts folder
  • Increase Number of lines for Noise Creation
  • Different color or custom colors for Line used for Noise.
  • Captcha Letters have different colors or you can provide your own color set.
  • Custom Image Height/Weight/Font-size
  • Many more…

Expected Look :

Captcha CI libraray

Captcha CI libraray

Requirment: CodeIgniter 1.7.* , GD, PHP 4/5

SOURCE CODE: In github [ How to  Use?  Check wiki page. ]


12 thoughts on “Another Captcha Library for CodeIgniter

  1. Jason says:


    Quick question, I’m unfamiliar with codeigniter. I’ve taken over a project and the client requires captcha to be installed in their currnet forms on the site. I’ve got this succesfully generating the images in the captcha folder, but for some reason I can’t seem to display the image in the form page.

    I’m using this in view page:

    <img src="” alt=”CAPTCHA”>

    It just shows blank, nothing. Would that mean the controller isn’t setup properly?

  2. sakawijaya says:

    Hello thanks for your awesome captcha….

    i deleted generate images in the directory, using this step (in controller) :

    foreach(glob($configs[‘img_path’].’*.*’) as $v){
    if($configs[‘img_path’].$captcha[‘time’].’.jpg’ != $v)

    thanks anyway… i am using your captcha now 😀

  3. AzeriFire says:

    I’ve an idea about auto clean older images.What about delete older ones every captcha plugin loads.Image name stores generated times also. We can check time now and delete older ones to check time in there names.


  4. tohin says:

    nice .. please if possible fork my project and add this piece of code. I am not sure when will be the next time i need to use this captcha but sure this piece of code can be a extra addition. Thanks

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s