<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.3.3" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: ActionScript 3 Tutorial - What Happened to getURL?</title>
	<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/</link>
	<description>Craig Campbell's Flash tutorials, insights, rantings, and general blather.</description>
	<pubDate>Thu, 21 Aug 2008 19:26:23 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.3</generator>
		<item>
		<title>By: jean roman</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-720</link>
		<dc:creator>jean roman</dc:creator>
		<pubDate>Tue, 12 Aug 2008 01:18:43 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-720</guid>
		<description>ps...
also wondering why the code you provided (reverse on placement of the "addEventListner") did not work unless placed after the FUNCTION }

FYI:  my System:  OS X 10.5.4 using CS3 Prod. Suite / FLASH AS3

any thoughts on that frustrating oddity?  I mean for heavens sake I tried it every which way, until I found the above reverse code (note: as you say the function can be named anything... in this case "getLink" was the given name to the code I found that worked)

meanwhile... and still working on multiple CLICKS same code on different buttons / instance names... any help will be appreciated to make this deadline &#62;.&#124;</description>
		<content:encoded><![CDATA[<p>ps&#8230;<br />
also wondering why the code you provided (reverse on placement of the &#8220;addEventListner&#8221;) did not work unless placed after the FUNCTION }</p>
<p>FYI:  my System:  OS X 10.5.4 using CS3 Prod. Suite / FLASH AS3</p>
<p>any thoughts on that frustrating oddity?  I mean for heavens sake I tried it every which way, until I found the above reverse code (note: as you say the function can be named anything&#8230; in this case &#8220;getLink&#8221; was the given name to the code I found that worked)</p>
<p>meanwhile&#8230; and still working on multiple CLICKS same code on different buttons / instance names&#8230; any help will be appreciated to make this deadline &gt;.|</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jean roman</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-719</link>
		<dc:creator>jean roman</dc:creator>
		<pubDate>Tue, 12 Aug 2008 00:28:18 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-719</guid>
		<description>Found a CODE that works great (but only for one btn)
(http://www.mandalatv.net/fcny/)  

however, just major problem: following code only allows one click.  
Question:  How would you REcode this to make it work 
for multiple (x4)  Buttons in same scene / page


function getLink(event:MouseEvent):void{
	var request:URLRequest = new URLRequest("http://www.happyCODE");
	navigateToURL(request, "");
}
Button1.addEventListener(MouseEvent.CLICK, getLink);</description>
		<content:encoded><![CDATA[<p>Found a CODE that works great (but only for one btn)<br />
(http://www.mandalatv.net/fcny/)  </p>
<p>however, just major problem: following code only allows one click.<br />
Question:  How would you REcode this to make it work<br />
for multiple (x4)  Buttons in same scene / page</p>
<p>function getLink(event:MouseEvent):void{<br />
	var request:URLRequest = new URLRequest(&#8221;http://www.happyCODE&#8221;);<br />
	navigateToURL(request, &#8220;&#8221;);<br />
}<br />
Button1.addEventListener(MouseEvent.CLICK, getLink);</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jean roman</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-712</link>
		<dc:creator>jean roman</dc:creator>
		<pubDate>Mon, 11 Aug 2008 05:22:41 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-712</guid>
		<description>Craig,
if you want to use CS3/AS3 to update your site. it's all very frustrating ~ and means recoding entire site ~ MAKES no sense and a BIG waste of precious time to redo older work.

I have tried all of the above to no avail ~ just won't work??

1) if you have a main stage timeline and on that a MC with a Button inside that on another timeline WHERE do you put the code?

2) do you have to instance name the MC or the BTN inside the MC
I just don't get it

it used to be so easy just to put the code on the BTN (which was inside a MC on the main stage)

i.e. please help translate this: code which used to be on BTN (which was inside a MC)

on (release) {
	getURL('http://www.VERY_FRUSTRATED_with_ADOBE_ASS3");
}

will appreciate all your help... I'm in a bind to get this done

jean roman</description>
		<content:encoded><![CDATA[<p>Craig,<br />
if you want to use CS3/AS3 to update your site. it&#8217;s all very frustrating ~ and means recoding entire site ~ MAKES no sense and a BIG waste of precious time to redo older work.</p>
<p>I have tried all of the above to no avail ~ just won&#8217;t work??</p>
<p>1) if you have a main stage timeline and on that a MC with a Button inside that on another timeline WHERE do you put the code?</p>
<p>2) do you have to instance name the MC or the BTN inside the MC<br />
I just don&#8217;t get it</p>
<p>it used to be so easy just to put the code on the BTN (which was inside a MC on the main stage)</p>
<p>i.e. please help translate this: code which used to be on BTN (which was inside a MC)</p>
<p>on (release) {<br />
	getURL(&#8217;http://www.VERY_FRUSTRATED_with_ADOBE_ASS3&#8243;);<br />
}</p>
<p>will appreciate all your help&#8230; I&#8217;m in a bind to get this done</p>
<p>jean roman</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: martart</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-710</link>
		<dc:creator>martart</dc:creator>
		<pubDate>Mon, 11 Aug 2008 01:15:50 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-710</guid>
		<description>Thanks Craig, worked for me.
I agree... what used to be so easy is now so much harder.
What some people might be missing from this tutorial and why it is not working for them is that you MUST name your button 'myButton' in the properties inspector for the above code to work. 
You can name the button anything you like as long as it's the same name in the first line of code. Also, make sure you convert the code to Plain Text if copying and pasting the code.</description>
		<content:encoded><![CDATA[<p>Thanks Craig, worked for me.<br />
I agree&#8230; what used to be so easy is now so much harder.<br />
What some people might be missing from this tutorial and why it is not working for them is that you MUST name your button &#8216;myButton&#8217; in the properties inspector for the above code to work.<br />
You can name the button anything you like as long as it&#8217;s the same name in the first line of code. Also, make sure you convert the code to Plain Text if copying and pasting the code.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: bill-hawaii</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-705</link>
		<dc:creator>bill-hawaii</dc:creator>
		<pubDate>Sat, 09 Aug 2008 19:06:43 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-705</guid>
		<description>Try not using the word - request - for your var name

the word 'request' turns blue in my ActionScript panel - This means 'request' is part of Flash's pre-defined vocabulary.

try replace 'request' with a descriptive name like 'whatWebPage'</description>
		<content:encoded><![CDATA[<p>Try not using the word - request - for your var name</p>
<p>the word &#8216;request&#8217; turns blue in my ActionScript panel - This means &#8216;request&#8217; is part of Flash&#8217;s pre-defined vocabulary.</p>
<p>try replace &#8216;request&#8217; with a descriptive name like &#8216;whatWebPage&#8217;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lee</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-702</link>
		<dc:creator>Lee</dc:creator>
		<pubDate>Fri, 08 Aug 2008 19:55:20 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-702</guid>
		<description>security warning is on local, you have to give permission for the .swf for local access to domains outside of your system... upload ftp to your server hosting directory and you shouldn' thave problems.

someone had issues with (henny?) errors, turns out some quotes are forward double quotes or two single quotes used as a double quote and Flash isn't reading the quote tags in the function calls correctly.
so use:
 URLRequest("http://www.google.com");
not
 URLRequest(''http://www.google.com'');
not
 URLRequest(”http://www.google.com”);

the ascii code for "  is different then ”

not sure if this text box will convert the text for me...</description>
		<content:encoded><![CDATA[<p>security warning is on local, you have to give permission for the .swf for local access to domains outside of your system&#8230; upload ftp to your server hosting directory and you shouldn&#8217; thave problems.</p>
<p>someone had issues with (henny?) errors, turns out some quotes are forward double quotes or two single quotes used as a double quote and Flash isn&#8217;t reading the quote tags in the function calls correctly.<br />
so use:<br />
 URLRequest(&#8221;http://www.google.com&#8221;);<br />
not<br />
 URLRequest(&#8221;http://www.google.com&#8221;);<br />
not<br />
 URLRequest(”http://www.google.com”);</p>
<p>the ascii code for &#8221;  is different then ”</p>
<p>not sure if this text box will convert the text for me&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: radikian</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-672</link>
		<dc:creator>radikian</dc:creator>
		<pubDate>Tue, 29 Jul 2008 16:09:24 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-672</guid>
		<description>You're simply the best!! thanks a lot!</description>
		<content:encoded><![CDATA[<p>You&#8217;re simply the best!! thanks a lot!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Henning</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-670</link>
		<dc:creator>Henning</dc:creator>
		<pubDate>Mon, 28 Jul 2008 09:15:49 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-670</guid>
		<description>why do i get an error message?

button.addEventListener(MouseEvent.CLICK, onMouseClick)

function onMouseClick(e:MouseEvent):void
{
	var request:URLRequest = new URLRequest("http://www.fedhealth.co.za");
	navigateToURL(request,"_blank");
}</description>
		<content:encoded><![CDATA[<p>why do i get an error message?</p>
<p>button.addEventListener(MouseEvent.CLICK, onMouseClick)</p>
<p>function onMouseClick(e:MouseEvent):void<br />
{<br />
	var request:URLRequest = new URLRequest(&#8221;http://www.fedhealth.co.za&#8221;);<br />
	navigateToURL(request,&#8221;_blank&#8221;);<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Anne Marie</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-656</link>
		<dc:creator>Anne Marie</dc:creator>
		<pubDate>Tue, 22 Jul 2008 07:02:34 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-656</guid>
		<description>There was an earlier post that pretty well framed my question - What if you just want it to go to a url when the movie is over?  I don't need a button, just want to have the user brought over to a new web page once the flash movie has finished.  I'm very new to Flash and would appreciate any help on this. How is that done?</description>
		<content:encoded><![CDATA[<p>There was an earlier post that pretty well framed my question - What if you just want it to go to a url when the movie is over?  I don&#8217;t need a button, just want to have the user brought over to a new web page once the flash movie has finished.  I&#8217;m very new to Flash and would appreciate any help on this. How is that done?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Craig</title>
		<link>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-649</link>
		<dc:creator>Craig</dc:creator>
		<pubDate>Sat, 19 Jul 2008 12:24:21 +0000</pubDate>
		<guid>http://schoolofflash.com/2008/04/17/actionscript-3-tutorial-what-happened-to-geturl/#comment-649</guid>
		<description>Sneed: The actions need to be placed in the timeline where the button is placed, not in the button's timeline. For example, if you placed your button on the main stage, you need give your button an instance name, then create a new layer on the main stage's timeline for your ActionScript. If your button is in frame 1 of the main timeline, then you don't need to add an extra keyframe, because there's already a keyframe in frame 1 when you create the layer.

Hope this helps!

Craig</description>
		<content:encoded><![CDATA[<p>Sneed: The actions need to be placed in the timeline where the button is placed, not in the button&#8217;s timeline. For example, if you placed your button on the main stage, you need give your button an instance name, then create a new layer on the main stage&#8217;s timeline for your ActionScript. If your button is in frame 1 of the main timeline, then you don&#8217;t need to add an extra keyframe, because there&#8217;s already a keyframe in frame 1 when you create the layer.</p>
<p>Hope this helps!</p>
<p>Craig</p>
]]></content:encoded>
	</item>
</channel>
</rss>
