I have a flash movie that uses MySql variables that get set in getpage.php. This php file simply queries the database and returns things like text color, the banner text, etc. all of this works fine, but I cannot seem to figure out how to pass in the page id number to the getpage.php that flash calls through myData.load("flash/getpage.php)" - currently I am not sending the id to getpage.php so I am getting my default id=1 so the query always gets record 1.
Basically I need to know how to send the page id# from webpage.html to flash and then in flash send it in the myData.load call (i guess) to getpage.php so that it knows the page number from the web site that is being loaded.
I can call the flash and send the id# by using the following, just don't know what to do once it is there? Thanks in Advance.
Web Page Code (just cut out part in flash object where it is called once)
<embed src="flash/banner.swf?id=<?=$id?>" quality="high" wmode="transparent" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="875" height="100"></embed>
My ActionScript:
function textLoader() {
myData = new LoadVars()
myData.ref = this
myData.onload = function(succes){
if(succes){
Title_txt.html = true;
Title_txt.htmlText = this.Title;
Title2_txt.html = true;
Title2_txt.htmlText = this.Title2;
comment_txt.html = true;
comment_txt.htmlText = this.Comments;
comment2_txt.html = true;
comment2_txt.htmlText = this.Comments2;
holder_mc.loadMovie(this.Image);
holder_mc2.loadMovie(this.Image1);
} else trace("Error loading data")
}
myData.load("flash/getpage.php")
}
inner_txt.text = passed;
var myCSS = new TextField.StyleSheet();
myCSS.load("flash/myStyle.php");
myCSS.onload = function() {
Title_txt.styleSheet = myCSS;
Title2_txt.styleSheet = myCSS;
comment_txt.styleSheet = myCSS;
comment2_txt.styleSheet = myCSS;
textLoader();
};
stop();

New Topic/Question
Reply



MultiQuote




|