Deaktivieren Sie Popup auf einem bestimmten ElementJquery

JQuery-Programmierung
Anonymous
 Deaktivieren Sie Popup auf einem bestimmten Element

Post by Anonymous »

i have a popup on my site which opens when user clicks anywhere on page
I wan to disable it from opening when user clicks on a specific element (in this case a DIV which has ID and CLASS)
(clicking on this specific DIV, will open a direct link to another page on site)
Here is how it is:

Code: Select all


 [url=LINK2]LINK2[/url] 

...... page content
(function(){const urlToOpen = "my_site/LINK1";document.addEventListener('click', function(event) {event.preventDefault();window.open(urlToOpen, '_blank');}});})();

Ich möchte das Öffnungslink 1 deaktivieren, wenn der Benutzer mit CALSS1 oder DIV mit ID1

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post