/ Published in: PHP
Insert a favicon using functions.php
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
/** * Add a Favicon * This prevents you from having to worry about updating your theme and losing your favicon. * */ function add_favicon(){ echo "<link rel='shortcut icon' href='" . get_stylesheet_directory_uri() . "/favicon.ico' />" . "n"; } add_action( 'wp_head', 'add_favicon');