sql修复
This commit is contained in:
parent
9399e82b8b
commit
dac4e4e27c
|
@ -70,7 +70,7 @@ class IndexController extends Zend_Controller_Action
|
||||||
$this->view->news = $rows;
|
$this->view->news = $rows;
|
||||||
|
|
||||||
$time = date("Y-m-d H:i:s",time());
|
$time = date("Y-m-d H:i:s",time());
|
||||||
$sql = "SELECT * FROM archive WHERE is_pub=true AND ts_published<'$time' LIMIT 8 order by ts_published desc";
|
$sql = "SELECT * FROM archive WHERE is_pub=true AND ts_published<'$time' order by ts_published desc LIMIT 8 ";
|
||||||
$sth = $this->db->query($sql);
|
$sth = $this->db->query($sql);
|
||||||
$rows = $sth->fetchAll(PDO::FETCH_BOTH);
|
$rows = $sth->fetchAll(PDO::FETCH_BOTH);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue