Jump to content

Problem Displaying Results from Query


AKalair

Recommended Posts

Hi,

 

When I display the results from this query the title and tagline changes but the image displayed is always the same despite having different images stored in the database.

 

$getlateststories = mysql_query("SELECT * FROM reviews, news ORDER BY 'creationdate' LIMIT 0, 2 ") or trigger_error('Unable to get latest stories', E_USER_ERROR);



while($Results = mysql_fetch_array($getlateststories))  

{

echo "<p class=Headings> <a href=/viewnewsstory.php?newsid=$Results[newsid]&catid=$Results[categoryid]>$Results[newstitle] </p></a> <img src=$Results[imageurl]> <br> <p class=Sub_Headings>$Results[newstagline]</p><br><br>  ";  
echo "<p class=Headings> <a href=/viewreviews.php?reviewid=$Results[reviewid]&catid=$Results[categoryid]>$Results[reviewtitle] </p></a> <img src=$Results[imageurl]> <p class=Sub_Headings>$Results[reviewtagline] </p><br><br>  ";
}

 

Any ideas?

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/173219-problem-displaying-results-from-query/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.