View comments | RSS feed

Dreamweaver CS3  |  Go to CS4 Help

Verify the user name and password (ColdFusion, ASP, JSP, PHP)

You must add a Log In User server behavior to the login page to ensure that the user name and password that a user enters are valid.

When a user clicks the Submit button on the login page, the Log In User server behavior compares the values entered by the user against the values for registered users. If the values match, the server behavior opens one page (usually the site’s Welcome screen). If the values do not match, the server behavior opens another page (usually a page alerting the user that the login attempt failed).

  1. In the Server Behaviors panel (Window > Server Behaviors), click the Plus (+) button and select User Authentication > Log In User from the pop‑up menu.
  2. Specify the form and the form objects that visitors use to enter their user name and password.
  3. (ColdFusion) Enter your user name and password if applicable.
  4. Specify the database table and columns that contain the user names and passwords of all the registered users.

    The server behavior compares the user name and password a visitor enters on the login page against the values in these columns.

  5. Specify a page to open if the login process succeeds.

    The specified page is usually the site’s Welcome screen.

  6. Specify a page to open if the login process fails.

    The specified page usually alerts the user that the login process failed and lets the user try again.

  7. If you want users forwarded to the login page after attempting to access a restricted page to return to that restricted page after logging in, select the Go To Previous URL option.

    If a user tries to access your site by opening a restricted page without first logging in, the restricted page can forward the user to the login page. After the user logs in successfully, the login page redirects the user to the restricted page that forwarded them to the login page in the first place.

    When you complete the dialog box for the Restrict Access To Page server behavior on these pages, ensure that you specify your login page in the If Access Denied, Go To box.
  8. Specify whether to grant access to the page based on user name and password alone, or based on authorization level too, and click OK.

    A server behavior is added to the login page that ensures the user name and password entered by a visitor are valid.




Comments

Comments are no longer accepted for Dreamweaver CS3. Dreamweaver CS4 is the current version. To discuss Dreamweaver CS3, please use the Adobe forum.

Comments


No screen name said on Jun 20, 2007 at 2:17 AM :
the previous page of these instructions says
You don’t have to specify an action or method attribute for the form to tell it where and how to send the record data when the user clicks the Submit button. The Log In User server behavior sets these attributes for you.

this page says
In the Server Behaviors panel (Window > Server Behaviors), click the Plus (+) button and select User Authentication > Log In User

before i can click the plus button, i must choose a server behavior, and once i do, it changes the page i am working on to a .cfm page.
i then fill in the dialogue box and enter the name of the .cfm as a form action in my .html page.
am i doing this right?
so far, i have only been able to get the login failed page to show.
aswrt said on Feb 26, 2008 at 10:10 PM :
I have same problem. all works well except the login page doesn't verify the username and password that is in mysql database. Login Failed keeps popping up.....
sundaydriver said on Mar 4, 2008 at 7:27 AM :
this didnt help me one bit, i couldnt get it to work, it does not work with any <cfform>,<cfinput> or any other CF tags. it also was unable to see my database, it was just one error after another...time to research session variables
bobsta63 said on Apr 29, 2008 at 7:26 AM :
I too have exactly the same issue and its the same for all three of my PC's I am using Dreamweaver CS3 with ColdFusion 8.

I try to add a 'User login behavior' fil it all in properly but same as you guys/gals all I get is 'Login failed'. If I do the same Login Behaviour in PHP instead of Coldfusion it works fine.

The issue must be with the Code that Dreamweaver generates and places in the .cfm file.

If anyone has a solution please get back to me,

Thanks,
Bobby
Alejandro Mena said on Nov 29, 2008 at 7:01 AM :
You must enable sessions in the application.cfm file. For more information, follow this link

http://livedocs.adobe.com/coldfusion/6/Developing_ColdFusion_MX_Applications_with_CFML/sharedVars5.htm

I made the file Application.cfm and put it in my root folder. In this file I put this code.

<cfapplication name="GetLeadApp"
sessionmanagement="Yes"
sessiontimeout=#CreateTimeSpan(0,0,45,0)#>

After this, the log in user behavior worked fine.

 

RSS feed | Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/en_US/Dreamweaver/9.0/WScbb6b82af5544594822510a94ae8d65-7880.html