Jan's Markdown Preview

Michel Fortin michel.fortin at michelf.com
Wed Dec 7 08:09:11 EST 2005


Le 2005-12-07 à 05:42, Julian 'Julik' Tarkhanov a écrit :


> <?php

> include_once 'markdown.php';

> ob_start('markdown');

> include($somehow_deducted_path_to_markdown_document);

> ob_end_flush();

> ?>


Be very careful with that as it will execute any PHP instruction
found in the Markdown-formatted document. If that's what you want,
fine; otherwise:

<?php
include_once 'markdown.php';
$body = Markdown(file_get_contents($path_to_markdown_file));
?>


Michel Fortin
michel.fortin at michelf.com
http://www.michelf.com/




More information about the Markdown-Discuss mailing list