Connecting Tech Pros Worldwide Help | Site Map

xml file - need url to open in new window when image clicked

Newbie
 
Join Date: Dec 2008
Posts: 1
#1: Dec 4 '08
Basically I just need the the link to open in a new browser window when the image is clicked.


This is the content of the xml file:
<!-- pages -->
<section name="pages">

<page name="home">
<image imageUrl="_pic4a.jpg" link="http://www.companyname.com"/>

This is the actionscript for that image and associated link in the Flash file:
onClipEvent (load) {
imageNumber=0;

imageProperties=_root.getCurrentImageName(imageNum ber);
loadMovie(_root.url+imageProperties['name'], this.cont.cont1);
url=imageProperties['linkToOpen'];
}
Moderator
 
Join Date: Mar 2006
Posts: 1,103
#2: Dec 4 '08

re: xml file - need url to open in new window when image clicked


Redirected to flash forum; hopefully someone has an answer there.
Markus's Avatar
Moderator
 
Join Date: Jun 2007
Location: York, England, with wolves.
Posts: 4,936
#3: Feb 15 '09

re: xml file - need url to open in new window when image clicked


Add an Event Handler for the image (movie clip or button), and then use getURL() to open the link.
Reply

Tags
actionscript, flash, links, xml


Similar Flash / Actionscript bytes