From e8a0227e77c03b638c15044a67d0a5480a435919 Mon Sep 17 00:00:00 2001 From: SBD Date: Tue, 28 Nov 2023 16:20:01 +0300 Subject: [PATCH] 0.0.40 --- static/aerbimJS.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/static/aerbimJS.js b/static/aerbimJS.js index a59d5d7..47c5984 100644 --- a/static/aerbimJS.js +++ b/static/aerbimJS.js @@ -76,14 +76,16 @@ function replaceHrefOnOnclick () { elements.forEach(function (){ let cur_el = elements[i] if (cur_el.attributes.hasOwnProperty("href")){ + cur_el.setAttribute("onclick",`renderContent(this)`) let str = cur_el.outerHTML let str_f_replace = cur_el.href str_f_replace = str_f_replace.replace(`${window.location.origin}`,'') str_f_replace = `href="${str_f_replace}"` str = str.replace(str_f_replace,'') str = str.replace('"target="_blank""','') + cur_el.outerHTML = str - cur_el.setAttribute("onclick",`renderContent(this)`) + } i++ })