[pmwiki-users] creole 1.0 help

Erlend Weydahl erlendsweydahl2007 at yahoo.com
Thu Oct 25 02:43:21 CDT 2007


hello,

im trying to have my wiki support creole 1.0 ( http://www.wikicreole.org/wiki/Creole1.0 ) im not suggesting that pmwiki should adopt it as default, but it would be nice if it does support it. most markup is already taken care of in pmwiki by scripts/creole.php. (thanks for that!) however some markup rules are missing or dont work: (see http://www.pmwiki.org/wiki/Cookbook/Creole-Sandbox )

1) images:
{{abc.jpg|xyz}}  xhtml: <img src="abc.jpgf" alt="xyz">
(or something equivalent)

2) table headers:
|=abc|=abc|=abc|
|=abc|xyz|xyz|
|=abc|xyx|xyz|
xhtml: ...<th>abc</th>...
(instead of <td>=abc</td>)

3) inline preformatted (no wiki)
{{{**abc**}}}  xhtml: <tt>**abc**</tt> (not bold)
(or <code>...)

4) escape character (~)
~**abc** (escapes first *)
~[[abc]] (escapes first [)
etc.

could somebody please help me get the markup to put in local/config.php?

thanks a lot!

-erlend

----------

ps. more detail:

1) images:
already in creole.php: (but it doesnt seem to work)

Markup('{{', 'inline',
  '/\\{\\{(?>(\\L))([^|\\]]*)(?:\\|\\s*(.*?)\\s*)?\\}\\}/e',
  "Keep(\$GLOBALS['LinkFunctions']['$1'](\$pagename, '$1', '$2', '$3',
     '$1$2', \$GLOBALS['ImgTagFmt']),'L')");

2) table headers:
other markup already in creole.php:

Markup('|-table', '>^||',
  '/^\\|(.*)$/e',
  "FormatTableRow(PSS('$0'), '\\|')");

idea: replace "|=" by "|!" before the function FormatTableRow in pmwiki.php gets it. Markup(???); (which should get called before the above rule)

3) inline preformatted (no wiki)
already creole.php: (but it doesnt seem to work)

Markup('{{{', '>{{{',
  '/\\{\\{\\{(.*?)\\}\\}\\}/se',
  "Keep(PSS('<code class=\"escaped\">$1</code>'))");

4) escape character (~)
not in scripts\creole.php. 

according to creole 1.0 :
"Outside nowiki, preformatted, and URL, the escape character only escapes the character immediately following it, provided that it is not a blank (space or line feed). The following character is rendered as is and cannot be a part of any Creole markup. The escape character disables the automatic conversion of the URL immediately following to links, and any similar mechanism supported by the wiki engine (camelcase wikiwords, copyright sign, etc.)."

Markup(???);

----------


-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/pmwiki-users/attachments/20071025/7bfcf966/attachment.html 


More information about the pmwiki-users mailing list