hi,
I have one problem regarding retriving data from database. I have created one database in userrecord and its table name is tbl_user. I am trying to display the user information when thy logged in the syste. i.e view logged user profile. The code is as follow:
<?php
include("auth_user.inc.php"); // authrization page
$uname=$_SESSION; // logged user name
$connection=mysql_connect("localhost","root"," ");
mysql_select_db("userrecord",$connection);
$sql=("select * from table_user where uname ='$uname'");
$result=@mysql_query($sql,$connection);
$row=mysql_fetch_array($result);
?>
<html>
<head><title>User Account</title>
</head>
<body bgcolor="#33CCFF">
<br>Your Details Information Is Shown Below:<br><br>
First Name:<?php echo $row;?><br>
Last Name:<?php echo $row;?><br>
Address:<?php echo $row;?><br>
E-Mail:<?php echo $row;?><br>
Gender:<?php echo $row;?><br>
User Name:<?php echo $row;?><br>
</body>
</html>
The code echo $row is not displaying the record from database.
Regards,
Prabhat Kumar Jha