$regdate = $Locations->getRegistrationDate(); $location = $Locations->getLocation(); $mediaid = $Locations->getMediaId(); $ratingid = $Locations->getUserRatingId(); $emailsub = $Locations->getEmailSub(); ?> <?php echo "The user is: " . $fname . "<br>"; ?> <?php } // end of foreach loop } // end of if statement $LocationManager = new LocationManager(); $Locations = $LocationManager->getUserByLocation(1); echo "<br/><br/><br/><b>Locations BY LOCATION</b><br>"; $userCount = count($Locations); if ($userCount > 0) { foreach ($Locations as $Locations) { $uid = $Locations->getUserId(); $fname = $Locations->getFirstName(); $lname = $Locations->getLastName(); $pwd = $Locations->getPassword(); $loginid = $Locations->getLogin(); $email = $Locations->getEmail(); $dob = $Locations->getDOB(); $language = $Locations->getUserLanguage(); $usertype = $Locations->getUserType(); $regdate = $Locations->getRegistrationDate(); $location = $Locations->getLocation();