summaryrefslogtreecommitdiff
path: root/app/utils/static/image-loader.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/utils/static/image-loader.js')
-rw-r--r--app/utils/static/image-loader.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/utils/static/image-loader.js b/app/utils/static/image-loader.js
new file mode 100644
index 0000000..90054de
--- /dev/null
+++ b/app/utils/static/image-loader.js
@@ -0,0 +1,8 @@
+function add_images(){
+ var el = document.getElementById("id_body_markdown");
+ var iframe = '<iframe frameborder="0" style="border: #dddddd 1px solid;margin-left: 20px;width:330px; height:720px;" src="/luximages/insert/?textarea='+el.id+'"></iframe>';
+ el.insertAdjacentHTML('afterend', iframe);
+}
+document.addEventListener("DOMContentLoaded", function(event) {
+ add_images();
+});