i've try it ....
and get error....
though $s_user and $s_level can echo out...
but ...still hav error....
it is on the line of session_start....
the prog is:
<body bgcolor="#FF9900" text="#333333" link="#FFFF00" alink="#666600" vlink="#FFCC66">
<div align="center">
<font size="6">«Où²Õ</font>
<img src="clccccphoto1.jpg" width="200" height="130"><br>
<form method="post" action="paullink.php">
<?php
$form_user="paul";
$success=0;
require 'common.inc' ;
$query="select * from user where name='$form_user' and password='$form_password'";
mysql_connect($host,$user,$password);
mysql_select_db($database);
$query = stripSlashes($query);
$result = mysql_query($query);
if ($row = mysql_fetch_array($result)){
if($row["level"]==3 || $row["level"]==4){
$success=1;
session_start(); //line 13
if (session_register("s_user") && session_register("s_level")){
$s_user=$form_user;
$s_level=$row['level'];
echo $s_user;
echo $s_level;}
}}
?>
error msg is
Warning: Cannot send session cookie - headers already sent by (output started at /home/clc/www/html/paullink.php:13) in /home/clc/www/html/paullink.php on line 28
Warning: Cannot send session cache limiter - headers already sent (output started at /home/clc/www/html/paullink.php:13) in /home/clc/www/html/paullink.php on line 28
paul3
the paul3 is the echoes...