Jump to content

carl_laruso

New Members
  • Posts

    7
  • Joined

  • Last visited

    Never

Everything posted by carl_laruso

  1. is there any more information i could give you guys to help out? C.
  2. ok i tried Joshua4550's insert statement but the flash game is still reporting "undefined" the PHP now looks like this: <? $mysqlhost = "**********"; $mysqluser = "**********"; $mysqlpass = "**********"; $mysqldatabase = "**********"; mysql_pconnect($mysqlhost, $mysqluser, $mysqlpass); mysql_select_db($mysqldatabase); $name = strip_tags($_REQUEST["var1"]); $score = strip_tags($_REQUEST["var2"]); $query = "INSERT INTO `scores_ast` (`score`, `name`) VALUES ('$name','$score')"; mysql_query($query); ?> DOH!!! also FYI i am copying and pasting the DB name and user etc directly just out of interest where is the word "undefined" coming from?
  3. hey guys thank you so much for your help....... just about to try a new insert statement here is my flash code - there is a lot of it but i think this is the most relevant ______________________________________________________________________ screen_gameover.dyn_feedback.text = ""; // Clear the reporting field. datatarget = "**************************************************"; // this is correct function collectdata():Void{ capsname = screen_gameover.theinput.text.charAt(0).toUpperCase()+screen_gameover.theinput.text.slice(1); // Force a capital on the gramatically lazy user gamedata = new LoadVars(); gamedata.var1 = capsname; gamedata.var2 = _root.score; trace (gamedata); trace ("=============================="); } screen_gameover.btn_submit.onRelease = function(){ if (screen_gameover.theinput.text == "" || screen_gameover.theinput.text == initmsg){ screen_gameover.dyn_feedback.text = "Please Enter Your E-Mail"; // Tell user cleartimer = setInterval(clearmsg, 2500); // So message above disappears after 4 seconds } else { // Only send if there is some text screen_gameover.btn_submit._visible = false; screen_gameover.btn_restart._visible = true; // now alow the user to restart the game collectdata(); gamedata.sendAndLoad(datatarget,gamedata,"post"); gamedata.onLoad = function(ok) { if (ok) { screen_gameover.dyn_feedback.text = this.msg; Key.removeListener(keyListener); } else { screen_gameover.dyn_feedback.text = "There was an error sending the data!"; screen_gameover.btn_submit._visible = true; } } _root.clearfield(); // Remove all badies again, just to be sure. } }
  4. one last try - i'd really appreciate any kind of pointer on this one guys its actually driving me nuts! c.
  5. also i should of mentioned that my MySQL looks like this.....
  6. Hey guys i'm trying to get 2 variables out of a flash game into a mysql dB via PHP var1 an email var2 a score the problem is my flash movie keeps saying "undefined" and the variables are not passed to the MySQL data base fire fox tamper says that POST_DATA is chucking out a score as var2 and a email as var1 my PHP code is below (i've blanked out the user/password stuff) <? $mysqlhost = "*********"; $mysqluser = "*********"; $mysqlpass = "*********"; $mysqldatabase = "*********"; mysql_pconnect($mysqlhost, $mysqluser, $mysqlpass); mysql_select_db($mysqldatabase); $name = strip_tags($_REQUEST["var1"]); $score = strip_tags($_REQUEST["var2"]); $query = "INSERT INTO scores_ast VALUES ('$name','$score')"; mysql_query($query); ?> can anyone see anything wrong with it or does any one have any ideas as to why its not working? C.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.