-
Creating Links to different Pictures
I am wondering if someone can please help me. I am trying to get each of the following pictures in my flash file to link to different webpages. I have tried a bunch of different things, and can't quite get it to work right. I have put different urls on the images, but when I click on them they all go to that first url. Can someone please help. I don't know if I have to write a if statement to accomplish this. Thanks in advance
Last edited by feeco; 01-07-2010 at 02:59 PM.
-
You can do this with code. You need to covet photos to movie clips and give each a unique instance name. They type the following code into the actions panel: (change blue type to your names/destination)
instanceName.addEventListener(MouseEvent.CLICK, functionName);
function functionName(event:MouseEvent):void{
var url:String = "web addy";
var request:URLRequest = new URLRequest(url);
flash.net.navigateToURL(request, "_blank");
}
This will open up the website in a new window. Note that each function name also has to be unique. like getURL; getURL1...
hope this helps!
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|