mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-20 08:15:13 +00:00
even more fine tuning of the markdown purifier - especially when used with the wiki
This commit is contained in:
parent
7a611c6d47
commit
35fc7328de
4 changed files with 4 additions and 3 deletions
|
@ -81,7 +81,7 @@ class MarkdownSoap {
|
|||
$s = str_replace("\t",' ',$s);
|
||||
$s = str_replace(' ',' ',$s);
|
||||
$s = purify_html($s);
|
||||
$s = str_replace(' '," ",$s);
|
||||
$s = str_replace([' ', mb_convert_encoding(' ','UTF-8','HTML-ENTITIES')], [ ' ', ' ' ],$s);
|
||||
$s = str_replace(['<br>','<br />'],["\n","\n"],$s);
|
||||
return $s;
|
||||
}
|
||||
|
|
|
@ -156,7 +156,7 @@ class NativeWikiPage {
|
|||
$content = $item['body'];
|
||||
|
||||
return [
|
||||
'content' => json_encode($content),
|
||||
'content' => $content,
|
||||
'mimeType' => $w['mimeType'],
|
||||
'message' => '',
|
||||
'success' => true
|
||||
|
|
|
@ -255,6 +255,7 @@ class Wiki extends \Zotlabs\Web\Controller {
|
|||
goaway('/' . argv(0) . '/' . argv(1) . '/' . $wikiUrlName . '/' . $pageUrlName);
|
||||
}
|
||||
|
||||
|
||||
$wikiModalID = random_string(3);
|
||||
|
||||
$wikiModal = replace_macros(get_markup_template('generic_modal.tpl'), array(
|
||||
|
|
|
@ -108,7 +108,7 @@
|
|||
window.wiki_resource_id = '{{$resource_id}}';
|
||||
window.wiki_page_name = '{{$page}}';
|
||||
// window.wiki_page_content = "{{$content|escape:'javascript'}}";
|
||||
window.wiki_page_content = {{$content}};
|
||||
window.wiki_page_content = '{{$content|escape:'quotes'}}';
|
||||
window.wiki_page_commit = '{{$commit}}';
|
||||
|
||||
$("#generic-modal-ok-{{$wikiModalID}}").removeClass('btn-primary');
|
||||
|
|
Loading…
Reference in a new issue