From 3dcf867634fd9ae97ed76009175a91c2786c0d46 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Wed, 18 Jan 2017 08:09:50 +0100 Subject: [PATCH] add code to open and close popup box --- styles/bootstrap/application.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/styles/bootstrap/application.js b/styles/bootstrap/application.js index 037f2731b..c67376d3f 100644 --- a/styles/bootstrap/application.js +++ b/styles/bootstrap/application.js @@ -989,9 +989,10 @@ $(document).ready(function() { /* {{{ */ }); }); - $('span.openpopupbox').on('click', function(e) { - $('div.popupbox').toggle(); - console.log('Hallo'); + $("body").on("click", "span.openpopupbox", function(e) { + $(""+$(e.target).data("href")).toggle(); + }); + $("body").on("click", "span.closepopupbox", function(e) { + $(this).parent().hide(); }); - }); /* }}} */