오류좀 봐주세요... 정보
오류좀 봐주세요...본문
select wr_id, ca_name, wr_subject, wr_content, mb_id, wr_name, wr_homepage, wr_email, wr_datetime, wr_last from g4_write_01_6 where 1=1 and wr_is_comment=0 and wr_datetime >= 1970-01-01 08:59:59 order by wr_id desc limit 0,100
1064 : 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 '08:59:59 order by wr_id desc limit 0,100' at line 2
error file : /syndi/syndi_echo.php
신디케이션 연동중인데 위와 같은 오류때문에 안된다고 하네요.
아래는 syndi_echo.php 파일 소스입니다. 이문제 때문에 한달이 넘게 사용을 못하고 있네요. 프로그램 초보라 어디가 잘못된건지 잘 모르겠습니다. 도움좀 주세요...
<?php
/**
* @file syndi_echo.php
* @author sol (*** 개인정보보호를 위한 이메일주소 노출방지 ***)
* @brief Print Syndication Data XML
*/
header("Content-Type: text/html; charset=UTF-8");
header("Pragma: no-cache");
if(version_compare(PHP_VERSION, '5.3.0') >= 0)
{
date_default_timezone_set(@date_default_timezone_get());
}
$syndi_path = dirname(__FILE__);
// include class
include $syndi_path . '/libs/SyndicationHandler.class.php';
include $syndi_path . '/libs/SyndicationObject.class.php';
include $syndi_path . '/libs/SyndicationSite.class.php';
include $syndi_path . '/libs/SyndicationChannel.class.php';
include $syndi_path . '/libs/SyndicationArticle.class.php';
include $syndi_path . '/libs/SyndicationDeleted.class.php';
// config & custom func for site
include $syndi_path . '/config/site.config.php';
include $syndi_path . '/func/site.func.php';
$oSyndicationHandler = &SyndicationHandler::getInstance();
$oSyndicationHandler->setArgument();
echo $oSyndicationHandler->getXML();
?>
1064 : 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 '08:59:59 order by wr_id desc limit 0,100' at line 2
error file : /syndi/syndi_echo.php
신디케이션 연동중인데 위와 같은 오류때문에 안된다고 하네요.
아래는 syndi_echo.php 파일 소스입니다. 이문제 때문에 한달이 넘게 사용을 못하고 있네요. 프로그램 초보라 어디가 잘못된건지 잘 모르겠습니다. 도움좀 주세요...
<?php
/**
* @file syndi_echo.php
* @author sol (*** 개인정보보호를 위한 이메일주소 노출방지 ***)
* @brief Print Syndication Data XML
*/
header("Content-Type: text/html; charset=UTF-8");
header("Pragma: no-cache");
if(version_compare(PHP_VERSION, '5.3.0') >= 0)
{
date_default_timezone_set(@date_default_timezone_get());
}
$syndi_path = dirname(__FILE__);
// include class
include $syndi_path . '/libs/SyndicationHandler.class.php';
include $syndi_path . '/libs/SyndicationObject.class.php';
include $syndi_path . '/libs/SyndicationSite.class.php';
include $syndi_path . '/libs/SyndicationChannel.class.php';
include $syndi_path . '/libs/SyndicationArticle.class.php';
include $syndi_path . '/libs/SyndicationDeleted.class.php';
// config & custom func for site
include $syndi_path . '/config/site.config.php';
include $syndi_path . '/func/site.func.php';
$oSyndicationHandler = &SyndicationHandler::getInstance();
$oSyndicationHandler->setArgument();
echo $oSyndicationHandler->getXML();
?>
댓글 전체
1970-01-01 08:59:59 <== 날짜부분에서 중간에 빈공간이 있어서 아마 문법에러가 나는것 같습니다.
1970-01-01 08:59:59 => '1970-01-01 08:59:59' (싱글쿼테이션으로 감싸주시면 정상적으로 동작할 것 같습니다.)
1970-01-01 08:59:59 => '1970-01-01 08:59:59' (싱글쿼테이션으로 감싸주시면 정상적으로 동작할 것 같습니다.)
별이되고싶어요님, 답변 진심으로 감사합니다. 근데, 어떤 파일에서 어디를 수정해야 하나요?;;
/syndi/syndi_echo.php 파일의
select wr_id, ca_name, wr_subject, wr_content, mb_id, wr_name, wr_homepage, wr_email, wr_datetime, wr_last from g4_write_01_6 where 1=1 and wr_is_comment=0 and wr_datetime >= 1970-01-01 08:59:59 order by wr_id desc limit 0,100 <== 이부분을 찾으신 후
1970-01-01 08:59:59 <== 이곳에 작은따옴표를 씌워주시면 됩니다. 이부분이 '$변수명' 로 되어 있을 수 있습니다. 이럴경우 '$변수명' 으로 바꿔주시면 됩니다.
수정해보신 후 안되시면 /syndi/syndi_echo.php 파일 소스를 올려주시면 알려드겠습니다.
select wr_id, ca_name, wr_subject, wr_content, mb_id, wr_name, wr_homepage, wr_email, wr_datetime, wr_last from g4_write_01_6 where 1=1 and wr_is_comment=0 and wr_datetime >= 1970-01-01 08:59:59 order by wr_id desc limit 0,100 <== 이부분을 찾으신 후
1970-01-01 08:59:59 <== 이곳에 작은따옴표를 씌워주시면 됩니다. 이부분이 '$변수명' 로 되어 있을 수 있습니다. 이럴경우 '$변수명' 으로 바꿔주시면 됩니다.
수정해보신 후 안되시면 /syndi/syndi_echo.php 파일 소스를 올려주시면 알려드겠습니다.
아, 별이되고싶어요님 정말 감사합니다. 지적해주신 부분이 맞았네요...고마워요!