Is there a more effecient way to do this??
PHP Code:// Retrieve all the data from the "example" table
$result1 = mysql_query("SELECT * FROM home WHERE id='1'");
$result2 = mysql_query("SELECT * FROM home WHERE id='2'");
// store the record of the "example" table into $row
$row1 = mysql_fetch_array( $result1);
$row2 = mysql_fetch_array( $result2);
// Print out the contents of the entry
$id1 = $row1['id'];
$title1 = $row1['title'];
$content1 = $row1['content'];
$image1 = $row1['image'];
$id2 = $row2['id'];
$title2 = $row2['title'];
$content2 = $row2['content'];
$image2 = $row2['image'];
?>


Reply With Quote
Bookmarks