PHP
  Home arrow PHP arrow A PHP Validation Helper Class in Action
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid  
Request Media Kit
Contact Us  
Site Map  
Privacy Policy  
Support  
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
Google.com  
PHP

A PHP Validation Helper Class in Action
By: Alejandro Gervasio
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 2
    2009-08-31


    Table of Contents:
  • A PHP Validation Helper Class in Action
  • Review: the previous ValidatorHelper class
  • Checking integers and float numbers with the ValidatorHelper
  • Validating alphabetic and alphanumeric values, IP and e-mail addresses, and URLs

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article

     
     
    ADVERTISEMENT


    A PHP Validation Helper Class in Action
    ( Page 1 of 4 )

    If you’re an enthusiastic PHP developer interested in learning how to build helper classes, you've come to the right place. This article series will teach you in a few simple steps how to build several kinds of helper classes for manipulating strings, generating dynamic URLs and validate incoming data, and so forth.

    Welcome to the penultimate tutorial of the series on building helpers in PHP 5. Comprised of eight articles, this series provides you with the basic pointers to start creating your own helper classes with minor hassles, and complements the corresponding theory with a great variety of hands-on examples.

    And now that you've been introduced to the aim of this series of articles, it’s time to review the topics that were treated in the last part. In that installment I finished building a simple helper class that could validate different types of data, including numeric and float numbers, IP and email addresses, and URLs as well.

    The functionality of each method of this class was based mostly on PHP filters, since this extension not only permits you to perform a decent validation on incoming data, but it makes this a no-brainer process.

    However, if you’re anything like me, then you may want to see how this validation helper class can be used in concrete situations, right? Well, in this tutorial I’m going to develop some basic examples that will illustrate the real capabilities of the class for verifying all the types of data mentioned above.

    So, now it’s time to leave the preliminaries behind us and start evaluating this sample helper class through some concrete and easy-to-grasp examples. Let’s jump in!



     
     
    >>> More PHP Articles          >>> More By Alejandro Gervasio
     

       

    PHP ARTICLES

    - Adding Ordering and Grouping Clauses to the ...
    - Implementing Factory Methods in PHP 5
    - Merging a File Split for FTP Upload using PHP
    - Getting Data from Yahoo Site Explorer Inboun...
    - Method Chaining: Adding More Selecting Metho...
    - How to Split a File During an FTP Upload Usi...
    - Expanding a Custom CodeIgniter Library with ...
    - Using the Yahoo Site Explorer Inbound Links ...
    - Building a CodeIgniter Custom Library with M...
    - Building an E-mini Trading System Using PHP ...
    - Completing the MySQL Class with Method Chain...
    - Building Dynamic Queries with Chainable Meth...
    - PHP Encryption and Decryption Methods
    - Building a MySQL Abstraction Class with Meth...
    - Completing a Sample String Processor with Me...





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek