duandianwen1723 2012-11-12 18:32
浏览 27
已采纳

徽标图片未加载 - PHP [关闭]

I'm working on a template file and I came across something that's biting my head.

On the header.php file I have the following

<div id="logo">
<a href="index.php"><img src="images/logo.png" alt="MY COMPANY""/></a>
<p class="tagline">MY COMPANY</p>

However the logo.png file is not showing up. only the alt= text and the "tagline" show up.

  1. The .png file is in the images folder
  2. The css file is properly configured (at least to my knowledge)
  3. the header.php file is outside the 'images' folder so the image path should be ok.

this is my css code just for reference.

#logo {
float:left;
margin:22px 0 0 0;
}
#logo a {
    float:left;
    }
#logo .tagline {
    display:inline;
    float:left;
    margin:0;
    width:115px;
    line-height:14px;
    color:#aeaeae;
    margin:0 0 0 10px;
    padding-top:5px;
    font-family:Arial, Helvetica, sans-serif;
    }

Thanks for the help in advance.

  • 写回答

4条回答 默认 最新

  • dongshuo1856 2012-11-12 18:53
    关注

    there is a mistake in your imgtag syntax, remove closing " at the end of alt attribute

    <img src="images/logo.png" alt="MY COMPANY"/>
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(3条)

报告相同问题?