PHP code example of breeswish / php-marked

1. Go to this page and download the library: Download breeswish/php-marked library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

breeswish / php-marked example snippets


echo \Breezewish\Marked\Marked::render('I am using __markdown__.');
// => <p>I am using <strong>markdown</strong>.</p>

\Breezewish\Marked\Marked::setOptions(array(
    'gfm'          => true,
    'tables'       => true,
    'breaks'       => false,
    'pedantic'     => false,
    'sanitize'     => false,
    'smartLists'   => false,
    'smartypants'  => false,
    'langPrefix'   => 'lang-',
    'xhtml'        => false,
    'headerPrefix' => '',
    'highlight'    => null,
    'renderer'     => new \Breezewish\Marked\Renderer()
));

echo \Breezewish\Marked\Marked::render('I am using __markdown__.');
bash
composer