0) $accessLevel = 0; else $accessLevel = 1; include_once("access.php"); /* Select member from DB */ $user = str_replace(";", ":", strtolower(strip_tags($user))); $query = "SELECT * FROM members WHERE username = \"$user\""; $result = mysql_query($query); /* If member not found/available show error page */ if(mysql_numrows($result) != 1) { include("header.php"); echo "

error!

An error occurred when trying to look up the member profile you requested!

back"; include("footer.php"); exit; } /* Load in all vars */ $user = mysql_result($result, 0, username); $id = mysql_result($result, 0, id); $activities = mysql_result($result, 0, activities); $type = mysql_result($result, 0, type); $status = mysql_result($result, 0, status); $postcode = mysql_result($result, 0, postcode); $membername = mysql_result($result, 0, membername); $memberdob = mysql_result($result, 0, memberdob); $memberclass = mysql_result($result, 0, memberclass); $memberheight = mysql_result($result, 0, memberheight); $memberbuild = mysql_result($result, 0, memberbuild); $adtitle = mysql_result($result, 0, adtitle); $adtext = mysql_result($result, 0, adtext)."

"; $lastlogin = mysql_result($result, 0, lastlogin); $datejoined = mysql_result($result, 0, datejoined); $membershiplevel = mysql_result($result, 0, membershiplevel); $renewaldate = mysql_result($result, 0, renewaldue); $country = mysql_result($result, 0, country); $todaydate = date("Ymd"); $animal = mysql_result($result, 0, animal); $music = mysql_result($result, 0, music); $children = mysql_result($result, 0, children); $wish = mysql_result($result, 0, wish); $food = mysql_result($result, 0, food); $weekend = mysql_result($result, 0, weekend); $house = mysql_result($result, 0, house); $eyecolour = mysql_result($result, 0, eyecolour); $haircolour = mysql_result($result, 0, haircolour); $looks = givemeLooks(mysql_result($result, 0, looks)); $want = givemeWant(mysql_result($result, 0, want)); $countr = mysql_result($result, 0, country); $temp9 = mysql_query("SELECT flag FROM countries WHERE country=\"$countr\""); $flag = mysql_result($temp9, 0, flag); if((strlen($renewaldate) == 8) && ($membershiplevel == 2) && ($renewaldate <= $todaydate)) $membershiplevel = 9; /* Work Out Last Login */ $lastin = mktime(substr($lastlogin, 8, 2),substr($lastlogin,10,2),substr($lastlogin,12,2),substr($lastlogin,4,2),substr($lastlogin,6,2),substr($lastlogin,0,4)); $nowis = mktime(); $seconds = $nowis - $lastin; $minutes = $seconds / 60; $hours = $minutes / 60; $days = $hours / 24; $weeks = $days / 7; if($minutes < 5) $lastinstring = "< 5 mins ago"; elseif($minutes < 60) $lastinstring = floor($minutes)." mins ago"; elseif($hours < 24) $lastinstring = floor($hours)." hours ago"; elseif($days < 7) $lastinstring = floor($days)." days ago"; else $lastinstring = floor($weeks)." weeks ago"; /* Work out date joined */ $montharray = array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"); $yearjoined = substr($datejoined, 0, 4); $monthjoined = substr($datejoined, 4, 2); $monthjoined--; $joinedstring = "$montharray[$monthjoined] $yearjoined"; /* Work out member type */ $displaytype = givemeMembershipType($type); /* Work out member gender(s) */ $membsex = "0"; $partsex = "0"; if(($memberclass == 1) || ($memberclass == 2) || ($memberclass == 3) || ($memberclass == 4) || ($memberclass == 5)) $membsex = "male"; elseif($memberclass == 6) $membsex = "transsexual"; else $membsex = "female"; if($type == "C") { if(($partnerclass == 1) || ($partnerclass == 2) || ($partnerclass == 3) || ($partnerclass == 4) || ($partnerclass == 5)) $partsex = "male"; elseif($partnerclass == 6) $partsex = "transsexual"; else $partsex = "female"; } /* Convert codes to text */ $lookingforarray = givemeLookingFor($lookingfor); $activitiesarray = givemeActivities($activities); $memberclassdisplay = givemeMemberClass($memberclass); $partnerclassdisplay = givemeMemberClass($partnerclass); $memberbuilddisplay = givemeMemberBuild($memberbuild); $partnerbuilddisplay = givemeMemberBuild($partnerbuild); $animal2 = strtolower(givemeAnimal($animal)); $animal = givemeAnimal($animal); $music = givemeMusic($music); $children = givemeChildren($children); $wish = givemeWish($wish); $food = givemeFood($food); $weekend = givemeWeekend($weekend); $house = givemeHouse($house); $eyecolour2 = givemeEye($eyecolour); $haircolour2 = givemeHair($haircolour); if($username){ /* Work out distance to member */ $query = "SELECT postcode FROM members WHERE username = \"$_SESSION[username]\""; $result = mysql_query($query); $originpc = mysql_result($result, 0, postcode); if(($thisUserCountry == "United Kingdom") && ($countr == "United Kingdom")) { $distance = postcodeDistance($originpc, $postcode); if($distance < 0.1) $displaydistance = "in your area"; elseif($distance < 10) $displaydistance = number_format($distance, 1, ".", ",")." miles away"; else $displaydistance = number_format($distance, 0, ".", ",")." miles away"; } elseif(($thisUserCountry == "United States") && ($countr == "United States")) { $distance = zipDistance($originpc, $postcode); if($distance < 0.1) $displaydistance = "in your area"; elseif($distance < 10) $displaydistance = number_format($distance, 1, ".", ",")." miles away"; else $displaydistance = number_format($distance, 0, ".", ",")." miles away"; } } /* Load up member's pix */ $pixquery = "SELECT * FROM gallerys WHERE user = \"$user\" ORDER BY RAND() LIMIT 3"; $pixresult = mysql_query($pixquery); /* Get total number of member's pix */ $pixquery = "SELECT id FROM gallerys WHERE user = \"$user\""; $totalpix = mysql_query($pixquery); $totalnumpics = mysql_numrows($totalpix); /* Main Pic */ $pixquery3 = "SELECT id FROM gallerys WHERE user = \"$user\" AND gdefault=1"; $pixresult3 = mysql_query($pixquery3); if(mysql_numrows($pixresult3) != 1) { $pixquery2 = "SELECT id FROM gallerys WHERE user = \"$user\""; $pixresult2 = mysql_query($pixquery2); if(mysql_numrows($pixresult2) == 0) { $noimage = "images/nopic$type.jpg"; } else { $imageid = mysql_result($pixresult2, 0, id); } } else { $imageid = mysql_result($pixresult3, 0, id); } /* See if user is chatting */ $chatquery = mysql_query("SELECT login_time FROM chat_users WHERE username = \"$user\""); $userchatting = mysql_numrows($chatquery); $pagetitle = "Member Profile"; $meta_keywords = ""; $meta_description = ""; include("header.php"); include_once("gallery_img_handler.php"); ?>
"; else echo "\"female\""; ?>
last logged in
member since
($postcode)
$displaydistance"; elseif(($thisUserCountry == "United States") && ($countr == "United States")) echo "($postcode)
$displaydistance
"; else echo "Location:
$countr
"; ?>
<?php echo $countr; ?>
0) echo "view photos |"; ?> contact this member | bookmark this profile
Make this member featured"; else echo "this member is a featured member"; } ?>
"; } else { $gend1 = "her"; $gend2 = "she"; $gend3 = "She"; $gend4 = "herself"; echo "
"; } ?>
Introduction:
is a who is years of age and from . classes as a , is in height and has a build. joined us on and says that if was an animal 'd be !
0) echo "\"There"; else { galleryImage($imageid, 270, 0, 0, 0); } ?>

0) { echo "My Gallery:

"; if($totalnumpics > 3) echo ""; echo "
"; while($row = mysql_fetch_array($pixresult)) { $piclink = "view-gallery-pic.html?id=$row[id]"; echo ""; galleryImage($row[id], 0, 50, 0, 0); echo "  "; } echo "
more photos
"; } /* } */ echo "
"; if($userchatting != 0) echo "
\"clickThis member is currenty in the chat room!
"; echo "
"; ?>
Profile:
Name: ()
Looking for:
Age:
Looks:
Height:
Build:
Eye Colour:
Hair Colour:
Children:
Residential Status:
What Music do I like:
What would I Wish for:
Favourite Food:
What do I do at the Weekend:
What animal would I be:
Enjoys the following activities:"; } ?>