SELECT * FROM dy_classtype WHERE molds='article' and tid= ORDER BY orders desc LIMIT 1
执行错误: 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 'ORDER BY orders desc LIMIT 1' at line 1
- /www/wwwroot/www.cvcaf.com/include/mysql.php on line 39
34.
$this->arrSql[] = $sql;
35.
if( $result = mysql_query($sql, $this->conn) ){
36.
return $result;
37.
}else{
38.
if(mysql_error()!=''){
39.
40.
syError("{$sql}<br />执行错误: " . mysql_error());
}else{
41.
return TRUE;
42.
}
43.
}
44.
}
- /www/wwwroot/www.cvcaf.com/include/mysql.php on line 8
3.
class db_mysql {
4.
public $conn;
5.
public $arrSql;
6.
public function getArray($sql)
7.
{
8.
9.
if( ! $result = $this->exec($sql) )return array();
if( ! mysql_num_rows($result) )return array();
10.
$rows = array();
11.
while($rows[] = mysql_fetch_array($result,MYSQL_ASSOC)){}
12.
mysql_free_result($result);
13.
array_pop($rows);
- /www/wwwroot/www.cvcaf.com/include/syModel.php on line 55
50.
}else{
51.
$sort = "ORDER BY {$this->pk}";
52.
}
53.
$sql = "SELECT {$fields} FROM {$this->tbl_name} {$where} {$sort}";
54.
if(null != $limit)$sql = $this->_db->setlimit($sql, $limit);
55.
56.
return $this->_db->getArray($sql);
}
57.
58.
public function escape($value)
59.
{
60.
return $this->_db->__val_escape($value);
- /www/wwwroot/www.cvcaf.com/include/syModel.php on line 27
22.
if ($this->_db->showtables($value)==0){return TRUE;}else{return FALSE;}
23.
}
24.
25.
public function find($conditions = null, $sort = null, $fields = null)
26.
{
27.
28.
if( $record = $this->findAll($conditions, $sort, $fields, 1) ){
return array_pop($record);
29.
}else{
30.
return FALSE;
31.
}
32.
}
- /www/wwwroot/www.cvcaf.com/source/article.php on line 22
17.
}else{
18.
$id = $this->syArgs('id');
19.
if(!$id){message("请指定内容id");}
20.
$this->article=syDB('article')->findSql('select * from '.$this->db.' a left join '.$this->db.'_field b on (a.id=b.aid) where id='.$id.' limit 1');
21.
}
22.
23.
$this->type = syDB('classtype')->find(" molds='article' and tid=" . $this->article[0]['tid'] . " ",'orders desc');
$this->ptype = syDB('classtype')->find(" molds='article' and tid=" . $this->type['pid'] . " ",'orders desc');
24.
$rid = $this->ptype['pid'] ? $this->ptype['pid'] : $this->ptype['tid'];
25.
$this->$rid = $rid;
26.
$this->rtype = syDB('classtype')->find(" molds='article' and tid=" . $rid . " ",'orders desc');
27.
//print_r($this->type);echo $rid;
- /www/wwwroot/www.cvcaf.com/include/Functions.php on line 20
15.
$handle_controller = syClass($__controller, null, $GLOBALS['G_DY']["controller_path"] . '/' . $__controller . ".php");
16.
if (!is_object($handle_controller) || !method_exists($handle_controller, $__action)) {
17.
syError('route Error');
18.
exit;
19.
}
20.
21.
$handle_controller->$__action();
if (FALSE != $GLOBALS['G_DY']['view']['auto_display']) {
22.
$__tplname = $__controller . $GLOBALS['G_DY']['view']['auto_display_sep'] .
23.
$__action . $GLOBALS['G_DY']['view']['auto_display_suffix'];
24.
$handle_controller->auto_display($__tplname);
25.
}
- /www/wwwroot/www.cvcaf.com/index.php on line 20
15.
$mobile_os_list=array('Google Wireless Transcoder','Windows CE','WindowsCE','Symbian','Android','armv6l','armv5','Mobile','CentOS','mowser','AvantGo','Opera Mobi','J2ME/MIDP','Smartphone','Go.Web','Palm','iPAQ');
16.
$mobile_token_list=array('Profile/MIDP','Configuration/CLDC-','160×160','176×220','240×240','240×320','320×240','UP.Browser','UP.Link','SymbianOS','PalmOS','PocketPC','SonyEricsson','Nokia','BlackBerry','Vodafone','BenQ','Novarra-Vision','Iris','NetFront','HTC_','Xda_','SAMSUNG-SGH','Wapaka','DoCoMo','iPhone','iPod');
17.
18.
$found_mobile=CheckSubstrs($mobile_os_list,$useragent_commentsblock) || CheckSubstrs($mobile_token_list,$useragent);
19.
20.
spRun();