If I'm not mistaken, CFLOCATION alters the http headers, which in turn
redirect the browser to the new page. Therefore, the Javascript on the
page containing the CFLOCATION will never be executed.
Have youe tried to do it purely by using javascript in the onLoad()
handler and doing: (in sequence) open the new window, redirect the browser
to the new page?
Jim
-----Original Message-----
From: Leong Yew <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED] <[EMAIL PROTECTED]>
Date: Saturday, June 17, 2000 2:11 AM
>Hi everyone,
>
>I'm wondering if anyone could help me out with a problem I'm having with
CFLOCATION. On one CF template I'm trying to do two things. The first is
to use javascript to open a new window. The second is to redirect the
parent window to a different (non CF) page using CFLOCATION.
>
>The problem is on that CF template I first use cfoutput to output the
javascript code and then use CFLOCATION. CF seems to ignore what's nested
in the cfoutput tag and it immediately redirects to the other page. The
reason why I'm using CFLOCATION rather than javascript is that the
redirect URL contains form elements and I don't want that to show on the
client's browser.
>
>Can anyone suggest an alternative to the following code?
>
>Thanks.
>
>Leong
>
>===here's the code===
><cfoutput><script>a.win=window.open("http://www.domain.com/a.cfm?username
=#form.username#);
></script></cfoutput>
>
><cflocation
url="http://www.anotherdomain.com/cgi-bin/b.pl?username=#form.username#">
>
>
>-------------------------------------------------------------------------
-----
>Archives: http://www.eGroups.com/list/cf-talk
>To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.