function MarkdownExtra_Parser::_processDefListItems_callback_dd in Markdown 5
Same name and namespace in other branches
- 6 markdown.php \MarkdownExtra_Parser::_processDefListItems_callback_dd()
File
- ./
markdown.php, line 2481
Class
Code
function _processDefListItems_callback_dd($matches) {
$leading_line = $matches[1];
$marker_space = $matches[2];
$def = $matches[3];
if ($leading_line || preg_match('/\\n{2,}/', $def)) {
# Replace marker with the appropriate whitespace indentation
$def = str_repeat(' ', strlen($marker_space)) . $def;
$def = $this
->runBlockGamut($this
->outdent($def . "\n\n"));
$def = "\n" . $def . "\n";
}
else {
$def = rtrim($def);
$def = $this
->runSpanGamut($this
->outdent($def));
}
return "\n<dd>" . $def . "</dd>\n";
}