Php variable passing

http://members.lycos.co.uk/grandsp5/

This is a direct upload of Jubba’s tutorial onto a website but for some reason it doesnt work. I enabled php but it doesnt recieve the variables for some reason. This is what I uploaded

he, this used to drive me crazy


$name = $_POST['name'];

Reason is because your php.ini file has Global variables turned off.
So you will need to use that syntax when passing variables

thats the syntax I have right now…isnt it? This is my very first time with php so if I am doing something dumb please let me know.

o wow sry it is, try using GET

ok will do

ok dig, using GET fixed it but can you explain why? I don’t know the differences between get and POST, all I know is they are a variable passing method.

$_GET[] is used when you send the variable thru the URL string like this:

http://www.mywebsite.com/index.php?myVariable=27

$_POST[] is used when you don’t send variables thru the URL string

post is more secure

right but how come your tutorial didnt work when I used post? I uploaded what you had to a site and it didnt work until I changed post to get. I just unzipped your file from the tutorial part one and uploaded it. I will try again to see if I made a dumb mistake.

probably a problem with the Flash file. I’m not sure. Its been a while. I’ll take a look at the files later this week.

Ok. Thanks for all of your help :slight_smile:

Jubba some servers don’t allow POST, why? I have no idea. But i just did some server side code for someone and i had to use GET

Well the weird thing is when I try the mail script, it works with both POST and GET so I’m pretty sure it allows POST. This is tripod.lycos.uk btw.

Well I never used lycos so I really can’t say for sure. I am taking it that that is a free host, so with server’s that are free, nothing ever works the way it is supposed to

very possible. Maybe its just a bug.?? Know of any other free servers that support PHP? I don’t want to waste money paying for my experiments in PHP…

yea your own pc laughs :slight_smile:

download php and mySQL and install it on your machine to learn how it really works. you will also need IIS

really you should, it will help you out a lot

I tried easy PHP but I can’t figure out how to make it work…

and IIS?

Internet Information Systems

http://www.kirupaforum.com/forums/showthread.php?threadid=27549&highlight=IIS

Bunch of stuff there on how to install it. It’s on your windows CD

Hmm, I got the administrator tools panel open in the start menu but IIS isnt there

Properties >> advanced >> show admin tools

I got that far. The Admin Tools panel is open but there is no IIS option.