使用time_diff时出现:diff.ago.hour;

解决:
1:引入"knplabs/knp-time-bundle": "^1.7",
https://github.com/KnpLabs/KnpTimeBundle 2:new Knp\Bundle\TimeBundle\KnpTimeBundle(), 3:配置config.yml
framework:
#esi: ~
translator: { fallbacks: ['%locale%'] } 这样时间是显示正常了 2 小时前


最新文章

  1. 离线安装 Python 2.7, paramiko 和 tornado
  2. linux下flash的安装
  3. jQuery—DOM操作
  4. ARM指令集(上)
  5. Twitter 登录和分享
  6. UIWebView swift
  7. 从user 登陆開始
  8. linux内核分析之内存管理
  9. 【noip2007】树网的核
  10. poj 3687 Labeling Balls【反向拓扑】
  11. ArcGis : unable to save as template this document is already based on another template
  12. An impassioned circulation of affection
  13. Java项目专栏之数据库建表
  14. python多线程与多进程--存活主机ping扫描以及爬取股票价格
  15. CSAPC2008 skyline
  16. 【JS面试向】选择排序、桶排序、冒泡排序和快速排序简介
  17. beanutils的使用
  18. jQuery学习之二
  19. Kattis之旅——Factovisors
  20. java中String new和直接赋值的区别

热门文章

  1. azkaban2.5 具体配置以及使用方式
  2. 重入锁的好搭档:Condition条件(读书笔记)
  3. [脚本编程] 过云盾、D盾各种盾shell
  4. Android学习(十二) ContentProvider
  5. 通过rinetd实现端口转发,同时访问阿里云RDS的内外网
  6. mysql学习笔记(编辑中)
  7. 调用iPhone的短信
  8. 正则表达式 判断IP 数字
  9. sklearn--feature extract--人脸识别
  10. android开发游记:meterial design 5.0 开源控件整套合集 及使用demo