Filter hook 'browse-happy-notice'

in WP Core File wp-admin/includes/dashboard.php at line 1776

View Source

browse-happy-notice

Filter Hook
Description
Filters the notice output for the 'Browse Happy' nag meta box.

Hook Information

File Location wp-admin/includes/dashboard.php View on GitHub
Hook Type Filter
Line Number 1776

Hook Parameters

Type Name Description
string $notice The notice content.
array|false $response An array containing web browser information, or false on failure. See wp_check_browser_version().

Usage Examples

Basic Usage
<?php
// Hook into browse-happy-notice
add_filter('browse-happy-notice', 'my_custom_filter', 10, 2);

function my_custom_filter($notice, $response) {
    // Your custom filtering logic here
    return $notice;
}

Source Code Context

wp-admin/includes/dashboard.php:1776 - How this hook is used in WordPress core
<?php
1771  	 *
1772  	 * @param string      $notice   The notice content.
1773  	 * @param array|false $response An array containing web browser information, or
1774  	 *                              false on failure. See wp_check_browser_version().
1775  	 */
1776  	echo apply_filters( 'browse-happy-notice', $notice, $response ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores
1777  }
1778  
1779  /**
1780   * Adds an additional class to the browser nag if the current version is insecure.
1781   *

PHP Documentation

<?php
/**
	 * Filters the notice output for the 'Browse Happy' nag meta box.
	 *
	 * @since 3.2.0
	 *
	 * @param string      $notice   The notice content.
	 * @param array|false $response An array containing web browser information, or
	 *                              false on failure. See wp_check_browser_version().
	 */
Quick Info
  • Hook Type: Filter
  • Parameters: 2
  • File: wp-admin/includes/dashboard.php
Related Hooks

Related hooks will be displayed here in future updates.