Hi Tom:

On Sun, Jun 23, 2002 at 01:24:57AM -0600, Thomas E. Ruth wrote:
> 
> If I have a script called "sendheader.php" with the following:
> 
> <?
> if (! isset($GLOBALS[sendheader])) {
>       header("Location: http://blah.com/sendheader.php";);
>       exit;
> }
> 
> echo "blah";
> ?>

Dude, what IS the point of this?

If the $sendheader variable isn't set, you're sending the person back to
the same page w/o setting the sentheader variable first...  So, you've 
created an infinite loop.  Do you mean to be doing:

   header('Location: http://blah.com/sendheader.php?sendheader=y');


Some other tips:

When array keys are strings, put them in quotes ($GLOBALS['sendheader'])

Use single quotes rather than double quotes when dealing with strings that 
are not being evaluated for variables in them.

--Dan

-- 
               PHP classes that make web design easier
        SQL Solution  |   Layout Solution   |  Form Solution
    sqlsolution.info  | layoutsolution.info |  formsolution.info
 T H E   A N A L Y S I S   A N D   S O L U T I O N S   C O M P A N Y
 4015 7 Av #4AJ, Brooklyn NY     v: 718-854-0335     f: 718-854-0409

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to