摘要: 1.打印AR结果1 $user = 模型->model()->findAll();2 foreach($user $v) {3 var_dump($v->attributes);4 } 阅读全文
posted @ 2012-02-18 23:58 mr.coke 阅读(180) 评论(0) 推荐(0) 编辑
摘要: 打开hosts文件 在最下面添加74.125.71.101 code.google.com74.125.71.102 code.google.com74.125.71.138 code.google.com即可解决问题 阅读全文
posted @ 2012-02-18 22:26 mr.coke 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 1 Yii::app()->clientScript->registerScriptFile(Yii::app()->theme->baseUrl.'/js/jQuery.js');2 Yii::app()->clientScript->registerCoreScript('jquery'); 阅读全文
posted @ 2012-02-18 21:37 mr.coke 阅读(420) 评论(0) 推荐(0) 编辑
摘要: main.php 1 <?php 2 3 // uncomment the following to define a path alias 4 // Yii::setPathOfAlias('local','path/to/local-folder'); 5 6 // This is the main Web application configuration. Any writable 7 // CWebApplication properties can be configured here. 8 return array( 9 'baseP 阅读全文
posted @ 2012-02-18 20:52 mr.coke 阅读(3491) 评论(0) 推荐(0) 编辑
摘要: YII中的日志很好很强大,允许你把日志信息存放到数据库,发送到制定email,存放咋文件中,意见显示页面是,甚至可以用来做性能分析。YII中日志的基本配置:/yii_dev/testwebap/protected/config/main.php 1 'log'=>array( 2 'class'=>'CLogRouter', 3 'routes'=>array( 4 array( 5 'class'=>'CFileLogRoute', 6 ... 阅读全文
posted @ 2012-02-18 19:46 mr.coke 阅读(10561) 评论(0) 推荐(1) 编辑