mirror of
https://github.com/renbaoshuo/S2OJ.git
synced 2024-11-21 19:48:42 +00:00
feat(api/markdown): default content
This commit is contained in:
parent
b656d59b23
commit
431598503f
@ -7,6 +7,10 @@ $purifier_type = UOJRequest::post('purifier_type', 'is_string', 'default');
|
|||||||
|
|
||||||
$markdown = UOJRequest::post('markdown', 'is_string', '');
|
$markdown = UOJRequest::post('markdown', 'is_string', '');
|
||||||
|
|
||||||
|
if ($markdown == '') {
|
||||||
|
$markdown = '_Nothing to preview._';
|
||||||
|
}
|
||||||
|
|
||||||
$parsedown = HTML::parsedown();
|
$parsedown = HTML::parsedown();
|
||||||
|
|
||||||
if ($purifier_type == 'inline') {
|
if ($purifier_type == 'inline') {
|
||||||
|
Loading…
Reference in New Issue
Block a user