# LostInBeta, or Senocular need some help

**URL:** <https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859>\
**Category:** flash\
**Created:** [May 14, 2003, 4:35am UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859 "2003-05-14T04:35:24Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![titter](https://avatars.discourse-cdn.com/v4/letter/t/f0a364/32.png) [@titter](https://forum.kirupa.com/u/titter)\
**Post date:** [May 14, 2003, 4:35am UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/1 "2003-05-14T04:35:24Z")

</div>

Ok, I am using your submenu system that has your names in the as code, so I fig ure i shoulda ask you. I implmented the menu on a new site I am designing, the only problem is the URL will not work, and how would I make them load into a iframe? The iframe name is set to main.

In the XML file would I do:

\<ITEM NAME=“Leagues”\>  
\<SUBITEM NAME=“CAL-IM” URL=“link.html” TARGET=“main” /\>  
\</ITEM\>

Any help from any1 would be great right now. To see the culprut that I am talking about check, [www.evilattitude.com/vexed](http://www.evilattitude.com/vexed) and you will see the menu. Thxs.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 4:55am UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/2 "2003-05-14T04:55:12Z")

</div>

lol great song!

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 6:34am UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/3 "2003-05-14T06:34:14Z")

</div>

There are two instance of this line in the script…

[AS]myButton.onRelease = function() {  
// getURL(this.myUrl);  
trace(this.buttonLabel.text+" : "+this.myURL);  
};[/AS]

The getURL was commented out (via //) for testing purposes. You can instead uncomment the getURL and write it like this…  
[AS]getURL(this.myUrl, “iframeName”);[/AS]  
Where iframeName is of course the name of your iframe.

Be sure to update both instances of the code in the script.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 12:45pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/4 "2003-05-14T12:45:03Z")

</div>

thanks beta, I was a lil tired when I was looking at the code. One more, now that the iframe works, there are about 2-3 links I need to load in a \_blank window. I kno I am being a pain in the arse, but this would be done, beats me.

Also maybe you could anwser my other post on the board about a menu question for the music.

[http://www.kirupaforum.com/forums/showthread.php?s=&threadid=23243](http://www.kirupaforum.com/forums/showthread.php?s=&threadid=23243)

Thanks again.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 5:29pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/5 "2003-05-14T17:29:41Z")

</div>

I didn’t test it but try this…

There are two instances of this line in the script (both are slighly different due to being button and submenu button, but you get the point)…  
[AS]myButton.myUrl = this.menuItem\*.attributes.URL;[/AS]

What you need to do is right under that line add this line…  
[AS]myButton.myTarget = this.menuItem\*.attributes.TARGET;[/AS]

So for the main buttons you will have…  
[AS]myButton.myUrl = menuItem\*.attributes.URL;  
myButton.myTarget = menuItem\*.attributes.TARGET;[/AS]

And for the subMenu buttons you will have  
[AS]mySubButton.myUrl = this.subMenuItem[j].attributes.URL;  
mySubButton.myTarget = this.subMenuItem[j].attributes.TARGET;[/AS]

Now remember those getURLS? Change them to look like this…  
[AS]getURL(this.myUrl, this.myTarget);[/AS]

Alright so we got the AS fixed. Now lets edit the XML file to incorporate this. You had it right the first time you posted the XML code (although you didn’t use the PHP vbCode tags so it didn’t show)

Just edit your XML tags to have a TARGET attribute…

```php
<ITEM NAME="Leagues">
<SUBITEM NAME="CAL-IM" URL="link.html" TARGET="main" />
</ITEM>

```

Then you change the target to \_blank to open in a new window.

Note: I did NOT test this, so I don’t know if it will work, but I think it will.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 5:31pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/6 "2003-05-14T17:31:25Z")

</div>

wow, we must think alike right b4 I check this I was adding target to the as code…weird?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 5:40pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/7 "2003-05-14T17:40:54Z")

</div>

Ok for the main buttons is it?

[AS]   
myButton.myUrl = this.menuItem\*.attributes.URL;  
myButton.myTarget = this.menuItem\*.attributes.TARGET;[/AS]

or

[AS]   
myButton.myUrl = menuItem\*.attributes.URL;  
myButton.myTarget = menuItem\*.attributes.TARGET;[/AS]

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 5:43pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/8 "2003-05-14T17:43:11Z")

</div>

Oh…lol. Sorry. It will work either way, but for good coding practice (which I apparently did not use) you should use this.menuItem\* 😉

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 5:48pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/9 "2003-05-14T17:48:12Z")

</div>

thanks, lol ya I was like hmmmmm

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 6:01pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/10 "2003-05-14T18:01:59Z")

</div>

[www.evilattitude.com/vexed](http://www.evilattitude.com/vexed)

Under the leagues submenu, it loads in a seperate window. Thanks again.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [May 14, 2003, 6:05pm UTC](https://forum.kirupa.com/t/lostinbeta-or-senocular-need-some-help/20859/11 "2003-05-14T18:05:17Z")

</div>

Cool, glad to see it worked.
