Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-13 Thread Pedder
Yeah, that worked. The embed code the user can copy from my page now directs to a server script "widget.swf" with some parameters. With a htaccess rewrite rule the call is redirected to a php script which stores the HTTP_REFERER and returns the "real" swf. In my first testings this worked fi

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-13 Thread Juan Pablo Califano
No problem. I'm glad you sorted it out. Cheers Juan Pablo Califano 2010/8/13 Pedder > Yeah, that worked. > The embed code the user can copy from my page now directs to a server > script "widget.swf" with some parameters. With a htaccess rewrite rule the > call is redirected to a php script whi

RE: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-13 Thread Cor
oders List Subject: Re: [Flashcoders] Getting the url where my Flash movie was embeded The following code requires AS3 script language // Create a regex that searches for a string like "... cannot access (...)". // The part in brackets will be captured

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Juan Pablo Califano
Maybe you could try a different approach. Although it's not 100% authoritative, the http referrer of the http request made to get your swf could help here. This is data sent by the client (the browser in this case), and might not even be sent to the server, but in almost every case, it is. So, yo

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Pedder
Shit, you're right! I realized that i was testing with the debug flash player. I forgot that. And now all i got is an error number and no error message again. Do you have any idea to get the url where my widget was embeded? Am 12.08.2010 um 17:57 schrieb Henrik Andersson: Pedder wrote: v

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Henrik Andersson
Pedder wrote: var search:RegExp = /.+cannot\saccess\s(.+)\./i ; That will not work for localized error messages in the localized versions of the player. I also have my doubts about it working in non debug players, I think the error message is the empty string in those. But I am not sure abo

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Pedder
m [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Pedder Sent: donderdag 12 augustus 2010 15:44 To: Flash Coders List Subject: Re: [Flashcoders] Getting the url where my Flash movie was embeded Hello Cor, this is the code is use and it is working fine for me. var location:String = "una

RE: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Cor
Original Message- > From: flashcoders-boun...@chattyfig.figleaf.com > [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of > allandt > bik-elliott (thefieldcomic.com) > Sent: donderdag 12 augustus 2010 14:09 > To: Flash Coders List > Subject: Re: [Flashcoders

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Pedder
om [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of allandt bik-elliott (thefieldcomic.com) Sent: donderdag 12 augustus 2010 14:09 To: Flash Coders List Subject: Re: [Flashcoders] Getting the url where my Flash movie was embeded good job mate :) On 12 August 2010 12:54, Pedder

RE: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Cor
bik-elliott (thefieldcomic.com) Sent: donderdag 12 augustus 2010 14:09 To: Flash Coders List Subject: Re: [Flashcoders] Getting the url where my Flash movie was embeded good job mate :) On 12 August 2010 12:54, Pedder wrote: > Ok, thank you for your answers. > > I tried this on a test s

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread allandt bik-elliott (thefieldcomic.com)
good job mate :) On 12 August 2010 12:54, Pedder wrote: > Ok, thank you for your answers. > > I tried this on a test system and it worked fine. Then i tried this on > facebook and got a "Security sandbox violation: external interface caller". > Well, the error message says something like "cannot

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Pedder
Ok, thank you for your answers. I tried this on a test system and it worked fine. Then i tried this on facebook and got a "Security sandbox violation: external interface caller". Well, the error message says something like "cannot access http://www.facebook.com ..." So, i now make the call w

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread allandt bik-elliott (thefieldcomic.com)
or you could do it all from within flash using var:urlPath:String = ExternalInterface.call(“window.location.href.toString”); On 12 August 2010 11:29, allandt bik-elliott (thefieldcomic.com) < alla...@gmail.com> wrote: > i think your best bet is to write a javascript function that returns > win

Re: [Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread allandt bik-elliott (thefieldcomic.com)
i think your best bet is to write a javascript function that returns window.location.href and then use the ExternalInterface class to call that function within the flash best a On 12 August 2010 10:51, Pedder wrote: > Hey all together, > > i was wondering if i can get the url where my flash mov

[Flashcoders] Getting the url where my Flash movie was embeded

2010-08-12 Thread Pedder
Hey all together, i was wondering if i can get the url where my flash movies are embeded. I have a little widget on my page to which i provide an embed code to my users so that they can embed my widget anywhere on the internet. But the problem is that i don't know where the widget is embe