Файл: 2/3020.ru/modules/guestbook/plugins/comments_delete.php
Строк: 8
<?php
IF (GET('comment_delete') && DB::GET_COLUMN("SELECT COUNT(*) FROM `GUESTBOOK` WHERE `ID` = '".INTVAL(GET('comment_delete'))."' LIMIT 1") == 1){
DB::GET_SET("DELETE FROM `GUESTBOOK_LIKES` WHERE `COMMENT_ID` = '".INTVAL(GET('comment_delete'))."'");
DB::GET_SET("DELETE FROM `GUESTBOOK` WHERE `ID` = '".INTVAL(GET('comment_delete'))."' LIMIT 1");
DB::GET_SET("DELETE FROM `ATTACHMENTS` WHERE `ID_POST` = '".INTVAL(GET('comment_delete'))."' AND `TYPE_POST` = 'guestbook'");
REDIRECT('/modules/?path=guestbook&page='.$page.'');
}
ECHO "<a href='/modules/?path=guestbook&page=".$page."&comment_delete=".$list['ID']."' class='btn-o'>".ICONS('trash', 12, 'fa-fw')." ".LG('Удл.')."</a>";
?>