-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi,
I tried to add a favicon to my web app by using the solution provided by robertpic71 in thread http://www.zkoss.org/forum/listComment/7518
So my zul page looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<?page id="xxx" title="xxx" automaticTimeout="false"?>
<?import src="/xx/xxx/sample.zul" directives="*"?>
<?link rel="shortcut icon" type="image/x-icon" href="/myFavicon.ico"?>
<?link rel="icon" type="image/x-icon" href="/myFavicon.ico"?>
<zk>
<zscript><![CDATA[
import com.tcs.gla.ui.Console;
Console.logout();
]]>
</zscript>
......
</zk>
It is not working no matter what browser I use. However when I tried to access favico directly through URL, the favicon shows up.
Can anyone help? I can't see what could be wrong.
Thank you
Check this.
Yes I've checked this thread.
I actually used your solution by adding following 2 lines:
<?link rel="shortcut icon" type="image/x-icon" href="/myFavicon.ico"?>
<?link rel="icon" type="image/x-icon" href="/myFavicon.ico"?>
But it is not working
what do you mean not working?
Hi
Could you test a simple zul like:
<?link rel="shortcut icon" type="image/x-icon" href="/myFavicon.ico"?>
<?link rel="icon" type="image/x-icon" href="/myFavicon.ico"?>
<zk>
</zk>
if it works , you can add back your content (maybe line by line ), maybe you can find what cause the problem.
/Matthew
work for me, maybe you should describe more about your setting, where is myFavicon.ico? I guess you have a wrong or wrong placed myFavicon.ico
Paula,
If you are running jBoss, you might also consider placing a "~" character at the front of the URL like this:
<?link rel="shortcut icon" type="image/x-icon" href="~/myFavicon.ico"?> <?link rel="icon" type="image/x-icon" href="~/myFavicon.ico"?>
Although I don't have to do this in Tomcat, it seems jBoss needs it.
Just a thought...
Todd
hi, Todd,
Why need to add ~/ in JBoss,
I think it is just http and html protocol isn't it?
Maybe paula need to describe more about the 'not work' not just two words.
/Dennis
Dennis,
I never could figure it out either but it seems necessary in our environment. Maybe it is a configuration issue on our side?
I could have one of our teams investigate but it seems to work in production so it doesn't seem worth it.
Sorry if I confused things...
Todd
Asked: 2011-04-13 17:31:19 +0800
Seen: 969 times
Last updated: Apr 15 '11