Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #987713
    Michael H
    Participant

    Hello,

    I just noticed the theme having issues with the touchstart. On my site, there was accordion which didn’t open on mobile and desktop. After update to recent theme’s version it starts working. But same issue moved to the buttons. When i click on buttons ( In mobile and table view), it just scroll up and bottom. I looked into forum for the solution. I was able to stop the scrolling. But button still not responding.

    Event Page Check here. When you click on buttons a form will popup on desktop screen.

    I tried to place the following code on my site. Things start working when i resize the window. I want the same on documents load.

    (function($) {
      
      $(document).on('click touchstart touchend', 'a.x-btn[href^=\\#contact_form_],.vc_tta-panel, li.vc_tta-tab,li.vc_tta-tab > a,li.vc_tta-tab > a>span,.vc_tta-panel-heading,.vc_tta-panel-heading > h4,.vc_tta-panel-heading > h4 > a', function(){
            $('html, body').stop();
    });
      setTimeout(function() {
        $('a.x-btn[href^=\\#contact_form_]').on('click load resize',function(ev) {
        	ev.preventDefault();
            //$('html, body').stop();
        	$(this).unbind('touchstart touchend');
        });
      },500); 
       
    })(jQuery);

    Hope you guys can help in fast. As it’s need to done in urgent.
    Best,
    Karan

    #988151
    Rupok
    Member

    Hi Karan,

    Thanks for updating. Let’s try updating the code :

    (function($) {
      
      $(document).on('click touchstart touchend', 'a.x-btn[href^=\\#contact_form_],.vc_tta-panel, li.vc_tta-tab,li.vc_tta-tab > a,li.vc_tta-tab > a>span,.vc_tta-panel-heading,.vc_tta-panel-heading > h4,.vc_tta-panel-heading > h4 > a', function(){
            $('html, body').stop();
    });
      setTimeout(function() {
        $('a.x-btn[href^=\\#contact_form_]').on('ready click load resize',function(ev) {
        	ev.preventDefault();
            //$('html, body').stop();
        	$(this).unbind('touchstart touchend');
        });
      },500); 
       
    })(jQuery);

    Let us know if that works.

    Cheers!

    #989504
    Michael H
    Participant

    Hello Rupok,

    Thanks for replying. I was waiting for your response. I tried updated code, but it’s still not working. I just want to stop the touchstart event for the buttons. My code could be wrong.
    Can please look into the site and let me know about the issue ?

    Whenever we resize window, popup starts working on button click.

    Regards,
    Karan

    #989608
    Paul R
    Moderator

    Hi Karan,

    You can try this code instead.

    
    (function($) {
         $('a.x-btn[href^=\\#contact_form_]').off('touchstart');
    })(jQuery);
    

    Hope that helps.

  • <script> jQuery(function($){ $("#no-reply-987713 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>