Taxonomy: After [36874], rename `$term_id` to `$tag_ID` in `wp-admin/edit-tag-form.php`.
This ensures that no variables changed in the process of introducing `wp-admin/term.php`, improving overall backward compatibility. Props Chouby for initial patch. Fixes #34988. Built from https://develop.svn.wordpress.org/trunk@36969 git-svn-id: http://core.svn.wordpress.org/trunk@36937 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
4497ddfcb2
commit
9462ab0576
|
@ -49,7 +49,7 @@ if ( 'category' == $taxonomy ) {
|
||||||
*/
|
*/
|
||||||
wp_reset_vars( array( 'wp_http_referer' ) );
|
wp_reset_vars( array( 'wp_http_referer' ) );
|
||||||
|
|
||||||
$wp_http_referer = remove_query_arg( array( 'action', 'message', 'term_id' ), $wp_http_referer );
|
$wp_http_referer = remove_query_arg( array( 'action', 'message', 'tag_ID' ), $wp_http_referer );
|
||||||
|
|
||||||
/** Also used by Edit Tags */
|
/** Also used by Edit Tags */
|
||||||
require_once( ABSPATH . 'wp-admin/includes/edit-tag-messages.php' );
|
require_once( ABSPATH . 'wp-admin/includes/edit-tag-messages.php' );
|
||||||
|
@ -96,11 +96,11 @@ do_action( "{$taxonomy}_pre_edit_form", $tag, $taxonomy ); ?>
|
||||||
do_action( "{$taxonomy}_term_edit_form_tag" );
|
do_action( "{$taxonomy}_term_edit_form_tag" );
|
||||||
?>>
|
?>>
|
||||||
<input type="hidden" name="action" value="editedtag"/>
|
<input type="hidden" name="action" value="editedtag"/>
|
||||||
<input type="hidden" name="tag_ID" value="<?php echo esc_attr( $term_id ) ?>"/>
|
<input type="hidden" name="tag_ID" value="<?php echo esc_attr( $tag_ID ) ?>"/>
|
||||||
<input type="hidden" name="taxonomy" value="<?php echo esc_attr( $taxonomy ) ?>"/>
|
<input type="hidden" name="taxonomy" value="<?php echo esc_attr( $taxonomy ) ?>"/>
|
||||||
<?php
|
<?php
|
||||||
wp_original_referer_field( true, 'previous' );
|
wp_original_referer_field( true, 'previous' );
|
||||||
wp_nonce_field( 'update-tag_' . $term_id );
|
wp_nonce_field( 'update-tag_' . $tag_ID );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Fires at the beginning of the Edit Term form.
|
* Fires at the beginning of the Edit Term form.
|
||||||
|
|
|
@ -19,8 +19,8 @@ if ( empty( $_REQUEST['tag_ID'] ) ) {
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
$term_id = absint( $_REQUEST['tag_ID'] );
|
$tag_ID = absint( $_REQUEST['tag_ID'] );
|
||||||
$tag = get_term( $term_id, '', OBJECT, 'edit' );
|
$tag = get_term( $tag_ID, '', OBJECT, 'edit' );
|
||||||
|
|
||||||
if ( ! $tag instanceof WP_Term ) {
|
if ( ! $tag instanceof WP_Term ) {
|
||||||
wp_die( __( 'You attempted to edit an item that doesn’t exist. Perhaps it was deleted?' ) );
|
wp_die( __( 'You attempted to edit an item that doesn’t exist. Perhaps it was deleted?' ) );
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.5-beta3-36968';
|
$wp_version = '4.5-beta3-36969';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue