PDA

View Full Version : PHP newbie question


ptrcklgrs
04-12-2006, 07:31 PM
Ok ive looked ove a couple of internet tutorials and they are all to confusing when it comes to talk about Flash with PHP. So ive got 2 basic questions i hope someone could help me with. Im trying to make a site that you can log into and create a new account.

First is i heard you can access the PHP file using:
LoadVariables()
LoadVariableNum()
GetUrl()

Which one is the best for what im doing.
The second thing is i want to know how to transfer a PHP variable $test into an actionscript variable. For instance.
Flash File

loadvariables(URL,0)
// disptest is the displayed in dynamic test variable


PHP file
<?
$test = 3
print "disptest = $test"
?>

Thank you i hope you understand what im trying to accomplish i just want to make ($test == disptest) thank you.

Flash Gordon
04-12-2006, 07:58 PM
secret option 4: LoadVars();

check my sig.

ptrcklgrs
04-12-2006, 09:16 PM
yea for some reason when i went looking up load variables everything simplified. Thankyou i just got one more question.
I just want to make sure that the .txt file that looks something like "&hitnumber=1&EOF=1&" can still be changed via PHP so that hitnumber==a greater number because some tutorials said something about this terchnique being limited.

Thanks

Flash Gordon
04-12-2006, 09:20 PM
that made absolutely no sense to me :(

ptrcklgrs
04-12-2006, 10:48 PM
Yea im sorry but i found the answer in another tutorial. But i do have one more question about arrays.

How do you type arrays in the .txt file? Ive never seen how its done because ive only seen sample variables. Would an array look like this in the .txt file.

&testlist=(variable0,variable1,variable2)

im wondering how you would do it if its possible and the line above is just my guess so you could see where im going. THank you.

Flash Gordon
04-12-2006, 10:57 PM
can't

you need to &myArray = foo.::.Bar.::.Coke.::.Babies.::.Miytiy&
myArray.split(".::.");

ptrcklgrs
04-12-2006, 11:34 PM
You have been a big help. I never found a basic tutorial when i was looking. Thank You.

I dont know how much you know about setting up local host. I have windows XP home and want to run apache, PHP, Mysql combo to test this stuff. I have apache and PHP working perfectly but when i go to start Mysql everything falls apart. Ive spent hours looking over the internet and reloading and loading Mysql using different tutorials but no matter what i tried nothing helped. Id have to resend the error messege it gives me. But i was wondering if you think you could help me if you know about it cause i am running out of options. ThankYou.

Flash Gordon
04-13-2006, 12:02 AM
xampp free and with self installer.