Файл: user/wall/file.php
Строк: 6
<?php
$q_f = mysql_query("SELECT * FROM `wall_files` WHERE `id_wall` = '$post[id]'");
while ($file = mysql_fetch_assoc($q_f)) {
if (preg_match('#jpg|jpeg|gif|png#i', $file['ras'])) {
if (isset($user) && $user['level'] > 1) {
echo "<a href = '/wall/delete/$file[id]/' title = 'Удалить файл'><img src = '/wall/files/$file[id]/$file[name].$file[ras]' max-width = '100' height = '100' style = 'margin: 1px;'/></a>";
} else {
echo "<img src = '/wall/files/$file[id]/$file[name].$file[ras]' max-width = '100' height = '100' style = 'margin: 1px;'/>";
}
}
}