favicon now showing up

If you have put the code in your header.php is the full URL to the Favicon correct? Also check in another browser as Favicons can be heavily cached (so check another machine) I’m assuming the non / page (without home) has the favicon code present on it as well? What is URL?

Problem with favicon in the latest wp

There is basic Favicon functionality built into WP. Go to Theme Customiser > Site Identity and use the ‘Site Icon’. In some cases its better to have custom code in the head, and the above doesn’t work for non WP pages within the site, if thats what you are using. However its worth a try … Read more

How do I add a favicon that only shows during viewing of my plugin’s admin panel?

When you add your admin (sub)page, then you’re (hopfully) using add_*menu_page(). You can simply save its result in a var. This var is the $hook_suffix. Then you can simply add your callback (that adds the favicon) to the admin_head-{$suffix} hook Source Link. As the plugins screenshot shows you, there’re also the load-{$hook_suffix}-hooks Source Link, which … Read more

Set Site Icon programmatically (eg. using `wp cli`)

The ‘official rules’ about site icons are here:https://www.w3.org/TR/html5/links.html#link-type-icon . They provide this example of site icons for several sizes: <link rel=icon href=favicon.png sizes=”16×16″ type=”image/png”> <link rel=icon href=windows.ico sizes=”32×32 48×48″ type=”image/vnd.microsoft.icon”> <link rel=icon href=mac.icns sizes=”128×128 512×512 8192×8192 32768×32768″> <link rel=icon href=iphone.png sizes=”57×57″ type=”image/png”> <link rel=icon href=gnome.svg sizes=”any” type=”image/svg+xml”> The above link also specifies if the ‘link … Read more

Multisite favicon.ico

I hope you are using different theme in each site Just add this code in your header.php file. <link rel=”shortcut icon” href=”https://wordpress.stackexchange.com/questions/25736/<?php bloginfo(“stylesheet_directory’); ?>/favicon.ico” /> Add your favicon in each theme. For favicon in admin area. Add the following function in your function.php file. function admin_favicon() { ?> <link rel=”shortcut icon” href=”https://wordpress.stackexchange.com/questions/25736/<?php bloginfo(“stylesheet_directory’); ?>/favicon.ico” /> … Read more