
December 9th, 2004, 04:59 PM
|
|
Contributing User
|
|
Join Date: Oct 2004
Posts: 79
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!
|