Changeset 5127 for trunk/picture.php
- Timestamp:
- Mar 13, 2010, 6:59:14 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/picture.php
r5021 r5127 26 26 include(PHPWG_ROOT_PATH.'include/section_init.inc.php'); 27 27 include_once(PHPWG_ROOT_PATH.'include/functions_picture.inc.php'); 28 include_once(PHPWG_ROOT_PATH.'include/functions_comment.inc.php');29 28 30 29 // Check Access and exit when user status is not ok … … 68 67 access_denied(); 69 68 } 70 list($page['image_id'], $page['image_file']) = $row; 69 70 $page['image_id'] = $row['id']; 71 $page['image_file'] = $row['file']; 71 72 if ( !isset($page['rank_of'][$page['image_id']]) ) 72 73 {// the image can still be non accessible (filter/cat perm) and/or not in the set … … 311 312 case 'edit_comment' : 312 313 { 314 include_once(PHPWG_ROOT_PATH.'include/functions_comment.inc.php'); 313 315 if (isset($_GET['comment_to_edit']) 314 316 and is_numeric($_GET['comment_to_edit']) 315 317 and (is_admin() || $conf['user_can_edit_comment'])) 316 318 { 317 if (!empty($_POST['content'])) 318 319 update_user_comment(array('comment_id' => $_GET['comment_to_edit'], 320 321 322 323 ); 324 325 326 327 328 319 if (!empty($_POST['content'])) 320 { 321 update_user_comment(array('comment_id' => $_GET['comment_to_edit'], 322 'image_id' => $page['image_id'], 323 'content' => $_POST['content']), 324 $_POST['key'] 325 ); 326 redirect($url_self); 327 } else { 328 $edit_comment = $_GET['comment_to_edit']; 329 break; 330 } 329 331 } 330 332 } 331 333 case 'delete_comment' : 332 334 { 335 include_once(PHPWG_ROOT_PATH.'include/functions_comment.inc.php'); 333 336 if (isset($_GET['comment_to_delete']) 334 337 and is_numeric($_GET['comment_to_delete']) 335 338 and (is_admin() || $conf['user_can_delete_comment'])) 336 339 { 337 340 delete_user_comment($_GET['comment_to_delete']); 338 341 } 339 342 redirect($url_self); … … 341 344 case 'validate_comment' : 342 345 { 346 include_once(PHPWG_ROOT_PATH.'include/functions_comment.inc.php'); 343 347 if (isset($_GET['comment_to_validate']) 344 348 and is_numeric($_GET['comment_to_validate'])
Note: See TracChangeset
for help on using the changeset viewer.