Russell,
cf_returnfuseaction is used when you want to call a fusebox from anywhere
and have it return to the place you called it from, ie. say you have many
curcuit applications that are secure, and a fuseaction is called you check
to see if the user is logged in, if not you send them to the login curcuit
application and then want to be return back to the fuseaction they once
called. You do this in cf_returnfuseaction like so.
<cf_returnfuseaction
action="set"
gotourl="URL of the curcuit app for desire to send the user to"
returnurl="URL of the curcuit app you desire the user to return to">
The action SET is used when SETTING the url to send the user to, and the url
to return the user to. This action will work like cflocation when it is
called. To return the user whence they came you simply use the tag with the
RETURN action.
<cf_returnfuseaction
action="return">
cf_returnfuseaction will then send the user back to the url originally set
in the RETURNURL attribute. This tag uses client variables so you will need
to make sure you have clientmanagement turned on. Below is one way I used
it in a current application. This goes to the login application which after
the user is logged in sends them back using action="return".
Craig Girard
<cfcase value="searchForm">
<cfmodule template="dsp_searchForm.cfm">
</cfcase>
<cfcase value="search">
<cfmodule template="dsp_searchForm.cfm">
<cfmodule template="/objects/productSearch/index.cfm"
fuseaction="search"
keyword="#attributes.keyword#" recordID="#attributes.recordID#">
</cfcase>
<cfcase value="details">
<cfmodule template="/objects/productSearch/index.cfm"
fuseaction="details" productID="#attributes.productID#">
</cfcase>
<cfcase value="createCollection">
<cfmodule template="/objects/productSearch/index.cfm"
fuseaction="createCollection" companyID="#attributes.companyID#">
</cfcase>
<cfcase value="deleteCollection">
<cfmodule template="/objects/productSearch/index.cfm"
fuseaction="deleteCollection" companyID="#attributes.companyID#">
</cfcase>
<cfcase value="login">
<cfif IsDefined("attributes.projectID")>
<cf_returnfuseaction
action="set"
gotourl="http://#cgi.http_host#/members/index.cfm?fuseaction=login"
returnurl="http://#cgi.http_host#/#cgi.script_name#?fuseaction=addtoproject&
productID=#attributes.productID#&projectID=#attributes.projectID#">
<cfelse>
<cf_returnfuseaction
action="set"
gotourl="http://#cgi.http_host#/members/index.cfm?fuseaction=login"
returnurl="http://#cgi.http_host#/#cgi.script_name#?fuseaction=addtoproject&
productID=#attributes.productID#">
</cfif>
</cfcase>
</cfswitch>
-----Original Message-----
From: Russell Jones [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 14, 2000 2:54 PM
To: [EMAIL PROTECTED]
Subject: fusebox : returnfuseaction ???
The following is contained in the index.cfm file of the "members" directory
in fusebox.org's source code.
perhaps someone could explain:
1. where is the fuseaction "goto" referenced elsewhere?
2. what purpose/function does "request.listofattributes" serve?
3. when does one use returnfuseaction's "set" or "return" command?
I would be greatly in your debt. Thanks so much.
<cfcase value="goto">
<cf_returnfuseaction
action="set"
returnurl="#cgi.http_referer#"
gotourl="index.cfm?fuseaction=#attributes.gotofuseaction#">
</cfcase>
<cfcase value="saveuser">
<cfinclude template="act_saveuser.cfm">
<cfset request.listofattributes="rememberme=#rememberme#">
<cf_returnfuseaction
action="return"
defaulturl="#request.webroot#/index.cfm?rememberme=#rememberme#">
</cfcase>
<cfcase value="login">
<cfinclude template="act_login.cfm">
<cfset request.listofattributes="rememberme=#rememberme#">
<cf_returnfuseaction
action="return"
defaulturl="#request.webroot#/index.cfm?rememberme=#rememberme#">
</cfcase>
-Russ
--
Russell Jones
Webmaster
ImproveNow.com
Phone: 207.236.0146
e-mail: [EMAIL PROTECTED]
----------------------------------------------------------------------------
--
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/fusebox or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
------------------------------------------------------------------------------
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/fusebox or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.