Action hook 'do_favicon'

in WP Core File wp-includes/template-loader.php at line 45

View Source

do_favicon

Action Hook
Description
Fired when the template loader determines a favicon.ico request.

Hook Information

File Location wp-includes/template-loader.php View on GitHub
Hook Type Action
Line Number 45

Hook Parameters

This hook doesn't accept any parameters.

Usage Examples

Basic Usage
<?php
// Hook into do_favicon
add_action('do_favicon', 'my_custom_function');

function my_custom_function() {
    // Your custom code here
}

Source Code Context

wp-includes/template-loader.php:45 - How this hook is used in WordPress core
<?php
  40  	/**
  41  	 * Fired when the template loader determines a favicon.ico request.
  42  	 *
  43  	 * @since 5.4.0
  44  	 */
  45  	do_action( 'do_favicon' );
  46  	return;
  47  } elseif ( is_feed() ) {
  48  	do_feed();
  49  	return;
  50  } elseif ( is_trackback() ) {

PHP Documentation

<?php
/**
	 * Fired when the template loader determines a favicon.ico request.
	 *
	 * @since 5.4.0
	 */
Quick Info
  • Hook Type: Action
  • Parameters: 0
  • File: wp-includes/template-loader.php
Related Hooks

Related hooks will be displayed here in future updates.