##// END OF EJS Templates
Don't run time conversion if Intl not available in browser. Also convert...
neko259 -
r1023:0040ea34 default
parent child Browse files
Show More
@@ -23,6 +23,7 b''
23 23 for the JavaScript code in this page.
24 24 */
25 25
26 if (window.Intl) {
26 27 var LOCALE = window.navigator.language;
27 28 var FORMATTER = new Intl.DateTimeFormat(
28 29 LOCALE,
@@ -31,6 +32,7 b' var FORMATTER = new Intl.DateTimeFormat('
31 32 hour: 'numeric', minute: '2-digit', second: '2-digit'
32 33 }
33 34 );
35 }
34 36
35 37 /**
36 38 * An email is a hidden file to prevent spam bots from posting. It has to be
@@ -53,6 +55,10 b' function highlightCode(node) {'
53 55 * Translate timestamps to local ones for all <time> tags inside node.
54 56 */
55 57 function translate_time(node) {
58 if (window.Intl === null) {
59 return;
60 }
61
56 62 var elements;
57 63
58 64 if (node === null) {
@@ -26,7 +26,7 b''
26 26 {% endcomment %}
27 27 {% if thread.archived %}
28 28 {% if is_opening %}
29 — {{ thread.bump_time }}
29 <time datetime="{{ thread.bump_time|date:'c' }}">{{ thread.bump_time|date:'r' }}</time>
30 30 {% endif %}
31 31 {% endif %}
32 32 {% if is_opening and need_open_link %}
General Comments 0
You need to be logged in to leave comments. Login now