[pmwiki-users] Work in progress notices

Petko Yotov 5ko at 5ko.fr
Fri Jul 26 04:21:46 PDT 2024


Oh, email clients may mangle the ">><<" at the last line of the markup 
replacement, as if it was quoted text from the email.

The last argument to the Markup() call is your replacement text that can 
include wiki markup. It should be wrapped in PVSE() if it contains <, >, 
&, or empty lines.

Otherwise you can simply do:

Markup('WIP', '<split', '/^@WIP/',
   "This page is a [[!wip|work in progress]]. It might be incomplete.");

Petko
-- 
If you upgrade :  https://www.pmwiki.org/Upgrades

On 26/07/2024 13:09, Petko Yotov wrote:
> Indeed, some markup directives like "include" and "pagelist" are not
> processed when a page is saved, so the categories and backlinks output
> by these directives are not indexed.
> 
> You can achieve this by adding a custom markup rule.
> 
> Add something like this to config.php:
> 
> Markup('WIP', '<split', '/^@WIP/m', PVSE(">>frame<<
> This page is a [[!wip|work in progress]].
> It might be incomplete.
> >> <<
> "));
> 
> Then in your pages, add somewhere "@WIP" at the start of a line, it
> will be replaced with the markup defined in the rule, then processed
> as it it were in the page.
> 
> Petko
> --
> If you upgrade :  https://www.pmwiki.org/Upgrades
> 
> On 26/07/2024 11:32, Александар Средојевић wrote:
>> I want to mark some pages as a work in progress,
>> as well as add them to a category called wip.
>> preferably with as little repeating as possible,
>> and also being able to change the notice itself
>> without changing every page it's on.
>> I was imagining it would work something like this:
>> 
>>     (:include wip:)
>> 
>>     This is an incomplete page
>> 
>> would get turned into something like this:
>> 
>>     This page is a [[!wip|work in progress]].
>>     It might be incomplete.
>> 
>>     This is an incomplete page.
>> 
>> I tried to make a page called wip
>> and include it in a page.
>> And while it displays nicely it doesn't get added to the wip category,
>> only the wip page itself is included.
>> 
>> Do you have any ideas how to achieve something like this?



More information about the pmwiki-users mailing list