Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Defining Link Target

Status
Not open for further replies.

RandyKr

Programmer
Oct 24, 2007
3
US
I have an image slideshow in Flash hooked up to the xml file below. Each image in the show is hyperlinked via the xml. But the links always open in a new window when clicked. How can I make them open in the same window as the show? (target="_top")

----------------------------------------------------------
<?xml version="1.0"?>
<RSS PAUSE="4000">
<IMAGE TRANSITION="1" TITLE="Fox News Home" LINK = " <IMAGE TRANSITION="2" TITLE="Google News Home" LINK = " <IMAGE TRANSITION="3" TITLE="CNN News Home" LINK = "</RSS>
----------------------------------------------------------
 
>How can I make them open in the same window as the show? (target="_top")
Do you mean how to add an attribute, whatever it is, to it by script? or are you asking what attribute should be added?
 
I guess I am asking what attribute should be added, and how to add it properly. I tried defining an attribute in Flash called "TARGET" and then calling it in the XML like the others (TARGET = "_top"). But that had no effect.
 
On that particular point, I happen to know something. I know there is some wrong statements out there on target set to "_top" or "_parent" or "_blank" or "_self" etc. But I think at least to the present state-of-the-art, it is not quite right and it is hard pressed to say it is not supported _yet_.

The proper attribute to make it work is linktarget.
[tt] linktarget="_top"[/tt]
or
[tt] linktarget="_self"[/tt]
 
tsuji, thank you so much for responding. Would you be able to give me an example of the syntax? I just tried implimenting this in Flash and in my xml file (see below) and it still does not seem to have any effect on the target.

-----------------------------------------------------------
<?xml version="1.0"?>
<RSS PAUSE="4000">
<IMAGE TRANSITION="1" TITLE="test copy" LINK = " LINKTARGET = "_top">homeimg/homepic01.jpg</IMAGE>
<IMAGE TRANSITION="2" TITLE="test copy" LINK = " LINKTARGET = "_top">homeimg/homepic02.jpg</IMAGE>
<IMAGE TRANSITION="3" TITLE="test copy" LINK = " LINKTARGET = "_top">homeimg/homepic03.jpg</IMAGE>
</RSS>
-----------------------------------------------------------

smiley_alien.gif
 
I use a reference free slideshow app
You can edit the xml to include the linktarget and observe the effect. It also has target attribute in their image tags which does not behave. If you change it to linktarget, it would perform. But, in general, for any other flash applications, I cannot be sure.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top