diff options
author | rvelices <rv-github@modusoptimus.com> | 2012-04-02 20:49:46 +0000 |
---|---|---|
committer | rvelices <rv-github@modusoptimus.com> | 2012-04-02 20:49:46 +0000 |
commit | 9c06bb55645c314541fdcff9e9611b38ca0694ac (patch) | |
tree | f1a544171c581cceaedd91b8a73c22ab17516541 /comments.php | |
parent | 9c6f27c0e127ba1d54435ade0045c591da0de65a (diff) |
- comment edit form looks ok now with the new comment layout
- removed unused css / simplify it
- simplified jquery drop boxes ...
git-svn-id: http://piwigo.org/svn/trunk@13865 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r-- | comments.php | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/comments.php b/comments.php index d1f1a27ec..5a7163fd9 100644 --- a/comments.php +++ b/comments.php @@ -206,8 +206,6 @@ foreach ($actions as $loop_action) if (isset($action)) { - check_pwg_token(); - $comment_author_id = get_comment_author_id($comment_id); if (can_manage_comment($action, $comment_author_id)) @@ -216,12 +214,14 @@ if (isset($action)) if ('delete' == $action) { + check_pwg_token(); delete_user_comment($comment_id); $perform_redirect = true; } if ('validate' == $action) { + check_pwg_token(); validate_user_comment($comment_id); $perform_redirect = true; } @@ -230,6 +230,7 @@ if (isset($action)) { if (!empty($_POST['content'])) { + check_pwg_token(); update_user_comment( array( 'comment_id' => $_GET['edit'], @@ -502,8 +503,7 @@ SELECT c.id, name, permalink, uppercats, com.id as comment_id $tpl_comment['U_EDIT'] = add_url_params( $url, array( - 'edit' => $comment['comment_id'], - 'pwg_token' => get_pwg_token(), + 'edit' => $comment['comment_id'] ) ); @@ -514,6 +514,7 @@ SELECT c.id, name, permalink, uppercats, com.id as comment_id $tpl_comment['KEY'] = $key; $tpl_comment['IMAGE_ID'] = $comment['image_id']; $tpl_comment['CONTENT'] = $comment['content']; + $tpl_comment['PWG_TOKEN'] = get_pwg_token(); } } |