close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

validation values

Thread began 2/03/2017 7:15 am by Jamie | Last modified 2/08/2017 3:22 am by Ray Borduin | 197 views | 8 replies |

Jamie

validation values

Hey Ray

On the attached update page, the update is working fine but retaining a value in an empty field on fail validation is just leaving the field empty and cant see where its going wrong.

Your advice as always gratefully received.

Cheers

Jamie

Sign in to reply to this post

Ray BorduinWebAssist

I don't fully understand the description of your problem. Which field has the problem? What exactly is the issue? Steps to reproduce and a more detailed description of the problem will help.

Sign in to reply to this post

Jamie

Ok. If an input, say Telephone, is empty in the db and then a user adds a value to the input field and hits submit but the submission fails on a different input (e.g. Password), the Telephone input goes back to blank when it should retain the value added before submission

Sign in to reply to this post

Ray BorduinWebAssist

To fix that you would set the phone input field value to:
value="<?php echo((isset($_GET["invalid"])?ValidatedField("customerupdate_096","UserPhone"):"".$row_WADAlogins["UserPhone"]."")); ?>"

That way if it fails validation it uses the ValidatedField value otherwise it gets the value from the recordset.

Sign in to reply to this post

Jamie

sorry, I have been using that structure (think I uploaded same named file, different project which didnt show the right code) for the input and thats why am getting confused. See attached. It doesnt retain an entered field on failed submissiona and cant figure out where its going wrong

Sign in to reply to this post

Ray BorduinWebAssist

Go through all of your text fields on that page. You will see that many of them do not use that syntax for setting the values.

Sign in to reply to this post

Jamie

i have no idea what is going on with the file...but the live file is definitely using the right syntax and have tried uploading it to this message as well...hopefully the right one is going up

Sign in to reply to this post

Ray BorduinWebAssist

You have to add the invalid url parameter to the validation fail redirect.

So On line 17 it should be something like:
$WAFV_Redirect = "member_update-2.php?invalid=1";

Sign in to reply to this post

Jamie

got it...thanks Ray

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