Version 0.0.1 Created by Evan Coury
To install EdpMarkdown, simply recursively clone this repository (
--recursive) into your ZF2 modules directory and enable it in your
config/application.config.php file. That's it!
With this module installed, using Markdown in your view scripts is easy:
<?= $this->markdown('Hello, **this** is _Markdown_!'); ?>
NOTE: For security purposes, the output SHOULD be sanitized if the Markdown is from an untrusted source. (@padraic says so!) See the Markdown documentation on inline HTML to understand why this is necessary.
By default, this module uses the "Markdown Extra"
parser. If you'd like to switch it to just use the normal markdown parser, you
can simply define the
MARKDOWN_PARSER_CLASS, which PHP Markdown is configured
to check for. An easy place to do this would be in a config file such as
<?php define('MARKDOWN_PARSER_CLASS', 'Markdown_Parser');
EdpMarkdown is released under the New BSD license. See the included LICENSE file.
PHP Markdown is available under the New BSD or the GNU GPL v2.