mirror of
https://github.com/claradex/nativegallery.git
synced 2024-11-15 03:31:10 +03:00
add email directive
This commit is contained in:
parent
7d3cfe163e
commit
820414ae37
4 changed files with 35 additions and 5 deletions
|
@ -14,8 +14,17 @@ class Load
|
||||||
{
|
{
|
||||||
|
|
||||||
$comments = DB::query('SELECT * FROM photos_comments WHERE photo_id=:pid', array(':pid'=>explode('/', $_SERVER['REQUEST_URI'])[4]));
|
$comments = DB::query('SELECT * FROM photos_comments WHERE photo_id=:pid', array(':pid'=>explode('/', $_SERVER['REQUEST_URI'])[4]));
|
||||||
|
$number = 1;
|
||||||
foreach ($comments as $c) {
|
foreach ($comments as $c) {
|
||||||
$comm = new Comment($c);
|
$comm = new Comment($c);
|
||||||
|
|
||||||
|
if ($number % 2 == 0) {
|
||||||
|
$class = 's11';
|
||||||
|
} else {
|
||||||
|
$class = 's1';
|
||||||
|
}
|
||||||
|
$comm->class($class);
|
||||||
|
$number++;
|
||||||
$comm->i();
|
$comm->i();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,7 +48,7 @@ class Comment {
|
||||||
}
|
}
|
||||||
echo '</span></div>
|
echo '</span></div>
|
||||||
<div class="rank">Фото: '.Photo::fetchAll($this->c['user_id']).' '.$admintype.'</div>
|
<div class="rank">Фото: '.Photo::fetchAll($this->c['user_id']).' '.$admintype.'</div>
|
||||||
<div class="message-text">'.htmlspecialchars($this->c['body']).'</div>
|
<div class="message-text">'.preg_replace("~(?:[\p{M}]{1})([\p{M}])+?~uis","", htmlspecialchars($this->c['body'])).'</div>
|
||||||
<div class="comment-votes-block">
|
<div class="comment-votes-block">
|
||||||
<div class="wvote" wid="'.$this->c['id'].'">
|
<div class="wvote" wid="'.$this->c['id'].'">
|
||||||
<a href="#" vote="1" class="w-btn s2"><span>+</span></a>
|
<a href="#" vote="1" class="w-btn s2"><span>+</span></a>
|
||||||
|
|
6
static/js/playerjs.js
Normal file
6
static/js/playerjs.js
Normal file
File diff suppressed because one or more lines are too long
|
@ -239,7 +239,7 @@ if ($photo->i('id') !== null) {
|
||||||
</table>
|
</table>
|
||||||
<table class="vblock coN">
|
<table class="vblock coN">
|
||||||
<?php
|
<?php
|
||||||
$votespos = DB::query('SELECT * FROM photos_rates WHERE photo_id=:pid AND type=0', array(':pid' => $id));
|
$votespos = DB::query('SELECT * FROM photos_rates WHERE photo_id=:pid AND type=0 ORDER BY id DESC', array(':pid' => $id));
|
||||||
foreach ($votespos as $ps) {
|
foreach ($votespos as $ps) {
|
||||||
$uservote = new User($ps['user_id']);
|
$uservote = new User($ps['user_id']);
|
||||||
echo ' <tr>
|
echo ' <tr>
|
||||||
|
@ -454,6 +454,21 @@ if ($photo->i('id') !== null) {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
function errimg() {
|
||||||
|
const content = `<center>
|
||||||
|
<div class="p20 s5" style="border:none; margin:0 -20px; display:none;">
|
||||||
|
<b>Фото потеряно при крахе винчестера</b>
|
||||||
|
<div class="sm" style="margin-top:5px">
|
||||||
|
Если у вас есть это фото, пожалуйста, пришлите его на
|
||||||
|
<a href="mailto:<?=NGALLERY['root']['adminemail']?>?subject=Для восстановления фото <?=$id?>"><?=NGALLERY['root']['adminemail']?></a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</center>`;
|
||||||
|
$('#err').html(content);
|
||||||
|
$('#err .p20').slideDown(500);
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue