dolibarr 21.0.0-beta
parsemd.lib.php File Reference

This file contains functions dedicated to MD parsing. More...

Go to the source code of this file.

Functions

 dolMd2Html ($content, $parser='parsedown', $replaceimagepath=null)
 Function to parse MD content into HTML.
 
 dolMd2Asciidoc ($content, $parser='dolibarr', $replaceimagepath=null)
 Function to parse MD content into ASCIIDOC.
 

Detailed Description

This file contains functions dedicated to MD parsing.

Definition in file parsemd.lib.php.

Function Documentation

◆ dolMd2Asciidoc()

dolMd2Asciidoc ( $content,
$parser = 'dolibarr',
$replaceimagepath = null )

Function to parse MD content into ASCIIDOC.

Parameters
string$contentMD content
string$parser'dolibarr'
?array<string,string>$replaceimagepath Replace path to image with another path. Example: ('doc/'=>'xxx/aaa/')
Returns
string Parsed content

Definition at line 79 of file parsemd.lib.php.

Referenced by Utils\generateDoc().

◆ dolMd2Html()

dolMd2Html ( $content,
$parser = 'parsedown',
$replaceimagepath = null )

Function to parse MD content into HTML.

Parameters
string$contentMD content
'parsedown'|'nl2br'$parser 'parsedown' or 'nl2br'
?array<string,string>$replaceimagepath Replace path to image with another path. Example: ('doc/'=>'xxx/aaa/')
Returns
string Parsed content

Definition at line 33 of file parsemd.lib.php.

Referenced by DolibarrModules\getChangeLog(), and DolibarrModules\getDescLong().