Sean,
sorry if my blathering wasa bit convoluted <grin> what I was trying to do
was work out how to replace this:
the fusebox way to make these logins work and "keep the user's focus" is to
cf_returnfuseaction to the login file. Once that's processed successfully,
the user is sent back to where they were going.
with my method:
display a different page to the login form, in a different frame to the one
the login form resides in
I do have it working now, but it required messing about with app_login and
adding javascript etc. I was trying to see if there was a more elegant way
to do it. It's probably just me but I somehow feel like reloading the
document.location of a page is kind scrappy...
Toby Tremayne
Code Poet and Zen Master of the Heavy Sleep
Show Ads Interactive
359 Plummer St
Port Melbourne
VIC 3207
P +61 3 9245 1247
F +61 3 9646 9814
ICQ UIN 13107913
-----Original Message-----
From: Sean Renet [mailto:[EMAIL PROTECTED]]
Sent: Thursday, 22 February 2001 9:35 PM
To: Fusebox
Subject: Re: logic question
Hmmm I am not quite sure I understand the question, but in most of my
display pages for logins and stuff I have an cfif statement around a row in
my table that is something like...
<cfif isdefined("client.error")>
<tr>
<td>
<font face="Arial" size="2" color="FFFF00"
class="bold"><cfoutput>#HTMLEditFormat(client.error)#</cfoutput></font>
<td>
<tr>
</cfif>
yer query page has some query named login and then the action page that
follows checks for failure. (I actually have a tag called
act_yougohungry.cfm that does the same thing that goes between the login
query and its display page.)
<cfif login.recordcount LTE >
<!--- if the login is not successful --->
<!--- set a client variable with the error --->
<cfset client.error = "You need to be logged in to access this area">
<!--- send them to the new user fuseaction --->
<cflocation url="index.cfm?fuseaction=newuser" addtoken="Yes">
(I wouldn't use returnfuseaction here as I am assuming you are sending
them to a page different from the login page.)
<cfabort>
<cfelse>
<!--- if the login is successful clear out the client variable called
error --->
<CFSET temp = DeleteClientVariable("error")>
</cfif>
If the login is successful, then you just go to your display page or
whatever would normally follow the query.
This of course would be easy to tagify, I am just not on my cfbox so its not
handy, but I think you get the idea.
Sean Renet
----- Original Message -----
From: "Toby Tremayne" <[EMAIL PROTECTED]>
To: "Fusebox" <[EMAIL PROTECTED]>
Sent: Wednesday, February 21, 2001 8:04 PM
Subject: logic question
> I've been playing with the fusebox security a bit and i'm wondering how
best
> to approach a particular setup I have here.
>
> In the normal course of things, you use app_Secure to verify the user is
> logged in. If they're not, they get sent using cf_returnfuseaction to the
> login form. herein lies my problem:
>
> my login form sits just at the top of the page in it's own frame. What I
> need to happen, is that if an area is secured, it should load the "create
a
> new user" page, with an extra message at the top saying "you need to be
> logged in to access this area" etc etc.
>
> using returnfuseaction this doesn't work obviously - and I was wondering
> what the best way to do this in a fusebox fashion would be - I still want
a
> user to be able to continue on to the place they were going, as they do
when
> you use return fuseaction, but I can't see how to make it work
>
> Toby
>
>
> Toby Tremayne
> Code Poet and Zen Master of the Heavy Sleep
> Show Ads Interactive
> 359 Plummer St
> Port Melbourne
> VIC 3207
> P +61 3 9245 1247
> F +61 3 9646 9814
> ICQ UIN 13107913
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists