Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrading af-php-wordpress to WordPress 3.5.1 #4

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion readme.html
Original file line number Diff line number Diff line change
Expand Up @@ -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.4.2
<br /> Version 3.5.1
</h1>
<p style="text-align: center">Semantic Personal Publishing Platform</p>

Expand Down
20 changes: 19 additions & 1 deletion wp-activate.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
<?php
/**
* Confirms that the activation key that is sent in an email after a user signs
* up for a new blog matches the key for that user and then displays confirmation.
*
* @package WordPress
*/

/** Define ABSPATH as this file's directory */
define( 'WP_INSTALLING', true );

/** Sets up the WordPress Environment. */
Expand All @@ -16,11 +24,21 @@

do_action( 'activate_header' );

/**
* Adds an action hook specific to this page that fires on wp_head
*
* @since MU
*/
function do_activate_header() {
do_action( 'activate_wp_head' );
}
add_action( 'wp_head', 'do_activate_header' );

/**
* Loads styles specific to this page.
*
* @since MU
*/
function wpmu_activate_stylesheet() {
?>
<style type="text/css">
Expand Down Expand Up @@ -77,7 +95,7 @@ function wpmu_activate_stylesheet() {
} else {
extract($result);
$url = get_blogaddress_by_id( (int) $blog_id);
$user = new WP_User( (int) $user_id);
$user = get_userdata( (int) $user_id);
?>
<h2><?php _e('Your account is now active!'); ?></h2>

Expand Down
109 changes: 52 additions & 57 deletions wp-admin/about.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

<h1><?php printf( __( 'Welcome to WordPress %s' ), $display_version ); ?></h1>

<div class="about-text"><?php printf( __( 'Thank you for updating to the latest version! WordPress %s is already making your website better, faster, and more attractive, just like you!' ), $display_version ); ?></div>
<div class="about-text"><?php printf( __( 'Thank you for updating to the latest version! WordPress %s is more polished and enjoyable than ever before. We hope you like it.' ), $display_version ); ?></div>

<div class="wp-badge"><?php printf( __( 'Version %s' ), $display_version ); ?></div>

Expand All @@ -34,100 +34,95 @@
</h2>

<div class="changelog point-releases">
<h3><?php echo _n( 'Maintenance and Security Release', 'Maintenance and Security Releases', 2 ); ?></h3>
<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.', 20 ), '3.4.2', number_format_i18n( 20 ) ); ?>
<?php printf( __( 'For more information, see <a href="%s">the release notes</a>.' ), 'http://codex.wordpress.org/Version_3.4.2' ); ?>
</p>

<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.', 21 ), '3.4.1', number_format_i18n( 21 ) ); ?>
<?php printf( __( 'For more information, see <a href="%s">the release notes</a>.' ), 'http://codex.wordpress.org/Version_3.4.1' ); ?>
'<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bugs.', 37 ), '3.5.1', number_format_i18n( 37 ) ); ?>
<?php printf( __( 'For more information, see <a href="%s">the release notes</a>.' ), 'http://codex.wordpress.org/Version_3.5.1' ); ?>
</p>
</div>

<div class="changelog">
<h3><?php _e( 'Live Theme Previews' ); ?></h3>
<h3><?php _e( 'New Media Manager' ); ?></h3>

<div class="feature-section images-stagger-right">
<img src="<?php echo esc_url( admin_url( 'images/screenshots/theme-customizer.png' ) ); ?>" class="image-50" />
<h4><?php _e( 'Try on New Themes' ); ?></h4>
<p><?php _e( 'Gone are the days of rushing to update your header, background, and the like as soon as you activate a new theme. You can now customize these options <strong>before</strong> activating a new theme. Note: this feature is available for installed themes only.' ); ?></p>
<div class="feature-section col two-col">
<img alt="" src="<?php echo esc_url( admin_url( 'images/screenshots/about-media.png' ) ); ?>" class="image-100" />

<h4><?php _e( 'Customize Current Theme' ); ?></h4>
<p><?php _e( 'Satisfy your curiosity and try on a fresh coat of paint &mdash; you can also use the live preview mode to customize your current theme. Look for the Customize link on the Themes screen.' ); ?></p>
<div>
<h4><?php _e( 'Beautiful Interface' ); ?></h4>
<p><?php _e( 'Adding media has been streamlined with an all-new experience, making it a breeze to upload files and place them into your posts.' ); ?></p>
</div>
<div class="last-feature">
<h4><?php _e( 'Picturesque Galleries' ); ?></h4>
<p><?php _e( 'Creating image galleries is faster with drag and drop reordering, inline caption editing, and simplified controls for layout.' ); ?></p>
</div>
</div>
</div>

<div class="changelog">
<h3><?php _e( 'Custom Headers' ); ?></h3>

<div class="feature-section">
<h4><?php _e( 'Flexible Sizes' ); ?></h4>
<p><?php _e( 'You can decide for yourself how tall or wide your custom header image should be. From now on, themes will provide a recommended image size for custom headers rather than a fixed requirement. Note: this feature requires <a href="http://codex.wordpress.org/Custom_Headers">theme support</a>.' ); ?></p>
<div class="three-col-images">
<img src="<?php echo esc_url( admin_url( 'images/screenshots/flex-header-1.png' ) ); ?>" class="image-30 first-feature" />
<img src="<?php echo esc_url( admin_url( 'images/screenshots/flex-header-2.png' ) ); ?>" class="image-30" />
<img src="<?php echo esc_url( admin_url( 'images/screenshots/flex-header-3.png' ) ); ?>" class="image-30 last-feature" />
</div>
</div>
<h3><?php _e( 'New Default Theme' ); ?></h3>

<div class="feature-section images-stagger-right">
<img src="<?php echo esc_url( admin_url( 'images/screenshots/flex-header-media-library.png' ) ); ?>" class="image-50" />
<h4><?php _e( 'Choose from Media Library' ); ?></h4>
<p><?php _e( 'Tired of re-uploading the same custom header image every time you check out a new theme? Now you can choose header images from your media library for easier customization.' ); ?></p>
<img alt="" src="<?php echo esc_url( admin_url( 'images/screenshots/about-twenty-twelve.png' ) ); ?>" class="image-66" />
<h4><?php _e( 'Introducing Twenty Twelve' ); ?></h4>
<p><?php _e( 'The newest default theme for WordPress is simple, flexible, and elegant.' ); ?></p>
<p><?php _e( 'What makes it really shine are the design details, like the gorgeous Open Sans typeface and a fully responsive design that looks great on any device.' ); ?></p>
<p><?php _e( 'Naturally, Twenty Twelve supports all the theme features you’ve come to know and love, but it is also designed to be as great for a website as it is for a blog.' ); ?></p>
</div>
</div>

<div class="changelog">
<h3><?php _e( 'Twitter Embeds' ); ?></h3>
<h3><?php _e( 'Retina Ready' ); ?></h3>

<div class="feature-section images-stagger-right">
<img src="<?php echo esc_url( admin_url( 'images/screenshots/twitter-embed-1.png' ) ); ?>" class="image-30" />
<img src="<?php echo esc_url( admin_url( 'images/screenshots/twitter-embed-2.png' ) ); ?>" class="image-30" />
<h4><?php _e( 'Share Tweets with Style' ); ?></h4>
<p><?php _e( 'You can now embed individual tweets in posts. It includes action links that allow readers to reply to, retweet, and favorite the tweet without leaving your site. Just paste a tweet URL on its own line.' ); ?></p>
<p><?php printf( __( 'This works with URLs from some other sites, too. For more, see the Codex article on <a href="%s">Embeds</a>.' ), __( 'http://codex.wordpress.org/Embeds' ) ); ?></p>
<img alt="" src="<?php echo esc_url( admin_url( 'images/screenshots/about-retina.png' ) ); ?>" class="image-66" />
<h4><?php _e( 'So Sharp You Can&#8217;t See the Pixels' ); ?></h4>
<p><?php _e( 'The WordPress dashboard now looks beautiful on high-resolution screens like those found on the iPad, Kindle Fire HD, Nexus 10, and MacBook Pro with Retina Display. Icons and other visual elements are crystal clear and full of detail.' ); ?></p>
</div>

</div>


<div class="changelog">
<h3><?php _e( 'Better Captions' ); ?></h3>
<h3><?php _e( 'Smoother Experience' ); ?></h3>

<div class="feature-section images-stagger-right">
<img src="<?php echo esc_url( admin_url( 'images/screenshots/captions-1.png' ) ); ?>" class="image-30" />
<img src="<?php echo esc_url( admin_url( 'images/screenshots/captions-2.png' ) ); ?>" class="image-30" />
<h4><?php _e( 'HTML Support' ); ?></h4>
<p><?php _e( 'Basic HTML support has been added to the caption field in the image uploader. This allows you to add links &mdash; great for photo credits or licensing details &mdash; and basic formatting such as bold and italicized text.' ); ?></p>
<img alt="" src="<?php echo esc_url( admin_url( 'images/screenshots/about-color-picker.png' ) ); ?>" class="image-30" />
<h4><?php _e( 'Better Accessibility' ); ?></h4>
<p><?php _e( 'WordPress supports more usage modes than ever before. Screenreaders, touch devices, and mouseless workflows all have improved ease of use and accessibility.' ); ?></p>

<h4><?php _e( 'More Polish' ); ?></h4>
<p><?php _e( 'A number of screens and controls have been refined. For example, a new color picker makes it easier for you to choose that perfect shade of blue.' ); ?></p>
</div>
</div>

<div class="changelog">
<h3><?php _e( 'Under the Hood' ); ?></h3>

<div class="feature-section three-col">
<div class="feature-section col three-col">
<div>
<h4><?php _e( 'Faster WP_Query' ); ?></h4>
<p><?php _e( 'Post queries have been optimized to improve performance, especially for sites with large databases.' ); ?></p>

<h4><?php _e( 'Faster Translations' ); ?></h4>
<p><?php _e( 'The number of strings loaded on the front end was greatly reduced, resulting in faster front page load times for localized installations.' ); ?> <?php _e( 'Also, better support for East Asian languages, right-to-left languages, theme translations, and more.' ); ?></p>
<h4><?php _e( 'Meta Query Additions' ); ?></h4>
<p><?php _e( 'The <code>WP_Comment_Query</code> and <code>WP_User_Query</code> classes now support meta queries just like <code>WP_Query.</code> Meta queries now support querying for objects without a particular meta key.' ); ?></p>
</div>
<div>
<h4><?php _e( 'Themes API' ); ?></h4>
<p><?php _e( 'WP_Theme, wp_get_themes(), wp_get_theme(). Faster, uses less memory, makes use of persistent caching.' ); ?></p>

<h4><?php _e( 'Custom Header and Background API' ); ?></h4>
<p><?php _e( 'Custom header and background API relocated into the theme support API.' ); ?></p>
<h4><?php _e( 'Post Objects' ); ?></h4>
<p><?php _e( 'Post objects are now instances of a <code>WP_Post</code> class, which improves performance by loading selected properties on demand.' ); ?></p>
</div>
<div class="last-feature">
<h4><?php _e( 'XML-RPC API' ); ?></h4>
<p><?php printf( __( 'A new <a href="%s">WordPress API</a> that supports custom content types and taxonomies, as well as dozens of other bug fixes and improvements.' ), __( 'http://codex.wordpress.org/XML-RPC_WordPress_API' ) ); ?></p>
<h4><?php _e( 'Image Editing API' ); ?></h4>
<p><?php _e( 'The <code>WP_Image_Editor</code> class abstracts image editing functionality such as cropping and scaling, and uses ImageMagick when available.' ); ?></p>
</div>
</div>

<div class="feature-section col three-col">
<div>
<h4><?php _e( 'Multisite Improvements' ); ?></h4>
<p><?php _e( '<code>switch_to_blog()</code> is now significantly faster and more reliable.' ); ?></p>
</div>
<div>
<h4><?php _e( 'XML-RPC API' ); ?></h4>
<p><?php printf( __( 'The <a href="%s">WordPress API</a> is now always enabled, and supports fetching users, editing profiles, managing post revisions, and searching posts.' ), __( 'http://codex.wordpress.org/XML-RPC_WordPress_API' ) ); ?></p>
</div>
<div class="last-feature">
<h4><?php _e( 'External Libraries' ); ?></h4>
<p><?php _e( 'jQuery, jQuery UI, TinyMCE, Plupload, PHPMailer, SimplePie, and other libraries were updated. jQuery UI Touch Punch was introduced.' ); ?></p>
<p><?php printf( __( 'WordPress now includes the <a href="%1$s">Underscore</a> and <a href="%2$s">Backbone</a> JavaScript libraries. TinyMCE, jQuery, jQuery UI, and SimplePie have all been updated to the latest versions.' ), 'http://underscorejs.org/', 'http://backbonejs.org/' ); ?></p>
</div>
</div>
</div>
Expand Down
14 changes: 10 additions & 4 deletions wp-admin/admin-ajax.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,16 @@
define( 'DOING_AJAX', true );
define( 'WP_ADMIN', true );

/** Load WordPress Bootstrap */
require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' );

/** Allow for cross-domain requests (from the frontend). */
send_origin_headers();

// Require an action parameter
if ( empty( $_REQUEST['action'] ) )
die( '0' );

/** Load WordPress Bootstrap */
require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' );

/** Load WordPress Administration APIs */
require_once( ABSPATH . 'wp-admin/includes/admin.php' );

Expand All @@ -33,6 +36,7 @@
@header( 'X-Robots-Tag: noindex' );

send_nosniff_header();
nocache_headers();

do_action( 'admin_init' );

Expand All @@ -50,7 +54,9 @@
'menu-locations-save', 'menu-quick-search', 'meta-box-order', 'get-permalink',
'sample-permalink', 'inline-save', 'inline-save-tax', 'find_posts', 'widgets-order',
'save-widget', 'set-post-thumbnail', 'date_format', 'time_format', 'wp-fullscreen-save-post',
'wp-remove-post-lock', 'dismiss-wp-pointer', 'upload-attachment',
'wp-remove-post-lock', 'dismiss-wp-pointer', 'upload-attachment', 'get-attachment',
'query-attachments', 'save-attachment', 'save-attachment-compat', 'send-link-to-editor',
'send-attachment-to-editor', 'save-attachment-order',
);

// Register core Ajax calls.
Expand Down
11 changes: 3 additions & 8 deletions wp-admin/admin-footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,12 @@
<div class="clear"></div></div><!-- wpbody -->
<div class="clear"></div></div><!-- wpcontent -->

<div id="footer">
<div id="wpfooter">
<?php do_action( 'in_admin_footer' ); ?>
<p id="footer-left" class="alignleft"><?php
$upgrade = apply_filters( 'update_footer', '' );
$footer_text = array(
'<span id="footer-thankyou">' . __( 'Thank you for creating with <a href="http://wordpress.org/">WordPress</a>.' ) . '</span>',
);
echo apply_filters( 'admin_footer_text', implode( ' &bull; ', $footer_text ) );
unset( $footer_text );
echo apply_filters( 'admin_footer_text', '<span id="footer-thankyou">' . __( 'Thank you for creating with <a href="http://wordpress.org/">WordPress</a>.' ) . '</span>' );
?></p>
<p id="footer-upgrade" class="alignright"><?php echo $upgrade; ?></p>
<p id="footer-upgrade" class="alignright"><?php echo apply_filters( 'update_footer', '' ); ?></p>
<div class="clear"></div>
</div>
<?php
Expand Down
15 changes: 7 additions & 8 deletions wp-admin/admin-header.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,7 @@
?>
<script type="text/javascript">
addLoadEvent = function(func){if(typeof jQuery!="undefined")jQuery(document).ready(func);else if(typeof wpOnload!='function'){wpOnload=func;}else{var oldonload=wpOnload;wpOnload=function(){oldonload();func();}}};
var userSettings = {
'url': '<?php echo SITECOOKIEPATH; ?>',
'uid': '<?php if ( ! isset($current_user) ) $current_user = wp_get_current_user(); echo $current_user->ID; ?>',
'time':'<?php echo time() ?>'
},
ajaxurl = '<?php echo admin_url( 'admin-ajax.php', 'relative' ); ?>',
var ajaxurl = '<?php echo admin_url( 'admin-ajax.php', 'relative' ); ?>',
pagenow = '<?php echo $current_screen->id; ?>',
typenow = '<?php echo $current_screen->post_type; ?>',
adminpage = '<?php echo $admin_body_class; ?>',
Expand All @@ -76,6 +71,9 @@
if ( get_user_setting('mfold') == 'f' )
$admin_body_class .= ' folded';

if ( !get_user_setting('unfold') )
$admin_body_class .= ' auto-fold';

if ( is_admin_bar_showing() )
$admin_body_class .= ' admin-bar';

Expand All @@ -94,7 +92,7 @@

?>
</head>
<body class="wp-admin no-js <?php echo apply_filters( 'admin_body_class', '' ) . " $admin_body_class"; ?>">
<body class="wp-admin wp-core-ui no-js <?php echo apply_filters( 'admin_body_class', '' ) . " $admin_body_class"; ?>">
<script type="text/javascript">
document.body.className = document.body.className.replace('no-js','js');
</script>
Expand All @@ -107,6 +105,7 @@
?>

<div id="wpwrap">
<a tabindex="1" href="#wpbody-content" class="screen-reader-shortcut"><?php _e('Skip to main content'); ?></a>
<?php require(ABSPATH . 'wp-admin/menu-header.php'); ?>
<div id="wpcontent">

Expand All @@ -122,7 +121,7 @@

?>

<div id="wpbody-content">
<div id="wpbody-content" aria-label="<?php esc_attr_e('Main content'); ?>" tabindex="0">
<?php

$current_screen->render_screen_meta();
Expand Down
8 changes: 5 additions & 3 deletions wp-admin/admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@

require_once(dirname(dirname(__FILE__)) . '/wp-load.php');

nocache_headers();

if ( get_option('db_upgraded') ) {
flush_rewrite_rules();
update_option( 'db_upgraded', false );
Expand All @@ -51,6 +53,7 @@
* @since 2.8.4b
*/
$c = get_blog_count();
// If 50 or fewer sites, run every time. Else, run "about ten percent" of the time. Shh, don't check that math.
if ( $c <= 50 || ( $c > 50 && mt_rand( 0, (int)( $c / 50 ) ) == 1 ) ) {
require_once( ABSPATH . WPINC . '/http.php' );
$response = wp_remote_get( admin_url( 'upgrade.php?step=1' ), array( 'timeout' => 120, 'httpversion' => '1.1' ) );
Expand All @@ -65,8 +68,6 @@

auth_redirect();

nocache_headers();

// Schedule trash collection
if ( !wp_next_scheduled('wp_scheduled_delete') && !defined('WP_INSTALLING') )
wp_schedule_event(time(), 'daily', 'wp_scheduled_delete');
Expand All @@ -79,7 +80,6 @@
wp_reset_vars(array('profile', 'redirect', 'redirect_url', 'a', 'text', 'trackback', 'pingback'));

wp_enqueue_script( 'common' );
wp_enqueue_script( 'jquery-color' );

$editing = false;

Expand Down Expand Up @@ -187,6 +187,8 @@
exit;
}

do_action( 'load-importer-' . $importer );

$parent_file = 'tools.php';
$submenu_file = 'import.php';
$title = __('Import');
Expand Down
Loading