From dac4e4e27cdc364a75389dc2bca2d7c9455dcd52 Mon Sep 17 00:00:00 2001 From: wlx Date: Fri, 11 Jan 2013 01:31:23 +0000 Subject: [PATCH] =?UTF-8?q?sql=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/default/controllers/IndexController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/default/controllers/IndexController.php b/application/default/controllers/IndexController.php index 98b52505..cfa4df82 100755 --- a/application/default/controllers/IndexController.php +++ b/application/default/controllers/IndexController.php @@ -70,7 +70,7 @@ class IndexController extends Zend_Controller_Action $this->view->news = $rows; $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); $rows = $sth->fetchAll(PDO::FETCH_BOTH);