你在header.inc文件中有输出,不能再用header("location:welcome.php?name=$name");header("");之前必须没有任何输出。

解决方案 »

  1.   


    你可以用<META http-equiv='refresh' content='0; url=welcome.php?name=$name'>
    或者
    <script>self.location='welcome.php?name=$name';</script>
      

  2.   

    "Warning: Cannot modify header information - headers already sent by (output started at D:\www\www\PBC\SiteManager\header.inc:12) in D:\www\www\PBC\SiteManager\sulogin.php3 on line 33"他的意思是说header已经重复了,可以在引用的文件里在header前家@符号,就可以要他不输出警告信息了。
      

  3.   


    echo "<script>top.location.href='welcome.php?name=$name';</script>";header()前有对浏览器的输出,不能重定向。