Click to See Complete Forum and Search --> : which variable needs to be turned "ON" in order to allow variable passing thru urls?


neil
08-21-2003, 08:56 AM
which variable needs to be turned "ON" in order to allow variable passing through urls?

I had a page which worked through the variable passing through href tags, but now it doesn't work because they've re-installed php5

please help

pyro
08-21-2003, 09:47 AM
PHP5? Which host are you with? PHP5 is still beta, and isn't supposed to be run in production environments yet... Maybe you mean PHP 4.3.2?

Anyway, you can most likely find your answer at http://www.webdevfaqs.com/php.php#globalvariables.

neil
08-21-2003, 10:49 AM
errr he said php 5, maybe he probably meant what you said.

I'll have a look at that link now

cheers mate :D

pyro
08-21-2003, 12:06 PM
You bet... Hope that solves it for you.

neil
08-21-2003, 12:21 PM
it would but I don't have user rights to access the php.ini file so I have to wait for my work colleague to finish doing something else first

which is a bit lame

pyro
08-21-2003, 12:36 PM
You could also just not use global variables, which is what is recommended...

neil
08-22-2003, 03:33 AM
hmm

I reasonably new to php, how would you suggest I go about it instead? I don't want to have to re-code too much stuff. Is there another way?

pyro
08-22-2003, 07:13 AM
Well, like I said, it is not recommended to use global variables, but if your server is running PHP as an Apache module, you should be able to change global variables to be on with an .htaccess file. See http://us2.php.net/configuration.changes for more information. Basically, you are going to want to add a line that looks like this to your .htaccess file:

php_value register_globals 1

Why shouldn't you use registered globals? http://us4.php.net/security.registerglobals

diamonds
08-24-2003, 05:18 PM
Why not use $_GET['action'] or @$_GET['action'] (see error control (http://php.net/manual/en/language.operators.errorcontrol.php))

And if you dont know what .hactass files are...
do what pyro said, but make the filename .hactass ONLY!
If you are creating it in notepad, enclose it in quotes. this will prevent the program form adding anything to the end, like '.txt', ending out as '.hactass.txt'