
Now i search for "central database" in the site. ...
#################################################################################
# Friend Finder for XOOPS 1.3.x and XOOPS 2.xx Version 3.1 beta #
# #
# Copyright 2003 by eagle81 #
# #
# Manuel Caballero friendfinder@dancepartner.net #
# Module Homepage: http://www.dancepartner.net #
# #
# Please report bugs and new feature request at modcentral.com friendfinder #
# forum or via mail frienfinder@dancepartner.net #
# #
# Copyright for this langfile #
# Lanuage: Language name #
# Name: your name and email #
# Homepage: your Homepage #
# #
# #
# Last modification: 2002-02-22 #
# #
# Initialy this script is based on phpMeet from #
# Jeremy Ross webmaster@phprank.com #
# Script design : PhpMeet Copyright 2002 - #
# Created 15/01/02 Last Modified 15/01/02 #
# Scripts Home http://www.jrscripts.com #
# #
# First XOOPS Versions from: #
# #
# Xoops-RC2 French Version : jokerman@free.fr #
# Web Home : http://www.webetfric.com #
# #
# Xoops-RC2 English Version : webmaster@modscentral.com #
# Web Home : http://www.modscentral.com #
#################################################################################
// ORIGINAL FILE INFO
include("../../mainfile.php");
include("../../header.php");
include("cache/config.php");
include("header.php");
include("age.php");
#include(XOOPS_ROOT_PATH."/include/xoopscodes.php");
include(XOOPS_ROOT_PATH."/include/version.php");
$myts =& MyTextSanitizer::getInstance();
$xoopsOption['show_rblock'] =1;
global $xoopsDB, $xoopsTheme, $xoopsConfig, $xoopsModule;
global $dateformat, $autoactive,$anonymusmail, $imagesize, $heightunit, $weightunit;
//Function to see if directfriends is installed
//This function only works with xoops2
if(XOOPS_VERSION=="XOOPS 2.0.6"){
$module_handler =& xoops_gethandler('module');
if ($module_handler->getCount(new Criteria('dirname', 'directfriends'))) {
$directfriends=1;
} else{
$directfriends=0;
}
}else{
if (XoopsModule::moduleExists("directfriends")) {
$directfriends=1;
} else{
$directfriends=0;
}
}
//end of direct friends
OpenTable();
//************************************************************
if (isset($id) || $id != "")
{
// $statistic = $xoopsDB->query("SELECT id,statistic FROM xoops_friendfinder WHERE id = '$id'");
// while (list($id,$statistic) = $xoopsDB->fetchRow($statistic)){
// $newstatistic= $statistic + 1;
// }
/* $updatestatistic= $xoopsDB->query("UPDATE ".$xoopsDB->prefix($xoopsModule->dirname())." set statistic='$newstatistic WHERE id='$id'");
*/
$view = $xoopsDB->query("SELECT uid,id,user,active,sex,category,name,email,city,state,country,hobby,partner,height,weight,birth,pic,Description,imgname,imgtime,date, topic,title FROM ".$xoopsDB->prefix($xoopsModule->dirname())."
inner join ".$xoopsDB->prefix($xoopsModule->dirname()."_state")." on state = cid
inner join ".$xoopsDB->prefix($xoopsModule->dirname()."_sex")." on sex = sid
inner join ".$xoopsDB->prefix($xoopsModule->dirname()."_category")." on category = catid
WHERE id = '$id'");
while (list($uid,$id,$user,$active,$sex,$category,$name,$email,$city,$state,$country,$hobby,$partner,$height,$weight,$birth,$pic,$Description,$imgname,$imgtime,$date,$topic,$title) = $xoopsDB->fetchRow($view)) {
// $newstatistic= $statistic + 1;
// $updatestatistic = $xoopsDB->query("UPDATE xoops_friendfinder set statistic='$newstatistic' WHERE id='$id'");
if ( $uid != 0 ) {
$poster = new XoopsUser($uid);
if ( !$poster->isActive() ) {
$poster = 0;
}
} else {
$poster = 0;
}
if ($pic==""){
$picture="/blank.gif";
$imgname="/blank.gif";
$imgtime="";
$gimaxwight=1;
}else{
$picture=$pic;
$imgtime="/".$imgtime."";
}
#############Prepare Data to show################################
$Description = $myts->makeTareaData4Show($Description,0,1,1);
$topic = $myts->makeTboxData4Show($topic,0,1,1);
$hobby = $myts->makeTboxData4Show($hobby,0,1,1);
$user = $myts->makeTboxData4Show($user,0,1,1);
$id = $myts->makeTboxData4Show($id,0,1,1);
$title = $myts->makeTboxData4Show($title,0,1,1);
$weight = $myts->makeTboxData4Show($weight,0,1,1);
$height = $myts->makeTboxData4Show($height,0,1,1);
#################################################################
echo"
.$logo." width=478 height=74>
".$topic."
"._DESCRIPTION."
".$Description."
"._HOBBY."
".$hobby."
"._UNAME."
".$user." ";
if($generateimage==1){
echo"
.$gimaxwight."&pfad=members/uploads".$imgtime."/&bildname=".$imgname."' border=0> ";
}else {
echo"
.$myts->makeTboxData4Show($picture)." border=0> ";
}
echo" ";
//
// "._TEXTVIEWREALNAME."
// ".$myts->makeTboxData4Show($name)."
//
echo"
"._TEXTVIEWEMAIL." ";
if(($anonymusemail==0) AND (!$xoopsUser)){
echo""._TEXTANONYMUSCANTMAIL." ";
} else {
echo".$id."> "._TEXTVIEWEMAILSEND." ";
}
echo"
State
".$title."
"._TEXTVIEWCITY."
".$myts->makeTboxData4Show($city)."
"._TEXTCATEGORY." ";
$cat_res=$xoopsDB->query("select cattitle, catdescription From ".$xoopsDB->prefix($xoopsModule->dirname()."_category")." WHERE catid='$category'");
list($cattitle, $catdescription) = $xoopsDB->fetchRow($cat_res);
echo "
.$catdescription." alt='".$cattitle."'>
"._PARTNER." ";
$pat_res=$xoopsDB->query("select sextitle, sexdescription From ".$xoopsDB->prefix($xoopsModule->dirname()."_sex")." WHERE sid='$partner'");
list($sextitle, $sexdescription) = $xoopsDB->fetchRow($pat_res);
echo "
.$sexdescription." alt='".$sextitle."'>
"._TEXTWEIGHT."
".$weight." ".$weightunit."
"._TEXTHEIGHT."
".$height." ".$heightunit."
"._TEXTAGE."
".getage($myts->makeTboxData4Show($birth))."
";
if ( $poster->isOnline() ) {
echo "![]()
";
} else {
echo "![]()
";
}
if ( $xoopsUser ) {
echo "java script:openWithSelfMain('".XOOPS_URL."/pmlite.php?send2=1&to_userid=".$poster->uid()."','pmlite',435,370);">
.XOOPS_URL."/images/icons/pm.gif' alt='".sprintf(_SENDPMTO,$poster->uname())."' /> ";
echo "";
if ( $xoopsUser && $directfriends==1) {
echo "$uid> Add to Rubrica ";
}
echo"
";
}
}
//$updatestatistic = $xoopsDB->query("UPDATE xoops_friendfinder set statistic='$newstatistic' WHERE id='$id'");
$xoopsDB->close();
} else {
echo "Unfortunatly no ID has been set so you cannot get a profile view!";
}
//include "admin/foot.php";
//************************************************************
CloseTable();
include("../../footer.php");
?>
Vict0r wrote:
yes, I found that but it's for e-xoops and I have xoops2.. so it wouldn't work..
so if anyone can help me fix the problem with friend finder I would really appreciate it.. or if you know a module that works in a similar way that might be helpful too..
thank you,
Victor