Corrected problem with md
This commit is contained in:
parent
63a8e21152
commit
043d774744
|
@ -140,6 +140,4 @@ function countIndentation($string){
|
||||||
function md2html($text){
|
function md2html($text){
|
||||||
return convert(split($text));
|
return convert(split($text));
|
||||||
}
|
}
|
||||||
|
|
||||||
echo md2html(file_get_contents("test.md"));
|
|
||||||
?>
|
?>
|
||||||
|
|
|
@ -9,7 +9,7 @@ if(isset($_GET["ID"])){
|
||||||
|
|
||||||
$authorName = getUserName($article["author"]);
|
$authorName = getUserName($article["author"]);
|
||||||
|
|
||||||
$content = "<h1>".$article["title"]."</h1><article>".convert($article["content"])."</article><span>written by ".$authorName." on ".$article["date"]."</span>";
|
$content = "<h1>".$article["title"]."</h1><article>".md2html($article["content"])."</article><span>written by ".$authorName." on ".$article["date"]."</span>";
|
||||||
}else{
|
}else{
|
||||||
$content = "Article ID is empty";
|
$content = "Article ID is empty";
|
||||||
}
|
}
|
||||||
|
|
Reference in New Issue