Home / Archive / MemberPress: Auto Expand Coupon Field
Duplicate Snippet

Embed Snippet on Your Site

MemberPress: Auto Expand Coupon Field

Removes the “Have a coupon?” link and instead defaults to showing the coupon input field.

Code Preview
php
<?php
function auto_click_have_coupon_link() {
  ?>
    <script type="text/javascript">
      ( function( $ ) {
        $( document ).ready(function() {
          $('.mepr-signup-form .have-coupon-link' ).trigger( 'click' );
        });
      })( jQuery );
    </script>
  <?php
}
add_action( 'wp_footer', 'auto_click_have_coupon_link' );

Comments

Add a Comment