close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Keep the user input on form fields not being validated

Thread began 1/30/2011 12:59 am by lightwalkercreations361768 | Last modified 3/07/2011 1:08 pm by Jason Byrnes | 3151 views | 5 replies |

lightwalkercreations361768Beta Tester

Keep the user input on form fields not being validated

Dear WebAssist,

I have server side validation which is working perfectly. If the validation fails the user input is retained in the fields that are being validated.

However I have a few field that I do not need validation on them and can be left blank if the user wishes. I tried using echo _POST but the this did not work as the validations are using sessions. How would I retain the user input in fields that are not being validated. Is there a way to validate a field that will allow a blank entry so that a session will be created so I can use it to echo the user input, or is there a better way.

Many thanks as always for your help

Sign in to reply to this post

Jason ByrnesWebAssist

The validated entries collection created by the Server Validations will retain the values of any form element that is posted as long as it does not fail validation. This is to say that if you have a form element that does not have any validation, it's value will still be retained in the validated entries collection since it did not fail.

you will just need to bind the initial value for these form elements top the corresponding entry in the validated entries collection.

Sign in to reply to this post

bbifl346249

Dumb Question

Sorry, I'm new to a lot of this, but how do you even get the form to retain fields that are being validated, after validation that fails ?

Is this a 'typical' PHP function, or is it something provided by the WebAssist Form Toolkit ?

Any guidance would be appreciated.

Thanks, Steve.

Sign in to reply to this post

Jason ByrnesWebAssist

my previous reply explains this:

  The validated entries collection created by the Server Validations will retain the values of any form element that is posted as long as it does not fail validation. This is to say that if you have a form element that does not have any validation, it's value will still be retained in the validated entries collection since it did not fail.

you will just need to bind the initial value for these form elements top the corresponding entry in the validated entries collection.  



you can also find more information in the Form Builder Help:
wa_fv_22.html

under the Server Validation -> Maintaining form data when validations fail section.

Sign in to reply to this post

bbifl346249

Duh

Thanks Jason, how come some days I'm so incompetent I can't even find clearly worded answers in help files ? arrrrggghhhhh :D

Sign in to reply to this post

Jason ByrnesWebAssist

no worries.

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...