CUTCODEDOWN
Minimalist Semantic Markup

Welcome Guest
Please Login or Register

If you have registered but not recieved your activation e-mail in a reasonable amount of time, or have issues with using the registration form, please use our Contact Form for assistance. Include both your username and the e-mail you tried to register with.

Author Topic: How to close your custom modal using js  (Read 449 times)

durango_d

  • Full Member
  • ***
  • Posts: 124
  • Karma: +1/-0
How to close your custom modal using js
« on: 1 Dec 2020, 07:49:26 am »
Hi,

I was wondering how i could close your custom modal using js.   Do i need to use a click validator on the class?

This is all i could come up with so far..

Code: [Select]
        var m = document.getElementById('shareit'); //the div wrapping the modal

        //and then later if they get the alert, and close that, it also closes the modal
         m.style="display:none";

« Last Edit: 1 Dec 2020, 08:31:24 am by durango_d »
Squeeze it Harley! Don't yank it!  It's not your D...!  Squeeze it !

 

SMF spam blocked by CleanTalk

Advertisement