From 663c13f39af9e50f59ee907ade4aaf4add0d8d01 Mon Sep 17 00:00:00 2001 From: rvelices Date: Tue, 1 Jun 2010 19:56:07 +0000 Subject: merge r6437 from trunk to branch 2.1 - do not remove slashes before calling insert_user_comment (homogeneity with update_user_comment and general use of slashes in piwigo) - when using a modifier on a non array variable use @| instead of | (generated code is simpler and faster) git-svn-id: http://piwigo.org/svn/branches/2.1@6438 68402e56-0260-453c-a942-63ccdbb3a9ee --- include/picture_comment.inc.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include/picture_comment.inc.php') diff --git a/include/picture_comment.inc.php b/include/picture_comment.inc.php index ac0cd9356..cc4970a34 100644 --- a/include/picture_comment.inc.php +++ b/include/picture_comment.inc.php @@ -46,8 +46,8 @@ if ( $page['show_comments'] and isset( $_POST['content'] ) ) } $comm = array( - 'author' => trim( stripslashes(@$_POST['author']) ), - 'content' => trim( stripslashes($_POST['content']) ), + 'author' => trim( @$_POST['author'] ), + 'content' => trim( $_POST['content'] ), 'image_id' => $page['image_id'], ); @@ -237,7 +237,7 @@ SELECT $content = ''; if ('reject'===@$comment_action) { - $content = htmlspecialchars($comm['content']); + $content = htmlspecialchars( stripslashes($comm['content']) ); } $template->assign('comment_add', array( -- cgit v1.2.3