Title: JavaScript Method to disable Supsystic popup
Last modified: February 27, 2017

---

# JavaScript Method to disable Supsystic popup

 *  Resolved [simonalwild](https://wordpress.org/support/users/simonalwild/)
 * (@simonalwild)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/javascript-method-to-disable-popup/)
 * We have integrated a gravity form into a popup. I was wondering if there is a
   JavaScript method to disable a popup or prevent it from showing when a user hits
   the submit button? Here is my jQuery function:
 *     ```
       jQuery(window).load(function() {
         jQuery("#gform_submit_button_15").click(function(){
           localStorage.setItem('popup_submitted', true);
         });
         if(localStorage.getItem('popup_submitted') === true) {
           // Method to disable popup goes here.
         }
       });
       ```
   
 * I have noticed that this can’t be done on a user action filter as I don’t think
   the plugin has gravity forms integration.
 * Thanks,
 * Simon
    -  This topic was modified 9 years, 3 months ago by [simonalwild](https://wordpress.org/support/users/simonalwild/).
    -  This topic was modified 9 years, 3 months ago by [simonalwild](https://wordpress.org/support/users/simonalwild/).

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Thread Starter [simonalwild](https://wordpress.org/support/users/simonalwild/)
 * (@simonalwild)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/javascript-method-to-disable-popup/#post-8854593)
 * For now I have done this hack:
 *     ```
       jQuery(document).ready(function(){
         jQuery("#gform_submit_button_15").click(function(){
           localStorage.setItem('popup_submitted', true);
         });
         if(localStorage.getItem('popup_submitted') !== null) {
           if(jQuery( "#gform_confirmation_message_15" ).length){
             // on confirmation page.
           } else {
             jQuery("#ppsPopupBgOverlay").addClass('hidden');
             jQuery(".ppsPopupListsShell").addClass('hidden');
           }
         }
       });
       ```
   
 *  Plugin Author [supsystic](https://wordpress.org/support/users/supsysticcom/)
 * (@supsysticcom)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/javascript-method-to-disable-popup/#post-8862216)
 * Hi!
    Go to /wp-content/plugins/popup-by-supsystic/modules/popup/js/frontend.popup.
   js – in this file are described all functions for using popup on frontend. In
   your case you need to use `ppsShowPopup()` function – where the first parameter
   should be popup ID.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘JavaScript Method to disable Supsystic popup’ is closed to new replies.

 * ![](https://ps.w.org/popup-by-supsystic/assets/icon-256x256.png?rev=1684296)
 * [Smart Popup by Supsystic](https://wordpress.org/plugins/popup-by-supsystic/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/popup-by-supsystic/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/popup-by-supsystic/)
 * [Active Topics](https://wordpress.org/support/plugin/popup-by-supsystic/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/popup-by-supsystic/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/popup-by-supsystic/reviews/)

## Tags

 * [jquery](https://wordpress.org/support/topic-tag/jquery/)
 * [popup](https://wordpress.org/support/topic-tag/popup/)

 * 2 replies
 * 2 participants
 * Last reply from: [supsystic](https://wordpress.org/support/users/supsysticcom/)
 * Last activity: [9 years, 3 months ago](https://wordpress.org/support/topic/javascript-method-to-disable-popup/#post-8862216)
 * Status: resolved