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

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

email PW often doesn't work

Thread began 2/07/2011 6:34 pm by CraigR | Last modified 2/08/2011 2:24 pm by Jason Byrnes | 1032 views | 7 replies |

CraigRBeta Tester

email PW often doesn't work

I have set up my email new password page, and on 10 tries this evening, the reset password only worked on 4 occasions.

if it always failed, that would be something to diagnose, but i can;t work out why it works some of the time

Sign in to reply to this post

Jason ByrnesWebAssist

can you send a copy of the page so i can see the code.

Sign in to reply to this post

CraigRBeta Tester

Ok, here it is

Attached Files
emailpw.zip
Sign in to reply to this post

Jason ByrnesWebAssist

One thing I see that could cause this page to not work is if you use the enter key to submit the form.


the enter key will press the first button on the page. On this page, the first button is the login button which will send you to the login page.


You have the email behavior set to send the user to the emailpwsent.php page. When it doesnt work, is the user going to that page or the login page?

When it doesnt work, what exact does happen?

Does the users password update in the database, but the email does not send, and the user is sent to the emailpwsent.php page?

Does the password update fail, the email fail and the user is directed to the login page?

or does the password update fail, the email fail and the user is directed to the emailpwsent.php page?

Sign in to reply to this post

CraigRBeta Tester

Hi Jason.

I will swap the button around, but..

When the email address is matched, the email is sent, every time, and the user is directed to the pwsent page.
When the email address is wrong, the user is directed to the fail page and no email is sent

However, the strange thing is, the password, even though it is always sent, doesn;t always work.

sometimes after 3 or 4 attempts, the login is allowed

Sign in to reply to this post

Jason ByrnesWebAssist

Ok, so it is either an issue with the update record behavior or the login behavior, My Money is on the update behavior.


first, edit the email form element to give it a value attribute, I have seen erratic behavior come from form elements that doent have a value:

<input name="emailAddress" type="text" size="50" value="" />




next take of the redirect in the email behavior, change:

php:
"successRedirect" => "emailpwsent.php",




to;

php:
"successRedirect" => "",



then add an echo to the body of the page to show the update statement:

php:
<?php if (isset($_POST["Send"])) { ?>

SQL: <?php echo($WA_Sql); ?>
newpassword session <?php echo($_SESSION['newpwd']); ?>
<?php 
?>
Sign in to reply to this post

CraigRBeta Tester

Thanks Jason.

The password and session variable were being set ok, so setting the text field value to an empty string may well have been it.

It seems to work now, I did get a couple of failures, but that was due, I think, to copy/paste errors

Sign in to reply to this post

Jason ByrnesWebAssist

Ok glad to hear it 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...