Smart questions
Smart answers
Smart people
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Member Login

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips now!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

Join Tek-Tips
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

LINK TO THIS FORUM!

Add Stickiness To Your Site By Linking To This Professionally Managed Technical Forum.
Just copy and paste the
code below into your site.

Partner With Us!

"Best Of Breed" Forums Add Stickiness To Your Site
Partner Button
(Download This Button Today!)

Feedback

"...I just wanted to say how much I have enjoyed these forums. I am a new user and have a lot of elementary questions. I get quick answers with a friendly attitude..."

Geography

Where in the world do Tek-Tips members come from?
metaphiz (Programmer)
30 Dec 11 11:20
I've got a basic CFLOGIN framework going to secure an application.  Everything is working fine, except after they log in I need to query a database for to pull info for each user.  I used to use session variables, set in the login script, to do this.  

I'd like to user cflogin.name and cflogin.password to identify the correct DB record.  But the Adobe documentation says "You can use these values in the cflogin tag body to authenticate the user, and, in the cfloginuser tag, to log the user in. The structure is only available in the cflogin tag body."

This seems like it defeats the point of using CFLOGIN, since the code between <cflogin> and </cflogin> only executes when a user IS NOT logged in. Does this mean that upon entering the correct user/pass, I have to also  set a session variable to identify the user outside of the CFLOGIN tag?  It seems redundant...

Anyone have an explanation/solution?  Below is my query and error.

THANKS!

    <cfquery datasource="DS" name="QName" username="username" password="password">
      SELECT *
      FROM table
      WHERE username = #cflogin.name#
    </CFQUERY>

Error:  Element NAME is undefined in CFLOGIN.
FALCONSEYE (Programmer)
8 Feb 12 10:32
Yes, please use session vars to store logged in user info.

ColdFusion Ninja for hire.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close