Add icon to html shortcut file

I have a html file that is used as a shortcut to my start up page.  How can I add a icon to this file?  Here is the code of the page:

<html>
<head>
<meta http-equiv="Refresh" content="0;url=Project/Main.htm">

</head>
</body>
</html>

I tried adding code below but not working
<link rel="icon" type="image/ico" href="favicon.ico"></link>
<link rel="shortcut icon" href="favicon.ico"></link>

for now I have the icon at the root level same as the the shortcut file.  Any ideas???
MadIceAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

GaryCommented:
If the icon is in the root it would be loaded automatically anyway. But if you are immediately redirecting the page then there is probably no time to even show the icon.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
MadIceAuthor Commented:
This project is browser based but ran from CD.  So the start file is what I'm trying to add an icon to.  not allowed to use an exe file so using html page.
0
Paul MacDonaldDirector, Information SystemsCommented:
I would make sure your pathing is correct.  If the .ico is in the root of your web site you shouldn't have a problem, but if it's somewhere else you will.  Also, make sure the image's file name is "favicon.ico."
0
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

GaryCommented:
But the page is immediately being redirected before the icon has chance to be loaded. Once you do a redirect all connections are closed to the current page.
If you take the redirect out and visit the page does the icon show?
0
Paul MacDonaldDirector, Information SystemsCommented:
I presume the redirection is to a different page on the same site.  The favicon is site-wide, not page-specific.  

That said, I also presume the destination page has a
   <link rel="icon" type="image/ico" href="favicon.ico"></link>
   <link rel="shortcut icon" href="favicon.ico"></link>

section as well.  If it doesn't, that's your problem.
0
GaryCommented:
If the .ico is in the root it will be loaded automatically by the browser, you don't need to specify a link
The only time you actually need to hardcode the ico file is when it is not in the root.
0
MadIceAuthor Commented:
It looks like I'm explaining this wrong so maybe the image below will help. If you look at the image, the file "Click here to start" has the IE icon. I want to switch it to the Icon image shown.  We don't allow autoloading when a cd/dvd is inserted.  So the user has start up the project by clicking on this file. This is our alternative to an exe file to start the project.  Hope this makes more sense.
Capture1.bmp
0
GaryCommented:
Now you make sense
You can only do it system wide.
But what you can do is create a shortcut, and then change the icon for the shortcut thru Right Click/Properties->Shortcut
0
Paul MacDonaldDirector, Information SystemsCommented:
As [GaryC123] notes, the IE icon is displayed because IE is the default application for web pages, and your OS doesn't know any better.

Further, as [GaryC123] also notes, you can create a shortcut and specify the icon in the shortcut setup, OR you can open the web page in your browser and drag-and-drop the icon from the address bar to your desktop.
0
GaryCommented:
@paulmacd
I'm curious what you mean by drag and drop to the desktop
0
Paul MacDonaldDirector, Information SystemsCommented:
Just that.

While you're viewing this page - in IE, at least - you can click on the "Experts Exchange" icon to the left of the URL in the address bar and drag it to the desktop.  This will create a shortcut to this page that has the EE favicon as its icon.

In fact, if you hover over it it will tell you "Drag to taskbar to pin site."  I'm saying drag it to the desktop, not the taskbar, but same difference.
0
GaryCommented:
What version, you cannot drag to desktop in any modern browser, it opens in a new window.
0
Paul MacDonaldDirector, Information SystemsCommented:
Yes, using IE10 it creates the shortcut and opens the page in a new window.  In Firefox it appears to just create the shortcut.  In either case you end up with a shortcut with the favicon as the icon which is what the OP asked for.
0
GaryCommented:
It doesn't create any shortcut for me IE9,IE10, FF and Chrome all just open a new window.
You can right click the page and create a shortcut
0
Paul MacDonaldDirector, Information SystemsCommented:
Hmmm.  I don't know what to say about that.  It works for me everywhere I've ever tried it.  I wonder if you're not grabbing the icon on the browser tab rather than the icon in the address bar.  In any case, I think the OP's question has been hijacked long enough.
0
GaryCommented:
D'oh
Not hijacking, you're giving an option.
0
MadIceAuthor Commented:
Never got this to work but I believe because based of what you mentioned.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
HTML

From novice to tech pro — start learning today.