【问题标题】:Wordpress header imgage won't display in IEWordpress 标题图像不会在 IE 中显示
【发布时间】:2012-06-08 21:50:08
【问题描述】:

标头中的图像在 Safari、FFX 和 Opera 中显示,但在 IE 中(在 9 上,顺便说一句)。

不确定这是否重要,但在使用 IE 的开发人员工具时,它会到处显示“空文本节点”。

我什至不知道要在这篇文章中附加什么其他代码...请告诉我。

网站网址:http://glassinfusion.accountsupport.com/

标题代码:

<!DOCTYPE html>
<html <?php language_attributes(); ?>>

<head>
    <meta charset="<?php bloginfo('charset'); ?>" />

    <?php if (is_search()) { ?>
       <meta name="robots" content="noindex, nofollow" /> 
    <?php } ?>

    <title>
           <?php
              if (function_exists('is_tag') && is_tag()) {
                 single_tag_title("Tag Archive for &quot;"); echo '&quot; - '; }
              elseif (is_archive()) {
                 wp_title(''); echo ' Archive - '; }
              elseif (is_search()) {
                 echo 'Search for &quot;'.wp_specialchars($s).'&quot; - '; }
              elseif (!(is_404()) && (is_single()) || (is_page())) {
                 wp_title(''); echo ' - '; }
              elseif (is_404()) {
                 echo 'Not Found - '; }
              if (is_home()) {
                 bloginfo('name'); echo ' - '; bloginfo('description'); }
              else {
                  bloginfo('name'); }
              if ($paged>1) {
                 echo ' - page '. $paged; }
           ?>
    </title>

    <link rel="shortcut icon" href="/favicon.ico">

    <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>">

    <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>">

    <link rel="icon" href="<?php bloginfo('template_directory'); ?>/favicon.ico" type="image/x-icon" />
    <link rel="shortcut icon" href="<?php bloginfo('template_directory'); ?>/favicon.ico" type="image/x-icon" />

    <?php if ( is_singular() ) wp_enqueue_script('comment-reply'); ?>

    <?php wp_head(); ?>
</head>



<body>
<div id="wrapper">
<div id="header">

    <!-- start logo -->

 <h1><a href="<?php echo get_option('home'); ?>/"><span><?php bloginfo('name'); ?></span>
       <img src="<?php bloginfo('template_directory'); ?>/images/logo3.jpg" width="" height=""alt="<?php bloginfo('name'); ?>"/> 
        </a></h1> 

     <!-- End Logo -->


<?php
        /* A sidebar on top of the content? Yep. You can can customize
         * your top with three columns of widgets.
         */
        get_sidebar('navigation');
?>


</div><!--end header -->


<!-- start middle -->
<div id="middle">

【问题讨论】:

    标签: image wordpress internet-explorer header


    【解决方案1】:

    在那些没有显示的图像的情况下,尝试使用不同格式的图像,例如 gif 而不是 jpg。

    【讨论】:

    • 关闭...它必须是.png! .gif 不起作用。感谢您的推动!
    • 请选择此答案并投票批准答案-谢谢
    猜你喜欢
    • 2016-01-12
    • 1970-01-01
    • 1970-01-01
    • 2018-10-12
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多