new installation help!

A

Anonymous

Guest
here is what we're using

APACHE version 1.3.27
MySQL version 4.0.12
PHP version 4.3.1

all TAR.GZ files.

We can't seem to make PHP work right. I can see PHP info and the other simple PHP stuff.

some functionalities I noticed tht doesn't work was my sessions don't work
GetHostByName($REMOTE_ADDR) returns no value

what could we have done wrong? any ideas? by the way, were using Red Hat 8.
 
YOU GOT IT MIKE! everythings seems to be working properly now!
Thanks!!
 
using register globals on is a security risk and SHOULD NOT be used. Yes it is a quick workaround but a dangerous one.

php.net doc said:
By turning off the ability for any user-submitted variable to be injected into PHP code, you can reduce the amount of variable poisoning a potential attacker may inflict. They will have to take the additional time to forge submissions, and your internal variables are effectively isolated from user submitted data.

see http://www.php.net/register_globals for more information
 
PHP should have set it to default a long time ago. before I developed my scripts. :x

now, how do I change it my variables so that it will work with register globals turned off :lol:
 
make your form submit as EITHER POST or GET, I recommend POST... to retrieve a variable, you then use:
Code:
$variable = $_POST["variable"];

Andrew
 
bezmond said:
make your form submit as EITHER POST or GET, I recommend POST... to retrieve a variable, you then use:
Code:
$variable = $_POST["variable"];

Andrew
as i know POST and GET it's two different way...
 
yeah sorry, meant to add...

if you use GET, you should do:
$variable = $_GET["variable"];

as I said, I suggest using POST, as GET sends variables in the URL, e.g. http://www.nowhere.com/file.php?x=1&y=2
etc etc

Andrew
 
bezmond said:
yeah sorry, meant to add...

if you use GET, you should do:
$variable = $_GET["variable"];

as I said, I suggest using POST, as GET sends variables in the URL, e.g. http://www.nowhere.com/file.php?x=1&y=2
etc etc

Andrew
not only....
if you use GET, than line string in youre browser shortest only 255 signs, and ones more GET work faster!
 
ok ok, personally, I prefer POST... the majority of forms I've used on my website send information that I need to keep secured, e.g. a username, password etc... so I use POST to help me that little bit more...

the other way, would be to encrypt it... e.g. submit everything with md5($variable) I suppose, but that's long-winded...

Andrew
 
bezmond said:
ok ok, personally, I prefer POST... the majority of forms I've used on my website send information that I need to keep secured, e.g. a username, password etc... so I use POST to help me that little bit more...

the other way, would be to encrypt it... e.g. submit everything with md5($variable) I suppose, but that's long-winded...

Andrew
I'm just give info about GET and POST :wink:
 
Back
Top