RE: [Flashcoders] Detecting embedded domain?

2007-03-13 Thread Dave Segal
Someone else on this list hooked me up with this a while back. It works as long as JavaScript is not restricted on the pages your swf is embedded on (see mySpace). var embedded_domain:String = flash.external.ExternalInterface.call("eval", "location.href"); -Original Message- From: [E

Re: [Flashcoders] Detecting embedded domain?

2007-03-13 Thread R�kos Attila
I think there is no reliable way for determining that. On client side it is not possible if embedding is not under your control (since some JS is needed for obtaining the HTML's URL). On server side you can check referer, but making fake headers is so simple :) Attila PB> Building a video play

RE: [Flashcoders] Detecting embedded domain?

2007-03-13 Thread Merrill, Jason
>>Does anyone know how to detect what the domain is for a page >>that the SWF is embedded on? Just use String functions to parse out what you need from this._url starting after http:// or whatever. Jason Merrill Bank of America Global Technology & Operations Learning & Leadership Development

Re: [Flashcoders] Detecting embedded domain?

2007-03-13 Thread Joshua Sera
var domain:String = _root.url.split("/")[2]; if (domain != "SI.com") { displayLogo(); } --- "Perdue, Blake" <[EMAIL PROTECTED]> wrote: > Building a video player that can be embedded in a > web page. We'd like to > be able to detect what domain the page the player is > embedded on lives. > If