Strip term name and description before preparing for DB.
git-svn-id: https://develop.svn.wordpress.org/trunk@6294 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
1521b5169b
commit
c66d25830f
@ -1033,6 +1033,7 @@ function wp_insert_term( $term, $taxonomy, $args = array() ) {
|
||||
|
||||
// expected_slashed ($name)
|
||||
$name = stripslashes($name);
|
||||
$description = stripslashes($description);
|
||||
|
||||
if ( empty($slug) )
|
||||
$slug = sanitize_title($name);
|
||||
@ -1242,6 +1243,10 @@ function wp_update_term( $term, $taxonomy, $args = array() ) {
|
||||
$args = sanitize_term($args, $taxonomy, 'db');
|
||||
extract($args, EXTR_SKIP);
|
||||
|
||||
// expected_slashed ($name)
|
||||
$name = stripslashes($name);
|
||||
$description = stripslashes($description);
|
||||
|
||||
$empty_slug = false;
|
||||
if ( empty($slug) ) {
|
||||
$empty_slug = true;
|
||||
|
Loading…
Reference in New Issue
Block a user