Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Trying to get window.opener in CF

Status
Not open for further replies.

LarrySteele

Programmer
May 18, 2004
318
US
I want to get the window.opener while processing CF - not after the page loads. Hence, not JavaScript because intent is to use the value in a cfif block.

I've Googled, asked, and read. So far no joy. Hoping someone knows way to pull information for a cfif block.

TIA,
Larry
 
Usually I try simple tests before I post, but not this time...

Code:
<cfif 1 eq 1>
    <script type="text/javascript">
        alert('hello');
    </script>
</cfif>

I don't know if I needed to wrap the JavaScript with cfif tags, but figured wrapping the script in some cf tag my force server side to process client side (or so I hoped).

Turns out it's a moot issue. The desired opener is from a different domain and JavaScript is not allowed access to the window.opener from a different domain. Makes sense when I read that considering what I can do with window.opener.document!

Larry
 
Code:
avaScript is not allowed access to the window.opener from a different domain.

Even if it were not, CF runs on the server and javascript on the client, and 'never the twain shall meet' ;-)

----------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top