ColdFusion Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreColdFusion Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper “Build Web 2.0 Applications Without Hand-Coding” Download now!
  #1  
Old December 9th, 2004, 04:59 PM
dragonvn dragonvn is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 79 dragonvn User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 12 h 31 m 23 sec
Reputation Power: 4
Undefined variable

Dear,

I am a newbie. Yesterday, I tried to create a simple login script in file paschk file like this:

Quote:
<cfset SESSION.Auth = StructNew()>
<cfset SESSION.Auth.IsLoggedIn = "Yes">
<cfset SESSION.Auth.First_Name = find_user.First_Name>
<cfset SESSION.Auth.Last_Name = find_user.Last_Name>
<!--- Everything is ok. Send the user to menu template. --->
<cflocation url="menu.cfm">


And the script in file menu.cfm

Quote:
First Name: <cfoutput>#SESSION.Auth.First_Name#</cfoutput>
Last Name: <cfoutput>#SESSION.Auth.Last_Name#</cfoutput>


Everything seems be fine. However when click a submit login, I got this error:

Quote:
Variable SESSION is undefined.

The error occurred in C:\www\cms\admin\menu.cfm: line 12

11 : <!--- Display the users first name. --->
12 : First Name: <cfoutput>#SESSION.Auth.First_Name#</cfoutput>


Please give me some ideas. Thank in advance!

Reply With Quote
  #2  
Old December 9th, 2004, 05:08 PM
FALCONSEYE FALCONSEYE is offline
Permanently Banned
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2004
Posts: 377 FALCONSEYE Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 1 Day 16 h 57 m 14 sec
Warnings Level: 15
Number of bans: 1
Reputation Power: 0
could you please create a file called application.cfm

then put this code

<Cfapplication name="something" sessionmanagement="yes">

Reply With Quote
  #3  
Old December 9th, 2004, 05:23 PM
dragonvn dragonvn is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Posts: 79 dragonvn User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 12 h 31 m 23 sec
Reputation Power: 4
Thanks, I got it

Reply With Quote
  #4  
Old December 9th, 2004, 06:09 PM
kiteless kiteless is offline
Moderator
Dev Shed Expert (3500 - 3999 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 3,627 kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 10 h 8 m 55 sec
Reputation Power: 53
It goes into the root directory of your application.
__________________
Ask if you have a question, but also help answer questions that you have knowledge of! Thanks, Brian.
How to Post a Question in the Forums

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreColdFusion Development > Undefined variable


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway