Hello hello,

I would like to set up a new pattern for multiline ptv ;
current (:bla bla this is a hidden ptv:) may me broken by the text.

Thus, I wish to create a more distinctive <<< new pattern >>> which would
work in the smiling case below :

<<< bla bla this is a new (hidden or not) ptv :) >>>

I don't know how to write the regex. Model is not easy to understand. May
someone help me ?

Thank you,
Gilles.

(by the way, $PageTextVarPatterns is not documented in the variables pages).

http://www.pmwiki.org/wiki/PmWiki/PageTextVariables-Talk says :
PageTextVar relies on the $PageTextVarPatterns variable (which can be used
to extend the recognized formats for page text variables in a page). In the
older 2.2.0 Beta versions of PmWiki, this variable wasn't initialized until
stdmarkup.php was run, after config.php was executed. Thus, if you needed
to use page text variables inside config.php, you had to initialize it
yourself. This is no longer necessary, but for those who are still running
earlier versions of the beta series, here's the value to use:
SDVA($PageTextVarPatterns, array(
  'var:' => '/^:*\\s*(\\w[-\\w]*)\\s*:[ \\t]?(.*)$/m',
  '(:var:...:)' => '/\\(: *(\\w[-\\w]*) *:(?!\\))\\s?(.*?):\\)/s'));



-- 

---------------------------------------
| A | de la langue française
| B | http://www.languefrancaise.net
| C | languefranca...@gmail.com
---------------------------------------
       @bobmonamour
---------------------------------------
_______________________________________________
pmwiki-users mailing list
pmwiki-users@pmichaud.com
http://www.pmichaud.com/mailman/listinfo/pmwiki-users

Reply via email to