[pmwiki-users] How can I read password protect all pages in a group except the HomePage?
Patrick R. Michaud
pmichaud at pobox.com
Mon Nov 6 15:07:36 CST 2006
On 11/6/06, H. Fox <haganfox at users.sourceforge.net> wrote:
> > How can I read password protect all pages in a group except the HomePage?
>
> First, set a read password for the group using a GroupName.php that
> looks like this:
>
> <?php if (!defined('PmWiki')) exit();
> $DefaultPasswords['read'] = crypt('your_secret_password');
Actually, this method won't work -- setting $DefaultPasswords['read']
in a per-group or per-page configuration file does not reliably
read-protect pages in that group or page. In particular, an author
can use (:include:) or other directives to read pages that have
their passwords "set" in this manner. (Group.php files are only
read when browsing a page in that group, but (:include:) will work
across groups without activating the corresponding Group.php .)
The only reliable way to set a read password on a group is to
use ?action=attr on the GroupAttributes page.
Pm
More information about the pmwiki-users
mailing list