글쓰기하고 저장하면...
아래와 같은 에러가 계속 떨어집니다.
Warning: Prepare fails (E [SQLSTATE=IX 000 SQLCODE=-617]) in /usr/local/apache/htdocs/myung/mtboard.php on line 415
Warning: Supplied argument is not a valid Informix Result resource in /usr/local/apache/htdocs/myung/mtboard.php on line 417
글쓰기에 문제가 째끔 있네요
mtboard.php 글쓰기 소스---------
function write($name,
$email,
$title,
$password,
$content)
{
$que="select max(parent_id) from board";
$this->rlt = ifx_query($que, $this->con);
$parent_id = ifx_fetch_row($this->rlt, "first");
$max_parent_id = $parent_id["(max)"] + 1;
ifx_free_result($this->rlt);
$title=htmlspecialchars($title);
$name=addslashes($name);
$title=addslashes($title);
$content=addslashes($content);
$date=date("Y.m.t");
$time=date("h:i:s");
$password=crypt($password, $password);
$blob_content=ifx_create_blob(1, 0, $content);
$blob_id[] = $blob_content;
// echo $email.$title."<br>";
$que="insert into board (parent_id, name, title, date, time, password, email, content) values
('$max_parent_id','$name','$title', '$date', '$time', '$password', '$email', '$content')";
echo ($que);
$rid=ifx_prepare($que, $this->con, $blob_id); ====> 415
if(!ifx_do($this->rid)) { =====>417
die ("글쓰기에 문제가 째끔 있네요");
echo ifx_error();
return;
}
}
|