function peopleGetProfile($id) { _filter_var($id); $c_content = ''; // text that we will return! global $group_name; global $access_isAuthenticated; $p = new PeoplePage($group_name); $c = $p->getProfile($id); $cres = $c[0]; $cfetch = $c[1]; if ($cres) { $c = $cfetch; // for compatibility issues! $age = $p->getAge($c["birthday"]); $zsign = $p->getZSign($c["birthday"]); /** * now it is time to evaluate the values we have */ $zsign_evaluated = $p->evaluateZSign($zsign); $songs_evaluated = $p->evaluateMusic($c["favorite_songs"]); $singers_evaluated = $p->evaluateMusic($c["favorite_singers"]); $movies_evaluated = $p->evaluateMovie($c["favorite_movies"]); $actors_evaluated = $p->evaluateMovie($c["favorite_actors"]); $books_evaluated = $p->evaluateBook($c["favorite_books"]); $authors_evaluated = $p->evaluateBook($c["favorite_authors"]); $artists_evaluated = $p->evaluateBook($c["favorite_artists"]); $hobbies_evaluated = $p->evaluateBook($c["hobbies"]); $c_content .= "<b>Motto:</b> <span id=\"area_profile_motto\">{$c["motto"]}</span><br />\n"; // we should be explicive here if (empty($c["birthday"])) { $c_content .= "<b>Birthday:</b> <span id=\"area_profile_birthday\">YYYY-MM-DD</span><br />\n"; } else { $c_content .= "<b>Birthday:</b> <span id=\"area_profile_birthday\">{$c["birthday"]}</span><br />\n"; } $c_content .= "<b>Age:</b> <span id=\"area_profile_age\">{$age}</span><br />\n"; $c_content .= "<span id=\"area_profile_zsign\"><b>Zodiac Sign:</b> <span id=\"area_profile_age\">{$zsign_evaluated}</span><br />\n"; $c_content .= "<b>Sexe:</b> <span id=\"area_profile_sexe\">{$c["sexe"]}</span><br />\n"; $c_content .= "<b>Sexual Orientation:</b> <span id=\"area_profile_sorientation\">{$c["sexual_orientation"]}</span><br />\n"; $c_content .= "<b>Marital Status:</b> <span id=\"area_profile_mstatus\">{$c["marital_status"]}</span><br />\n"; $c_content .= "<b>Occupation:</b> <span id=\"area_profile_occupation\">{$c["occupation"]}</span><br />\n"; $c_content .= "<b>Nationality:</b> <span id=\"area_profile_nationality\">{$c["nationality"]}</span><br />\n"; $c_content .= "<b>2<sup>nd</sup> Nationality:</b> <span id=\"area_profile_2nationality\">{$c["second_nationality"]}</span><br />\n"; $c_content .= "<b>Ethnic Race:</b> <span id=\"area_profile_erace\">{$c["ethnic_race"]}</span><br />\n"; $c_content .= "<b>Religion:</b> <span id=\"area_profile_religion\">{$c["religion"]}</span><br />\n"; $c_content .= "<b>Favorite Songs:</b> <span id=\"area_profile_fsongs\">{$songs_evaluated}</span><br />\n"; $c_content .= "<b>Favorite Singers:</b> <span id=\"area_profile_fsingers\">{$singers_evaluated}</span><br />\n"; $c_content .= "<b>Favorite Movies:</b> <span id=\"area_profile_fmovies\">{$movies_evaluated}</span><br />\n"; $c_content .= "<b>Favorite Actors/Actresses/Directors:</b> <span id=\"area_profile_factors\">{$actors_evaluated}</span><br />\n"; $c_content .= "<b>Favorite Books:</b> <span id=\"area_profile_fbooks\">{$books_evaluated}</span><br />\n"; $c_content .= "<b>Favorite Authors:</b> <span id=\"area_profile_fauthors\">{$authors_evaluated}</span><br />\n"; $c_content .= "<b>Favorite Sportsmen:</b> <span id=\"area_profile_fsportsmen\">{$c["favorite_sportsmen"]}</span><br />\n"; $c_content .= "<b>Favorite Artists:</b> <span id=\"area_profile_fartists\">{$artists_evaluated}</span><br />\n"; //* $c_content .= "<b>Favorite Cities:</b> <span id=\"area_profile_fcities\">{$c["favorite_cities"]}</span><br />\n"; //* $c_content .= "<b>Favorite Colors:</b> <span id=\"area_profile_fcolors\">{$c["favorite_colors"]}</span><br />\n"; $c_content .= "<b>Hobbies:</b> <span id=\"area_profile_hobbies\">{$hobbies_evaluated}</span><br />\n"; $c_content .= "<b>Fobbies:</b> <span id=\"area_profile_fobbies\">{$c["fobbies"]}</span><br />\n"; // } if ($access_isAuthenticated && $p->isOwner($id, $_SESSION['valid_user'])) { $c_content .= "<br />\n<div>[ <a href=\"javascript:void(people_editprofile({$id}))\">" . $this->_("Edit") . "</a> ]</div>"; } } else { $c_content .= "<span id=\"area_profile_motto\"></span>"; $c_content .= "<span id=\"area_profile_birthday\" style=\"position:absolute;visibility:hidden;\">YYYY-MM-DD</span>"; $c_content .= "<span id=\"area_profile_age\"></span>"; $c_content .= "<span id=\"area_profile_zsign\"></span><span id=\"area_profile_age\"></span>"; $c_content .= "<span id=\"area_profile_sexe\"></span>"; $c_content .= "<span id=\"area_profile_sorientation\"></span>"; $c_content .= "<span id=\"area_profile_mstatus\"></span>"; $c_content .= "<span id=\"area_profile_occupation\"></span>"; $c_content .= "<span id=\"area_profile_nationality\"></span>"; $c_content .= "<span id=\"area_profile_2nationality\"></span>"; $c_content .= "<span id=\"area_profile_erace\"></span>"; $c_content .= "<span id=\"area_profile_religion\"></span>"; $c_content .= "<span id=\"area_profile_fsongs\"></span>"; $c_content .= "<span id=\"area_profile_fsingers\"></span>"; $c_content .= "<span id=\"area_profile_fmovies\"></span>"; $c_content .= "<span id=\"area_profile_factors\"></span>"; $c_content .= "<span id=\"area_profile_fbooks\"></span>"; $c_content .= "<span id=\"area_profile_fauthors\"></span>"; $c_content .= "<span id=\"area_profile_fsportsmen\"></span>"; $c_content .= "<span id=\"area_profile_fartists\"></span>"; $c_content .= "<span id=\"area_profile_fcities\"></span>"; $c_content .= "<span id=\"area_profile_fcolors\"></span>"; $c_content .= "<span id=\"area_profile_hobbies\"></span>"; $c_content .= "<span id=\"area_profile_fobbies\"></span>\n"; $c_content .= "<br />\n"; if ($access_isAuthenticated && $p->isOwner($id, $_SESSION['valid_user'])) { $c_content .= "<br />\n<div>[ <a href=\"javascript:void(people_editprofile({$id}))\">" . $this->_("Edit") . "</a> ]</div>"; } } return $c_content; }