dashboard_primary_title
Filters the primary link title for the 'WordPress News' dashboard widget.
Description
Parameters (1)
- 0. $var (string) =>
__( 'WordPress Blog' )
- Title attribute for the widget's primary link.
Usage
- To run the hook, copy the example below.
- $var = apply_filters( 'dashboard_primary_title', $var );
- if ( !empty( $var ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the dashboard_primary_title callback
- function filter_dashboard_primary_title( $var ) {
- // make filter magic happen here...
- return $var;
- };
- // add the filter
- add_filter( 'dashboard_primary_title', 'filter_dashboard_primary_title', 10, 1 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'dashboard_primary_title', 'filter_dashboard_primary_title', 10, 1 );
Defined (1)
The filter is defined in the following location(s).
- /wp-admin/includes/dashboard.php
- 'title' => apply_filters( 'dashboard_primary_title', __( 'WordPress Blog' ) ),