qForms v2.0 Preview Online...

Posted by Dan on Apr 14, 2004 @ 3:50 PM

Ok, I finally got the qForms v2.0 Preview uploaded. I had some problems with Camtasia on my laptop—the recording was fine, but I couldn't export to SWF—I finally got things working by installing Camtasia on one of my desktops. Here's a quick rundown on some of the things you'll see in the preview:

New Features

  • Support for internationalization (i18n.) The window.$language variable will allow you define a language pack to load.
  • Better support for add-on modules. The API has been re-written to easily allow add-on mods to the library. The previous version did a great job on allow allowing new validation method to be quickly added and to add custom functions, but it took a little too much work to change the default behavior or to add your own event hooks.
  • You can now overwrite the default methods used to output errors to the screen. The sample addon/dhtml mod shows an example of this.
  • Lots of new methods--such as the setMaxLength() method which can be used to automatically forward the user to another field after X number of characters are entered. This is great for times when you went to split input between multiple fields (such as the case in phone numbers, ssn, serial numbers, etc.)
  • You can now set dynamic masking for a field. When filling out fields such as phone numbers and ssn, masks can be applied to the field and qForms will automatically filter out invalid keystrokes and insert the required mask characters where appropriate.
  • A new "Group" object has been added. Groups allow you to take multiple fields and treat them as one. This feature will often be used in conjunction with the setMaxLength() method in order to break up a particular value into multiple fields.
  • The ability to delete validation rules from the queue on-the-fly.
  • Disable/enable validation for the entire form.
  • Much, much more.

Go view the qForms v2.0 Preview over at PengoWorks.com. Let me know if you have any comments!

Categories: JavaScript, qForms, HTML/ColdFusion


  • Looks great Dan!

    Glad to see the messages can be customised -- no more "The your name field is required"...

    When a group is submitted, does a form variable exist containing the aggregated content of the multiple fields.

    Is the mask cross-browser? I've experimented with this kinda idea but only ever succeeded in IE.
  • A form field could--you can use the mirrorTo() method to copy it to a hidden form field. One of the goals of groups is so that you can also apply validation to a group. So if you have a need to break a value across multiple field, you can still validate against it.

    The mask library will be cross browser. I'm in the process of re-doing it now, there are issues with it I'm not happy with. I'm becomming tempted to ignore NS4 support though. Keeping NS4 support has really added a lot of code within qForms and I'm seriously considering whether it's worth supporting anymore. After all, it is like 7 years old.
  • Yes, ignore NS4, but please don't forget Safari. Thanks!
  • Unfortunately, I don't have access to a Mac to test Safari--so I have to leave it up to beta testers to report and help debug issues.
  • I'm with Greg, drop NS4.
  • Hey Dan, I was just looking at this stuff thinking "cool, a new version of qForms" and then I looked at the post date and realized it's 2 years old. Did it ever get finished or are you still in need of able assistants?
  • We use qforms on almost all our forms and have recently discovered that dependencies in qforms do not work in Safari. Dan, if you are still developing qforms, is there anything you can do about this?
  • Would somebody be willing to send me an example page with qforms validation for various fields (email, name, alphanumeric, phone etc) that uses "post" method. What also would be great is an example of the server side that does the insert into a MYSQL database and returns you to the original form page.

    Thanks in advance, bruce
  • Will it add support for detecting default values and whether the form is modified or not when using dynamic related selected boxes?

Comments for this entry have been disabled.