News Feed
Jobs Feed
Sections




News Archive
feed this:

Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
Simple Captchas with PHP and GD
March 07, 2014 @ 12:05:38

On the SitePoint PHP blog there's a new post by Mahul Jain looking at a simple way to create CAPTCHA images in PHP using the built-in GD libraries.

By now, we've all encountered captcha images in online forms. Captchas are a necessary evil, and this article will teach you how they're made. Please note that while there are better, automatic third party solutions for captchas out there such as ReCaptcha, this tutorial aims merely to explain and demonstrate how such technology actually works. We won't be explaining what captchas actually are, as it's assumed to be common knowledge and already covered in greater detail elsewhere.

He walks you through the whole process of making the sample CAPTCHA (like this one):

  • Display an empty image on the browser
  • Create a shape
  • Generate random lines
  • Generate random dots
  • Generate random text

There's screenshots all along the way too for reference as to what your result should look like. You can download the full code over on GitHub.

0 comments voice your opinion now!
captcha gd tutorial introduction

Link: http://www.sitepoint.com/simple-captchas-php-gd/

DevShed.com:
Asirra Captcha PHP Integration
July 29, 2010 @ 10:36:28

On DevShed.com today there's a new tutorial about implementing the Asirra CAPTCHA system (from Microsoft) into your application for spam prevention.

Unlike other types of captcha that utilize difficult text obfuscation techniques (such as Google reCaptcha), this system utilizes images of dogs and cats, such as those shown in this screenshot.

They describe some of the reasons to use the system (hard to break, doesn't use sessions, easy to integrate) and how it works. They show how to implement the system on both the server and client side.

0 comments voice your opinion now!
asirra captcha tutorial integrate spam


phpDevelopment Blog:
Zend Framework Tutorial Series Part 3 '" Login and Signup with (RE)Captcha
July 13, 2010 @ 12:30:32

In a new post to his phpDevelopment blog Andrei Gabreanu has added the third part of his Zend Framework tutorial series. This time he looks at using a CAPTCHA image in your form via a call to a Zend_Captcha component.

he third part of the tutorial series will present you with a fully functionable solution for a login and signup page that activates a RECaptcha, via Zend_Captcha as a Service, when the user attempts to login/signup 3 times and fails. The tutorial will also show you how to use your models and how to structure your business logic inside your module based application.

They help you set up the database configuration information, create a sample layout for the page, work with the authentication and users controllers and, of course, the form. The inclusion of the CAPTCHA is as easy as adding a Zend_Form_Element_Captcha to the Zend_Form instance and setting up the user/signin process.

0 comments voice your opinion now!
zendframework login signup tutorial captcha


PHPBuilder.com:
Create a CAPTCHA Script with PHP
January 06, 2010 @ 11:49:52

On PHPBuilder.com today there's a new tutorial posted helping you create a simple CAPTCHA image you can use in your forms to help to somewhat secure them from scripts out there that might abuse them.

CAPTCHA protection is used on web site forms and works by generating a random string, writing it to an image, then storing the string inside of a session. Then, the site checks the CAPTCHA when the form is submitted. In this article, you will learn how to make your own simple CAPTCHA image using PHP. You will create the CAPTCHA image step by step.

Their example uses numbers, lowercase letters and a few other characters to create the distorted image. The tutorial shows you how to take this character set, pull out a few randomized values and push them into a dynamically created image with PHP's built-in GD functionality. They also include a brief script showing how to use it in the form for validation of the submission.

1 comment voice your opinion now!
captcha tutorial gd image


The Tutorial Blog:
Adding security to CodeIgniter forms with a custom library class
December 17, 2009 @ 08:15:41

On The Tutorial Blog today they've shared a library that you can use on your CodeIgniter application to help give your forms a bit more security - a math problem "captcha".

The class that we are going to create within CI will simply add a math question that the user will have to enter correctly to continue. This is useful to stop bots from mass submitting information to your forms. The class we are going to write is only very short and simple, but it will give you an idea of how to create classes for your own projects.

Their class creates two random numbers to be used for the question, displays the question the user should answer (Ex. "What is 2 + 4?") and sets the answer in the flashdata, ready for the page submit. When the controller reloads, the answer the user gave and the one from the flash are compared as a part of the standard form validation rules.

0 comments voice your opinion now!
codeigniter framework tutorial captcha addition


NETTUTS.com:
Build Your Own Captcha and Contact Form
June 11, 2009 @ 13:39:48

NETTUTS.com has posted a new tutorial on how to create and use your own CAPTCHA image to help protect the submission of your form.

Ever get hit with spam through the contact form on your personal site? Well, here is a short tutorial on how to build a custom captcha to keep the bad guys out.

The tutorial's broken up into eight steps:

  • captcha.php and the Session
  • Random String
  • Storage Folder and Colors
  • Building the Image
  • Image Final
  • contact.php
  • HTML & CSS
  • Validate

Plenty of screen shots and example code/HTML/CSS are included.

1 comment voice your opinion now!
form contact tutorial captcha


DevShed:
Designing a Captcha System with PHP and MySQL
June 05, 2009 @ 08:49:15

On DevShed's PHP section today there's a new tutorial focusing on the creation of a CAPTCHA image to help prevent spam on the forms (and other input methods) of your website.

Spam is one of the biggest problems on the Internet. It is getting harder to fight with the advent of spam bots that visit websites and automatically fetch email addresses, fill out forms and do other nasty things, such as blog spam comments, that could degrade your integrity. Fortunately, using captcha can help. This article will show you how to implement captcha on your site.

CAPTCHA images are those small images, usually at the bottom of forms, that have distorted letters and numbers in an effort to prevent anything not human from submitting the form correctly. They're usually accompanied by a form field asking for the letters/numbers displayed in the image. In the tutorial they use PHP's built in GD support to create a script that builds the image from an inputted string.

They also give an option for a GD-less version, but it's not nearly as dynamic and wouldn't help as much as the image generated on the fly.

0 comments voice your opinion now!
tutorial gd mysql captcha


NETTUTS.com:
9 Extremely Useful and Free PHP Libraries
April 09, 2009 @ 07:51:16

NETTUTS.com has posted a list of nine libraries you can use to quickly and easily add functionality to your web application.

A lot of functionality is shared among applications - like sending emails or preventing spam. In the spirit of reusing the wheel instead of reinventing it, here are nine free web libraries that you can use in your next program which will dramatically increase your efficiency.

Here's their list:

Screenshots (and code examples) are provided for several of the items as well as links to their website and documentation pages.

5 comments voice your opinion now!
useful library list captcha aksimet json chart xmlrpc amazon s3 mail


WebReference.com:
User Personalization with PHP The Verification Code
March 17, 2009 @ 09:37:50

WebReference.com continues their look at user personalization with the second part of the series - how to validate that the users signing up for your site are valid. (Here's part one, the introduction).

In this article, we will be looking at user authentication. User authentication simply means verifying that a particular user has the right to access a part of our application. Because our application deals with user preferences, access control is even more pertinent especially since multiple users are going to try to access this application at any given time.

As a part of this user validation and customization, they need to create a form that non-human scripts have a harder time using (hopefully weeding them out and getting better user information). The article steps you through a few lines of code that you can use to create a simple image of a four-digit number whose value is placed in a session variable so it can be validated on submission of the form.

0 comments voice your opinion now!
captcha image validation user personalization gd random digit


Asvin Balloo's Blog:
10 useful PHP PEAR packages
March 02, 2009 @ 07:58:22

In a new post to his blog today Asvin Balloo has posted ten useful PEAR packages (just some out of a long list) that can help you with everything from database access to creating Excel spreadsheets.

His list of ten is made up of:

  • MDB2 (database access)
  • Text_CAPTCHA
  • Log
  • LiveUser
  • Translation2
  • Validate
  • Spreadsheet_Excel_Writer
  • Net_GeoIP
  • File_Archive
  • XML_Serializer

For most of them he also includes links to tutorials showing how to use them and with more info about them.

0 comments voice your opinion now!
pear package list useful database logging validate captcha



Community Events











Don't see your event here?
Let us know!


language introduction package database hack install podcast component hhvm symfony2 facebook release project performance composer example unittest application security framework

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework