Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Passwords to differnet Pages

Status
Not open for further replies.

kpierson

Technical User
Jul 13, 2000
9
0
0
US
This should be easy but I am brain dead today after working on email server till 3am.

I have two passworded pages, what I need is, if password1 is used it goes to
page 1, if password 2 is used it goes to page 2.

What I have right now is for on one page is:
<cfif (trim(login_password)) is NOT &quot;password1&quot;>
<h2>You entered an incorrect password!</h2>
<cfabort>
</cfif>

How can I get it to check and see that if password2 is used it will go to page2.cfm and if password2 is not used, to check and see if password1 is used. If it is then go to page1. If neither is used to abort.
 
<cfif (trim(login_password)) eq &quot;password1&quot;>
<cflocation url = &quot;page1.cfm&quot;>
<cfelseif (trim(login_password)) eq &quot;password2&quot;>
<cflocation url = &quot;page2.cfm&quot;>
<cfelse>
<h2>You entered an incorrect password!</h2>
<cfabort>
</cfif>

thereptilian120x120.gif
 
Thanks for your reply, I will give that a try.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top