04-01-2008, 12:21 PM
|
#5 (permalink)
|
|
The Contributor
Join Date: Feb 2008
Location: Croatia
Posts: 90
Thanks: 4
|
You can always use the WHERE in your SQL. Of course you will have to know the id or any other "connection" you can make to get that item out.
Your query would look like then
PHP Code:
<?php
include ("connect.php");
mysql_select_db("test_db", $con);
// The ID part
// Lets say you have index.php?id=12
$id = $_GET['id'];
if ( is_numeric( $id ) ) {
$result = mysql_query("SELECT * FROM test WHERE id = '".$id."'");
while ( $res = mysql_fetch_array($result) ) {
echo "<td> " . $res['test_the_name'] . " </td>";
}
print("<td> " . $res['test the name'] . " </td>");
mysql_close($con);
} else {
die( "Error");
}
?>
I'm just guessing here, can you post your db table structure?

__________________
Back from sysadmins to the programmers.
|
|
|