[pmwiki-users] Re: Re: Re: Supporting different modes in default pmwiki

chr at home.se chr at home.se
Sun Aug 7 13:30:41 CDT 2005

On Sun, 7 Aug 2005, Hans wrote:

> Sunday, August 7, 2005, 6:17:23 PM, chr wrote:
> > But back to (:if auth ..:)
> > I don't think it'll work since it requires the user to enter a password?
> > Or rather, it checks if the user is allowed access... what I'm thinking of
> > is actually orthogonal to this. Even someone who normally administers the
> > wiki should be able to use them in reading mode if he feels like it, while
> > still accessing pages that are password protected.
> > So something like (:if mode author:) would be needed rather than 'auth'.
> For 'if auth' we got the parameters: read, edit, attr, admin, uploads.

I'd like modes to work regardless if pages are proteced or not. 

> How else would pmwiki know if a user is a reader or an author or an
> admin?

That's the new functionality I'd like from pmwiki. A way to set your
current mode and have pmwiki remember this. Straight away I can think of 
using cookies or an argument on the URI (?mode=...).

> Or do you envision a 'mode' switch in the skin? 

Exactly - I've just tried to avoid talking about it in terms of solutions
(i.e. using skins). To me, the first question should be if it's something
that's useful and what it should do, not how to implement it :-)

> Like ?setmode action links? Then why not customise variations to a skin
> and use ?setskin=readmode, ?setskin=editmode, ?setskin=adminmode, with
> readmode, editmode and adminmode being these skin variations.

That sounds exactly what I'm looking for. I've not played around with
skinds so I have no familiarity with ?setskin=... However, I'd probably
still prefer to us an action link such as ?setmode=... To me the mode is
more like an (optional) argument to the skin, allowing the skin to look
and act differently depending on the mode. In addition, it should be 
possible to do something like this in the sidebar

	(:if mode admin:)* Site.AllrecentChanges(:ifend:)

I'm still interested to know if this idea of having different modes makes 
sense or not. Is it just something that makes pmwiki more complicated to 
user, or could we use it to make the UI better?



Christian Ridderström, +46-8-768 39 44               http://www.md.kth.se/~chr

More information about the pmwiki-users mailing list