[pmwiki-users] Feature request: Action lists in skins

Hans design at flutesong.net
Wed Apr 6 04:30:49 CDT 2005


Tuesday, April 5, 2005, 9:14:14 PM, Patrick wrote:
> Thinking about it some more, another problem with actions-stored-in-wikipages
> is that they don't internationalize well, at least not in the current sense
> of how we do i18n.  I suppose an admin could easily edit the action
> pages to translate the actions into the appropriate language, or that
> we could provide PmWikiXx.Actions pages for each language, but somehow
> it doesn't feel consistent with the current way we do i18n.

Yes this is a disadvantage if this approach gets used as standard.
It would be good to have an out-of-the-box translation of standard
actions.
I wonder if it is possible to provide a special markup which
translates expressions in wiki pages according to XLPage.
similar what is done with the expressions in the template:
   <a href='$PageUrl?action=edit'>$[Edit Page]</a>
In an action defining wiki page this reads (without
internationalisation) as:
  *[[{$Name}?action=edit | Edit Page]]
Maybe a markup like i18n(expression), so the above could be written as
  *[[{$Name}?action=edit | i18n(Edit Page)]]
and the string translates according to the i18n setting.
You can probably think of a better markup name than i18n,
perhaps XL(expression)?

Another idea:
Rather than having wiki pages defining the actions as opposed to
having the actions defined in the skin template, maybe we can have
the standard actions defined through a variable, and use a special
function in the skin template to get the actions from this variable
(as the standard default setting), but can switch on the option of
loading the actions via action-defining wiki pages.

This would solve the problem of internationalisation.
It would also give an administrator the possibility to either have the
actions as a predefined standard which can't be changed by a user, or
provide customisation options via defining actions in wiki pages,
which could be doen by admin or users.

Sorry this is just a rough idea, and I don't know how this could be
implemented through php.

Re: Naming of action defining wiki pages:
Radu wrote:
> IMHO, those pages can contain more than lists and actions. Since skins deal
> (ideally) with layout and not function, I'd have to cast a vote in favor of 
> naming the pages by location. And in order to have them sorted in the same 
> place,
> * in the browser for making sure they're there or
> * in (:pagelist:) directives for editing purposes (no more hunting for them 
> up and down a list)
> , I agree with
> 
> PageTop
> PageBottom
> PageLeft
> PageRight
> 
> where "Page" (my favorite cos it's descriptive), could also be "Bar" or "Menu"
> 
> Of course, Sidebar stays for backwards comp and could very well 
> (:redirect:) silently either of these pages
> 
> And all these don't exclude the use of a general PageFooter to be used 
> throughout the wiki for describing it.

This sounds good to me. I like all these pages listed together.
Having called them PageTopMenu and PageFootMenu was a compromise of
naming by location and by function for me. Putting "Page" at the front
ensured they will list together, and to distinguish them from GroupHeader
and GroupFooter.

Best, 
~Hans                           




More information about the pmwiki-users mailing list