/    Sign up×
Community /Pin to ProfileBookmark

How to put icon by favorits

Hello,

I have read that i have to put:

  • an icon for example ‘logo.ico’ in the root and

  • <link rel=”shortcut icon” href=”logo.ico”> in the head of the page
  • This is my script for the add to function:

    <SCRIPT LANGUAGE=”JavaScript”>

    <!– Begin
    function addbookmark()
    {
    bookmarkurl=”http://www.abc.com
    bookmarktitle=”abc”
    if (document.all)
    window.external.AddFavorite(bookmarkurl,bookmarktitle)
    }
    // End –>
    </script>

    The script works but there is no icon in the favorits.

    Where do i have to put ‘<link rel=”shortcut icon” href=”logo.ico”>’ inside or outside the javascript?

    What did I wrong or forgot something?

    Thanks,
    Johan.

    to post a comment
    JavaScript

    2 Comments(s)

    Copy linkTweet thisAlerts:
    @gil_davisMar 27.2003 — Where do i have to put ... [/quote]In the <HEAD> section, all by itself, and not inside the <SCRIPT> tags.
    Copy linkTweet thisAlerts:
    @JohanvhauthorMar 27.2003 — I have placed '<link rel="shortcut icon" href="maes.ico">'

    in the head after the javascript (see example) on my page.

    The result is the same: add on favorites works but without icon.

    Here is the code I use:

    <!-- Begin

    function addbookmark()

    {

    bookmarkurl="http://www.maeselectronics.be"

    bookmarktitle="Maes Electronics"

    if (document.all)

    window.external.AddFavorite(bookmarkurl,bookmarktitle)

    }

    // End -->

    </script>

    <link rel="shortcut icon" href="maes.ico">

    Has someone an answer please.

    Thanks.
    ×

    Success!

    Help @Johanvh spread the word by sharing this article on Twitter...

    Tweet This
    Sign in
    Forgot password?
    Sign in with TwitchSign in with GithubCreate Account
    about: ({
    version: 0.1.9 BETA 6.18,
    whats_new: community page,
    up_next: more Davinci•003 tasks,
    coming_soon: events calendar,
    social: @webDeveloperHQ
    });

    legal: ({
    terms: of use,
    privacy: policy
    });
    changelog: (
    version: 0.1.9,
    notes: added community page

    version: 0.1.8,
    notes: added Davinci•003

    version: 0.1.7,
    notes: upvote answers to bounties

    version: 0.1.6,
    notes: article editor refresh
    )...
    recent_tips: (
    tipper: @nearjob,
    tipped: article
    amount: 1000 SATS,

    tipper: @meenaratha,
    tipped: article
    amount: 1000 SATS,

    tipper: @meenaratha,
    tipped: article
    amount: 1000 SATS,
    )...