Page 1 of 1

PHP / IIS installation

Posted: Thu May 08, 2003 1:18 am
by kieran
Hi,

I'm fairly new to PHP scripting. I've just installed PHP on IIS on my stand alone computer running XP. I want to try and teach myself PHP.

I think I've installed PHP successfully ..... it works if I use a function like phpinfo() or if I get it to print the current time onscreen BUT it doesn't seem to recognise variables (e.g. from a HTML form) or be able to take variables sent from a form on one HTML page and process the variables and pass them to another HTML page.

Can anyone help me? What have I done wrong ? Is it maybe the way I've installed PHP ? I would appreciate any advice you can offer.

Kieran

U have to Configure the php.ini file

Posted: Thu May 08, 2003 1:37 am
by anz789
hi,
U have to do some settings( Infact aLot ":D") in the php.ini file

1) to get the html varriable u have to set the register_globals varriable true
////////////////// part frm php.ini///////////////////////
You should do your best to write your scripts so that they do not require
; register_globals to be on; Using form variables as globals can easily lead
; to possible security problems, if the code is not very well thought of.

register_globals = 1
//////////////////////////////

this will solve ur varriale problem ...
if U donot wana on globals then U can access these in the super global array
HTTP_POST.. or HTTP_GET [] ...
check these to in the manual

GOOD Luck !
Noman !

Posted: Thu May 08, 2003 2:10 am
by volka
viewtopic.php?t=511 will tell you more about it.

Posted: Thu May 08, 2003 4:16 am
by twigletmac
Please don't turn register_globals on as anz789 suggested - if you're new to PHP it will be worth your while to learn about $_POST, $_GET et. al. as register_globals is deprecated, that is it is not going to be in all future releases of PHP and gradually hosts (believing there is a security issue) will stop turning it on as well.

Mac