summaryrefslogtreecommitdiff
path: root/includes
diff options
context:
space:
mode:
Diffstat (limited to 'includes')
-rw-r--r--includes/ShowUserPicture.php58
-rwxr-xr-xincludes/funktion_user.php42
2 files changed, 21 insertions, 79 deletions
diff --git a/includes/ShowUserPicture.php b/includes/ShowUserPicture.php
deleted file mode 100644
index 0b61d153..00000000
--- a/includes/ShowUserPicture.php
+++ /dev/null
@@ -1,58 +0,0 @@
-<?PHP
-
-include ("../includes/config.php");
-include ("../includes/error_handler.php");
-include ("../includes/config_db.php");
-if( !isset($_SESSION)) session_start();
-include ("../includes/secure.php");
-
-
-// Parameter check
-if( !isset($_GET["UID"]) )
- $_GET["UID"]= "-1";
-
-$SQL= "SELECT * FROM `UserPicture` WHERE `UID`='". $_GET["UID"]. "'";
-$res = mysql_query( $SQL, $con);
-
-if( mysql_num_rows($res) == 1)
-{
- //genügend rechte
- if( !isset($_SESSION['UID']) || $_SESSION['UID'] == -1)
- {
- header( "HTTP/1.0 403 Forbidden");
- die( "403 Forbidden");
- }
-
- // ist das bild sichtbar?
- if( (mysql_result($res, 0, "show")=="N") AND
- ($_SESSION['UID']!=$_GET["UID"]) AND
- ($_SESSION['CVS'][ "admin/UserPicture.php" ] == "N"))
- {
- $SQL= "SELECT * FROM `UserPicture` WHERE `UID`='-1'";
- $res = mysql_query( $SQL, $con);
- if( mysql_num_rows($res) != 1)
- {
- header( 'HTTP/1.0 404 Not Found');
- die( "404 Not Found");
- }
- }
-
- /// bild aus db auslesen
- $bild = mysql_result($res, 0, "Bild");
-
- // ausgabe bild
- header( "Accept-Ranges: bytes");
- header( "Content-Length: ". strlen($bild));
- header( "Content-type: ". mysql_result($res, 0, "ContentType"));
- header( "Cache-control: public");
- header( "Cache-request-directive: min-fresh = 120");
- header( "Cache-request-directive: max-age = 360");
- echo $bild;
-}
-else
-{
- header( 'HTTP/1.0 404 Not Found');
- die( "404 Not Found");
-}
-
-?>
diff --git a/includes/funktion_user.php b/includes/funktion_user.php
index cf4ae10c..cce7d5af 100755
--- a/includes/funktion_user.php
+++ b/includes/funktion_user.php
@@ -34,26 +34,26 @@ function TID2Type($TID)
function ReplaceSmilies($eckig) {
$neueckig = $eckig;
- $neueckig = str_replace(";o))","<img src=\"./inc/smiles/icon_redface.gif\">",$neueckig);
- $neueckig = str_replace(":-))","<img src=\"./inc/smiles/icon_redface.gif\">",$neueckig);
- $neueckig = str_replace(";o)","<img src=\"./inc/smiles/icon_wind.gif\">",$neueckig);
- $neueckig = str_replace(":)","<img src=\"./inc/smiles/icon_smile.gif\">",$neueckig);
- $neueckig = str_replace(":-)","<img src=\"./inc/smiles/icon_smile.gif\">",$neueckig);
- $neueckig = str_replace(":(","<img src=\"./inc/smiles/icon_sad.gif\">",$neueckig);
- $neueckig = str_replace(":-(","<img src=\"./inc/smiles/icon_sad.gif\">",$neueckig);
- $neueckig = str_replace(":o(","<img src=\"./inc/smiles/icon_sad.gif\">",$neueckig);
- $neueckig = str_replace(":o)","<img src=\"./inc/smiles/icon_lol.gif\">",$neueckig);
- $neueckig = str_replace(";o(","<img src=\"./inc/smiles/icon_cry.gif\">",$neueckig);
- $neueckig = str_replace(";(","<img src=\"./inc/smiles/icon_cry.gif\">",$neueckig);
- $neueckig = str_replace(";-(","<img src=\"./inc/smiles/icon_cry.gif\">",$neueckig);
- $neueckig = str_replace("8)","<img src=\"./inc/smiles/icon_rolleyes.gif\">",$neueckig);
- $neueckig = str_replace("8o)","<img src=\"./inc/smiles/icon_rolleyes.gif\">",$neueckig);
- $neueckig = str_replace(":P","<img src=\"./inc/smiles/icon_evil.gif\">",$neueckig);
- $neueckig = str_replace(":-P","<img src=\"./inc/smiles/icon_evil.gif\">",$neueckig);
- $neueckig = str_replace(":oP","<img src=\"./inc/smiles/icon_evil.gif\">",$neueckig);
- $neueckig = str_replace(";P","<img src=\"./inc/smiles/icon_mad.gif\">",$neueckig);
- $neueckig = str_replace(";oP","<img src=\"./inc/smiles/icon_mad.gif\">",$neueckig);
- $neueckig = str_replace("?)","<img src=\"./inc/smiles/icon_question.gif\">",$neueckig);
+ $neueckig = str_replace(";o))","<img src=\"/pic/smiles/icon_redface.gif\">",$neueckig);
+ $neueckig = str_replace(":-))","<img src=\"/pic/smiles/icon_redface.gif\">",$neueckig);
+ $neueckig = str_replace(";o)","<img src=\"/pic/smiles/icon_wind.gif\">",$neueckig);
+ $neueckig = str_replace(":)","<img src=\"/pic/smiles/icon_smile.gif\">",$neueckig);
+ $neueckig = str_replace(":-)","<img src=\"/pic/smiles/icon_smile.gif\">",$neueckig);
+ $neueckig = str_replace(":(","<img src=\"/pic/smiles/icon_sad.gif\">",$neueckig);
+ $neueckig = str_replace(":-(","<img src=\"/pic/smiles/icon_sad.gif\">",$neueckig);
+ $neueckig = str_replace(":o(","<img src=\"/pic/smiles/icon_sad.gif\">",$neueckig);
+ $neueckig = str_replace(":o)","<img src=\"/pic/smiles/icon_lol.gif\">",$neueckig);
+ $neueckig = str_replace(";o(","<img src=\"/pic/smiles/icon_cry.gif\">",$neueckig);
+ $neueckig = str_replace(";(","<img src=\"/pic/smiles/icon_cry.gif\">",$neueckig);
+ $neueckig = str_replace(";-(","<img src=\"/pic/smiles/icon_cry.gif\">",$neueckig);
+ $neueckig = str_replace("8)","<img src=\"/pic/smiles/icon_rolleyes.gif\">",$neueckig);
+ $neueckig = str_replace("8o)","<img src=\"/pic/smiles/icon_rolleyes.gif\">",$neueckig);
+ $neueckig = str_replace(":P","<img src=\"/pic/smiles/icon_evil.gif\">",$neueckig);
+ $neueckig = str_replace(":-P","<img src=\"/pic/smiles/icon_evil.gif\">",$neueckig);
+ $neueckig = str_replace(":oP","<img src=\"/pic/smiles/icon_evil.gif\">",$neueckig);
+ $neueckig = str_replace(";P","<img src=\"/pic/smiles/icon_mad.gif\">",$neueckig);
+ $neueckig = str_replace(";oP","<img src=\"/pic/smiles/icon_mad.gif\">",$neueckig);
+ $neueckig = str_replace("?)","<img src=\"/pic/smiles/icon_question.gif\">",$neueckig);
return $neueckig;
}
@@ -98,7 +98,7 @@ function displayavatar( $UID, $height="30")
$aerg = mysql_query ($asql, $con);
if( mysql_num_rows($aerg) )
if( mysql_result($aerg, 0, "Avatar") > 0)
- return ("&nbsp;<img src=\"./inc/avatar/avatar". mysql_result($aerg, 0, "Avatar"). ".gif\">");
+ return ("&nbsp;<img src=\"/pic/avatar/avatar". mysql_result($aerg, 0, "Avatar"). ".gif\">");
}