mirror of
https://github.com/Karaka-Management/oms-Editor.git
synced 2026-01-22 06:18:44 +00:00
Add html escaping
This commit is contained in:
parent
a69d02e5bd
commit
39a0f9464d
|
|
@ -24,7 +24,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<div class="inner">
|
||||
<form id="fEditor" method="POST" action="<?= \phpOMS\Uri\UriFactory::build('{/base}/{/lang}/api/editor?{?}&csrf={$CSRF}'); ?>">
|
||||
<input name="title" type="text" class="wf-100">
|
||||
<input type="submit" value="<?= $this->getText('Save'); ?>">
|
||||
<input type="submit" value="<?= $this->getHtml('Save') ?>">
|
||||
</form>
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -36,9 +36,9 @@ echo $this->getData('nav')->render(); ?>
|
|||
<div class="box wf-100">
|
||||
<div class="tabular">
|
||||
<ul class="tab-links">
|
||||
<li><label for="c-tab-1"><?= $this->getText('Start') ?></label>
|
||||
<li><label for="c-tab-2"><?= $this->getText('Insert') ?></label>
|
||||
<li><label for="c-tab-3"><?= $this->getText('Layout') ?></label>
|
||||
<li><label for="c-tab-1"><?= $this->getHtml('Start'); ?></label>
|
||||
<li><label for="c-tab-2"><?= $this->getHtml('Insert'); ?></label>
|
||||
<li><label for="c-tab-3"><?= $this->getHtml('Layout'); ?></label>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
<input type="radio" id="c-tab-1" name="tabular-1" checked>
|
||||
|
|
@ -99,8 +99,8 @@ echo $this->getData('nav')->render(); ?>
|
|||
<div class="box wf-100">
|
||||
<div class="tabular">
|
||||
<ul class="tab-links">
|
||||
<li><label for="c-tab2-1"><?= $this->getText('Text') ?></label>
|
||||
<li><label for="c-tab2-2"><?= $this->getText('Preview') ?></label>
|
||||
<li><label for="c-tab2-1"><?= $this->getHtml('Text'); ?></label>
|
||||
<li><label for="c-tab2-2"><?= $this->getHtml('Preview'); ?></label>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
<input type="radio" id="c-tab2-1" name="tabular-2" checked>
|
||||
|
|
@ -122,12 +122,12 @@ echo $this->getData('nav')->render(); ?>
|
|||
<div class="inner">
|
||||
<form>
|
||||
<table class="layout">
|
||||
<tr><td colspan="2"><label><?= $this->getText('Permission') ?></label>
|
||||
<tr><td colspan="2"><label><?= $this->getHtml('Permission'); ?></label>
|
||||
<tr><td><select>
|
||||
<option>
|
||||
</select>
|
||||
<tr><td colspan="2"><label><?= $this->getText('GroupUser') ?></label>
|
||||
<tr><td><input id="iPermission" name="group" type="text" placeholder=""><td><button><?= $this->getText('Add') ?></button>
|
||||
<tr><td colspan="2"><label><?= $this->getHtml('GroupUser'); ?></label>
|
||||
<tr><td><input id="iPermission" name="group" type="text" placeholder=""><td><button><?= $this->getHtml('Add'); ?></button>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -28,25 +28,25 @@ echo $this->getData('nav')->render(); ?>
|
|||
<div class="col-xs-12">
|
||||
<div class="box wf-100">
|
||||
<table class="table red">
|
||||
<caption><?= $this->getText('Documents'); ?></caption>
|
||||
<caption><?= $this->getHtml('Documents') ?></caption>
|
||||
<thead>
|
||||
<tr>
|
||||
<td class="wf-100"><?= $this->getText('Title'); ?>
|
||||
<td><?= $this->getText('Creator'); ?>
|
||||
<td><?= $this->getText('Created'); ?>
|
||||
<td class="wf-100"><?= $this->getHtml('Title') ?>
|
||||
<td><?= $this->getHtml('Creator') ?>
|
||||
<td><?= $this->getHtml('Created') ?>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="3"><?= $footerView->render(); ?>
|
||||
<td colspan="3"><?= htmlspecialchars($footerView->render(), ENT_COMPAT, 'utf-8'); ?>
|
||||
<tbody>
|
||||
<?php $count = 0; foreach($docs as $key => $value) : $count++;
|
||||
$url = \phpOMS\Uri\UriFactory::build('{/base}/{/lang}/backend/editor/single?{?}&id=' . $value->getId()); ?>
|
||||
<tr data-href="<?= $url; ?>">
|
||||
<td><a href="<?= $url; ?>"><?= $value->getTitle(); ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= $value->getCreatedBy()->getName1(); ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= $value->getCreatedAt()->format('Y-m-d H:i:s'); ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= htmlspecialchars($value->getTitle(), ENT_COMPAT, 'utf-8'); ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= htmlspecialchars($value->getCreatedBy()->getName1(), ENT_COMPAT, 'utf-8'); ?></a>
|
||||
<td><a href="<?= $url; ?>"><?= htmlspecialchars($value->getCreatedAt()->format('Y-m-d H:i:s'), ENT_COMPAT, 'utf-8'); ?></a>
|
||||
<?php endforeach; ?>
|
||||
<?php if($count === 0) : ?>
|
||||
<tr><td colspan="5" class="empty"><?= $this->getText('Empty', 0, 0); ?>
|
||||
<tr><td colspan="5" class="empty"><?= $this->getHtml('Empty', 0, 0); ?>
|
||||
<?php endif; ?>
|
||||
</table>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
<?= $this->getData('nav')->render(); ?>
|
||||
<?= htmlspecialchars($this->getData('nav')->render(), ENT_COMPAT, 'utf-8'); ?>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
|
|
|
|||
|
|
@ -45,19 +45,19 @@ $doc = $this->getData('doc') ?? null;
|
|||
<div class="box wf-100">
|
||||
<div class="tabular">
|
||||
<ul class="tab-links">
|
||||
<li><label for="c-tab-1"><?= $this->getText('Text') ?></label>
|
||||
<li><label for="c-tab-2"><?= $this->getText('Preview') ?></label>
|
||||
<li><label for="c-tab-1"><?= $this->getHtml('Text'); ?></label>
|
||||
<li><label for="c-tab-2"><?= $this->getHtml('Preview'); ?></label>
|
||||
</ul>
|
||||
<div class="tab-content">
|
||||
<input type="radio" id="c-tab-1" name="tabular-1" checked>
|
||||
|
||||
<div class="tab">
|
||||
<textarea style="height: 300px" placeholder="" name="plain" form="docForm"><?= isset($doc) ? $doc->getPlain() : ''; ?></textarea><input type="hidden" id="iParsed" name="parsed">
|
||||
<textarea style="height: 300px" placeholder="" name="plain" form="docForm"><?= htmlspecialchars(isset($doc) ? $doc->getPlain() : '', ENT_COMPAT, 'utf-8'); ?></textarea><input type="hidden" id="iParsed" name="parsed">
|
||||
</div>
|
||||
<input type="radio" id="c-tab-2" name="tabular-1">
|
||||
|
||||
<div class="tab">
|
||||
<?= isset($doc) ? $doc->getContent() : ''; ?>
|
||||
<?= htmlspecialchars(isset($doc) ? $doc->getContent() : '', ENT_COMPAT, 'utf-8'); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user