for each error retrieved by get_settings_errors().
+ * Part of the Settings API. Outputs a div for each error retrieved by
+ * {@see get_settings_errors()}.
*
- * This is called automatically after a settings page based on the Settings API is submitted.
- * Errors should be added during the validation callback function for a setting defined in register_setting()
+ * This is called automatically after a settings page based on the
+ * Settings API is submitted. Errors should be added during the validation
+ * callback function for a setting defined in {@see register_setting()}
*
- * The $sanitize option is passed into get_settings_errors() and will re-run the setting sanitization
+ * The $sanitize option is passed into {@see get_settings_errors()} and will
+ * re-run the setting sanitization
* on its current value.
*
- * The $hide_on_update option will cause errors to only show when the settings page is first loaded.
- * if the user has already saved new values it will be hidden to avoid repeating messages already
- * shown in the default error reporting after submission. This is useful to show general errors like missing
- * settings when the user arrives at the settings page.
+ * The $hide_on_update option will cause errors to only show when the settings
+ * page is first loaded. if the user has already saved new values it will be
+ * hidden to avoid repeating messages already shown in the default error
+ * reporting after submission. This is useful to show general errors like
+ * missing settings when the user arrives at the settings page.
*
* @since 3.0.0
*
@@ -1262,30 +1444,33 @@ function settings_errors( $setting = '', $sanitize = false, $hide_on_update = fa
*
* @since 2.7.0
*
- * @param unknown_type $found_action
+ * @param string $found_action
*/
function find_posts_div($found_action = '') {
?>
-
-
+
',
- 'uid': 'ID; ?>',
- 'time':''
- },
- ajaxurl = '',
+var ajaxurl = '',
pagenow = 'id; ?>',
typenow = 'post_type; ?>',
adminpage = '',
@@ -1378,18 +1557,39 @@ var userSettings = {
//]]>
- class="wp-admin wp-core-ui no-js iframe ">
+
+ class="wp-admin wp-core-ui no-js iframe ">
@@ -1440,7 +1649,16 @@ function _post_states($post) {
if ( is_sticky($post->ID) )
$post_states['sticky'] = __('Sticky');
- $post_states = apply_filters( 'display_post_states', $post_states );
+ /**
+ * Filter the default post display states used in the Posts list table.
+ *
+ * @since 2.8.0
+ *
+ * @param array $post_states An array of post display states. Values include 'Password protected',
+ * 'Private', 'Draft', 'Pending', and 'Sticky'.
+ * @param int $post The post ID.
+ */
+ $post_states = apply_filters( 'display_post_states', $post_states, $post );
if ( ! empty($post_states) ) {
$state_count = count($post_states);
@@ -1453,8 +1671,6 @@ function _post_states($post) {
}
}
- if ( get_post_format( $post->ID ) )
- echo ' -
' . get_post_format_string( get_post_format( $post->ID ) ) . '';
}
function _media_states( $post ) {
@@ -1473,6 +1689,14 @@ function _media_states( $post ) {
$media_states[] = __( 'Background Image' );
}
+ /**
+ * Filter the default media display states for items in the Media list table.
+ *
+ * @since 3.2.0
+ *
+ * @param array $media_states An array of media states. Default 'Header Image',
+ * 'Background Image'.
+ */
$media_states = apply_filters( 'display_media_states', $media_states );
if ( ! empty( $media_states ) ) {
@@ -1553,21 +1777,26 @@ function compression_test() {
}
/**
- * Echos a submit button, with provided text and appropriate class
+ * Echoes a submit button, with provided text and appropriate class(es).
*
* @since 3.1.0
*
- * @param string $text The text of the button (defaults to 'Save Changes')
- * @param string $type The type of button. One of: primary, secondary, delete
- * @param string $name The HTML name of the submit button. Defaults to "submit". If no id attribute
- * is given in $other_attributes below, $name will be used as the button's id.
- * @param bool $wrap True if the output button should be wrapped in a paragraph tag,
- * false otherwise. Defaults to true
- * @param array|string $other_attributes Other attributes that should be output with the button,
- * mapping attributes to their values, such as array( 'tabindex' => '1' ).
- * These attributes will be output as attribute="value", such as tabindex="1".
- * Defaults to no other attributes. Other attributes can also be provided as a
- * string such as 'tabindex="1"', though the array format is typically cleaner.
+ * @see get_submit_button()
+ *
+ * @param string $text The text of the button (defaults to 'Save Changes')
+ * @param string $type Optional. The type and CSS class(es) of the button. Core values
+ * include 'primary', 'secondary', 'delete'. Default 'primary'
+ * @param string $name The HTML name of the submit button. Defaults to "submit". If no
+ * id attribute is given in $other_attributes below, $name will be
+ * used as the button's id.
+ * @param bool $wrap True if the output button should be wrapped in a paragraph tag,
+ * false otherwise. Defaults to true
+ * @param array|string $other_attributes Other attributes that should be output with the button, mapping
+ * attributes to their values, such as setting tabindex to 1, etc.
+ * These key/value attribute pairs will be output as attribute="value",
+ * where attribute is the key. Other attributes can also be provided
+ * as a string such as 'tabindex="1"', though the array format is
+ * preferred. Default null.
*/
function submit_button( $text = null, $type = 'primary', $name = 'submit', $wrap = true, $other_attributes = null ) {
echo get_submit_button( $text, $type, $name, $wrap, $other_attributes );
@@ -1635,14 +1864,30 @@ function get_submit_button( $text = null, $type = 'primary large', $name = 'subm
}
function _wp_admin_html_begin() {
+ global $is_IE;
+
$admin_html_class = ( is_admin_bar_showing() ) ? 'wp-toolbar' : '';
+
+ if ( $is_IE )
+ @header('X-UA-Compatible: IE=edge');
+
?>
- >
+ >
@@ -1658,8 +1903,8 @@ final class WP_Internal_Pointers {
* All pointers can be disabled using the following:
* remove_action( 'admin_enqueue_scripts', array( 'WP_Internal_Pointers', 'enqueue_scripts' ) );
*
- * Individual pointers (e.g. wp330_toolbar) can be disabled using the following:
- * remove_action( 'admin_print_footer_scripts', array( 'WP_Internal_Pointers', 'pointer_wp330_toolbar' ) );
+ * Individual pointers (e.g. wp390_widgets) can be disabled using the following:
+ * remove_action( 'admin_print_footer_scripts', array( 'WP_Internal_Pointers', 'pointer_wp390_widgets' ) );
*/
public static function enqueue_scripts( $hook_suffix ) {
/*
@@ -1668,12 +1913,11 @@ final class WP_Internal_Pointers {
*/
$registered_pointers = array(
- 'index.php' => 'wp330_toolbar',
- 'post-new.php' => 'wp350_media',
- 'post.php' => 'wp350_media',
- 'themes.php' => array( 'wp330_saving_widgets', 'wp340_customize_current_theme_link' ),
- 'appearance_page_custom-header' => 'wp340_choose_image_from_library',
- 'appearance_page_custom-background' => 'wp340_choose_image_from_library',
+ 'post-new.php' => 'wp410_dfw',
+ 'post.php' => 'wp410_dfw',
+ 'edit.php' => 'wp360_locks',
+ 'widgets.php' => 'wp390_widgets',
+ 'themes.php' => 'wp390_widgets',
);
// Check if screen related pointer is registered
@@ -1683,10 +1927,7 @@ final class WP_Internal_Pointers {
$pointers = (array) $registered_pointers[ $hook_suffix ];
$caps_required = array(
- 'wp330_saving_widgets' => array( 'edit_theme_options', 'switch_themes' ),
- 'wp340_customize_current_theme_link' => array( 'edit_theme_options' ),
- 'wp340_choose_image_from_library' => array( 'edit_theme_options' ),
- 'wp350_media' => array( 'upload_files' ),
+ 'wp390_widgets' => array( 'edit_theme_options' ),
);
// Get dismissed pointers
@@ -1715,7 +1956,7 @@ final class WP_Internal_Pointers {
}
/**
- * Print the pointer javascript data.
+ * Print the pointer JavaScript data.
*
* @since 3.3.0
*
@@ -1731,7 +1972,7 @@ final class WP_Internal_Pointers {