Pridan kod pro zobrazeni favicony
authorThomas Mudrunka <tomas@mudrunka.cz>
Fri, 9 Dec 2011 19:32:56 +0000 (20:32 +0100)
committerThomas Mudrunka <tomas@mudrunka.cz>
Fri, 9 Dec 2011 19:32:56 +0000 (20:32 +0100)
index.php

index 88b7f1380c0a9930500b05941660549f944540ca..95d4a59f9f414280d7162aaf4bbf28b6b7dc47be 100755 (executable)
--- a/index.php
+++ b/index.php
@@ -151,10 +151,16 @@ class HTML {
                return "<div$options>$html</div>";
        }
 
+       function favicon($url='/favicon.ico') {
+               return '<link rel="shortcut icon" href="'.$url.'" /><link href="'.$url.'" rel="icon" type="image/gif" />';
+
+       }
+
        function head($title=false,$charset='UTF-8',$more='') {
                $title = $title ? "\n<title>$title</title>" : '';
                $html= '<head>';
                $html.= '<meta http-equiv="Content-Type" content="text/html; charset='.$charset.'" />'.$title.$more;
+               $html.= $this->favicon(dirname($_SERVER['SCRIPT_NAME']).'/favicon.ico');
                $html.= '</head>';
                return $html;
        }
This page took 0.117064 seconds and 4 git commands to generate.