|
|
@ -21,10 +21,10 @@ if ($("#description").length) {
|
|
|
|
var results = /(\d{4})[-\/\\](\d{1,2})[-\/\\](\d{1,2})/.exec(this.value); // YYYY-MM-DD
|
|
|
|
var results = /(\d{4})[-\/\\](\d{1,2})[-\/\\](\d{1,2})/.exec(this.value); // YYYY-MM-DD
|
|
|
|
if (results) {
|
|
|
|
if (results) {
|
|
|
|
pubDate = new Date(results[1], parseInt(results[2], 10) - 1, results[3]) || new Date(this.value);
|
|
|
|
pubDate = new Date(results[1], parseInt(results[2], 10) - 1, results[3]) || new Date(this.value);
|
|
|
|
}
|
|
|
|
|
|
|
|
$("#fake_pubdate")
|
|
|
|
$("#fake_pubdate")
|
|
|
|
.val(pubDate.toLocaleDateString(language))
|
|
|
|
.val(pubDate.toLocaleDateString(language))
|
|
|
|
.removeClass("hidden");
|
|
|
|
.removeClass("hidden");
|
|
|
|
|
|
|
|
}
|
|
|
|
}).trigger("change");
|
|
|
|
}).trigger("change");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|