<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
     xmlns:admin="http://webns.net/mvcb/"
     xmlns:content="http://purl.org/rss/1.0/modules/content/"
     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
	<channel> 

	<title>Comments on: Passing Variables to Flash with URLs</title>
	<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs/</link>
	<description>Comments on Ask MetaFilter post Passing Variables to Flash with URLs</description>
	<pubDate>Mon, 04 Dec 2006 17:11:26 -0800</pubDate>
	<lastBuildDate>Mon, 04 Dec 2006 17:11:26 -0800</lastBuildDate>
	<language>en-us</language>
	<docs>http://blogs.law.harvard.edu/tech/rss</docs>
	<ttl>60</ttl>

	<item>
		<title>Question: Passing Variables to Flash with URLs</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs</link>	
		<description>How can I change variables in a Flash movie based a URL parameter? &lt;br /&gt;&lt;br /&gt; I have some text in my Flash movie, and I want to change it based on a parameter in the URL. For example, if the URL ends with something like ?text=beer, I want the Flash movie to say &quot;beer.&quot;</description>
		<guid isPermaLink="false">post:ask.metafilter.com,2006:site.52398</guid>
		<pubDate>Mon, 04 Dec 2006 16:58:04 -0800</pubDate>
		<dc:creator>kirkaracha</dc:creator>
		
			<category>flash</category>
		
			<category>actionscript</category>
		
	</item> <item>
		<title>By: niles</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs#790993</link>	
		<description>&lt;a href=&quot;http://www.permadi.com/tutorial/flashQueryString/&quot;&gt;Passing Variables to Flash from HTML via Query String&lt;/a&gt;&lt;br&gt;
&lt;small&gt;&lt;a href=&quot;http://www.google.com/search?hl=en&amp;q=pass+variables+to+flash+url&amp;btnG=Google+Search&quot;&gt;Google Query&lt;/a&gt;: pass variables to flash url&lt;/small&gt;</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.52398-790993</guid>
		<pubDate>Mon, 04 Dec 2006 17:11:26 -0800</pubDate>
		<dc:creator>niles</dc:creator>
	</item><item>
		<title>By: grumblebee</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs#791052</link>	
		<description>url variables appear in the _root scope. So if you should just be able to write&lt;br&gt;
&lt;br&gt;
textfield.text = text;</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.52398-791052</guid>
		<pubDate>Mon, 04 Dec 2006 18:20:12 -0800</pubDate>
		<dc:creator>grumblebee</dc:creator>
	</item><item>
		<title>By: thinman</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs#791147</link>	
		<description>You probably just want to pass the query string to Flash using javascript, like &lt;a href=&quot;http://www.noscope.com/journal/2003/12/query_string&quot;&gt;this&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
You can tack the variables onto the &lt;code&gt;movie&lt;/code&gt; parameter as in the above example, or use another parameter called &lt;a href=&quot;http://www.adobe.com/cfusion/knowledgebase/index.cfm?id=tn_16417&quot;&gt;flashvars&lt;/a&gt;.&lt;br&gt;
&lt;br&gt;
&lt;b&gt;grumblebee&lt;/b&gt;, query string variables are only available to the _root of a movie if the swf is called directly. If it is in &lt;code&gt;object&lt;/code&gt; and &lt;code&gt;embed&lt;/code&gt; tags, as it usually will be, stuff from the url won&apos;t be available to it. Variables appended to the &lt;code&gt;movie&lt;/code&gt; parameter would be, but they&apos;d be static unless built using something like the javascript method above.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.52398-791147</guid>
		<pubDate>Mon, 04 Dec 2006 19:59:33 -0800</pubDate>
		<dc:creator>thinman</dc:creator>
	</item><item>
		<title>By: thinman</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs#791150</link>	
		<description>Or you could use &lt;a href=&quot;http://blog.deconcept.com/swfobject/&quot;&gt;SWFObject&lt;/a&gt;. I have. It works well. Wish I&apos;d remembered it before posting above.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.52398-791150</guid>
		<pubDate>Mon, 04 Dec 2006 20:03:59 -0800</pubDate>
		<dc:creator>thinman</dc:creator>
	</item><item>
		<title>By: grumblebee</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs#791187</link>	
		<description>You&apos;re right, thinman. I misunderstood the original post. I thought he meant vars appended to the end of the swf url.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.52398-791187</guid>
		<pubDate>Mon, 04 Dec 2006 21:01:20 -0800</pubDate>
		<dc:creator>grumblebee</dc:creator>
	</item><item>
		<title>By: malevolent</title>
		<link>http://ask.metafilter.com/52398/Passing-Variables-to-Flash-with-URLs#791263</link>	
		<description>Another recommendation for SWFObject, which makes detection, embedding and passing in variables nice and tidy.&lt;br&gt;
&lt;br&gt;
For displaying the text, you need to put a Dynamic Text field  into the movie, give it an Instance Name, and set it to embed any characters you might need to use (otherwise it won&apos;t know how much of your chosen font it&apos;ll need to retain). The variable you&apos;ve passed in will exist in the root of the movie, so if your text field is also in the root you&apos;ll just need to use&lt;br&gt;
&lt;em&gt;instanceName&lt;/em&gt;.text = &lt;em&gt;variableName&lt;/em&gt;;</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.52398-791263</guid>
		<pubDate>Mon, 04 Dec 2006 23:28:27 -0800</pubDate>
		<dc:creator>malevolent</dc:creator>
	</item>
	</channel>
</rss>
