mirror of
https://github.com/claradex/nativegallery.git
synced 2024-11-15 03:31:10 +03:00
fix xss
This commit is contained in:
parent
7cbb9124fb
commit
ceb737fc40
2 changed files with 5 additions and 6 deletions
|
@ -99,8 +99,7 @@
|
||||||
|
|
||||||
|
|
||||||
function errimg() {
|
function errimg() {
|
||||||
// Create the HTML content
|
const content = `<center>
|
||||||
const content = <center>
|
|
||||||
<div class="p20 s5" style="border:none; margin:0 -20px; display:none;">
|
<div class="p20 s5" style="border:none; margin:0 -20px; display:none;">
|
||||||
<b>Фото потеряно при крахе винчестера</b>
|
<b>Фото потеряно при крахе винчестера</b>
|
||||||
<div class="sm" style="margin-top:5px">
|
<div class="sm" style="margin-top:5px">
|
||||||
|
@ -108,7 +107,7 @@ function errimg() {
|
||||||
<a href="mailto:admin@transphoto.org?subject=Для восстановления фото 651731">admin@transphoto.org</a>
|
<a href="mailto:admin@transphoto.org?subject=Для восстановления фото 651731">admin@transphoto.org</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</center>;
|
</center>`;
|
||||||
$('#err').html(content);
|
$('#err').html(content);
|
||||||
$('#err .p20').slideDown(500);
|
$('#err .p20').slideDown(500);
|
||||||
}
|
}
|
||||||
|
|
|
@ -127,8 +127,8 @@ if ($photo->i('id') !== null) {
|
||||||
<table class="pwrite">
|
<table class="pwrite">
|
||||||
<tr>
|
<tr>
|
||||||
<?php
|
<?php
|
||||||
if ($photo->i('place') != null) { ?>
|
if ($photo->i('postbody') != null) { ?>
|
||||||
<td class="nw" valign="top" align="right"><b><?= $photo->i('postbody') ?></b></td>
|
<td class="nw" valign="top" align="right"><b><?= htmlspecialchars($photo->i('postbody')) ?></b></td>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
<td class="nw" align="left" valign="top"></td>
|
<td class="nw" align="left" valign="top"></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -139,7 +139,7 @@ if ($photo->i('id') !== null) {
|
||||||
<div>
|
<div>
|
||||||
<?php
|
<?php
|
||||||
if ($photo->content('comment') != null) { ?>
|
if ($photo->content('comment') != null) { ?>
|
||||||
<div style="padding-top:8px"><?= $photo->content('comment') ?></div>
|
<div style="padding-top:8px"><?= htmlspecialchars($photo->content('comment')) ?></div>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
</div><br>
|
</div><br>
|
||||||
<?php
|
<?php
|
||||||
|
|
Loading…
Reference in a new issue