mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-05 07:58:35 +01:00
Addslashes to user data before inserting in DB.
git-svn-id: http://svn.automattic.com/wordpress/trunk@2231 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
49490ac2ac
commit
65381ba8c5
@ -21,9 +21,9 @@ $comment_content = $_POST['comment'];
|
|||||||
// If the user is logged in
|
// If the user is logged in
|
||||||
get_currentuserinfo();
|
get_currentuserinfo();
|
||||||
if ( $user_ID ) :
|
if ( $user_ID ) :
|
||||||
$comment_author = $user_identity;
|
$comment_author = addslashes($user_identity);
|
||||||
$comment_author_email = $user_email;
|
$comment_author_email = addslashes($user_email);
|
||||||
$comment_author_url = str_replace('http://', '', $user_url);
|
$comment_author_url = addslashes(str_replace('http://', '', $user_url));
|
||||||
else :
|
else :
|
||||||
if ( get_option('comment_registration') )
|
if ( get_option('comment_registration') )
|
||||||
die( __('Sorry, you must be logged in to post a comment.') );
|
die( __('Sorry, you must be logged in to post a comment.') );
|
||||||
|
Loading…
Reference in New Issue
Block a user