1.问题:
  将导航头封装成head.php文件,在各页面文件中用include调用它,结果导航头只显示文字图片,原http://IP/daohang/head.php做好的导航样式都没有显示(php不太懂)请大侠赐教,不胜感激!
我的首页是http://IP.index.php   , <?php include("..daohang/head.php");  ?>或用代码<?php include("http://IP/daohang/head.php");  
都只显示导航图片和文字,无样式。http://IP/daohang/head.php  导航正常!
另外两个页面都有<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
请大侠解谜   跪谢!

解决方案 »

  1.   

    WWW/daohang/head.php       daohang目录下有css文件夹 images文件夹 和js文件夹 和head.php
      

  2.   

    查看一下源码看css路径是什么,点开是404没有
      

  3.   

    是不是被你index.php 里的css影响了?
    另外看是不是缓存的问题,用firefox 和 chrome测试是什么情况呢
      

  4.   

    在WWW目录下新建 daohangtest.php     测试网页什么内容都没  ,        <?php include("http://200.120.37.123/daohang/head.php"); ?>   语句还是问题依旧,我内外电脑I浏览器只有IE和360,都是显示如此, 清理缓存后问题依旧!!
      

  5.   

    <?php include("../daohang/head.php");  ?>
      

  6.   

    右键bug页面源代码,点击关于头部的css链接,看是否正常
      

  7.   

    include("daohang/head.php");另外请检查 head.php 中 css 的路径是否正确
    若 http://IP/daohang/head.php  导航正常的话,显然是少了一层目录
      

  8.   

    http://IP/daohang/head.php这个head文件浏览器能访问么
      

  9.   

    head里面引用css去掉daohang这个目录就好了    要不就改成/daohang/css/name.css
      

  10.   

    查看源码,看下css路径的文件是否访问?