diff --git a/lib/md.php b/lib/md.php index 12ee978..fa338bd 100644 --- a/lib/md.php +++ b/lib/md.php @@ -140,6 +140,4 @@ function countIndentation($string){ function md2html($text){ return convert(split($text)); } - -echo md2html(file_get_contents("test.md")); ?> diff --git a/views/article.php b/views/article.php index 2c474cb..4c73133 100644 --- a/views/article.php +++ b/views/article.php @@ -9,7 +9,7 @@ if(isset($_GET["ID"])){ $authorName = getUserName($article["author"]); - $content = "

".$article["title"]."

".convert($article["content"])."
written by ".$authorName." on ".$article["date"].""; + $content = "

".$article["title"]."

".md2html($article["content"])."
written by ".$authorName." on ".$article["date"].""; }else{ $content = "Article ID is empty"; }