Comments 4Tymnus started the conversationSeptember 28, 2022 at 8:34pmRegarding Ticket Sales: Is there a way to make the default ticket quantity to “1” in the sales popup? Currently, the default is set to ZERO. Please help.1 Like 877Zhivko repliedSeptember 29, 2022 at 8:20amHi,Place this hook in your theme or child-theme functions.php file. /** * Set booking quantity to 1 by default */ add_action('wp_footer', function () { ?> <script type="text/javascript"> (function($) { $(function() { if (typeof window.StecBooking === 'undefined') { return; } window.StecBooking.prototype.popOpen = function() { var popup, scroller; $('body').addClass('stec-modal-opened stec-no-scroll'); $('#stec-layout-event-inner-out-wrapper-' + this.settings.glob.options.id).hide(); popup = $(this.popHtml()).appendTo('body'); if (!popup.find('.stec-scrollable').data('stec-scroll')) { scroller = new window.StecScroll(); scroller.create(popup.find('.stec-scrollable')); $(this).find('.stec-scrollable').data('stec-scroll', scroller); } $('.stec-booking-item-quantity').val(1); } }); })(window.jQuery); </script> <?php }); Stachethemes Developer Sign in to reply ...
Regarding Ticket Sales: Is there a way to make the default ticket quantity to “1” in the sales popup? Currently, the default is set to ZERO. Please help.
Hi,
Place this hook in your theme or child-theme functions.php file.
Stachethemes Developer