Results 1 to 1 of 1

Thread: Workin' on a Form Validation solution...

  1. #1
    Thread Starter
    Junior Member pfadmin's Avatar
    Join Date
    Aug 2010
    Posts
    41
    Thanks
    0
    Thanked 5 Times in 3 Posts

    Workin' on a Form Validation solution...

    Hi guys,
    as I said I would like to implement the form validation into CP, in order to be able to check what the user are entering IE: if a field requires a email address, email address must be!

    So I've been watching around the code of CP, and i've been surprised from the presence of the jquery.validate.js plugin. So I started to wonder how could be possible to imprement this plugin with the form that users are using to add new ads!

    This plugin is very useful because it let you set the kind of validation for each field simply by adding or removing classes to the object. I thought it could be cool to implement this functionality in CP so I started to edit some core files of the template.

    I went accross the valiable $options_new_field inside the file admin-values.php. In here I added another array with the following options:
    Code:
       array( 'name' => __('Validazione Campo', 'cp'),
                'desc' => '',
                'tip' => __('Selezionare se è necessario attivare gli strumenti di validazione per questo campo, successivamente sará possibile selezionare quale/i validazioni prendere in considerazione.'),
                'id' => 'field_validation',
                'css' => 'min-width: 400px;',
                'type' => 'checkbox',
                'req' => '',
                'vis' => '',
        ),
    I would like to add a list of checkboxes with different values, one for each class used by the plugin, but in the file is not clear how to create multiple checkboxes...

    Anyone of you has got any idea?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. post an ad Form validation & paypal not working
    By getliveads in forum Help Using ClassiPress
    Replies: 3
    Last Post: January 11th, 2011, 06:30 AM
  2. [SOLVED] Since I upgrade to 3.0.5.2 All the site widgets stop workin..
    By adfree in forum Report ClassiPress Bugs
    Replies: 2
    Last Post: December 18th, 2010, 11:06 AM
  3. For Validation
    By jaidev in forum Report ClassiPress Bugs
    Replies: 3
    Last Post: September 19th, 2010, 10:09 AM
  4. Zip code validation
    By featured in forum Help Using ClassiPress
    Replies: 2
    Last Post: May 4th, 2010, 01:31 PM