PHP / IIS installation

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
kieran
Forum Newbie
Posts: 1
Joined: Thu May 08, 2003 1:18 am
Location: Australia

PHP / IIS installation

Post 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
anz789
Forum Newbie
Posts: 3
Joined: Sun May 04, 2003 1:41 am

U have to Configure the php.ini file

Post 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 !
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

viewtopic.php?t=511 will tell you more about it.
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post 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
Post Reply