Ok, I have a page that has a username as a link that looks like this:
<? <a href='profile.php?user=$user'> $user </a> ?>
That would send me to the proper page, and it does, now I have this other page that I want it to display the users info. But for some reason it wont pull the info from the URL or something. Think you could help? This is my script below
<?
$user = $HTTP_GET_VARS['user'];
?>
<? include('hiddencode.php'); ?>
<? include('top.php'); ?>
<? include('dbinfo.inc.php'); ?>
<?
$query = mysql_query("SELECT * FROM users WHERE username='$user'") or die(mysql_error());
$row = mysql_fetch_assoc($query);
$username = $row['username'];
$fname = $row['fname'];
$lname = $row['lname'];
$age = $row['age'];
$email = $row['email'];
$city = $row['city'];
$state = $row['syaye'];
$homepage = $row['homepage'];
$profile = $row['profile'];
$type = $row['type'];
?>
<table width="129%" border="0" cellspacing="0" cellpadding="3" height="55%">
<tr>
<td height="248" valign="top" width="991">
<table width="85%" border="1" bordercolor="#000000" cellspacing="0" cellpadding="0" align="center" background="/images/turntable.jpg">
<tr>
<td height="475" width="100%" valign="center"><table width="85%" border="0">
<tr>
<td width="20%"><strong><font size="2" face="Tahoma">Username:</font></strong></td>
<td width="80%"> <? $username ?> </td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Real Name:</font></strong></td>
<td><? $fname $lname ?></td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Age:</font></strong></td>
<td><? $age ?></td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Email Address:</font></strong></td>
<td><? $email ?></td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Hometown:</font></strong></td>
<td><? $city ',' $state ?></td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Homepage:</font></strong></td>
<td><? <a href='http://$homepage'> $homepage </a> ?></td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Account Type:</font></strong></td>
<td><? $type ?></td>
</tr>
<tr>
<td><strong><font size="2" face="Tahoma">Profile:</font></strong></td>
<td><? $profile ?></td>
</tr>
</table> </tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr valign="top">
<td height="50" colspan="2">
<div align="right">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td background="/images/bar3.gif" height="21">
</td>
</tr>
</table>
<? include('bottom.php'); ?>
Thank you in advance. How I know it isnt working is becuase I get a parse error when it tries to post the variable in the page. Like the SQL statement never went or something. Sorry, I am a newbie at this as well.