close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Captcha fail wipes out data?

Thread began 8/26/2010 12:02 pm by ShorePatrol | Last modified 9/08/2010 11:34 am by Jason Byrnes | 3222 views | 15 replies |

ShorePatrol

Captcha fail wipes out data?

I love the captcha feature, but I find it annoying that if you type in the wrong letters, you lose all your other field data.

Is there any way around this?

Thanks!

Sign in to reply to this post

Jason ByrnesWebAssist

yes, server validations creates a validated entries binding group on the bindings panel.

Bind the initial value for each form element to the corresponding Validated Entry binding.

Sign in to reply to this post

ShorePatrol

Confused

Jason,

The contact_group_name field already has this as it's value:
value="<?php echo((isset($_GET["Contact_me_group_Name"]))?$_GET["Contact_me_group_Name"]:"") ?>"

Shouldn't this be inserting the value if the captcha code fails?

Any advice appreciated.

Sign in to reply to this post

Jason ByrnesWebAssist

No, that value is for the querystring. This will not be passed when the form fails validation.

Sign in to reply to this post

ShorePatrol

hmmm

Ok. But that doesn't help me...

Let me ask this: when is the captcha validated? before the form is submitted, or after on the receiving page?

Again, I don't know how to fix this problem. Can you describe in detail how to fix? I would think this functionality should be built in, no?

I only ask because most forms I see on the internet, when captcha fails, all my other fields are still there, and don't have to be filled out again (aside from password fields).

Thanks for any more guidance.

Sign in to reply to this post

Jason ByrnesWebAssist

captcha is validated when the form submits.


What you are trying to do is built in. It is built into the validated entries bindings on the bindings panel


the validatied entries are created when the form fails validation.

it is created to hold the form values that passed validation.

if you bind the initial values of the form fields to the validated entries bindings, they will retain the values.

Sign in to reply to this post

ShorePatrol

grrrr

Jason,

I know the validation occurs when the form is submitted - but does the validation happen on the current page BEFORE submission, or the posting page? (for the captcha) - if I understood this, maybe that might help me understand why the values are not being retained.

You can see my screen shot - under the bindings tab, there is nothing listed under "WA Validated Entries" for me to assign anything to. So I end up assigning it to the form value (above WA Validated Entries) and I get this code for value:

After binding the values, this is what the "value" attribute is showing for the name field:
value="<?php echo((isset($_POST["Contact_me_group_Name"]))?$_POST["Contact_me_group_Name"]:"") ?>"

And of course, the values are not retained after failed validation.

What "should" the above code be? I'm totally confused at this point, because I would think this should be all set up as soon as the code is inserted, I wouldn't think I would need to assign anything, etc...

Please explain - sorry if I'm being stupid here - but I'm not getting it....

Thanks

Sign in to reply to this post

Jason ByrnesWebAssist

do you have the forms action set to post to another page?


The validated entries bindings only exist on the forms action page.

to get the correct code to use, you can go to the forms action page and expand the validated entries bindings there to copy to the form page.

Sign in to reply to this post

ShorePatrol

2 pages

Yes, the form.php page POSTs to the send.php page. But again, there is nothing under the WA validated entires.

I give up

Sign in to reply to this post

Jason ByrnesWebAssist

there is nothing under validated entries on the send.php page?


can you send copies of your pages so I can take a look at how it is set up.

Sign in to reply to this post
loading

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