Joining tables and displaying the correct information
Hello, I'm trying to join two tables and show the name of the Originization the member is attached to. Problem is it only shows the top most orginization. This is what my tables looks like:
myMembers - (name of table)
id orgid firstname lastname etc
churches - (name of table)
orgid orgname orgcontact etc
---------------------------------------------------------------------------------
<?PHP
$sql_default = mysql_query("SELECT * FROM myMembers JOIN churches
ON myMembers.orgid=churches.orgid'");
while($row = mysql_fetch_array($sql_default)){
$orgid = $row["orgid"];
$orgname = $row["orgname"];
$orgzip = $row["orgzip"];
}
?>
--------------------------------------------------------------------------
HTML
<?php print "$orgname"; ?>
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Bookmarks