我以前用的时候
没有使用$_SESSION这个东西的,
判断是否注册了用session_is_registered()基本上采用标准的function就可以用的~但是不知道你的错误为什么?

解决方案 »

  1.   

    session_is_registered()
    我在php4.1.1下用的,
    没有问题!!
    你可以给他升级啊!!!!
      

  2.   

    PHP4.0.6版本现在已经搞定了,贴出来给大家讨论一下,有没有需要完善的地方。请大家指教,我是PHP新手。
    loginsubmit.php
    <?php
    $admin_code=$row["base_admin_code"];
    session_register("admin_code");
    ?>
    check.php
    <?php
    session_start();
    if (!session_is_registered("admin_code")){
    echo "<script language=JavaScript>";
    echo "window.location.href='logon.php';";
    echo "</script>";
    }
    ?>
    其他页面加验证
    <?php
    require("check.php");
    ?>
      

  3.   

    直接使用 $xxxxx
    不必要一定用 $_SESSION['xxxxx']
      

  4.   

    $_SESSION['xxxxx'] 是在4。11版本以后才有的,4。06当然会有问题