博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
关于TP5模板输出时间戳问题--A non well formed numeric value encountered
阅读量:4678 次
发布时间:2019-06-09

本文共 840 字,大约阅读时间需要 2 分钟。

  某日。因为一个项目。控制器我是这么写的

1 /** 2    * get admin/Picture/index 3    * 显示所有图册信息 4    * @return view 5    */ 6     public function index() 7     { 8         $data = $this->model->getAllPicture(); 9        10         // dump($data);11         $this->assign('data',$data);12         return view();13     }

模型我是这么写的

1 /**2   *  取得所有3   */4   public function getAllPicture(){5       return Cache::tag('admin_cache_data')->remember('cache_picture',function(){6             return Db('picture')->field('id,category_id,title,tags,download_count,picture_cover_url,preview_count,picture_details_id,status,update_time,sort')->select();7       });8   }

然后。报了这个错。

    A non well formed numeric value encountered

我心里一万个草泥马。。。

 

后来。过程很艰辛。。。

 

啥都别说了。在config.php加上这句。搞定。

 

参考:http://www.thinkphp.cn/topic/45698.html

 

转载于:https://www.cnblogs.com/chenrunxuan/p/7247941.html

你可能感兴趣的文章
一些小例子
查看>>
WebSocket4Net 0.5发布
查看>>
转 Winmail 退信分析大全 (2012,05,02 更新)
查看>>
499 单词计数 (Map Reduce版本)
查看>>
python笔记
查看>>
2、openSession和getCurrentSession方法的区别
查看>>
msgbox.js的修改使在iframe的可视区域显示
查看>>
a、b交换
查看>>
[SDOI2015]序列统计
查看>>
LaTeX技巧892: Ubuntu 安装新版本TeXLive并更新
查看>>
昨天用的流量有点多60M
查看>>
kafka中的消费组
查看>>
用SDWebImage加载FLAnimatedImage
查看>>
Linux中常用操作命令
查看>>
asp.net core使用gzip
查看>>
野指针产生
查看>>
Java replace & replaceAll
查看>>
ios8--加载图片
查看>>
netty3---传统IO,NIO,nettyIO
查看>>
js--09定时器
查看>>