summaryrefslogtreecommitdiffstats
path: root/source/_includes/post/date.html
diff options
context:
space:
mode:
authorSkyArrow <tommy351@gmail.com>2012-01-24 14:53:22 +0100
committerSkyArrow <tommy351@gmail.com>2012-01-24 14:53:22 +0100
commit1c574d24b7fdd482499fa9553c19342b6a4d391e (patch)
tree3381ce235c72044d6fa76243e9d6948c737a6e4f /source/_includes/post/date.html
downloadoctopress-theme-jeyzu-1c574d24b7fdd482499fa9553c19342b6a4d391e.zip
octopress-theme-jeyzu-1c574d24b7fdd482499fa9553c19342b6a4d391e.tar.gz
created
Diffstat (limited to 'source/_includes/post/date.html')
-rw-r--r--source/_includes/post/date.html15
1 files changed, 15 insertions, 0 deletions
diff --git a/source/_includes/post/date.html b/source/_includes/post/date.html
new file mode 100644
index 0000000..ecf1ad7
--- /dev/null
+++ b/source/_includes/post/date.html
@@ -0,0 +1,15 @@
+{% capture date %}{{ page.date }}{{ post.date }}{% endcapture %}
+{% capture date_formatted %}{{ page.date_formatted }}{{ post.date_formatted }}{% endcapture %}
+{% capture has_date %}{{ date | size }}{% endcapture %}
+
+{% capture updated %}{{ page.updated }}{{ post.updated }}{% endcapture %}
+{% capture updated_formatted %}{{ page.updated_formatted }}{{ post.updated_formatted }}{% endcapture %}
+{% capture was_updated %}{{ updated | size }}{% endcapture %}
+
+{% if has_date != '0' %}
+ {% capture time %}<time datetime="{{ date | datetime | date_to_xmlschema }}" pubdate{% if updated %} data-updated="true"{% endif %}>{{ date_formatted }}</time>{% endcapture %}
+{% endif %}
+
+{% if was_updated != '0' %}
+ {% capture updated %}<time datetime="{{ updated | datetime | date_to_xmlschema }}" class="updated">Updated {{ updated_formatted }}</time>{% endcapture %}
+{% else %}{% assign updated = false %}{% endif %} \ No newline at end of file