我已将一个新的favicon上传到Drupal网站,清除了我的缓存,它仍然显示为滴水图标,它只在我登录时和后端显示自定义图标。
我试过firefox 4和IE 8
感谢您的帮助!
更新 - 下面添加了HTML标头代码。
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Home | CIOB</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="shortcut icon" href="/misc/favicon.ico" type="image/x-icon" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/admin_menu/admin_menu.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/ciob.org.uk/files/ctools/css/8df0ab71786aec38c5eef01816622257.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/node/node.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/defaults.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/system.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/system-menus.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/user/user.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/cck/theme/content-module.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/ctools/css/ctools.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/date/date.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/filefield/filefield.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/lightbox2/css/lightbox.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/panels/css/panels.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/admin/toolbar/admin_toolbar.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/calendar/calendar.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/misc/farbtastic/farbtastic.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/views/css/views.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/panels/plugins/layouts/flexible/flexible.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/ciob/styles/framework/reset.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/ciob/styles/framework/text.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/ciob/styles/framework/960.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/ciob/styles/framework/debug.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/themes/ciob/styles/styles.css?d" />
<script type="text/javascript" src="/misc/jquery.js?d"></script>
<script type="text/javascript" src="/misc/drupal.js?d"></script>
<script type="text/javascript" defer="defer" src="/sites/all/modules/admin_menu/admin_menu.js?d"></script>
<script type="text/javascript" src="/sites/all/modules/lightbox2/js/lightbox_video.js?d"></script>
<script type="text/javascript" src="/sites/all/modules/lightbox2/js/lightbox.js?d"> </script>
<script type="text/javascript" src="/sites/all/modules/panels/js/panels.js?d"></script>
<script type="text/javascript" src="/sites/all/modules/poormanscron/poormanscron.js?d"</script>
<script type="text/javascript" src="/sites/all/modules/admin/toolbar/admin_toolbar.js?d"></script>
<script type="text/javascript" src="/sites/all/themes/ciob/bookmark.js?d"></script>
<script type="text/javascript" src="/sites/all/themes/ciob/ciob.js?d"></script>
<script type="text/javascript" src="/sites/all/themes/ciob/ui.core.js?d"></script>
<script type="text/javascript" src="/sites/all/themes/ciob/ui.tabs.js?d"></script>
<script type="text/javascript">
<!--//--><![CDATA[//><!--
jQuery.extend(Drupal.settings, { "basePath": "/", "admin_menu": { "margin_top": 1, "position_fixed": 1 }, "CTools": { "pageId": "page-7f4aa01928040cccbbe2bef65e92817b" }, "googleanalytics": { "trackOutgoing": 1, "trackMailto": 1, "trackDownload": 1, "trackDownloadExtensions": "7z|aac|avi|csv|doc|exe|flv|gif|gz|jpe?g|js|mp(3|4|e?g)|mov|pdf|phps|png|ppt|rar|sit|tar|torrent|txt|wma|wmv|xls|xml|zip" }, "lightbox2": { "rtl": 0, "file_path": "/(\\w\\w/)sites/ciob.org.uk/files", "default_image": "/sites/all/modules/lightbox2/images/brokenimage.jpg", "border_size": "10", "font_color": "000", "box_color": "fff", "top_position": "", "overlay_opacity": "0.8", "overlay_color": "000", "disable_close_click": 1, "resize_sequence": "0", "resize_speed": 400, "fade_in_speed": 400, "slide_down_speed": 600, "use_alt_layout": 0, "disable_resize": 0, "disable_zoom": 0, "force_show_nav": 0, "loop_items": 0, "node_link_text": "View Image Details", "node_link_target": 0, "image_count": "Image !current of !total", "video_count": "Video !current of !total", "page_count": "Page !current of !total", "lite_press_x_close": "press \x3ca href=\"#\" onclick=\"hideLightbox(); return FALSE;\"\x3e\x3ckbd\x3ex\x3c/kbd\x3e\x3c/a\x3e to close", "download_link_text": "Download Original", "enable_login": false, "enable_contact": false, "keys_close": "c x 27", "keys_previous": "p 37", "keys_next": "n 39", "keys_zoom": "z", "keys_play_pause": "32", "display_image_size": "", "image_node_sizes": "()", "trigger_lightbox_classes": "", "trigger_lightbox_group_classes": "", "trigger_slideshow_classes": "", "trigger_lightframe_classes": "", "trigger_lightframe_group_classes": "", "custom_class_handler": 0, "custom_trigger_classes": "", "disable_for_gallery_lists": true, "disable_for_acidfree_gallery_lists": true, "enable_acidfree_videos": true, "slideshow_interval": 5000, "slideshow_automatic_start": true, "slideshow_automatic_exit": true, "show_play_pause": true, "pause_on_next_click": false, "pause_on_previous_click": true, "loop_slides": false, "iframe_width": 600, "iframe_height": 400, "iframe_border": 1, "enable_video": 1, "flvPlayer": "/flvplayer.swf", "flvFlashvars": "" }, "cron": { "basePath": "/poormanscron", "runNext": 1303116980 } });
//--><!]]>
</script>
<!--[if lte IE 6]>
<link rel="stylesheet" href="/sites/all/themes/ciob/styles/ie6.css" type="text/css" />
<script type="text/javascript">
$(document).ready(function(){
$(document).pngFix();
});
</script>
<![endif]-->
<!--[if IE 7]>
<link rel="stylesheet" href="/sites/all/themes/ciob/styles/ie7.css" type="text/css" />
<![endif]-->
<!--[if IE 8]>
<link rel="stylesheet" href="/sites/all/themes/ciob/styles/ie8.css" type="text/css" />
<![endif]-->
</head>
答案 0 :(得分:3)
如您所见,HTML指向默认的favicon:<link rel="shortcut icon" href="/misc/favicon.ico" type="image/x-icon" />
Drupal不会覆盖它,但会将您的自定义图标上传到“files / ....”然后更改HTML以使用它。
您的HTML未更改。这可能意味着两件事之一:
我怀疑后者。您主题的page.tpl.php
文件应包含<?php print $header ?>
,而不是硬编码的<link rel="shortcut icon" ...
。
答案 1 :(得分:1)
主要针对那些在管理页面中显示favicon但在首页上没有显示相同问题的人:
答案 2 :(得分:0)
在我的情况下,它使用了favicon图标设置bij opengraph元属性而不是link rel快捷方式图标。 例如。 这取决于您使用的浏览器。 因此,请确保在META模块和主题设置中正确设置。
答案 3 :(得分:-2)
Changing Favicon icon in Drupal
更改活动主题设置中的图标。
转到外观&gt;您的主题设置&gt; 并取消选中(使用主题提供的默认快捷方式图标),然后上传您的favicon图标并保存。