Search code examples
htmlfaviconfullpage.js

favorite icon disappears after changing section on the website


I'm loading my favorite icon like this:

  <link rel="icon" type="image/ico" href="images/logoico.ico">

And I'm using fullpage.js. So when I click a button to go to a different section my url changes from this:

file://localhost/Users/mauriciosanchezduque/Documents/codeMath/index.html

to this:

file://localhost/Users/mauriciosanchezduque/Documents/codeMath/index.html#secondPage

and the favicon disappears. Any idea?


Solution

  • Well... according to the link you provided. When I view the source, I see

    <link rel="icon" href="favicon.ico" type="image/x-icon">
    

    but your favicon is located here: http://54.235.78.67/codeMath/images/logo.ico

    Here your path is wrong and the filename Is also wrong. Try using this:

    <link rel="icon" type="image/ico" href="images/logo.ico">