Plugin Author
Phil
(@philsbury)
Hi @mk8rocks,
Looks like your main CSS file is hiding all buttons, this CSS should make it show, put this in the CSS for you theme or the custom editor in age gate advanced settings
input[type=submit].age-gate-submit {
display: inline-block;
padding: 10px;
margin: 20px 0;
}
You’ve also got a lot of info in the additional content, I’d be tempted to make that wider on big screens, something like this should do:
@media screen and (min-width: 1024px) {
.age-gate-form {
max-width: 50%;
}
}
For an auto submit, this JS would need to be added to one of your theme’s JavaScript files and enqueued:
jQuery(function(){
jQuery('.age-gate-input').on('keyup', function(){
var submit = true;
jQuery.each(jQuery('.age-gate-input'), function(idx, element){
if (jQuery(element).attr('minlength') != jQuery(element).val().length) {
submit = false;
}
});
if (submit) {
jQuery('.age-gate-form').submit()
}
});
});
Thanks,
Phil
Is there a way to see if this has effected the existing buttons on my pages? I’m not able to add things to my cart on the product pages…I hadn’t reviewed them prior to adding the code.
Plugin Author
Phil
(@philsbury)
Hi @mk8rocks,
This will not have affected any other buttons on your site. As I said before, your theme or another plugin is hiding all buttons.
See this image for the offending CSS
Thanks
Phil