close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

EmailPW sending just [Session.NewPW]

Thread began 2/02/2011 1:28 pm by dan361748 | Last modified 2/02/2011 2:04 pm by Jason Byrnes | 1168 views | 2 replies |

dan361748

EmailPW sending just [Session.NewPW]

Hi - I have at the top of my emailPW.php file this code:

<?php
if (!session_id()) session_start();
if(isset($_POST["Send_x"])) {
$_SESSION["NewPW"] = "".WA_RandomPassword(9, true, true, true, "") ."";
}?>

The page is generating the random password properly I think and it is being written to the DB.

However when the email behaviour sends out the new password, the recipient gets this:

Your new password is: [Session.NewPW]

The other fields (like username) are being generated fine. But the new password doesn't display - just the reference for it.

Any help would be really appreciated!

Thanks
Dan

Sign in to reply to this post

dan361748

More info on this - here is my code for the Email behaviour:

// WA_SecurityAssist_Email_1_SendMail

if($_SERVER["REQUEST_METHOD"] == "POST"){
//WA SecurityAssist Email object="Mail for Linux"
$WA_Auth_Parameter = array(
"connection" => $boomcms,
"database" => $database_boomcms,
"tableName" => "users",
"filterColumn" => "UserEmail",
"columnValue" => "".((isset($_POST["emailAddress"]))?$_POST["emailAddress"]:"") ."",
"columnType" => "text",
"usernameColumn" => "UserName",
"passwordColumn" => "UserPassword",
"selectColumns" => array(""),
"sessionVariables" => array(""),
"successRedirect" => "emailPW-thanks.php",
"failRedirect" => "emailPW.php?email=failed",
"keepQueryString" => FALSE,
"toAddressColumn" => "UserEmail",
"fromAddress" => "info@mydomain.com",
"fromAddressDisplay" => "mydomain.com",
"subject" => "Your password has been reset.",
"mailBody" => "Your password at mydomain.com has been reset. <br />Your new account details are as follows:<br />\nUser name: [UserName]<br />\nPassword: [Session.NewPW]<br />\nTo log in using your new password, please visit mydomain.com",
"emailFunction" => "WA_SecurityAssist_Email_1_SendMail"
);

WA_Auth_ForgotPassword($WA_Auth_Parameter);
}

Sign in to reply to this post

Jason ByrnesWebAssist

change:
"sessionVariables" => array(""),

to:
"sessionVariables" => array("NewPW"),

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