yes, it does sound like a beginer question, but I must say, when I started on this path a few years ago I remember there was NOTHING that told me how to do it (That was before there was much support out there) So I am willing to pass on a little knowlagde 🙂
There are two ways of doing it... the one I will show you works great if you know the names of the feilds you are pulling but is a little slower, however if you plan to pull multiple rows it will be the best way.
$id = whatever;
$getinfo = mysql_query("select * from tablename where id='$1d'");
$valueone = mysql_result($getinfo,0,"valueone");
$valuetwo = mysql_result($getinfo,0,"valuetwo");
$valuethree = mysql_result($getinfo,0,"valuethree");
echo("<table><TR><TD>$valueone</TD><TD>$valuetwo</TD><TD>$valuethree</TD></TABLE>");
If you have multiple rows in your table with the same ID you could...
$id = whatever;
$getinfo = mysql_query("select * from tablename where id='$1d'");
$rows = mysql_num_rows($getinfo);
echo("<table>");
for($i=0;$i<$rows;$i++){
$valueone = mysql_result($getinfo,$i,"valueone");
$valuetwo = mysql_result($getinfo,$i,"valuetwo");
$valuethree = mysql_result($getinfo,$i,"valuethree");
echo("TR><TD>$valueone</TD><TD>$valuetwo</TD><TD>$valuethree</TD>");
}
echo("</table>");
Travis Harris