/*
* nocache.js
*
* Date: 2023.4.21
*
* Copyright (c) 2020, 2021, 2023 AOK (aokura.com)
*
*/
if (!apply_nocache) {
var apply_nocache = function(selectors) {
var t = Date.now();
var el = document.querySelectorAll(selectors);
el.forEach(function(x) {
if (x.tagName === 'IMG') {
var src = x.getAttribute('src');
if (/\.(jpe?g|gif|png)$/i.test(src)) {
x.setAttribute('src', `${src}?${t}`);
}
} else if (x.tagName === 'A') {
var href = x.getAttribute('href');
if (href.match(/\.(pdf|docx?|xlsx?|pptx?)$/i)) {
x.setAttribute('href', `${href}?${t}.${RegExp.$1}`);
x.setAttribute('target', '_blank');
}
}
});
};
}
if (!include_nocache) {
var include_nocache = function(path) {
var t = Date.now();
if (/\.css$/i.test(path)) {
document.write('');
} else if (/\.js$/i.test(path)) {
document.write('