Changeset 3487 for trunk/comments.php
- Timestamp:
- Jul 1, 2009, 10:43:20 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/comments.php
r3452 r3487 101 101 if (isset($_GET['author']) and !empty($_GET['author'])) 102 102 { 103 $page['where_clauses'][] = 104 'u.'.$conf['user_fields']['username'].' = \''. addslashes($_GET['author']).'\'105 OR author = \''. addslashes($_GET['author']).'\'';103 $page['where_clauses'][] = 104 'u.'.$conf['user_fields']['username'].' = \''.$_GET['author'].'\' 105 OR author = \''.$_GET['author'].'\''; 106 106 } 107 107 … … 167 167 and (is_admin() || $conf['user_can_edit_comment'])) 168 168 { 169 if (!empty($_POST['content'])) 169 if (!empty($_POST['content'])) 170 170 { 171 update_user_comment(array('comment_id' => $_GET['edit'], 171 update_user_comment(array('comment_id' => $_GET['edit'], 172 172 'image_id' => $_POST['image_id'], 173 173 'content' => $_POST['content']), 174 174 $_POST['key'] 175 ); 175 ); 176 176 177 177 $edit_comment = null; 178 178 } 179 else 179 else 180 180 { 181 181 $edit_comment = $_GET['edit']; … … 306 306 , com.validated 307 307 FROM '.IMAGE_CATEGORY_TABLE.' AS ic 308 INNER JOIN '.COMMENTS_TABLE.' AS com 308 INNER JOIN '.COMMENTS_TABLE.' AS com 309 309 ON ic.image_id = com.image_id 310 310 LEFT JOIN '.USERS_TABLE.' AS u … … 375 375 ); 376 376 377 if (!empty($comment['author'])) 377 if (!empty($comment['author'])) 378 378 { 379 379 $author = $comment['author']; … … 398 398 ); 399 399 400 if (can_manage_comment('delete', $comment['author_id'])) 400 if (can_manage_comment('delete', $comment['author_id'])) 401 401 { 402 402 $url = get_root_url().'comments.php' 403 403 .get_query_string_diff(array('delete','validate','edit')); 404 $tpl_comment['U_DELETE'] = 404 $tpl_comment['U_DELETE'] = 405 405 add_url_params($url, 406 406 array('delete'=>$comment['comment_id']) … … 411 411 $url = get_root_url().'comments.php' 412 412 .get_query_string_diff(array('edit', 'delete','validate')); 413 $tpl_comment['U_EDIT'] = 413 $tpl_comment['U_EDIT'] = 414 414 add_url_params($url, 415 415 array('edit'=>$comment['comment_id']) 416 416 ); 417 if (isset($edit_comment) and ($comment['comment_id'] == $edit_comment)) 417 if (isset($edit_comment) and ($comment['comment_id'] == $edit_comment)) 418 418 { 419 419 $tpl_comment['IN_EDIT'] = true; … … 427 427 if ( is_admin() && $comment['validated'] != 'true') 428 428 { 429 $tpl_comment['U_VALIDATE'] = 429 $tpl_comment['U_VALIDATE'] = 430 430 add_url_params($url, 431 431 array('validate'=>$comment['comment_id'])
Note: See TracChangeset
for help on using the changeset viewer.