<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">
<!--
.STYLE1 {color: #FF0000}
-->
</style>
</head><body>
<table width="750" border="1" align="center">
  <tr>
    <td width="131" align="left" valign="top" bgcolor="#CCCCCC"><p>
</p>
    </td>
    <td width="603"><div align="center"><?php
session_start();session_unset();session_destroy();echo '<div align="center"><font color="#0000FF"><strong>成功退出!</strong></font></div>';exit;?></div></td>
  </tr>
</table><?php include ("end.html");?>
</body>
</html>总出现 以下错误Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at F:\web\115\login_success.php:3) in F:\web\115\access.php on line 2Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at F:\web\115\login_success.php:3) in F:\web\115\access.php on line 2權限控管頁面!Session 變數如下:登入時間: 2008-02-28 01:55:20
orange
banana
apple[ 登 出 ]

解决方案 »

  1.   

    <?PHP
    session_start(); 
    ?>
    <!DOCTYPE   html   PUBLIC   "-//W3C//DTD   XHTML   1.0   Transitional//EN"   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
    <html   xmlns="http://www.w3.org/1999/xhtml"> 
    <head> 
    <meta   http-equiv="Content-Type"   content="text/html;   charset=gb2312"   /> 
    <title> 无标题文档 </title> 
    <style   type="text/css"> 
    <!-- 
    .STYLE1   {color:   #FF0000} 
    --> 
    </style> 
    </head> <body> 
    <table   width="750"   border="1"   align="center"> 
    <tr> 
    <td   width="131"   align="left"   valign="top"   bgcolor="#CCCCCC"> <p> 
    </p> 
    </td> 
    <td   width="603"> <div   align="center"> 
    <?php 
    echo   ' <div   align="center"> <font   color="#0000FF"> <strong> 成功退出! </strong> </font> </div> '; 
    exit; ?> 
    </div>
    </td> 
    </tr> 
    </table>
    <?php   include   ("end.html");?> 
    </body> 
    </html> 
    <?PHP
    session_unset(); session_destroy(); 
    ?>