From 4ff647569a7119a77b7c4a54c19400c9eb023a35 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Tue, 29 Sep 2020 12:47:12 +0200 Subject: Detail: add a link to generate iframe --- chimere/static/saclay/js/interface.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'chimere/static/saclay/js/interface.js') diff --git a/chimere/static/saclay/js/interface.js b/chimere/static/saclay/js/interface.js index 413a50b..d3e756f 100644 --- a/chimere/static/saclay/js/interface.js +++ b/chimere/static/saclay/js/interface.js @@ -598,3 +598,18 @@ var init_modal_window = function(){ }); }; +var generate_iframe = function(){ + var html; + if (update_permalink){ + update_permalink(); + var permalink = window.location.protocol + "//" + window.location.host + $("#permalink").attr('href'); + html = ''; + html = html.replace(//g, ">"); + html = "
" + html + "
"; + html = "

Pour insérer la carte sur un site web, veuillez recopier le code suivant :

" + html; + } else { + html = "

Erreur lors de l'initialisation de l'iframe.

" + } + $("#modal-default-message .modal-body").html(html); + $('#modal-default-message').modal("show"); +} \ No newline at end of file -- cgit v1.2.3