Topic: favico problem

hi,

i want to add a favico to my forum and placed the following code, which i found on google, in header.php
after <?php

echo "<link rel=\"icon\" href=\"img/favicon.ico\" type=\"image/x-icon\">";
echo "<link rel=\"shortcut icon\" href=\"img/favicon.ico\" type=\"image/x-icon\">";

the favico loads but all the bodytext inside the forum turns black. (it was white)

what happens here?
and how can i solve it?

thanks for helping out.

Re: favico problem

What site?

Re: favico problem

the one in my signature wink

Re: favico problem

It would require having the favico patch... you put it in main.tpl right?

5 (edited by Smartys 2006-09-17 16:18)

Re: favico problem

machinetaal wrote:

the one in my signature wink

I don't see the code you posted anywhere in your HTML

Re: favico problem

i removed it because it looks so ugly smile

but i put it back now for bugtesting.

the exact code =

echo "<link rel=\"icon\" href=\"http://www.electricbounce.nl/mt.ico\" type=\"image/x-icon\">";
echo "<link rel=\"shortcut icon\" href=\"http://www.electricbounce.nl/mt.ico\" type=\"image/x-icon\">";

Re: favico problem

Probably has to do with where you're outputting it, it should be inside <head></head>
Edit main.tpl instead?

Re: favico problem

Your main.tpl

Put it in there.

Re: favico problem

ok the code is now in the head of main.tpl.

looks like this:

<head>
<link rel=\"icon\" href=\"http://www.electricbounce.nl/mt.ico\" type=\"image/x-icon\">
<link rel=\"shortcut icon\" href=\"http://www.electricbounce.nl/mt.ico\" type=\"image/x-icon\">
<meta http-equiv="Content-Type" content="text/html; charset=<pun_char_encoding>" />
<pun_head>
</head>

black text is gone but still no favicon to be seen

Re: favico problem

remove the \

Re: favico problem

big_smile

thank you all very much for helping me so quick and good!!!

12

Re: favico problem

The best solution is to add this into header.php:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<link rel="shortcut icon" href="img/favicon.ico" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
</html>

This works in IE7,8 and FF3.0!