Click to See Complete Forum and Search --> : php configuration problem?


ziggie216
10-31-2003, 04:40 AM
I just setup my server and was testing a very simple script

filename: test.php

<?php
echo $repeat;
?>

when I go to http://something.com/test.php?repeat=testing

nothing shows.

I uploaded this file to a web host and it works. is there something I need to configure in the php.ini to get this to work?

LordShryku
10-31-2003, 12:14 PM
You probably have register_globals off. It's default off in newest versions. Try doing this instead

<?php
echo $_GET['repeat'];
?>

It's best to try to code with register_globals off. Read more about it here (http://www.php.net/register_globals)

ziggie216
10-31-2003, 05:03 PM
so any lines that is trying to call up something like $repeat must be like $_GET['repeat'] ?

LordShryku
10-31-2003, 06:33 PM
Either that, or you turn on register_globals.