• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Passing a session variable to the next Application.cfm

LEGEND ,
Jan 12, 2007 Jan 12, 2007

Copy link to clipboard

Copied

I have installed CanvasWiki on our law school web site. In the main login
section of our site, it's creates a session that holds the student's id
which is used to authorize users for different sections.When I try to move
to the Wiki, it forgets the Session varible (doesn't pass it).
How can I maintain it to the next application.cfm / section?

Login page:
<cfquery name="info" datasource="***">
select people_code_id
from users
where Username = '#getAuthUser()#'
</cfquery>
<cfset SESSION.Authorization.pfcode = people_code_id>

CanvasWiki application.cfm
<cfsilent><cfapplication name="CanvasWiki" sessionmanagement="true"
loginstorage="session" sessiontimeout="#createtimespan(0,1,0,0)#"/>
<cfsetting showdebugoutput="false"></cfsilent>

Any ideas?


TOPICS
Advanced techniques

Views

273

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jan 12, 2007 Jan 12, 2007

Copy link to clipboard

Copied

LATEST
ColdFusion searches up the tree for the Application.cfm

You may not need the Application.cfm in a sub tree. If there is application related code that must be executed in a subtree, include the previous application.cfm page and then add any specific subtree application.cfm code

Application.cfm
<~--- application tag and auth/login code here --->

subtree/Application.cfm
<cfinclude template="../Application.cfm">
<!--- additional application code --->
<cfif GetAuthUser() eq "" or Not IsUserInRole("Admin")>
<cfoutput>Access Denied</cfoutput>
<cfabort>
</cfif>

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation