mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-14 21:51:32 +00:00
no need to include parsedown/Parsedown.php anymore, set flags of htmlspecialchars()
This commit is contained in:
parent
ee7b09d3fb
commit
575355731a
|
@ -74,14 +74,13 @@ $(document).ready(function() {
|
||||||
<div class="tab-content">
|
<div class="tab-content">
|
||||||
<div class="tab-pane active" id="preview_markdown">
|
<div class="tab-pane active" id="preview_markdown">
|
||||||
<?php
|
<?php
|
||||||
require_once('parsedown/Parsedown.php');
|
|
||||||
$Parsedown = new Parsedown();
|
$Parsedown = new Parsedown();
|
||||||
echo $Parsedown->text(file_get_contents($dms->contentDir . $version->getPath()));
|
echo $Parsedown->text(file_get_contents($dms->contentDir . $version->getPath()));
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab-pane" id="preview_plain">
|
<div class="tab-pane" id="preview_plain">
|
||||||
<?php
|
<?php
|
||||||
echo "<pre>".htmlspecialchars(file_get_contents($dms->contentDir . $version->getPath()))."</pre>";
|
echo "<pre>".htmlspecialchars(file_get_contents($dms->contentDir . $version->getPath()), ENT_SUBSTITUTE)."</pre>";
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -121,7 +120,7 @@ $this->contentHeading(getMLText("content"));
|
||||||
<input type="hidden" name="documentid" value="<?php echo $document->getId(); ?>" />
|
<input type="hidden" name="documentid" value="<?php echo $document->getId(); ?>" />
|
||||||
<textarea id="markdown" name="data" width="100%" rows="20">
|
<textarea id="markdown" name="data" width="100%" rows="20">
|
||||||
<?php
|
<?php
|
||||||
echo htmlspecialchars(file_get_contents($dms->contentDir . $version->getPath()));
|
echo htmlspecialchars(file_get_contents($dms->contentDir . $version->getPath()), ENT_SUBSTITUTE);
|
||||||
?>
|
?>
|
||||||
</textarea>
|
</textarea>
|
||||||
<button id="update" type="submit" class="btn btn-primary"><i class="icon-save"></i> <?php printMLText("save"); ?></button>
|
<button id="update" type="submit" class="btn btn-primary"><i class="icon-save"></i> <?php printMLText("save"); ?></button>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user