Question

I created this banner with Flash and I need that on click it opens a web page.

I used this Actionscript 3.0 code...

link_btn.addEventListener(MouseEvent.CLICK, openurl);

function openurl(event:MouseEvent):void {
var url:URLRequest = new URLRequest("http://www.festivity.it");
navigateToURL(url, "_blank");
}

BUT it's not working!

WHYYYYY?!

I tried setting it on the timeline and also on a button, but nothing changed.

Whenever I click on the button... nothing happens, but sometimes a message opens with a security alert.

Thanks.

Chiara

Was it helpful?

Solution

Make sure your publish settings enable network access from "local playback security":

publish-settings

OTHER TIPS

I have spent hours and hours working with the action code snippets. My head was practically bleeding, trying to figure out why my simple Go-To-URL action script wasn't working. I've been using a much older version of Flash for ten years. The "local playback security" setting was the problem, and it was not mentioned in any of the Adobe forums that I visited. What a frustrating "feature".

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top