mirror of
https://github.com/getgrav/grav.git
synced 2025-11-02 03:16:04 +01:00
Update Markdown.php
This commit is contained in:
@@ -109,7 +109,7 @@ class Markdown extends General
|
|||||||
$var = preg_replace("/(\r\n|\r)/", "\n", $var);
|
$var = preg_replace("/(\r\n|\r)/", "\n", $var);
|
||||||
|
|
||||||
// Parse header.
|
// Parse header.
|
||||||
preg_match("/---\n(.+?)\n---(\n\n|$)/uism", $this->raw(), $m);
|
preg_match("/---\n(.+?)\n---(\n\n|$)/uism", $var, $m);
|
||||||
$content['header'] = isset($m[1]) ? YamlParser::parse(preg_replace("/\n\t/", "\n ", $m[1])) : array();
|
$content['header'] = isset($m[1]) ? YamlParser::parse(preg_replace("/\n\t/", "\n ", $m[1])) : array();
|
||||||
|
|
||||||
// Strip header to get content.
|
// Strip header to get content.
|
||||||
|
|||||||
Reference in New Issue
Block a user