close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

CSS form builder / Form toolkit hook up own validation functions

Thread began 12/09/2010 12:25 am by biesheuvel378713 | Last modified 12/09/2010 1:20 pm by Jason Byrnes | 1533 views | 5 replies |

biesheuvel378713

CSS form builder / Form toolkit hook up own validation functions

I'm evry happy with both extensions they allow me to build a decent form within minutes. I like the server validation but there is still one thing I'm missing.

There are scenarios where you still have to write your own validations. It would be nice if both form toolkit and css form builder had the possibility of hooking up your own validation functions by means of a callback script.

It would greatly benefit the functionallity of both extensions.

For instance, now I'm building a site wich uses the phpbb membership for the whole site. I've constructed it that way that users can register on my site and automatically are members of the forum. To exclude spambots people can only register on my site on a form build by css form builder. This is very efficient, I haven't had any spambot until today.

But I had to add two more validations, one that checked if the username allreay existed and one that checked if the email existed. It's not very hard to do but building it into the css formbuilder form was very contra productive. In that case it would have been nice if I could hookup these functions in the css form builder (or form toolkit) validation.

I think there are many more of these scenarios and having the ability to hook up your own validation functions in both web assist extensions would speed up designing and building these forms and would benefit the functionality and quality of these extensions so maybe it's a good idea for the next upgrade?

Sign in to reply to this post

Jason ByrnesWebAssist

I dont follow what you mean exactly by "Hook up your own validations"

but once the form is created using css form builder, the server validation server behavior can be edited to add extra validations if needed.

Sign in to reply to this post

biesheuvel378713

What I meant was a feature that needs a function to validate. So the server validation will also look at the outcome of the function when validating the page.

The function would have an outcome of true or false (or any other values like "FAILED" "SUCCES" and would be called by the validation script of webassist.

In that case you can add more complex validations (like checking a database if the username or email exists) without breaking any of the webassist code.

Sign in to reply to this post

Jason ByrnesWebAssist

you can already check a database for a value with out breaking the code.

if you want to check if a username or email already exists in the database, create a lookup recordset that will filter the username or email address entered in the form on corresponding database column.

a dreamweaver recordset will create a variable that contains the total rows of the recordset, it will be named:
$totalRows_RecordsetName

where RecordsetName is the name of the recordset.


you can add a server validation that uses this variable:

in server validations select numeric validation.

set the server variable to use the totalRows variable:
$totalRows_RecordsetName


set the minimum number to -1 and the maximum number to 0.


this will cause validation to fail if the recordset is not empty

Sign in to reply to this post

biesheuvel378713

Wow thanks. Did it with SELECT COUNTER(*) AS counter.

Beautiful now it doesn't break the layout anymore, thanks for your great support!

Sign in to reply to this post

Jason ByrnesWebAssist

glad to hear i is working.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...