why will this not work? (PHP)?

Luke

New member
<div class="content">
<div class="tableContent2">
<div class="titTable2">




<?php
$id = (SELECT `id` FROM `BPPENNYAUTOBID_users` WHERE `nick` = $_POST["nick"]);
echo $id;
?>


</div>
</div>
</div>
</div>
oh sorry i pasted the wrong one here is the one im trying to use



<?php
$con = mysql_connect("localhost","root","Lukecudnik1");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}

mysql_select_db("pennybids", $con);

$result = mysql_query("SELECT * FROM BPPENNYAUTOBID_users WHERE nick = $_POST['nick']");

while($row = mysql_fetch_array($result))
{
$id = $row['id']
}

mysql_close($con);
?>
 
Back
Top