Guten morgen/ abend ^^
Ich bin schon seit 1 stunde am suchen und ausprobieren und auch Google konnte mir nicht helfen! jetzt muss ich mal euch fragen!
Ich habe da ein Problem mit eine Code
der Code
wenn ich die seite (post.php) jetzt öffne dann bekomme ich folgende Fehlermeldung:
Kann mir da jemand helfen??
lg
oliking
Ich bin schon seit 1 stunde am suchen und ausprobieren und auch Google konnte mir nicht helfen! jetzt muss ich mal euch fragen!
Ich habe da ein Problem mit eine Code
der Code
PHP-Code:
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
if (PHP_VERSION < 6) {
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
}
$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}
$colname_posteingang = "-1";
if (isset($_SESSION['MM_Username'])) {
$colname_posteingang = $_SESSION['MM_Username'];
}
mysql_select_db($database_local, $local);
$query_posteingang = sprintf("SELECT * FROM post WHERE empfaenger = %s AND read=1", GetSQLValueString($colname_posteingang, "text"));
$posteingang = mysql_query($query_posteingang, $local) or die(mysql_error());
$row_posteingang = mysql_fetch_assoc($posteingang);
$totalRows_posteingang = mysql_num_rows($posteingang);
?>
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'read=1' at line 1
lg
oliking

Kommentar