Compare commits
31 Commits
3.6
...
3.6-branch
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9d4f26a514 | ||
|
|
ee3487220b | ||
|
|
4dfa2da172 | ||
|
|
9c9324a364 | ||
|
|
96532bc309 | ||
|
|
6a018de1e2 | ||
|
|
1f06608a5e | ||
|
|
18dba66bfb | ||
|
|
a2b1caaaee | ||
|
|
5ea0b8ae86 | ||
|
|
e933603003 | ||
|
|
102e8f6257 | ||
|
|
f6d01839a2 | ||
|
|
0b4b9bfa2b | ||
|
|
85da1c49a1 | ||
|
|
3fe4481673 | ||
|
|
1272cebae4 | ||
|
|
3b4e94c1ac | ||
|
|
54d986e028 | ||
|
|
716fa8d64c | ||
|
|
a09b555bec | ||
|
|
17068d7e86 | ||
|
|
f29ed573de | ||
|
|
06114cd25f | ||
|
|
dd5de4133d | ||
|
|
d9dc2ddbed | ||
|
|
db8fe9a291 | ||
|
|
861f928256 | ||
|
|
fa09261d26 | ||
|
|
5f7f39240d | ||
|
|
c20fb5af65 |
@@ -8,7 +8,7 @@
|
||||
<body>
|
||||
<h1 id="logo">
|
||||
<a href="http://wordpress.org/"><img alt="WordPress" src="wp-admin/images/wordpress-logo.png" /></a>
|
||||
<br /> Version 3.6
|
||||
<br /> Version 3.6.1
|
||||
</h1>
|
||||
<p style="text-align: center">Semantic Personal Publishing Platform</p>
|
||||
|
||||
|
||||
@@ -33,6 +33,14 @@ include( ABSPATH . 'wp-admin/admin-header.php' );
|
||||
</a>
|
||||
</h2>
|
||||
|
||||
<div class="changelog point-releases">
|
||||
<h3><?php echo _n( 'Maintenance and Security Release', 'Maintenance and Security Releases', 1 ); ?></h3>
|
||||
<p><?php printf( _n( '<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bug.',
|
||||
'<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bugs.', 13 ), '3.6.1', number_format_i18n( 13 ) ); ?>
|
||||
<?php printf( __( 'For more information, see <a href="%s">the release notes</a>.' ), 'http://codex.wordpress.org/Version_3.6.1' ); ?>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div class="changelog">
|
||||
<h3><?php _e( 'Colorful New Theme' ); ?></h3>
|
||||
|
||||
|
||||
@@ -52,8 +52,7 @@ function _wp_translate_postdata( $update = false, $post_data = null ) {
|
||||
if ( isset($post_data['trackback_url']) )
|
||||
$post_data['to_ping'] = $post_data['trackback_url'];
|
||||
|
||||
if ( !isset($post_data['user_ID']) )
|
||||
$post_data['user_ID'] = $GLOBALS['user_ID'];
|
||||
$post_data['user_ID'] = $GLOBALS['user_ID'];
|
||||
|
||||
if (!empty ( $post_data['post_author_override'] ) ) {
|
||||
$post_data['post_author'] = (int) $post_data['post_author_override'];
|
||||
|
||||
@@ -1811,7 +1811,7 @@ final class WP_Internal_Pointers {
|
||||
});
|
||||
|
||||
setup = function() {
|
||||
$('<?php echo $selector; ?>').pointer( options ).pointer('open');
|
||||
$('<?php echo $selector; ?>').first().pointer( options ).pointer('open');
|
||||
};
|
||||
|
||||
if ( options.position && options.position.defer_loading )
|
||||
|
||||
@@ -554,6 +554,10 @@ $_old_files = array(
|
||||
// 3.6
|
||||
'wp-admin/js/revisions-js.php',
|
||||
'wp-admin/images/screenshots',
|
||||
'wp-admin/js/categories.js',
|
||||
'wp-admin/js/categories.min.js',
|
||||
'wp-admin/js/custom-fields.js',
|
||||
'wp-admin/js/custom-fields.min.js',
|
||||
);
|
||||
|
||||
/**
|
||||
|
||||
0
wp-admin/js/categories.min.js
vendored
0
wp-admin/js/categories.min.js
vendored
@@ -185,15 +185,15 @@ $(document).ready( function() {
|
||||
if ( body.hasClass('auto-fold') ) {
|
||||
body.removeClass('auto-fold').removeClass('folded');
|
||||
setUserSetting('unfold', 1);
|
||||
deleteUserSetting('mfold');
|
||||
setUserSetting('mfold', 'o');
|
||||
} else {
|
||||
body.addClass('auto-fold');
|
||||
deleteUserSetting('unfold');
|
||||
setUserSetting('unfold', 0);
|
||||
}
|
||||
} else {
|
||||
if ( body.hasClass('folded') ) {
|
||||
body.removeClass('folded');
|
||||
deleteUserSetting('mfold');
|
||||
setUserSetting('mfold', 'o');
|
||||
} else {
|
||||
body.addClass('folded');
|
||||
setUserSetting('mfold', 'f');
|
||||
|
||||
2
wp-admin/js/common.min.js
vendored
2
wp-admin/js/common.min.js
vendored
File diff suppressed because one or more lines are too long
0
wp-admin/js/custom-fields.min.js
vendored
0
wp-admin/js/custom-fields.min.js
vendored
@@ -300,18 +300,19 @@ switch ( $action ) {
|
||||
// If there are menu items, add them
|
||||
wp_nav_menu_update_menu_items( $nav_menu_selected_id, $nav_menu_selected_title );
|
||||
// Auto-save nav_menu_locations
|
||||
$locations = get_theme_mod( 'nav_menu_locations' );
|
||||
foreach ( (array) $locations as $location => $menu_id ) {
|
||||
$locations = get_nav_menu_locations();
|
||||
foreach ( $locations as $location => $menu_id ) {
|
||||
$locations[ $location ] = $nav_menu_selected_id;
|
||||
break; // There should only be 1
|
||||
}
|
||||
set_theme_mod( 'nav_menu_locations', $locations );
|
||||
}
|
||||
if ( isset( $_REQUEST['use-location'] ) ) {
|
||||
$locations = get_theme_mod( 'nav_menu_locations' );
|
||||
if ( isset( $locations[$_REQUEST['use-location']] ) )
|
||||
$locations[$_REQUEST['use-location']] = $nav_menu_selected_id;
|
||||
set_theme_mod( 'nav_menu_locations', $locations );
|
||||
$locations = get_registered_nav_menus();
|
||||
$menu_locations = get_nav_menu_locations();
|
||||
if ( isset( $locations[ $_REQUEST['use-location'] ] ) )
|
||||
$menu_locations[ $_REQUEST['use-location'] ] = $nav_menu_selected_id;
|
||||
set_theme_mod( 'nav_menu_locations', $menu_locations );
|
||||
}
|
||||
// $messages[] = '<div id="message" class="updated"><p>' . sprintf( __( '<strong>%s</strong> has been created.' ), $nav_menu_selected_title ) . '</p></div>';
|
||||
wp_redirect( admin_url( 'nav-menus.php?menu=' . $_nav_menu_selected_id ) );
|
||||
|
||||
@@ -84,9 +84,12 @@ switch ( $action ) {
|
||||
break;
|
||||
case 'show':
|
||||
default:
|
||||
if ( get_site_option( 'wpmu_upgrade_site' ) != $GLOBALS['wp_db_version'] ) :
|
||||
?>
|
||||
<h3><?php _e( 'Database Upgrade Required' ); ?></h3>
|
||||
<p><?php _e( 'WordPress has been updated! Before we send you on your way, we need to individually upgrade the sites in your network.' ); ?></p>
|
||||
<?php endif; ?>
|
||||
|
||||
<p><?php _e( 'The upgrade process may take a little while, so please be patient.' ); ?></p>
|
||||
<p><a class="button" href="upgrade.php?action=upgrade"><?php _e( 'Upgrade Network' ); ?></a></p>
|
||||
<?php
|
||||
|
||||
@@ -1302,6 +1302,11 @@ class WP_Http_Curl {
|
||||
* @return int
|
||||
*/
|
||||
private function stream_body( $handle, $data ) {
|
||||
if ( function_exists( 'ini_get' ) && ( ini_get( 'mbstring.func_overload' ) & 2 ) && function_exists( 'mb_internal_encoding' ) ) {
|
||||
$mb_encoding = mb_internal_encoding();
|
||||
mb_internal_encoding( 'ISO-8859-1' );
|
||||
}
|
||||
|
||||
if ( $this->max_body_length && ( strlen( $this->body ) + strlen( $data ) ) > $this->max_body_length )
|
||||
$data = substr( $data, 0, ( $this->max_body_length - strlen( $this->body ) ) );
|
||||
|
||||
@@ -1310,7 +1315,12 @@ class WP_Http_Curl {
|
||||
else
|
||||
$this->body .= $data;
|
||||
|
||||
return strlen( $data );
|
||||
$data_length = strlen( $data );
|
||||
|
||||
if ( isset( $mb_encoding ) )
|
||||
mb_internal_encoding( $mb_encoding );
|
||||
|
||||
return $data_length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -1606,6 +1606,7 @@ function comment_form( $args = array(), $post_id = null ) {
|
||||
$user = wp_get_current_user();
|
||||
$user_identity = $user->exists() ? $user->display_name : '';
|
||||
|
||||
$args = wp_parse_args( $args );
|
||||
if ( ! isset( $args['format'] ) )
|
||||
$args['format'] = current_theme_supports( 'html5', 'comment-form' ) ? 'html5' : 'xhtml';
|
||||
|
||||
|
||||
@@ -242,9 +242,10 @@ function maybe_unserialize( $original ) {
|
||||
* @since 2.0.5
|
||||
*
|
||||
* @param mixed $data Value to check to see if was serialized.
|
||||
* @param bool $strict Optional. Whether to be strict about the end of the string. Defaults true.
|
||||
* @return bool False if not serialized and true if it was.
|
||||
*/
|
||||
function is_serialized( $data ) {
|
||||
function is_serialized( $data, $strict = true ) {
|
||||
// if it isn't a string, it isn't serialized
|
||||
if ( ! is_string( $data ) )
|
||||
return false;
|
||||
@@ -256,21 +257,39 @@ function is_serialized( $data ) {
|
||||
return false;
|
||||
if ( ':' !== $data[1] )
|
||||
return false;
|
||||
$lastc = $data[$length-1];
|
||||
if ( ';' !== $lastc && '}' !== $lastc )
|
||||
return false;
|
||||
if ( $strict ) {
|
||||
$lastc = $data[ $length - 1 ];
|
||||
if ( ';' !== $lastc && '}' !== $lastc )
|
||||
return false;
|
||||
} else {
|
||||
$semicolon = strpos( $data, ';' );
|
||||
$brace = strpos( $data, '}' );
|
||||
// Either ; or } must exist.
|
||||
if ( false === $semicolon && false === $brace )
|
||||
return false;
|
||||
// But neither must be in the first X characters.
|
||||
if ( false !== $semicolon && $semicolon < 3 )
|
||||
return false;
|
||||
if ( false !== $brace && $brace < 4 )
|
||||
return false;
|
||||
}
|
||||
$token = $data[0];
|
||||
switch ( $token ) {
|
||||
case 's' :
|
||||
if ( '"' !== $data[$length-2] )
|
||||
if ( $strict ) {
|
||||
if ( '"' !== $data[ $length - 2 ] )
|
||||
return false;
|
||||
} elseif ( false === strpos( $data, '"' ) ) {
|
||||
return false;
|
||||
}
|
||||
case 'a' :
|
||||
case 'O' :
|
||||
return (bool) preg_match( "/^{$token}:[0-9]+:/s", $data );
|
||||
case 'b' :
|
||||
case 'i' :
|
||||
case 'd' :
|
||||
return (bool) preg_match( "/^{$token}:[0-9.E-]+;\$/", $data );
|
||||
$end = $strict ? '$' : '';
|
||||
return (bool) preg_match( "/^{$token}:[0-9.E-]+;$end/", $data );
|
||||
}
|
||||
return false;
|
||||
}
|
||||
@@ -317,7 +336,7 @@ function maybe_serialize( $data ) {
|
||||
|
||||
// Double serialization is required for backward compatibility.
|
||||
// See http://core.trac.wordpress.org/ticket/12930
|
||||
if ( is_serialized( $data ) )
|
||||
if ( is_serialized( $data, false ) )
|
||||
return serialize( $data );
|
||||
|
||||
return $data;
|
||||
@@ -1276,6 +1295,8 @@ function wp_original_referer_field( $echo = true, $jump_back_to = 'current' ) {
|
||||
* @return string|bool False on failure. Referer URL on success.
|
||||
*/
|
||||
function wp_get_referer() {
|
||||
if ( ! function_exists( 'wp_validate_redirect' ) )
|
||||
return false;
|
||||
$ref = false;
|
||||
if ( ! empty( $_REQUEST['_wp_http_referer'] ) )
|
||||
$ref = wp_unslash( $_REQUEST['_wp_http_referer'] );
|
||||
@@ -1283,7 +1304,7 @@ function wp_get_referer() {
|
||||
$ref = wp_unslash( $_SERVER['HTTP_REFERER'] );
|
||||
|
||||
if ( $ref && $ref !== wp_unslash( $_SERVER['REQUEST_URI'] ) )
|
||||
return wp_unslash( $ref );
|
||||
return wp_validate_redirect( $ref, false );
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1297,8 +1318,8 @@ function wp_get_referer() {
|
||||
* @return string|bool False if no original referer or original referer if set.
|
||||
*/
|
||||
function wp_get_original_referer() {
|
||||
if ( !empty( $_REQUEST['_wp_original_http_referer'] ) )
|
||||
return wp_unslash( $_REQUEST['_wp_original_http_referer'] );
|
||||
if ( ! empty( $_REQUEST['_wp_original_http_referer'] ) && function_exists( 'wp_validate_redirect' ) )
|
||||
return wp_validate_redirect( wp_unslash( $_REQUEST['_wp_original_http_referer'] ), false );
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -2006,10 +2027,20 @@ function wp_get_mime_types() {
|
||||
* @uses apply_filters() Calls 'upload_mimes' on returned array
|
||||
* @uses wp_get_upload_mime_types() to fetch the list of mime types
|
||||
*
|
||||
* @param int|WP_User $user Optional. User to check. Defaults to current user.
|
||||
* @return array Array of mime types keyed by the file extension regex corresponding to those types.
|
||||
*/
|
||||
function get_allowed_mime_types() {
|
||||
return apply_filters( 'upload_mimes', wp_get_mime_types() );
|
||||
function get_allowed_mime_types( $user = null ) {
|
||||
$t = wp_get_mime_types();
|
||||
|
||||
unset( $t['swf'], $t['exe'] );
|
||||
if ( function_exists( 'current_user_can' ) )
|
||||
$unfiltered = $user ? user_can( $user, 'unfiltered_html' ) : current_user_can( 'unfiltered_html' );
|
||||
|
||||
if ( empty( $unfiltered ) )
|
||||
unset( $t['htm|html'] );
|
||||
|
||||
return apply_filters( 'upload_mimes', $t, $user );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
1
wp-includes/js/jquery/jquery.js
vendored
1
wp-includes/js/jquery/jquery.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -228,6 +228,16 @@
|
||||
o.content = o.content.replace(/<p>(<br ?\/?>|\u00a0|\uFEFF)?<\/p>/g, '<p> </p>');
|
||||
});
|
||||
|
||||
// Fix bug in iOS Safari where it's impossible to type after a touchstart event on the parent document.
|
||||
// Happens after zooming in or out while the keyboard is open. See #25131.
|
||||
if ( tinymce.isIOS5 ) {
|
||||
ed.onKeyDown.add( function() {
|
||||
if ( document.activeElement == document.body ) {
|
||||
ed.getWin().focus();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
ed.onSaveContent.add(function(ed, o) {
|
||||
// If editor is hidden, we just want the textarea's value to be saved
|
||||
if ( ed.isHidden() )
|
||||
|
||||
Binary file not shown.
@@ -2238,10 +2238,17 @@ function set_url_scheme( $url, $scheme = null ) {
|
||||
$scheme = ( is_ssl() ? 'https' : 'http' );
|
||||
}
|
||||
|
||||
if ( 'relative' == $scheme )
|
||||
$url = preg_replace( '#^.+://[^/]*#', '', $url );
|
||||
else
|
||||
$url = preg_replace( '#^.+://#', $scheme . '://', $url );
|
||||
$url = trim( $url );
|
||||
if ( substr( $url, 0, 2 ) === '//' )
|
||||
$url = 'http:' . $url;
|
||||
|
||||
if ( 'relative' == $scheme ) {
|
||||
$url = ltrim( preg_replace( '#^\w+://[^/]*#', '', $url ) );
|
||||
if ( $url !== '' && $url[0] === '/' )
|
||||
$url = '/' . ltrim($url , "/ \t\n\r\0\x0B" );
|
||||
} else {
|
||||
$url = preg_replace( '#^\w+://#', $scheme . '://', $url );
|
||||
}
|
||||
|
||||
return apply_filters( 'set_url_scheme', $url, $scheme, $orig_scheme );
|
||||
}
|
||||
|
||||
@@ -378,7 +378,10 @@ function is_email_address_unsafe( $user_email ) {
|
||||
$is_email_address_unsafe = false;
|
||||
|
||||
if ( $banned_names && is_array( $banned_names ) ) {
|
||||
list( $email_local_part, $email_domain ) = explode( '@', $user_email );
|
||||
$banned_names = array_map( 'strtolower', $banned_names );
|
||||
$normalized_email = strtolower( $user_email );
|
||||
|
||||
list( $email_local_part, $email_domain ) = explode( '@', $normalized_email );
|
||||
|
||||
foreach ( $banned_names as $banned_domain ) {
|
||||
if ( ! $banned_domain )
|
||||
@@ -390,7 +393,7 @@ function is_email_address_unsafe( $user_email ) {
|
||||
}
|
||||
|
||||
$dotted_domain = ".$banned_domain";
|
||||
if ( $dotted_domain === substr( $user_email, -strlen( $dotted_domain ) ) ) {
|
||||
if ( $dotted_domain === substr( $normalized_email, -strlen( $dotted_domain ) ) ) {
|
||||
$is_email_address_unsafe = true;
|
||||
break;
|
||||
}
|
||||
@@ -898,10 +901,8 @@ function wpmu_create_user( $user_name, $password, $email ) {
|
||||
if ( is_wp_error( $user_id ) )
|
||||
return false;
|
||||
|
||||
$user = new WP_User( $user_id );
|
||||
|
||||
// Newly created users have no roles or caps until they are added to a blog.
|
||||
delete_user_option( $user_id, $user->cap_key );
|
||||
delete_user_option( $user_id, 'capabilities' );
|
||||
delete_user_option( $user_id, 'user_level' );
|
||||
|
||||
do_action( 'wpmu_new_user', $user_id );
|
||||
|
||||
@@ -942,6 +942,7 @@ if ( !function_exists('wp_validate_redirect') ) :
|
||||
* @return string redirect-sanitized URL
|
||||
**/
|
||||
function wp_validate_redirect($location, $default = '') {
|
||||
$location = trim( $location );
|
||||
// browsers will assume 'http' is your protocol, and will obey a redirect to a URL starting with '//'
|
||||
if ( substr($location, 0, 2) == '//' )
|
||||
$location = 'http:' . $location;
|
||||
|
||||
@@ -1428,31 +1428,5 @@ function wp_list_post_revisions( $post_id = 0, $type = 'all' ) {
|
||||
|
||||
echo "<ul class='post-revisions hide-if-no-js'>\n";
|
||||
echo $rows;
|
||||
|
||||
// if the post was previously restored from a revision
|
||||
// show the restore event details
|
||||
if ( $restored_from_meta = get_post_meta( $post->ID, '_post_restored_from', true ) ) {
|
||||
$author = get_user_by( 'id', $restored_from_meta[ 'restored_by_user' ] );
|
||||
/* translators: revision date format, see http://php.net/date */
|
||||
$datef = _x( 'j F, Y @ G:i:s', 'revision date format');
|
||||
$date = date_i18n( $datef, strtotime( $restored_from_meta[ 'restored_time' ] ) );
|
||||
$time_diff = human_time_diff( $restored_from_meta[ 'restored_time' ] ) ;
|
||||
?>
|
||||
<hr />
|
||||
<div id="revisions-meta-restored">
|
||||
<?php
|
||||
printf(
|
||||
/* translators: restored revision details: 1: gravatar image, 2: author name, 3: time ago, 4: date */
|
||||
__( 'Previously restored by %1$s %2$s, %3$s ago (%4$s)' ),
|
||||
get_avatar( $author->ID, 24 ),
|
||||
$author->display_name,
|
||||
$time_diff,
|
||||
$date
|
||||
);
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
echo "</ul>";
|
||||
}
|
||||
|
||||
echo "</ul>";
|
||||
}
|
||||
|
||||
@@ -1264,6 +1264,20 @@ function add_theme_support( $feature ) {
|
||||
$args[0] = array_intersect( $args[0], array_keys( get_post_format_slugs() ) );
|
||||
break;
|
||||
|
||||
case 'html5' :
|
||||
// You can't just pass 'html5', you need to pass an array of types.
|
||||
if ( empty( $args[0] ) ) {
|
||||
$args = array( 0 => array( 'comment-list', 'comment-form', 'search-form' ) );
|
||||
} elseif ( ! is_array( $args[0] ) ) {
|
||||
_doing_it_wrong( "add_theme_support( 'html5' )", 'You need to pass an array of types.', '3.6.1' );
|
||||
return false;
|
||||
}
|
||||
|
||||
// Calling 'html5' again merges, rather than overwrites.
|
||||
if ( isset( $_wp_theme_features['html5'] ) )
|
||||
$args[0] = array_merge( $_wp_theme_features['html5'][0], $args[0] );
|
||||
break;
|
||||
|
||||
case 'custom-header-uploads' :
|
||||
return add_theme_support( 'custom-header', array( 'uploads' => true ) );
|
||||
break;
|
||||
@@ -1547,11 +1561,15 @@ function current_theme_supports( $feature ) {
|
||||
return in_array( $content_type, $_wp_theme_features[$feature][0] );
|
||||
break;
|
||||
|
||||
case 'html5':
|
||||
case 'post-formats':
|
||||
// specific post formats can be registered by passing an array of types to
|
||||
// add_theme_support()
|
||||
$post_format = $args[0];
|
||||
return in_array( $post_format, $_wp_theme_features[$feature][0] );
|
||||
|
||||
// Specific areas of HTML5 support *must* be passed via an array to add_theme_support()
|
||||
|
||||
$type = $args[0];
|
||||
return in_array( $type, $_wp_theme_features[$feature][0] );
|
||||
break;
|
||||
|
||||
case 'custom-header':
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '3.6';
|
||||
$wp_version = '3.6.2-alpha';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
@@ -18,7 +18,7 @@ $wp_db_version = 24448;
|
||||
*
|
||||
* @global string $tinymce_version
|
||||
*/
|
||||
$tinymce_version = '358-24485';
|
||||
$tinymce_version = '358-25336';
|
||||
|
||||
/**
|
||||
* Holds the required PHP version
|
||||
|
||||
Reference in New Issue
Block a user