Skip to content
This repository has been archived by the owner on Sep 16, 2019. It is now read-only.

Title and favicon #576

Closed
ableslayer opened this issue Dec 3, 2015 · 7 comments
Closed

Title and favicon #576

ableslayer opened this issue Dec 3, 2015 · 7 comments

Comments

@ableslayer
Copy link

On the header.php, I cannot find where the <title> is but on the rendered page, the title is there. Where is this inserted. For example I want to have a title like this on my pages: Home - My Site.

Currently, its: Home | My Site.

I'm also wondering why in my attachments page (image.php template), it's not getting the site's favicon like the rest of the pages.

Where do I add this? How do I edit it?

@Aetles
Copy link
Contributor

Aetles commented Dec 3, 2015

The <title> tag was removed from the theme in fbde88f and is now handled by WordPress, as is recommended by WordPress.

@ableslayer
Copy link
Author

Thanks @Aetles. I didn't know that. How about the favicon in the attachment page, you know why it won't display?

@dantahoua
Copy link
Contributor

The favicon on the attachment page (or on the admin page) will only show if it is placed in the root of your website (not in the theme folder)...

@ableslayer
Copy link
Author

Thanks @dantahoua for giving me an idea. However while I was googling wp+root+favicon, I found out that favicons can be inserted in the WP admin area on the site identity via this link - https://make.wordpress.org/core/2015/07/27/site-icon/.

What I did was removed everything that involves favicons / icons in the header and then inserted the image in the customizer. The header looks cleaner and it solved my problem.

@Aetles
Copy link
Contributor

Aetles commented Dec 8, 2015

FoundationPress does not support all the features of the Customizer and site icon is one of those. FoundationsPress has a hard coded path for the favicon, just look at line 18 in header.php:

<link rel="icon" href="<?php echo get_stylesheet_directory_uri(); ?>/assets/images/icons/favicon.ico" type="image/x-icon">

@ableslayer
Copy link
Author

But the favicon appears and my site seems to be working fine now even without those link tags.

I'm still using the FoundationPress based on Foundation 5 (haven't updated to FP6) with the latest version of WP.

So it seems to be supporting it?

EDIT:

Also, the save to home bookmark on the iPhone also seems to be working now. Before, it didn't show the icon on the home button.

@Aetles
Copy link
Contributor

Aetles commented Dec 8, 2015

Yeah, I wasn't totally clear before. Site Icons works without theme support, it says so right on the page that you linked:

Site Icons work out of the box, are theme independent, and don’t require theme support.

But in order for that to work with FoundationPress you have to remove the hard coded favicon support that is currently in header.php, as you did.

IMO FoundationPress should remove those lines and rely on Site Icons instead. (Also, most of what's in cleanup.php should be removed, but that's another story…)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants