http://66.118.157.72/editor/editor.php
<?php require_once('../connections/fbf.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 "decimal": $theValue = ($theValue != "") ? floatval($theValue) : "NULL"; break; case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "defined": $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue; break; } return $theValue; } $editFormAction = $HTTP_SERVER_VARS['PHP_SELF']; if (isset($HTTP_SERVER_VARS['QUERY_STRING'])) { $editFormAction .= "?" . $HTTP_SERVER_VARS['QUERY_STRING']; } if ((isset($HTTP_POST_VARS["fbf_update"])) && ($HTTP_POST_VARS["fbf_update"] == "form1")) { $updateSQL = sprintf("UPDATE que_content SET entry=%s WHERE id_number=%s", GetSQLValueString($HTTP_POST_VARS['entry'], "text"), GetSQLValueString($HTTP_POST_VARS['id_number'], "int")); mysql_select_db($database_fbf, $flawlor); $Result1 = mysql_query($updateSQL, $flawlor) or die(mysql_error()); $updateGoTo = "final.php"; if (isset($HTTP_SERVER_VARS['QUERY_STRING'])) { // $updateGoTo .= (strpos($updateGoTo, '?')) ? "&" : "?"; $updateGoTo .= $HTTP_SERVER_VARS['QUERY_STRING']; } header(sprintf("Location: %s", $updateGoTo)); } mysql_select_db($database_fbf, $flawlor); $query_Recordset1 = "SELECT id_number, entry FROM que_content WHERE id_number=1"; $Recordset1 = mysql_query($query_Recordset1, $flawlor) or die(mysql_error()); $row_Recordset1 = mysql_fetch_assoc($Recordset1); $totalRows_Recordset1 = mysql_num_rows($Recordset1); include("../fckeditor/fckeditor.php"); ?>
http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd
http://www.w3.org/1999/xhtml
<form method="post" name="form1" action="<?php echo $editFormAction; ?>">
<?php $oFCKeditor = new FCKeditor('form1') ; $oFCKeditor->BasePath = '../fckeditor/' ; if ( isset($_GET['Toolbar']) ) $oFCKeditor->ToolbarSet = $_GET['Toolbar'] ; $oFCKeditor->Value = $row_Recordset1['entry'] ; $oFCKeditor->Create() ; ?>
<input type="hidden" name="id_number" value="<?php echo $row_Recordset1['id_number']; ?>">
<?php mysql_free_result($Recordset1); ?>

RE: PHP/MySQL: Problems posting input to data
RE: PHP/MySQL: Problems posting input to data
http://66.118.157.72/editor/editor2.php
<?php require_once('../connections/fbf.php'); ?><?php function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") { if ((isset($HTTP_POST_VARS["fbf_update"])) && ($HTTP_POST_VARS["fbf_update"] == "form1")) { $entryVar = $HTTP_POST_VARS['entry']; $idVar = $HTTP_POST_VARS['id_number']; $updateSQL = "UPDATE que_content SET entry = '".$entryVar."' WHERE id_number = ".$idVar; } } mysql_select_db($database_fbf, $flawlor); $query_Recordset1 = "SELECT id_number, entry FROM que_content WHERE id_number=1"; $Recordset1 = mysql_query($query_Recordset1, $flawlor) or die(mysql_error()); $row_Recordset1 = mysql_fetch_assoc($Recordset1); $totalRows_Recordset1 = mysql_num_rows($Recordset1); include("../fckeditor/fckeditor.php"); ?>http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd
http://www.w3.org/1999/xhtml
<form method="post" name="form1" action="<?php echo $editFormAction; ?>"><?php $oFCKeditor = new FCKeditor('form1') ; $oFCKeditor->BasePath = '../fckeditor/' ; if ( isset($_GET['Toolbar']) ) $oFCKeditor->ToolbarSet = $_GET['Toolbar'] ; $oFCKeditor->Value = $row_Recordset1['entry'] ; $oFCKeditor->Create() ; ?><input type="hidden" name="id_number" value="<?php echo $row_Recordset1['id_number']; ?>"><?php mysql_free_result($Recordset1); ?>RE: PHP/MySQL: Problems posting input to data
RE: PHP/MySQL: Problems posting input to data