Re: Passing var to Flash
| From: | Miles Thompson | Date: | Mon, 28 Apr 2003 02:09:29 +0000 |
| Subject: | Re: Passing var to Flash | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-145462@lists.php.net to get a copy of this message | ||
Daniel,
Thanks for your response and suggestion.
I've tried adding both _level0. and _root. to the variable name, neither made any difference.
I've also tried declaring dtDate in the functions frame of the movie and in the read frame, and not declaring it at all. No difference.
I've had a dynamic text box in the movie to receive the date since the beginning, and except when I run it on the local LAN, it never gets the date passed to it.
Do you know of a particular setting in PHP or Apache which might affect this?
This is most frustrating, an steer in almost any direction will be welcome.
Regards - Miles Thompson
At 09:33 AM 4/24/2003 -0700, Daniel Guerrier wrote:
The variable passed from the php script <embed src="AllNS_preview.swf?dtDate=2003-04-23" will be available in _level0 or _root in the flash movie. So xmlReceiver.load( "http://" + host + > "feed_xml_story.php?dtDate=" + dtDate); should be xmlReceiver.load( "http://" + host + "feed_xml_story.php?dtDate=" + _root.dtDate); try that and see how it goes. You could create a dynamic text field in flash and set the value to _root.dtDate to verify that you are getting the value. --- Miles Thompson <milesthompson@ns.sympatico.ca> wrote: I'm using a Flash movie which will publish daily sets of news stories. Writers of course need to preview their work, so they can see how it will look in the movie. That's where I'm encountering trouble, with the preview.php and preview.swf. The movie works fine on my test server, but not on the production machine. It is as if the movie did not receive or accept the date variable passed to it. Preview.php is called as follows, with the usual submit button. <form method="post" target= "_blank" action="preview.php?dtDate=<?php echo $dtLvTo?>"> Preview.php calls the preview.swf with this line, between <OBJECT> tags ... <EMBED src="AllNS_preview.swf?dtDate=<?echo $dtDate?>" quality=high bgcolor=#FFFFFF WIDTH="490" HEIGHT="362" NAME="AllNS_preview" ALIGN="" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED> Which renders to the following HTML: <embed src="AllNS_preview.swf?dtDate=2003-04-23" qual <rest snipped> Echoing dtDate within preview.php shows that it is passed correctly, as does the above fragment. What I get is the movie, with no content. Within the movie, content is called for with this line ... xmlReceiver.load( "http://" + host + "feed_xml_story.php?dtDate=" + dtDate); (host is defined in an included .as file) Yes, I have tested the above, stand-alone, in the browser and it creates an xml file used by the movie. Does anyone have any suggestions? I've tried surrounding the date with single quotes and it made no difference. The problem appears to be with the Flash movie getting the date. Help & SWAG's will be appreciated - Miles Thompson -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php __________________________________________________ Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo http://search.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php