Navigation
This is archived content. Visit our new forum.
  • Author
    Posts
  • #138470

    Marty S
    Participant

    I looked at ticket 112855 and the answer did not quite seem to fit my goal…I also want to have my custom favicon in my child theme

    The new favicon is my logo, I already have it formatted 16×16 as a .ico …..just need to implement

    The advisement in ticket 112855 was to add code in header/footer php..I do not necessarily need or want to add code script/html/js to the header section, I only want to have a custom favicon.ico in my child theme (UNLESS the header section is the best way of course, I have an open mind 🙂

    SO

    Question 1 > >>> There is an existing favicon.ico (WP Engine Logo) located in wp-content/mu-plugins/wpengine-common/images

    DO I REMOVE IT?

    See SS at this link

    https://app.sugarsync.com/iris/wf/D6184542_90119684_6538349

    You can also view a SS of my child theme folders and files there as well

    How should I proceed?

    Thanks so much
    Marty

    #138624

    Darshana
    Moderator

    Hi there,

    Upload your favicon file to your website first, either through FTP or Media uploader on WordPress. Then get the link/path to your favicon file, for example: http://mywebsite.com/favicon.ico.

    Finally, go to your Customizer > Site Icons > Favicon section and add the path to your favicon file.

    Hope that helps.

    #138806

    Marty S
    Participant

    Thanks much
    BUT
    The question remains from my op

    Question 1 > >>> There is an existing favicon.ico (WP Engine Logo) located in wp-content/mu-plugins/wpengine-common/images

    DO I REMOVE IT?

    ALSO

    I do not use the customizer any more since I have a child theme
    So what code would I add and where in my child theme to reach my favicon goal?
    Is there any benefit to adding favicon code in the child header.php file as was advised in ticket #112855?

    Thanks

    #138903

    Kosher K
    Member

    Hi There,

    The wpengine fav icon is probably use and set as default fav icon when there’s no fav icon set to your install so I think its better not to remove it, You may want to replace the that icon with different image but the same name, but its better to ask assistance from wp engine on that matter as is it not really theme related matters.

    Adding fav icon on a site requires this code below to be added on the inside the head tag

    <link rel="shortcut icon" href="your-icon.ico" />

    You can either place it directly on header.php or you can use your child theme functions.php to add that line inside the head tag

    You just need to add this code below in your child theme functions.php

    add_action('wp_head','my_custom_fav_ico');
    function my_custom_fav_ico() {
     echo '<link rel="shortcut icon" href="your-icon.ico" />';
    }

    Have a great day

    #141037

    Marty S
    Participant

    Thanks so much

    I held my breathe and implemented your instruction, adding yur code into child PHPfunction file/

    It worked nicely!

    Thank You
    Marty

    #141174

    Christopher
    Moderator

    You’re welcome.

    #571139

    alex527
    Participant

    Hey!

    Thanks X, works great, that’s what I needed as well. And @Marty for asking 🙂

    Cheers,
    Alex

    #599110

    Friech
    Moderator

    Glad we could help.

    Cheers!