Re: [PHPLIB] Falling back to "nobody" ? From: Massimiliano Masserelli (negro <email protected>)
Date: 11/16/99

On Tue, Nov 16, 1999 at 10:02:52AM +0100, Stefano 'Panda' Baraldi wrote:

 SB> I have public pages (Default_Auth) and protected ones (Auth). If a
 SB> user visits a public page everything is fine (he's nobody), then if
 SB> he checks a protected page he gets a pretty login form.
 SB> That is good, but if he visits a public page again page he's getting
 SB> another login form, and therefore he's not able to visit them
 SB> anymore. It's like a single access to a page with Auth makes
 SB> Default_Auth useless...
 SB> Is this a normal behaviour?

Nope, it should not. Please take care, anyway, that you should use the
same auth class all over your project. That is: all page_open() calls
must have the same "auth"=>"Whatever_Auth" parameter.

In your case, you would have $nobody=true in your auth class, then "protect"
reserved pages with $login_if($auth->auth["uid"] == "nobody").

If you your setup is what I've just described AND you're using latest
phplib (7.2), then something is going wrong and I'd like to have a closer
look at your application.
 
Bye.

--
     Massimiliano Masserelli       |     URL:    http://www.interim.it/
     Internet Images S.r.l.        |     Tel:    +39-051-3390671
     vicolo Viazzolo, 3            |     Fax:    +39-051-557890
     40124 - Bologna - Italy       |
-------------------------------------------------------------------------------
Using words to describe magic is like using a screwdriver to cut roast beef.
		-- Tom Robbins
-
PHP3 Base Library Mailing List. Send messages to <phplib <email protected>>.
To unsubscribe, send "unsubscribe" to <phplib-request <email protected>> in
the body, not the subject, of your message.