- send status code 403 when attempt to enter a comment, but comments are disabled

- added trigger wether we should increment hit count

git-svn-id: http://piwigo.org/svn/branches/branch-1_7@2154 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
rvelices
2007-10-29 23:10:31 +00:00
parent eab34bed9c
commit 56a533f3cb
2 changed files with 13 additions and 6 deletions
+5 -2
View File
@@ -244,13 +244,16 @@ DELETE FROM '.COMMENTS_TABLE.'
}
// incrementation of the number of hits, we do this only if no action
$query = '
if (trigger_event('allow_increment_element_hit_count', !isset($_POST['content']) ) )
{
$query = '
UPDATE
'.IMAGES_TABLE.'
SET hit = hit+1
WHERE id = '.$page['image_id'].'
;';
pwg_query($query);
pwg_query($query);
}
//---------------------------------------------------------- related categories
$query = '