I have the following code:
$query = "SELECT * FROM xoops_album,xoops_artist WHERE
xoops_album.artist_id = xoops_artist.artist_id"; 
 $albumby = mysql_query($query) or die("Select Failed!");
 
echo"<td><center>";
if (mysql_num_rows($albumr)) {
    while ($album = mysql_fetch_array($albumr))
    { 
echo ($album[album]);
echo"<i> by "; echo ($albumby[xoops_artist.artist]); echo"<i><br>";
}
   echo "</center></td>";
    }
What I'm trying to do is select the album title from one table ( this
works ok ) and get the artist name from another table ( this is the part
I can't get to work ).  I believe it has something to do with the code
above as the rest works ok. The result I end up with is below:
 
Waterloo by ( this is where I want to put the artist name)
 
 
Thanks for in help in advance.


Reply via email to