mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 09:37:42 +01:00
Strip slashes in the text widget for users without the unfiltered_html capability, props jamescollins, fixes #10563
git-svn-id: http://svn.automattic.com/wordpress/trunk@11794 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
2d4728eb39
commit
f0618619e1
@ -391,7 +391,7 @@ class WP_Widget_Text extends WP_Widget {
|
|||||||
if ( current_user_can('unfiltered_html') )
|
if ( current_user_can('unfiltered_html') )
|
||||||
$instance['text'] = $new_instance['text'];
|
$instance['text'] = $new_instance['text'];
|
||||||
else
|
else
|
||||||
$instance['text'] = wp_filter_post_kses( $new_instance['text'] );
|
$instance['text'] = stripslashes( wp_filter_post_kses( $new_instance['text'] ) );
|
||||||
$instance['filter'] = isset($new_instance['filter']);
|
$instance['filter'] = isset($new_instance['filter']);
|
||||||
return $instance;
|
return $instance;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user