php留言板顯示不了使用者
(這個不知道有傳片) 我的留言板裡,留言了,但是留言人沒顯示出來。。我發現不了 - -!求指點、。。。代碼奉上(不知道是這段代碼不) (我的資料庫也沒使用者名稱,也是空白的)
/*
* Created on 2012-3-23
*
* To change the template for this generated file go to
* Window - Preferences - PHPeclipse - PHP - Code Templates
*/
include_once("comm.php");
$conn = mysql_connect("localhost","root","123456") or die("無法建立串連!");
mysql_select_db("lyb") or die(mysql_error()."資料庫無法開啟");
$title = $_POST['title'];
$type = $_POST['type'];
$content = $_POST['content'];
$date_time = date("Y-m-d H:m:s");
$author = $_SESSION['user'];
if($content!="" and $title!=""){
$sql = "insert into lyb_table (subject,type,content,publish_time,user) values('$title','$type','$content','$date_time','$author')";
mysql_query("set names 'gb2312'");
mysql_query($sql,$conn);
get_show_msg("lyb.php","留言成功!");
}else{
get_show_msg("lyb.php","留言填寫錯誤,請重新填寫!");
}