It would be desirable to use possibilities of moduls of a forum. If to use SQL - there is a necessity of creation of all authentications...
in editpost.php unit there is a section
PHP Code:
if ($HTTP_POST_VARS['action']=="updatepost") {
....
if (trim($attachmentaction)=="delete") {
$attachmentsql=",attachmentid=0";
$DB_site->query("DELETE FROM attachment WHERE attachmentid=$postinfo[attachmentid]");
updatethreadcount($threadinfo[threadid]);
}
...
How to use the given possibility?