close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Check for Email Confirm bug is back

Thread began 2/17/2010 1:35 pm by mikeljones390303 | Last modified 2/22/2010 10:16 am by mikeljones390303 | 1616 views | 8 replies



I found the server behavior for the statement: WA_Auth_RulePasses("Email Confirmed")

The server behavior code is as follows:

Allow if <?php echo $_SESSION['UserEmailVerified']; ?> = 1
Allow if <?php echo $_SESSION['UserID']; ?> <> empty

So i added code to check the session values for both 'UserEmailVerified' and 'UserID' to the page.

When I run the page the session 'UserID' is 4 and the session 'UserEmailVerified' is 0 however the WA_Auth_RulePasses("Email Confirmed") check still returns success.

I'm confused... How can the check return true if the values show up on the same page as being false?

Is the server behavior check for two entries an && or an || operation?

Example of AND operation: ((confirm == 1) && (userid <> null)) == true;
Example of OR operation: ((confirm == 1) || (userid <> null)) == true;

If the check is an OR operation it would explain the bug.
An OR operation of the two decisions would return true as the userid decision will return true even if the verified value is 0.

Why does the email confirmed server behavior include code to check the userid?

* Test Code *
<p>Raw UserEmailVerified database table entry for this user:&nbsp;<?php echo $row_WAATKusers['UserEmailVerified'];?></p>
<p>SESSION UserEmailVerified:&nbsp;<?php echo $_SESSION['UserEmailVerified']; ?></p>
<p>SESSION UserID:&nbsp;<?php echo $_SESSION['UserID']; ?></p>

<p>Test of show region: WA_Auth_RulePasses("Email Confirmed"):&nbsp;
<?php if(WA_Auth_RulePasses("Email Confirmed")){ // Begin Show Region ?>
<?php } // End Show Region ?>
<?php if(!WA_Auth_RulePasses("Email Confirmed")){ // Begin Show Region ?>
<?php } // End Show Region ?>

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





Ease of use


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