Page 1 of 1

Problem using query string navigation on php 4.3.1 (ensim)

Posted: Fri Aug 15, 2003 9:00 am
by dtportnoy69
I seem to be having a problem using url query strings.

It works fine on a 4.3.2 host:

http://www.wintermyth.com/archeronne/ma ... elcome.tpl

It doesn't work on the main server though and i have no idea why.

http://archeronne.tcpgaming.net/archeronne/main.php

The main server is running php 4.3.1 on IIS using the ensim package. Its not my server but the admin doesn't know what the problem is either.

I set up a php info page for you guys to look at

http://archeronne.tcpgaming.net/phpinfo.php

Basically i set link='welcome.tpl' by default in my php file. So on the 4.3.1 server when you click on News, Downloads etc.. it will stay on the welcome page because the value for link hasn't changed. And there's the problem. the value should have changed.

I have no clue what the problem is, i've been looking everywhere for a solution. Supposedly passing a query through your URL is part of PHP's URL Functions which, accordign to php's manual, is already in its core so it doesn't need to be set. Is it the same for 4.3.1 ?

Well thanks in advance :)

Posted: Fri Aug 15, 2003 9:06 am
by twigletmac
phpinfo report wrote:register_globals Off
How are you trying to access the variables from the query string? Are you using $_GET?

Mac

RE

Posted: Fri Aug 15, 2003 1:41 pm
by dtportnoy69
Nope. Just passing values for link. Not using @_Get or @_Post. Hyperlink to News is main.php?link=news.tpl

That's it. :P So that would need register globals on?

Posted: Fri Aug 15, 2003 2:31 pm
by twigletmac
Personally I would change the code to not rely on reg globals (not all hosts will turn it on) but a quick fix would be to enable it.

Mac

Posted: Fri Aug 15, 2003 3:06 pm
by dtportnoy69
ah thanks for the help. I'll try to think of a way to get it to work without turning it on then.

Great forum and great help ;) It's really appreciated . Thank you :)