forked from yiisoft/yii2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMarkdown.php
33 lines (31 loc) · 1.04 KB
/
Markdown.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php
/**
* @link http://www.yiiframework.com/
* @copyright Copyright (c) 2008 Yii Software LLC
* @license http://www.yiiframework.com/license/
*/
namespace yii\helpers;
/**
* Markdown provides an ability to transform markdown into HTML.
*
* Basic usage is the following:
*
* ```php
* $myHtml = Markdown::process($myText); // use original markdown flavor
* $myHtml = Markdown::process($myText, 'gfm'); // use github flavored markdown
* $myHtml = Markdown::process($myText, 'extra'); // use markdown extra
* ```
*
* You can configure multiple flavors using the [[$flavors]] property.
*
* For more details please refer to the [Markdown library documentation](https://github.com/cebe/markdown#readme).
*
* > Note: The Markdown library works with PHPDoc annotations so if you use it together with
* > PHP `opcache` make sure [it does not strip comments](https://secure.php.net/manual/en/opcache.configuration.php#ini.opcache.save-comments).
*
* @author Carsten Brandt <[email protected]>
* @since 2.0
*/
class Markdown extends BaseMarkdown
{
}