0)
$SQL = "SELECT Nick FROM `User` WHERE UID='$UID'";
else
$SQL = "SELECT Name FROM `Groups` WHERE UID='$UID'";
$Erg = sql_select($SQL);
if (count($Erg) > 0) {
if ($UID > 0)
return $Erg[0]['Nick'];
else
return "Group-" . $Erg[0]['Name'];
} else {
if ($UID == -1)
return "Guest";
else
return "UserID $UID not found";
}
}
function TID2Type($TID) {
global $con;
$SQL = "SELECT Name FROM `EngelType` WHERE TID='$TID'";
$Erg = mysql_query($SQL, $con);
if (mysql_num_rows($Erg))
return mysql_result($Erg, 0);
else
return "";
}
function ReplaceSmilies($neueckig) {
global $url, $ENGEL_ROOT;
$neueckig = str_replace(";o))", "", $neueckig);
$neueckig = str_replace(":-))", "", $neueckig);
$neueckig = str_replace(";o)", "", $neueckig);
$neueckig = str_replace(":)", "", $neueckig);
$neueckig = str_replace(":-)", "", $neueckig);
$neueckig = str_replace(":(", "", $neueckig);
$neueckig = str_replace(":-(", "", $neueckig);
$neueckig = str_replace(":o(", "", $neueckig);
$neueckig = str_replace(":o)", "", $neueckig);
$neueckig = str_replace(";o(", "", $neueckig);
$neueckig = str_replace(";(", "", $neueckig);
$neueckig = str_replace(";-(", "", $neueckig);
$neueckig = str_replace("8)", "", $neueckig);
$neueckig = str_replace("8o)", "", $neueckig);
$neueckig = str_replace(":P", "", $neueckig);
$neueckig = str_replace(":-P", "", $neueckig);
$neueckig = str_replace(":oP", "", $neueckig);
$neueckig = str_replace(";P", "", $neueckig);
$neueckig = str_replace(";oP", "", $neueckig);
$neueckig = str_replace("?)", "", $neueckig);
return $neueckig;
}
function GetPicturShow($UID) {
global $con;
$SQL = "SELECT `show` FROM `UserPicture` WHERE `UID`='$UID'";
$res = mysql_query($SQL, $con);
if (mysql_num_rows($res) == 1)
return mysql_result($res, 0, 0);
else
return "";
}
function displayPictur($UID, $height = "30") {
global $url, $ENGEL_ROOT;
if ($height > 0)
return ("");
else
return ("");
}
function displayavatar($UID, $height = "30") {
global $con, $url, $ENGEL_ROOT;
if (GetPicturShow($UID) == 'Y')
return " " . displayPictur($UID, $height);
// show avator
$asql = "select * from User where UID = $UID";
$aerg = mysql_query($asql, $con);
if (mysql_num_rows($aerg))
if (mysql_result($aerg, 0, "Avatar") > 0)
return (" ");
}
function UIDgekommen($UID) {
global $con;
$SQL = "SELECT `Gekommen` FROM `User` WHERE UID='$UID'";
$Erg = mysql_query($SQL, $con);
if (mysql_num_rows($Erg))
return mysql_result($Erg, 0);
else
return "0";
}
?>