Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 13 of 13
  1. #1
    New Coder
    Join Date
    Apr 2012
    Posts
    32
    Thanks
    20
    Thanked 0 Times in 0 Posts

    Favicons... Sorry....

    hi all, im sure you get this loads, sorry.

    no matter what i try i cant get the darned things to work locally. i google it, try a different piece of code, that doesnt work, try again, and so on.

    given that i have an icon file called favicon.ico and/or a favicon.png in the same directory as my images, html and css,

    any surefire ways to get these to work, please?
    id rather use the png if thats possible

    advice greatly appreciated

    regards,
    redd .

  • #2
    Regular Coder
    Join Date
    Jul 2012
    Location
    London
    Posts
    473
    Thanks
    4
    Thanked 86 Times in 86 Posts
    http://www.convertico.com/

    Add this to your

    Code:
    <head>

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

  • Users who have thanked tempz for this post:

    Redd4 (08-06-2012)

  • #3
    New Coder
    Join Date
    Apr 2012
    Posts
    32
    Thanks
    20
    Thanked 0 Times in 0 Posts
    Tempz, cheers man, but, it didnt work. i copied your code, and also i went to the link and converted the png into yet another .ico,
    just in case i was doing something wrong, but still no banana.

    these damned things. my whole class couldnt figure this out 2 months ago, so its not just that im a dummy

  • #4
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    This version works for me

    Code:
    <link rel="icon" href="images/favicon.ico" type="image/x-icon">
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    Redd4 (08-06-2012)

  • #5
    New Coder
    Join Date
    Apr 2012
    Posts
    32
    Thanks
    20
    Thanked 0 Times in 0 Posts
    Andrew cheers also. tried that too, im afraid it doesnt work.
    im using chrome. ill try it in firefox...

    nope, nor in safari.

    here is my code, i dont have an images folder, all the files are lumped in the one directory. tried it with and without a ./

    <!doctype html>

    <head>

    <meta charset="utf-8">
    <title>Muddy Bit's 4x4</title>
    <link rel=stylesheet type="text/css" href="./muddyStyle.css" />

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

    <style>


    header{
    background-image:url('header.png');
    }

    nav{
    background-image:url('nav.png');
    }

    article{
    background-image:url('article.png');
    }

    footer{
    background-image:url('footer.png');
    }



    </style>

    </head>

  • #6
    New Coder
    Join Date
    Apr 2012
    Posts
    32
    Thanks
    20
    Thanked 0 Times in 0 Posts
    whoa it did work in Firefox, but not in chrome

  • #7
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    Try re-ordering, and quoting "attributes" (i.e. "stylesheet"), and you don't need to close <link>

    Code:
    <meta charset="utf-8">
    <link rel="icon" href="favicon.ico" type="image/x-icon">
    <title>Muddy Bit's 4x4</title>
    <link rel="stylesheet" type="text/css" href="muddyStyle.css">
    
    
    <style type="text/css">
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    Redd4 (08-06-2012)

  • #8
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    .. and perhaps check that your icon is of size 16*16 or 32*32.
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    Redd4 (08-06-2012)

  • #9
    New Coder
    Join Date
    Apr 2012
    Posts
    32
    Thanks
    20
    Thanked 0 Times in 0 Posts
    if nothing else you made my code a bit tidier lol, cheers

    still the same, works in firefox not in chrome. its 16 x 16.

  • #10
    New Coder
    Join Date
    Apr 2012
    Posts
    32
    Thanks
    20
    Thanked 0 Times in 0 Posts
    looks like theyre on the way out.... thats a pity


    http://econsultancy.com/ie/blog/9688...om-address-bar

  • #11
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    If it works it FF then this suggests there is nothing wrong with your code. But if it's going to be dropped then..
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    Redd4 (08-06-2012)

  • #12
    Regular Coder
    Join Date
    Jul 2012
    Location
    London
    Posts
    473
    Thanks
    4
    Thanked 86 Times in 86 Posts
    You have a dot in-front of your location.

  • #13


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •