What is the best way of creating variable session scopes called from a global vars page without CF chucking errors..
global vars page <cfscript> request.sessionVar = "mySite"; // This changes across the mini sites request.dbsitePrefix = "test"; </cfscript> Application.cfm Page - and yes sessionmanagement is on <cfif Not IsDefined("SESSION[request.sessionVar]")> <cfscript> SESSION[request.sessionVar] = StructNew(); SESSION[request.sessionVar].USERNAME = ""; SESSION[request.sessionVar].OBJECTID = ""; SESSION[request.sessionVar].USER_LOGGEDIN = "false"; SESSION[request.sessionVar].Agree = "False"; </cfscript> </cfif> <cfif NOT SESSION[request.sessionVar].USER_LOGGEDIN> <cflocation addtoken="no" url="signin.cfm"> </cfif> The error I get is Element USER_LOGGEDIN is undefined in a CFML structure referenced as part of an expression, plus other pages throughout the site which have other similar things Test.cfm <cfif NOT SESSION[request.sessionVar].Agree> <cflocation addtoken="no" url="index.cfm"> </cfif> Thanks Carl ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Purchase from House of Fusion, a Macromedia Authorized Affiliate and support the CF community. http://www.houseoffusion.com/banners/view.cfm?bannerid=34 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:182791 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54