On Tuesday, April 16, 2002, at 02:40  PM, Jeff Lewis wrote:

> Right after I call those I try a is_registered and it showed that these
> registered correctly.  I removed that code and added a call to another
> function: redirectinternal();

You can avoid the whole "session_register()" business if you simply 
refer to these variables as $_SESSION['valid_user'] and 
$_SESSION['privs'] -- after all, that's what they are, simply session 
variables.  By using this convention, you clarify exactly what kind of 
variables they are each time you write them, which is good for 
legibility later in the future.  Also, you don't need to declare them as 
global in your redirectinternal() function, since any $_* variable is 
considered global at all times.

> That function is below:
>
> function redirectinternal () {
>  global $valid_user,$privs;
>
>  echo "Login good!";
>  echo "<BR>".$valid_user." - ".$privs.$temp;
>
> }
>
> Now, I can't seem to get those values to print to the screen.  I added a
> session_start before the echo and I just can't get my values out...what 
> am I
> missing?

You'll have to post the context of this function (how it is called in 
the script) for an answer to this question.


Erik





----

Erik Price
Web Developer Temp
Media Lab, H.H. Brown
[EMAIL PROTECTED]


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

Reply via email to