Hallo Leute,
ich benutze das folgende Skript als Eingabeform in meinem Forum nur leider geht er nach dem Speichern in der DB nicht auf die Bestätigungsseite.
Was hab ich jetzt schon wieder falsch gemacht?
ich benutze das folgende Skript als Eingabeform in meinem Forum nur leider geht er nach dem Speichern in der DB nicht auf die Bestätigungsseite.
Was hab ich jetzt schon wieder falsch gemacht?

PHP:
<? include '../../logged_in.php'; ?>
<?php require_once('../../Connections/db.php'); ?><?php
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
$theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : $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;
}
$editFormAction = $_SERVER['PHP_SELF'];
if (isset($_SERVER['QUERY_STRING'])) {
$editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
}
if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
$insertSQL = sprintf("INSERT INTO for_beitrag (for_thema_ID, beitrag_bezeichnung, beitrag_text, beitrag_user_ID, beitrag_user_IP, beitrag_time) VALUES (%s, %s, %s, %s, %s, %s)",
GetSQLValueString($_POST['for_thema_ID'], "int"),
GetSQLValueString($_POST['beitrag_bezeichnung'], "text"),
GetSQLValueString($_POST['beitrag_text'], "text"),
GetSQLValueString($_POST['beitrag_user_ID'], "int"),
GetSQLValueString($_POST['beitrag_user_IP'], "text"),
GetSQLValueString($_POST['beitrag_time'], "text"));
mysql_select_db($database_db, $db);
$Result1 = mysql_query($insertSQL, $db) or die(mysql_error());
$insertGoTo = "for_gespeichert.php";
if (isset($_SERVER['QUERY_STRING'])) {
$insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
$insertGoTo .= $_SERVER['QUERY_STRING'];
}
}
?>