Cut 'em out, move 'em on, trailing whitespace

git-svn-id: http://svn.automattic.com/wordpress/trunk@15116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2010-06-02 20:04:07 +00:00
parent a2b95178e4
commit 17129fb62e
33 changed files with 59 additions and 59 deletions

View File

@ -1115,9 +1115,9 @@ case 'menu-get-metabox' :
'args' => $item, 'args' => $item,
) )
)); ));
$markup = ob_get_clean(); $markup = ob_get_clean();
echo json_encode(array( echo json_encode(array(
'replace-id' => $type . '-' . $item->name, 'replace-id' => $type . '-' . $item->name,
'markup' => $markup, 'markup' => $markup,

View File

@ -694,7 +694,7 @@ function wp_nav_menu_item_post_type_meta_box( $object, $post_type ) {
<ul id="<?php echo $post_type_name; ?>checklist" class="list:<?php echo $post_type_name?> categorychecklist form-no-clear"> <ul id="<?php echo $post_type_name; ?>checklist" class="list:<?php echo $post_type_name?> categorychecklist form-no-clear">
<?php <?php
$args['walker'] = $walker; $args['walker'] = $walker;
// if we're dealing with pages, let's put a checkbox for the front page at the top of the list // if we're dealing with pages, let's put a checkbox for the front page at the top of the list
if ( 'page' == $post_type_name ) { if ( 'page' == $post_type_name ) {
$front_page = 'page' == get_option('show_on_front') ? (int) get_option( 'page_on_front' ) : 0; $front_page = 'page' == get_option('show_on_front') ? (int) get_option( 'page_on_front' ) : 0;
@ -1106,7 +1106,7 @@ function wp_nav_menu_manage_columns() {
); );
} }
/** /**
* Deletes orphaned draft menu items * Deletes orphaned draft menu items
* *
* @access private * @access private

View File

@ -56,7 +56,7 @@ jQuery(document).ready( function($) {
if ( 'pop' == getUserSetting('cats') ) if ( 'pop' == getUserSetting('cats') )
$('a[href="#categories-pop"]').click(); $('a[href="#categories-pop"]').click();
$('#category-add-toggle').click( function() { $('#category-add-toggle').click( function() {
$(this).parents('div:first').toggleClass( 'wp-hidden-children' ); $(this).parents('div:first').toggleClass( 'wp-hidden-children' );
$('#category-tabs a[href="#categories-all"]').click(); $('#category-tabs a[href="#categories-all"]').click();
$('#newcategory').focus(); $('#newcategory').focus();

View File

@ -138,10 +138,10 @@ var wpNavMenu;
listItemDBIDMatch = re.exec( t.attr('name') ), listItemDBIDMatch = re.exec( t.attr('name') ),
listItemDBID = 'undefined' == typeof listItemDBIDMatch[1] ? 0 : parseInt(listItemDBIDMatch[1], 10); listItemDBID = 'undefined' == typeof listItemDBIDMatch[1] ? 0 : parseInt(listItemDBIDMatch[1], 10);
if ( this.className && -1 != this.className.indexOf('add-to-top') ) if ( this.className && -1 != this.className.indexOf('add-to-top') )
processMethod = api.addMenuItemToTop; processMethod = api.addMenuItemToTop;
menuItems[listItemDBID] = t.closest('li').getItemData( 'add-menu-item', listItemDBID ); menuItems[listItemDBID] = t.closest('li').getItemData( 'add-menu-item', listItemDBID );
}); });
// Add the items // Add the items
api.addItemToMenu(menuItems, processMethod, function(){ api.addItemToMenu(menuItems, processMethod, function(){
// Deselect the items and hide the ajax spinner // Deselect the items and hide the ajax spinner
@ -249,7 +249,7 @@ var wpNavMenu;
placeholder: 'sortable-placeholder', placeholder: 'sortable-placeholder',
start: function(e, ui) { start: function(e, ui) {
var height, width, parent, children, maxChildDepth, tempHolder; var height, width, parent, children, maxChildDepth, tempHolder;
// handle placement for rtl orientation // handle placement for rtl orientation
if ( api.isRTL ) if ( api.isRTL )
ui.item[0].style.right = 'auto'; ui.item[0].style.right = 'auto';
@ -622,7 +622,7 @@ var wpNavMenu;
$('#' + e.target.id.replace(/submit-/, '')).addSelectedToMenu( api.addMenuItemToBottom ); $('#' + e.target.id.replace(/submit-/, '')).addSelectedToMenu( api.addMenuItemToBottom );
return false; return false;
} else if ( target.hasClass('page-numbers') ) { } else if ( target.hasClass('page-numbers') ) {
$.post( ajaxurl, e.target.href.replace(/.*\?/, '').replace(/action=([^&]*)/, '') + '&action=menu-get-metabox', $.post( ajaxurl, e.target.href.replace(/.*\?/, '').replace(/action=([^&]*)/, '') + '&action=menu-get-metabox',
function( resp ) { function( resp ) {
if ( -1 == resp.indexOf('replace-id') ) if ( -1 == resp.indexOf('replace-id') )
return; return;
@ -646,7 +646,7 @@ var wpNavMenu;
} }
); );
return false; return false;
} }
}); });
@ -670,7 +670,7 @@ var wpNavMenu;
fixedLeft = fixed.offset().left; fixedLeft = fixed.offset().left;
fixedRight = fixedLeft + fixedWidth; fixedRight = fixedLeft + fixedWidth;
active.makeTabVisible(); active.makeTabVisible();
// Prevent space from building up next to the last tab if there's more to show // Prevent space from building up next to the last tab if there's more to show
if( tabs.last().isTabVisible() ) { if( tabs.last().isTabVisible() ) {
margin = fixed.width() - tabsWidth; margin = fixed.width() - tabsWidth;

View File

@ -315,7 +315,7 @@ jQuery(document).ready( function($) {
$('#' + taxonomy + '-add-toggle').click( function() { $('#' + taxonomy + '-add-toggle').click( function() {
$('#' + taxonomy + '-adder').toggleClass( 'wp-hidden-children' ); $('#' + taxonomy + '-adder').toggleClass( 'wp-hidden-children' );
$('a[href="#' + taxonomy + '-all"]', '#' + taxonomy + '-tabs').click(); $('a[href="#' + taxonomy + '-all"]', '#' + taxonomy + '-tabs').click();
$('#new'+taxonomy).focus(); $('#new'+taxonomy).focus();
return false; return false;
}); });

View File

@ -18,7 +18,7 @@ if ( ! current_user_can( 'manage_network' ) )
$title = __( 'Network Admin' ); $title = __( 'Network Admin' );
$parent_file = 'ms-admin.php'; $parent_file = 'ms-admin.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('Until WordPress 3.0, running multiple sites required using WordPress MU instead of regular WordPress. In version 3.0, these applications have merged. If you are a former MU user, you should be aware of the following changes:') . '</p>' . '<p>' . __('Until WordPress 3.0, running multiple sites required using WordPress MU instead of regular WordPress. In version 3.0, these applications have merged. If you are a former MU user, you should be aware of the following changes:') . '</p>' .
'<ul><li>' . __('Site Admin is now Super Admin (we highly encourage you to get yourself a cape!).') . '</li>' . '<ul><li>' . __('Site Admin is now Super Admin (we highly encourage you to get yourself a cape!).') . '</li>' .
'<li>' . __('Blogs are now called Sites; Site is now called Network.') . '</li></ul>' . '<li>' . __('Blogs are now called Sites; Site is now called Network.') . '</li></ul>' .

View File

@ -18,7 +18,7 @@ if ( ! current_user_can( 'manage_network_options' ) )
$title = __( 'Network Options' ); $title = __( 'Network Options' );
$parent_file = 'ms-admin.php'; $parent_file = 'ms-admin.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen sets and changes options for the network as a whole. The first site is the main site in the network and network options are pulled from that original site&#8217;s options.') . '</p>' . '<p>' . __('This screen sets and changes options for the network as a whole. The first site is the main site in the network and network options are pulled from that original site&#8217;s options.') . '</p>' .
'<p>' . __('Operational settings has fields for the network&#8217;s name, admin email, and whether global terms will be disabled (the default) or maintained across all sites on the network.') . '</p>' . '<p>' . __('Operational settings has fields for the network&#8217;s name, admin email, and whether global terms will be disabled (the default) or maintained across all sites on the network.') . '</p>' .
'<p>' . __('Dashboard Site is an option to give a site to users who do not have a site on the system. Their default role is subscribed but that default can be changed. The Admin Notice Feed can provide a notice on all dashboards of the latest post via RSS or Atom, or provide no such notice if left blank.') . '</p>' . '<p>' . __('Dashboard Site is an option to give a site to users who do not have a site on the system. Their default role is subscribed but that default can be changed. The Admin Notice Feed can provide a notice on all dashboards of the latest post via RSS or Atom, or provide no such notice if left blank.') . '</p>' .

View File

@ -19,7 +19,7 @@ $title = __( 'Sites' );
$parent_file = 'ms-admin.php'; $parent_file = 'ms-admin.php';
if ( isset( $_GET['action'] ) && 'editblog' == $_GET['action'] ) { if ( isset( $_GET['action'] ) && 'editblog' == $_GET['action'] ) {
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('The network admin arrives at this screen to make choices for a given site by clicking on the Edit link on the Sites screen available to them in the Super Admin navigation menu.') . '</p>' . '<p>' . __('The network admin arrives at this screen to make choices for a given site by clicking on the Edit link on the Sites screen available to them in the Super Admin navigation menu.') . '</p>' .
'<p>' . __('This extensive list of options has five modules: Site Info, Site Options, allowing Site Themes for this given site, changing the Site User(s) roles and passwords for that site, Adding a new user, and Miscellaneous Site Actions (upload size limits).') . '</p>' . '<p>' . __('This extensive list of options has five modules: Site Info, Site Options, allowing Site Themes for this given site, changing the Site User(s) roles and passwords for that site, Adding a new user, and Miscellaneous Site Actions (upload size limits).') . '</p>' .
'<p>' . __('Note that some fields in Site Options are grayed out and say Serialized Data. These are stored values in the database which you cannot change from here.') . '</p>' . '<p>' . __('Note that some fields in Site Options are grayed out and say Serialized Data. These are stored values in the database which you cannot change from here.') . '</p>' .
@ -28,7 +28,7 @@ if ( isset( $_GET['action'] ) && 'editblog' == $_GET['action'] ) {
'<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>' '<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>'
); );
} else { } else {
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('Add New takes you farther down on this same page. You can search for a site by Name, ID number, or IP address. Screen Options allows you to choose how many sites to display on one page.') . '</p>' . '<p>' . __('Add New takes you farther down on this same page. You can search for a site by Name, ID number, or IP address. Screen Options allows you to choose how many sites to display on one page.') . '</p>' .
'<p>' . __('This is the main table of all sites on this network. Switch between list and excerpt views by using the icons above the right side of the table.') . '</p>' . '<p>' . __('This is the main table of all sites on this network. Switch between list and excerpt views by using the icons above the right side of the table.') . '</p>' .
'<p>' . __('Hovering over each site reveals seven options (only three for the primary or originating site for the network):') . '</p>' . '<p>' . __('Hovering over each site reveals seven options (only three for the primary or originating site for the network):') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_network_themes' ) )
$title = __( 'Network Themes' ); $title = __( 'Network Themes' );
$parent_file = 'ms-admin.php'; $parent_file = 'ms-admin.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen enables and disables the inclusion of themes available to choose in the Appearance menu for each site. It does not activate or deactivate which theme a site is currently using.') . '</p>' . '<p>' . __('This screen enables and disables the inclusion of themes available to choose in the Appearance menu for each site. It does not activate or deactivate which theme a site is currently using.') . '</p>' .
'<p>' . __('If the network admin disables a theme that is in use, it can still remain selected on that site. If another theme is chosen, the disabled theme will not appear in the site&#8217;s Appearance > Themes screen.') . '</p>' . '<p>' . __('If the network admin disables a theme that is in use, it can still remain selected on that site. If another theme is chosen, the disabled theme will not appear in the site&#8217;s Appearance > Themes screen.') . '</p>' .
'<p>' . __('Themes can be enabled on a site by site basis by the network admin on the Edit Site screen you go to via the Edit hover link on the Sites screen.') . '</p>' . '<p>' . __('Themes can be enabled on a site by site basis by the network admin on the Edit Site screen you go to via the Edit hover link on the Sites screen.') . '</p>' .

View File

@ -17,7 +17,7 @@ require_once( ABSPATH . WPINC . '/http.php' );
$title = __( 'Update Network' ); $title = __( 'Update Network' );
$parent_file = 'ms-admin.php'; $parent_file = 'ms-admin.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('Only use this screen once you have updated to a new version of WordPress through Dashboard > Updates. Clicking the Update Network button will step through each site in the network, five at a time, and make sure any database upgrades are applied.') . '</p>' . '<p>' . __('Only use this screen once you have updated to a new version of WordPress through Dashboard > Updates. Clicking the Update Network button will step through each site in the network, five at a time, and make sure any database upgrades are applied.') . '</p>' .
'<p>' . __('If a version update to core has not happened, clicking this button won&#8217;t affect anything.') . '</p>' . '<p>' . __('If a version update to core has not happened, clicking this button won&#8217;t affect anything.') . '</p>' .
'<p>' . __('If this process fails for any reason, users logging in to their sites will force the same update.') . '</p>' . '<p>' . __('If this process fails for any reason, users logging in to their sites will force the same update.') . '</p>' .

View File

@ -18,7 +18,7 @@ if ( ! current_user_can( 'manage_network_users' ) )
$title = __( 'Users' ); $title = __( 'Users' );
$parent_file = 'ms-admin.php'; $parent_file = 'ms-admin.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This table shows all users across the network and the sites to which they are assigned.') . '</p>' . '<p>' . __('This table shows all users across the network and the sites to which they are assigned.') . '</p>' .
'<p>' . __('Hover over any user on the list to make the edit links appear. The Edit link on the left will take you to his or her Edit User profile page; the Edit link on the right by any site name goes to an Edit Site screen for that site.') . '</p>' . '<p>' . __('Hover over any user on the list to make the edit links appear. The Edit link on the left will take you to his or her Edit User profile page; the Edit link on the right by any site name goes to an Edit Site screen for that site.') . '</p>' .
'<p>' . __('You can also go to the user&#8217;s profile page by clicking on the individual username.') . '</p>' . '<p>' . __('You can also go to the user&#8217;s profile page by clicking on the individual username.') . '</p>' .

View File

@ -38,7 +38,7 @@ if ( 'updateblogsettings' == $action && isset( $_POST['primary_blog'] ) ) {
$title = __( 'My Sites' ); $title = __( 'My Sites' );
$parent_file = 'index.php'; $parent_file = 'index.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen shows an individual user all of their sites in this network, and also allows that user to set a primary site. He or she can use the links under each site to visit either the frontend or the dashboard for that site.') . '</p>' . '<p>' . __('This screen shows an individual user all of their sites in this network, and also allows that user to set a primary site. He or she can use the links under each site to visit either the frontend or the dashboard for that site.') . '</p>' .
'<p>' . __('Up until WordPress version 3.0, what is now called a Multi-site Network had to be installed separately as WordPress MU (multi-user).') . '</p>' . '<p>' . __('Up until WordPress version 3.0, what is now called a Multi-site Network had to be installed separately as WordPress MU (multi-user).') . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .

View File

@ -441,7 +441,7 @@ wp_initial_nav_menu_meta_boxes();
$help = '<p>' . __('This feature is new in version 3.0; to use a custom menu in place of your theme&#8217;s default menus, support for this feature must be registered in the theme&#8217;s functions.php file. If your theme does not support the custom menus feature yet (the new default theme, Twenty Ten, does), you can learn about adding support yourself by following the below link.') . '</p>'; $help = '<p>' . __('This feature is new in version 3.0; to use a custom menu in place of your theme&#8217;s default menus, support for this feature must be registered in the theme&#8217;s functions.php file. If your theme does not support the custom menus feature yet (the new default theme, Twenty Ten, does), you can learn about adding support yourself by following the below link.') . '</p>';
$help .= '<p>' . __('You can create custom menus for your site. These menus may contain links to pages, categories, custom links or other content types (use the Screen Options tab to decide which ones to show on the screen). You can specify a different navigation label for a menu item as well as other attributes. You can create multiple menus. If your theme includes more than one menu, you can choose which custom menu to associate with each. You can also use custom menus in conjunction with the Custom Menus widget.') . '</p>'; $help .= '<p>' . __('You can create custom menus for your site. These menus may contain links to pages, categories, custom links or other content types (use the Screen Options tab to decide which ones to show on the screen). You can specify a different navigation label for a menu item as well as other attributes. You can create multiple menus. If your theme includes more than one menu, you can choose which custom menu to associate with each. You can also use custom menus in conjunction with the Custom Menus widget.') . '</p>';
$help .= '<p>' . __('To create a new custom menu, click on the + tab, give the menu a name, and click Create Menu. Next, add menu items from the appropriate boxes. You&#8217;ll be able to edit the information for each menu item, and can drag and drop to put them in order. You can also drag a menu item a little to the right to make it a submenu, to create menus with hierarchy. You&#8217;ll see when the position of the drop target shifts over to create the nested placement. Don&#8217;t forget to click Save when you&#8217;re finished.') . '</p>'; $help .= '<p>' . __('To create a new custom menu, click on the + tab, give the menu a name, and click Create Menu. Next, add menu items from the appropriate boxes. You&#8217;ll be able to edit the information for each menu item, and can drag and drop to put them in order. You can also drag a menu item a little to the right to make it a submenu, to create menus with hierarchy. You&#8217;ll see when the position of the drop target shifts over to create the nested placement. Don&#8217;t forget to click Save when you&#8217;re finished.') . '</p>';
$help .= '<p><strong>' . __('For more information:') . '</strong></p>'; $help .= '<p><strong>' . __('For more information:') . '</strong></p>';
$help .= '<p>' . __('<a href="http://codex.wordpress.org/Appearance_Menus_SubPanel">Menus Documentation</a>') . '</p>'; $help .= '<p>' . __('<a href="http://codex.wordpress.org/Appearance_Menus_SubPanel">Menus Documentation</a>') . '</p>';
$help .= '<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>'; $help .= '<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>';
@ -565,7 +565,7 @@ require_once( 'admin-header.php' );
</div><!-- END #nav-menu-header --> </div><!-- END #nav-menu-header -->
<div id="post-body"> <div id="post-body">
<div id="post-body-content"> <div id="post-body-content">
<?php <?php
if ( is_nav_menu( $nav_menu_selected_id ) ) : if ( is_nav_menu( $nav_menu_selected_id ) ) :
$edit_markup = wp_get_nav_menu_to_edit( $nav_menu_selected_id ); $edit_markup = wp_get_nav_menu_to_edit( $nav_menu_selected_id );
if ( ! is_wp_error( $edit_markup ) ) : if ( ! is_wp_error( $edit_markup ) ) :
@ -577,7 +577,7 @@ require_once( 'admin-header.php' );
echo '<p>' . __('After you have added your items, drag and drop to put them in the order you want. You can also click each item to reveal additional configuration options.') . '</p>'; echo '<p>' . __('After you have added your items, drag and drop to put them in the order you want. You can also click each item to reveal additional configuration options.') . '</p>';
echo '<p>' . __('When you have finished building your custom menu, make sure you click the Save Menu button.') . '</p>'; echo '<p>' . __('When you have finished building your custom menu, make sure you click the Save Menu button.') . '</p>';
echo '</div>'; echo '</div>';
endif; endif;
?> ?>
</div><!-- /#post-body-content --> </div><!-- /#post-body-content -->
</div><!-- /#post-body --> </div><!-- /#post-body -->

View File

@ -89,7 +89,7 @@ if ( ! network_domain_check() && ( ! defined( 'WP_ALLOW_MULTISITE' ) || ! WP_ALL
$title = __( 'Create a Network of WordPress Sites' ); $title = __( 'Create a Network of WordPress Sites' );
$parent_file = 'tools.php'; $parent_file = 'tools.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen allows you to configure a network as having subdomains (site1.example.com) or subdirectories (example.com/site1). Subdomains require wildcard subdomains to be enabled in Apache and DNS records, if your host allows it.') . '</p>' . '<p>' . __('This screen allows you to configure a network as having subdomains (site1.example.com) or subdirectories (example.com/site1). Subdomains require wildcard subdomains to be enabled in Apache and DNS records, if your host allows it.') . '</p>' .
'<p>' . __('Choose subdomains or subdirectories; this can only be switched afterwards by reconfiguring your install. Fill out the network details, and click install. If this does not work, you may have to add a wildcard DNS record (for subdomains) or change to another setting in Permalinks (for subdirectories).') . '</p>' . '<p>' . __('Choose subdomains or subdirectories; this can only be switched afterwards by reconfiguring your install. Fill out the network details, and click install. If this does not work, you may have to add a wildcard DNS record (for subdomains) or change to another setting in Permalinks (for subdirectories).') . '</p>' .
'<p>' . __('The next screen for Network will give you individually-generated lines of code to add to your wp-config.php and .htaccess files. Make sure the settings of your FTP client make files starting with a dot visible, so that you can find .htaccess; you may have to create this file if it really is not there. Make backup copies of those two files.') . '</p>' . '<p>' . __('The next screen for Network will give you individually-generated lines of code to add to your wp-config.php and .htaccess files. Make sure the settings of your FTP client make files starting with a dot visible, so that you can find .htaccess; you may have to create this file if it really is not there. Make backup copies of those two files.') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_options' ) )
$title = __('Discussion Settings'); $title = __('Discussion Settings');
$parent_file = 'options-general.php'; $parent_file = 'options-general.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen provides many options for controlling the management and display of comments and links to your posts/pages. So many, in fact, they won&#8217;t all fit here! :) Use the documentation link below to get information on what each discussion setting does.') . '</p>' . '<p>' . __('This screen provides many options for controlling the management and display of comments and links to your posts/pages. So many, in fact, they won&#8217;t all fit here! :) Use the documentation link below to get information on what each discussion setting does.') . '</p>' .
'<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' . '<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .

View File

@ -50,7 +50,7 @@ function add_js() {
} }
add_filter('admin_head', 'add_js'); add_filter('admin_head', 'add_js');
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('The fields on this screen determine some of the basics of your site setup.') . '</p>' . '<p>' . __('The fields on this screen determine some of the basics of your site setup.') . '</p>' .
'<p>' . __('Most themes display the site title at the top of every page, in the title bar of the browser, and as the identifying name for syndicated feeds. The tagline is also displayed by many themes.') . '</p>' . '<p>' . __('Most themes display the site title at the top of every page, in the title bar of the browser, and as the identifying name for syndicated feeds. The tagline is also displayed by many themes.') . '</p>' .
'<p>' . __('The WordPress URL and the Site URL can be the same (example.com) or different; for example, having the WordPress core files (example.com/wordpress) in a subdirectory instead of the root directory.') . '</p>' . '<p>' . __('The WordPress URL and the Site URL can be the same (example.com) or different; for example, having the WordPress core files (example.com/wordpress) in a subdirectory instead of the root directory.') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_options' ) )
$title = __('Media Settings'); $title = __('Media Settings');
$parent_file = 'options-general.php'; $parent_file = 'options-general.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('You can set maximum sizes for images inserted into your written content; you can also insert an image as Full Size.') . '</p>' . '<p>' . __('You can set maximum sizes for images inserted into your written content; you can also insert an image as Full Size.') . '</p>' .
'<p>' . __('The Embed option allows you embed a video, image, or other media content into your content automatically by typing the URL (of the web page where the file lives) on its own line when you create your content.') . '</p>' . '<p>' . __('The Embed option allows you embed a video, image, or other media content into your content automatically by typing the URL (of the web page where the file lives) on its own line when you create your content.') . '</p>' .
'<p>' . __('Uploading Options gives you folder and path choices for storing your files in your installation&#8217;s directory.') . '</p>' . '<p>' . __('Uploading Options gives you folder and path choices for storing your files in your installation&#8217;s directory.') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_options' ) )
$title = __('Permalink Settings'); $title = __('Permalink Settings');
$parent_file = 'options-general.php'; $parent_file = 'options-general.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen provides some common options for your default permalinks URL structure.') . '</p>' . '<p>' . __('This screen provides some common options for your default permalinks URL structure.') . '</p>' .
'<p>' . __('If you pick an option other than Default, your general URL path with structure tags, terms surrounded by %, will also appear in the custom structure field and your path can be further modified there.') . '</p>' . '<p>' . __('If you pick an option other than Default, your general URL path with structure tags, terms surrounded by %, will also appear in the custom structure field and your path can be further modified there.') . '</p>' .
'<p>' . __('When you assign multiple categories or tags to a post, only one can show up in the permalink: the lowest numbered category. This applies if your custom structure includes %category% or %tag%.') . '</p>' . '<p>' . __('When you assign multiple categories or tags to a post, only one can show up in the permalink: the lowest numbered category. This applies if your custom structure includes %category% or %tag%.') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_options' ) )
$title = __('Privacy Settings'); $title = __('Privacy Settings');
$parent_file = 'options-general.php'; $parent_file = 'options-general.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('You can choose whether or not your site will be crawled by robots, ping services, and spiders. If you want those services to ignore your site, click the second option here. Note that your privacy is not complete; your site is still visible on the web.') . '</p>' . '<p>' . __('You can choose whether or not your site will be crawled by robots, ping services, and spiders. If you want those services to ignore your site, click the second option here. Note that your privacy is not complete; your site is still visible on the web.') . '</p>' .
'<p>' . __('When this setting is in effect a reminder is shown in the header of these administration screens that says, &#8220;Search Engines Blocked,&#8221; to remind you that your site is not being crawled.') . '</p>' . '<p>' . __('When this setting is in effect a reminder is shown in the header of these administration screens that says, &#8220;Search Engines Blocked,&#8221; to remind you that your site is not being crawled.') . '</p>' .
'<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' . '<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_options' ) )
$title = __( 'Reading Settings' ); $title = __( 'Reading Settings' );
$parent_file = 'options-general.php'; $parent_file = 'options-general.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen contains the settings that affect the display of your content.') . '</p>' . '<p>' . __('This screen contains the settings that affect the display of your content.') . '</p>' .
'<p>' . __('You can choose what&#8217;s displayed on the front page of your site. It can be posts in reverse chronological order (classic blog), or a fixed/static page. To set a static home page, you first need to create two <a href="post-new.php?post_type=page">Pages</a>. One will become the front page, and the other will be where your posts are displayed.') . '</p>' . '<p>' . __('You can choose what&#8217;s displayed on the front page of your site. It can be posts in reverse chronological order (classic blog), or a fixed/static page. To set a static home page, you first need to create two <a href="post-new.php?post_type=page">Pages</a>. One will become the front page, and the other will be where your posts are displayed.') . '</p>' .
'<p>' . __('You can also control the display of your content in RSS feeds, including the maximum numbers of posts to display, whether to show full text or a summary, and the character set encoding.') . '</p>' . '<p>' . __('You can also control the display of your content in RSS feeds, including the maximum numbers of posts to display, whether to show full text or a summary, and the character set encoding.') . '</p>' .

View File

@ -15,7 +15,7 @@ if ( ! current_user_can( 'manage_options' ) )
$title = __('Writing Settings'); $title = __('Writing Settings');
$parent_file = 'options-general.php'; $parent_file = 'options-general.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('You can submit content in several different ways; this screen holds the settings for all of them. The top section controls the editor within these administration screens, while the rest control external publishing methods. For more information on any of these methods, use the documentation links below.') . '</p>' . '<p>' . __('You can submit content in several different ways; this screen holds the settings for all of them. The top section controls the editor within these administration screens, while the rest control external publishing methods. For more information on any of these methods, use the documentation links below.') . '</p>' .
'<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' . '<p>' . __('You must click the Save Changes button at the bottom of the screen for new settings to take effect.') . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .

View File

@ -309,7 +309,7 @@ add_contextual_help($current_screen,
'<p>' . __('Plugins extend and expand the functionality of WordPress. Once a plugin is installed, you may activate it or deactivate it here.') . '</p>' . '<p>' . __('Plugins extend and expand the functionality of WordPress. Once a plugin is installed, you may activate it or deactivate it here.') . '</p>' .
'<p>' . sprintf(__('You can find additional plugins for your site by using the <a href="%1$s">Plugin Browser/Installer</a> functionality or by browsing the <a href="%2$s">WordPress Plugin Directory</a> directly and installing new plugins manually. To manually install a plugin you generally just need to upload the plugin file into your <code>/wp-content/plugins</code> directory. Once a plugin has been installed, you can activate it here.'), 'plugin-install.php', 'http://wordpress.org/extend/plugins/') . '</p>' . '<p>' . sprintf(__('You can find additional plugins for your site by using the <a href="%1$s">Plugin Browser/Installer</a> functionality or by browsing the <a href="%2$s">WordPress Plugin Directory</a> directly and installing new plugins manually. To manually install a plugin you generally just need to upload the plugin file into your <code>/wp-content/plugins</code> directory. Once a plugin has been installed, you can activate it here.'), 'plugin-install.php', 'http://wordpress.org/extend/plugins/') . '</p>' .
'<p>' . __('Most of the time, plugins play nicely with the core of WordPress and with other plugins. Sometimes, though, a plugin&#8217;s code will get in the way of another plugin, causing compatibility issues. If your site starts doing strange things, this may be the problem. Try deactivating all your plugins and re-activating them in various combinations until you isolate which one(s) caused the issue.') . '</p>' . '<p>' . __('Most of the time, plugins play nicely with the core of WordPress and with other plugins. Sometimes, though, a plugin&#8217;s code will get in the way of another plugin, causing compatibility issues. If your site starts doing strange things, this may be the problem. Try deactivating all your plugins and re-activating them in various combinations until you isolate which one(s) caused the issue.') . '</p>' .
'<p>' . sprintf( __('If something goes wrong with a plugin and you can&#8217;t use WordPress, delete or rename that file in the <code>%s</code> directory and it will be automatically deactivated.'), WP_PLUGIN_DIR) . '</p>' . '<p>' . sprintf( __('If something goes wrong with a plugin and you can&#8217;t use WordPress, delete or rename that file in the <code>%s</code> directory and it will be automatically deactivated.'), WP_PLUGIN_DIR) . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .
'<p>' . __('<a href="http://codex.wordpress.org/Managing_Plugins#Plugin_Management">Documentation on Managing Plugins</a>') . '</p>' . '<p>' . __('<a href="http://codex.wordpress.org/Managing_Plugins#Plugin_Management">Documentation on Managing Plugins</a>') . '</p>' .
'<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>' '<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>'

View File

@ -37,7 +37,7 @@ $help = '<p>' . __('Aside from the default theme included with your WordPress in
$help .= '<p>' . __('You can see your active theme at the top of the screen. Below are the other themes you have installed that are not currently in use. You can see what your site would look like with one of these themes by clicking the Preview link. To change themes, click the Activate link.') . '</p>'; $help .= '<p>' . __('You can see your active theme at the top of the screen. Below are the other themes you have installed that are not currently in use. You can see what your site would look like with one of these themes by clicking the Preview link. To change themes, click the Activate link.') . '</p>';
if ( current_user_can('install_themes') ) if ( current_user_can('install_themes') )
$help .= '<p>' . sprintf(__('If you would like to see more themes to choose from, click on the &#8220;Install Themes&#8221; tab and you will be able to browse or search for additional themes from the <a href="%s">WordPress.org theme repository</a>. Themes in the WordPress.org theme repository are designed and developed by third parties, and are licensed under the GNU General Public License, version 2, just like WordPress. Oh, and they&#8217;re free!'), 'http://wordpress.org/extend/themes/') . '</p>'; $help .= '<p>' . sprintf(__('If you would like to see more themes to choose from, click on the &#8220;Install Themes&#8221; tab and you will be able to browse or search for additional themes from the <a href="%s">WordPress.org theme repository</a>. Themes in the WordPress.org theme repository are designed and developed by third parties, and are licensed under the GNU General Public License, version 2, just like WordPress. Oh, and they&#8217;re free!'), 'http://wordpress.org/extend/themes/') . '</p>';
$help .= '<p><strong>' . __('For more information:') . '</strong></p>'; $help .= '<p><strong>' . __('For more information:') . '</strong></p>';
$help .= '<p>' . __('<a href="http://codex.wordpress.org/Using_Themes">Documentation on Using Themes</a>') . '</p>'; $help .= '<p>' . __('<a href="http://codex.wordpress.org/Using_Themes">Documentation on Using Themes</a>') . '</p>';
$help .= '<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>'; $help .= '<p>' . __('<a href="http://wordpress.org/support/">Support Forums</a>') . '</p>';

View File

@ -36,13 +36,13 @@ $parent_file = 'users.php';
// contextual help - choose Help on the top right of admin panel to preview this. // contextual help - choose Help on the top right of admin panel to preview this.
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('Your profile contains information about you (your &#8220;account&#8221;) as well as some personal options related to using WordPress.') . '</p>' . '<p>' . __('Your profile contains information about you (your &#8220;account&#8221;) as well as some personal options related to using WordPress.') . '</p>' .
'<p>' . __('You can change your password, turn on keyboard shortcuts, change the color scheme of your WordPress administration screens, and turn off the WYSIWYG (Visual) editor, among other things.') . '</p>' . '<p>' . __('You can change your password, turn on keyboard shortcuts, change the color scheme of your WordPress administration screens, and turn off the WYSIWYG (Visual) editor, among other things.') . '</p>' .
'<p>' . __('Your username cannot be changed, but you can use other fields to enter your real name or a nickname, and change which name to display on your posts.') . '</p>' . '<p>' . __('Your username cannot be changed, but you can use other fields to enter your real name or a nickname, and change which name to display on your posts.') . '</p>' .
'<p>' . __('Required fields are indicated; the rest are optional. Profile information will only be displayed if your theme is set up to do so.') . '</p>' . '<p>' . __('Required fields are indicated; the rest are optional. Profile information will only be displayed if your theme is set up to do so.') . '</p>' .
'<p>' . __('Remember to click the Update Profile button when you are finished.') . '</p>' . '<p>' . __('Remember to click the Update Profile button when you are finished.') . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .
'<p>' . __('<a target="_blank" href="http://codex.wordpress.org/Users_Your_Profile_SubPanel">Documentation on User Profiles</a>') . '</p>' . '<p>' . __('<a target="_blank" href="http://codex.wordpress.org/Users_Your_Profile_SubPanel">Documentation on User Profiles</a>') . '</p>' .
'<p>' . __('<a target="_blank" href="http://wordpress.org/support/">Support Forums</a>') . '</p>' '<p>' . __('<a target="_blank" href="http://wordpress.org/support/">Support Forums</a>') . '</p>'
); );

View File

@ -108,20 +108,20 @@ if ( isset($_REQUEST['action']) && 'adduser' == $_REQUEST['action'] ) {
$title = __('Add New User'); $title = __('Add New User');
$parent_file = 'users.php'; $parent_file = 'users.php';
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('To add a new user to your site, fill in the form on this screen. If you&#8217;re not sure which role to assign, you can use the link below to review the different roles and their capabilities. Here is a basic overview of roles:') . '</p>' . '<p>' . __('To add a new user to your site, fill in the form on this screen. If you&#8217;re not sure which role to assign, you can use the link below to review the different roles and their capabilities. Here is a basic overview of roles:') . '</p>' .
'<ul>' . '<ul>' .
'<li>' . __('Administrators have access to all the administration features.') . '</li>' . '<li>' . __('Administrators have access to all the administration features.') . '</li>' .
'<li>' . __('Editors can publish posts, manage posts as well as manage other people&#8217;s posts, etc.') . '</li>' . '<li>' . __('Editors can publish posts, manage posts as well as manage other people&#8217;s posts, etc.') . '</li>' .
'<li>' . __('Authors can publish and manage their own posts.') . '</li>' . '<li>' . __('Authors can publish and manage their own posts.') . '</li>' .
'<li>' . __('Contributors can write and manage their posts but not publish posts or upload media files.') . '</li>' . '<li>' . __('Contributors can write and manage their posts but not publish posts or upload media files.') . '</li>' .
'<li>' . __('Subscribers can read comments/comment/receive newsletters, etc.') . '</li>' . '<li>' . __('Subscribers can read comments/comment/receive newsletters, etc.') . '</li>' .
'</ul>' . '</ul>' .
'<p>' . __('You must assign a password to the new user, but don&#8217;t worry; when they log in for the first time they will be prompted to change it. The username, however, cannot be changed.') . '</p>' . '<p>' . __('You must assign a password to the new user, but don&#8217;t worry; when they log in for the first time they will be prompted to change it. The username, however, cannot be changed.') . '</p>' .
'<p>' . __('New users will receive an email letting them know they&#8217;ve been added as a user for your site. By default, this email will also contain their password. Uncheck the box if you do not the password to be included in the welcome email.') . '</p>' . '<p>' . __('New users will receive an email letting them know they&#8217;ve been added as a user for your site. By default, this email will also contain their password. Uncheck the box if you do not the password to be included in the welcome email.') . '</p>' .
'<p>' . __('Remember to click the Add User button at the bottom of this screen when you are finished.') . '</p>' . '<p>' . __('Remember to click the Add User button at the bottom of this screen when you are finished.') . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .
'<p>' . __('<a target="_blank" href="http://codex.wordpress.org/Users_Add_New_SubPanel">Documentation on Adding New Users</a>') . '</p>' . '<p>' . __('<a target="_blank" href="http://codex.wordpress.org/Users_Add_New_SubPanel">Documentation on Adding New Users</a>') . '</p>' .
'<p>' . __('<a target="_blank" href="http://wordpress.org/support/">Support Forums</a>') . '</p>' '<p>' . __('<a target="_blank" href="http://wordpress.org/support/">Support Forums</a>') . '</p>'
); );

View File

@ -21,12 +21,12 @@ $parent_file = 'users.php';
// contextual help - choose Help on the top right of admin panel to preview this. // contextual help - choose Help on the top right of admin panel to preview this.
add_contextual_help($current_screen, add_contextual_help($current_screen,
'<p>' . __('This screen lists all the existing users for your site. Each user has one of five defined roles as set by the site admin: Site Administrator, Editor, Author, Contributor, or Subscriber. Users with roles other than Administrator will see fewer options when they are logged in, based on their role.') . '</p>' . '<p>' . __('This screen lists all the existing users for your site. Each user has one of five defined roles as set by the site admin: Site Administrator, Editor, Author, Contributor, or Subscriber. Users with roles other than Administrator will see fewer options when they are logged in, based on their role.') . '</p>' .
'<p>' . __('You can customize the display of information on this screen as you can on other screens, by using the Screen Options tab and the on-screen filters.') . '</p>' . '<p>' . __('You can customize the display of information on this screen as you can on other screens, by using the Screen Options tab and the on-screen filters.') . '</p>' .
'<p>' . __('To add a new user for your site, click the Add New button at the top of the screen or Add New in the Users menu section.') . '</p>' . '<p>' . __('To add a new user for your site, click the Add New button at the top of the screen or Add New in the Users menu section.') . '</p>' .
'<p><strong>' . __('For more information:') . '</strong></p>' . '<p><strong>' . __('For more information:') . '</strong></p>' .
'<p>' . __('<a target="_blank" href=http://codex.wordpress.org/Users_Authors_and_Users_SubPanel">Documentation on Authors and Users</a>') . '</p>' . '<p>' . __('<a target="_blank" href=http://codex.wordpress.org/Users_Authors_and_Users_SubPanel">Documentation on Authors and Users</a>') . '</p>' .
'<p>' . __('<a target="_blank" href="http://codex.wordpress.org/Roles_and_Capabilities">Roles and Capabilities Descriptions</a>') . '</p>' . '<p>' . __('<a target="_blank" href="http://codex.wordpress.org/Roles_and_Capabilities">Roles and Capabilities Descriptions</a>') . '</p>' .
'<p>' . __('<a target="_blank" href="http://wordpress.org/support/">Support Forums</a>') . '</p>' '<p>' . __('<a target="_blank" href="http://wordpress.org/support/">Support Forums</a>') . '</p>'
); );
$update = $doaction = ''; $update = $doaction = '';

View File

@ -191,7 +191,7 @@ function the_permalink_rss() {
/** /**
* Outputs the link to the comments for the current post in an xml safe way * Outputs the link to the comments for the current post in an xml safe way
* *
* @since 3.0.0 * @since 3.0.0
* @return none * @return none
*/ */

View File

@ -2306,7 +2306,7 @@ function wp_upload_bits( $name, $deprecated, $bits, $time = null ) {
@fwrite( $ifp, $bits ); @fwrite( $ifp, $bits );
fclose( $ifp ); fclose( $ifp );
clearstatcache(); clearstatcache();
// Set correct file permissions // Set correct file permissions
$stat = @ stat( dirname( $new_file ) ); $stat = @ stat( dirname( $new_file ) );
$perms = $stat['mode'] & 0007777; $perms = $stat['mode'] & 0007777;

View File

@ -366,7 +366,7 @@ function load_default_textdomain() {
$locale = get_locale(); $locale = get_locale();
load_textdomain( 'default', WP_LANG_DIR . "/$locale.mo" ); load_textdomain( 'default', WP_LANG_DIR . "/$locale.mo" );
if ( is_multisite() || ( defined( 'WP_NETWORK_ADMIN_PAGE' ) && WP_NETWORK_ADMIN_PAGE ) ) { if ( is_multisite() || ( defined( 'WP_NETWORK_ADMIN_PAGE' ) && WP_NETWORK_ADMIN_PAGE ) ) {
load_textdomain( 'default', WP_LANG_DIR . "/ms-$locale.mo" ); load_textdomain( 'default', WP_LANG_DIR . "/ms-$locale.mo" );
} }

View File

@ -314,9 +314,9 @@ function _wp_menu_item_classes_by_context( &$menu_items ) {
$active_object = $menu_item->object; $active_object = $menu_item->object;
} }
} }
// back-compat with wp_page_menu: add "current_page_parent" to static home page link for any non-page query // back-compat with wp_page_menu: add "current_page_parent" to static home page link for any non-page query
if ( ! empty( $home_page_id ) && 'post_type' == $menu_item->type && empty( $wp_query->is_page ) && $home_page_id == $menu_item->object_id ) if ( ! empty( $home_page_id ) && 'post_type' == $menu_item->type && empty( $wp_query->is_page ) && $home_page_id == $menu_item->object_id )
$classes[] = 'current_page_parent'; $classes[] = 'current_page_parent';
$menu_items[$key]->classes = array_unique( $classes ); $menu_items[$key]->classes = array_unique( $classes );
@ -343,7 +343,7 @@ function _wp_menu_item_classes_by_context( &$menu_items ) {
$classes[] = 'current-menu-parent'; $classes[] = 'current-menu-parent';
if ( in_array( $parent_item->object_id, $active_parent_object_ids ) ) if ( in_array( $parent_item->object_id, $active_parent_object_ids ) )
$classes[] = 'current-' . $active_object . '-parent'; $classes[] = 'current-' . $active_object . '-parent';
if ( 'post_type' == $parent_item->type && 'page' == $parent_item->object ) { if ( 'post_type' == $parent_item->type && 'page' == $parent_item->object ) {
// Back compat classes for pages to match wp_page_menu() // Back compat classes for pages to match wp_page_menu()
if ( in_array('current-menu-parent', $classes) ) if ( in_array('current-menu-parent', $classes) )
@ -351,7 +351,7 @@ function _wp_menu_item_classes_by_context( &$menu_items ) {
if ( in_array('current-menu-ancestor', $classes) ) if ( in_array('current-menu-ancestor', $classes) )
$classes[] = 'current_page_ancestor'; $classes[] = 'current_page_ancestor';
} }
$menu_items[$key]->classes = array_unique( $classes ); $menu_items[$key]->classes = array_unique( $classes );
} }
} }

View File

@ -284,7 +284,7 @@ function wp_update_nav_menu_item( $menu_id = 0, $menu_item_db_id = 0, $menu_item
); );
$args = wp_parse_args( $menu_item_data, $defaults ); $args = wp_parse_args( $menu_item_data, $defaults );
if ( 0 == $menu_id ) { if ( 0 == $menu_id ) {
$args['menu-item-position'] = 1; $args['menu-item-position'] = 1;
} elseif ( 0 == (int) $args['menu-item-position'] ) { } elseif ( 0 == (int) $args['menu-item-position'] ) {
@ -367,13 +367,13 @@ function wp_update_nav_menu_item( $menu_id = 0, $menu_item_db_id = 0, $menu_item
update_post_meta( $menu_item_db_id, '_menu_item_object_id', (int) $args['menu-item-object-id'] ); update_post_meta( $menu_item_db_id, '_menu_item_object_id', (int) $args['menu-item-object-id'] );
update_post_meta( $menu_item_db_id, '_menu_item_object', sanitize_key($args['menu-item-object']) ); update_post_meta( $menu_item_db_id, '_menu_item_object', sanitize_key($args['menu-item-object']) );
update_post_meta( $menu_item_db_id, '_menu_item_target', sanitize_key($args['menu-item-target']) ); update_post_meta( $menu_item_db_id, '_menu_item_target', sanitize_key($args['menu-item-target']) );
$args['menu-item-classes'] = array_map( 'sanitize_html_class', explode( ' ', $args['menu-item-classes'] ) ); $args['menu-item-classes'] = array_map( 'sanitize_html_class', explode( ' ', $args['menu-item-classes'] ) );
$args['menu-item-xfn'] = implode( ' ', array_map( 'sanitize_html_class', explode( ' ', $args['menu-item-xfn'] ) ) ); $args['menu-item-xfn'] = implode( ' ', array_map( 'sanitize_html_class', explode( ' ', $args['menu-item-xfn'] ) ) );
update_post_meta( $menu_item_db_id, '_menu_item_classes', $args['menu-item-classes'] ); update_post_meta( $menu_item_db_id, '_menu_item_classes', $args['menu-item-classes'] );
update_post_meta( $menu_item_db_id, '_menu_item_xfn', $args['menu-item-xfn'] ); update_post_meta( $menu_item_db_id, '_menu_item_xfn', $args['menu-item-xfn'] );
update_post_meta( $menu_item_db_id, '_menu_item_url', esc_url_raw($args['menu-item-url']) ); update_post_meta( $menu_item_db_id, '_menu_item_url', esc_url_raw($args['menu-item-url']) );
if ( 0 == $menu_id ) if ( 0 == $menu_id )
update_post_meta( $menu_item_db_id, '_menu_item_orphaned', time() ); update_post_meta( $menu_item_db_id, '_menu_item_orphaned', time() );
else else

View File

@ -127,7 +127,7 @@ function get_the_title( $id = 0 ) {
* The guid will appear to be a link, but should not be used as an link to the * The guid will appear to be a link, but should not be used as an link to the
* post. The reason you should not use it as a link, is because of moving the * post. The reason you should not use it as a link, is because of moving the
* blog across domains. * blog across domains.
* *
* Url is escaped to make it xml safe * Url is escaped to make it xml safe
* *
* @since 1.5.0 * @since 1.5.0

View File

@ -2395,7 +2395,7 @@ function _pad_term_counts(&$terms, $taxonomy) {
// Get the object and term ids and stick them in a lookup table // Get the object and term ids and stick them in a lookup table
$tax_obj = get_taxonomy($taxonomy); $tax_obj = get_taxonomy($taxonomy);
$object_types = esc_sql($tax_obj->object_type); $object_types = esc_sql($tax_obj->object_type);
$results = $wpdb->get_results("SELECT object_id, term_taxonomy_id FROM $wpdb->term_relationships INNER JOIN $wpdb->posts ON object_id = ID WHERE term_taxonomy_id IN (" . implode(',', array_keys($term_ids)) . ") AND post_type IN ('" . implode("', '", $object_types) . "') AND post_status = 'publish'"); $results = $wpdb->get_results("SELECT object_id, term_taxonomy_id FROM $wpdb->term_relationships INNER JOIN $wpdb->posts ON object_id = ID WHERE term_taxonomy_id IN (" . implode(',', array_keys($term_ids)) . ") AND post_type IN ('" . implode("', '", $object_types) . "') AND post_status = 'publish'");
foreach ( $results as $row ) { foreach ( $results as $row ) {
$id = $term_ids[$row->term_taxonomy_id]; $id = $term_ids[$row->term_taxonomy_id];
$term_items[$id][$row->object_id] = isset($term_items[$id][$row->object_id]) ? ++$term_items[$id][$row->object_id] : 1; $term_items[$id][$row->object_id] = isset($term_items[$id][$row->object_id]) ? ++$term_items[$id][$row->object_id] : 1;