1 个回答

时间的问题我已经解决了,围观的同学或者遇到问题的同学看一下下面的代码就好,具体路径在这里:
\octopress\source_includes\post\date.html

代码:

{% capture date %}{{ page.date }}{{ post.date }}{% endcapture %}
{% capture date_formatted %}{% if page.date %}{{ page.date | date: site.date_format }}{% endif %}{% if post.date %}{{ post.date | date: site.date_format }}{% endif %}{% endcapture %}
{% capture has_date %}{{ date | size }}{% endcapture %}
{% capture updated %}{{ page.updated }}{{ post.updated }}{% endcapture %}
{% capture updated_formatted %}{% if page.updated %}{{ page.updated | date: site.date_format }}{% endif %}{% if post.updated %}{{ post.updated | date: site.date_format }}{% endif %}{% endcapture %}
{% capture was_updated %}{{ updated | size }}{% endcapture %}
{% if has_date != '0' %}
{% capture time %} {% endcapture %}
{% endif %}
{% if was_updated != '0' %}
{% capture updated %} {% endcapture %}
{% else %}{% assign updated = false %}{% endif %}

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题