Review empty fileds alert - by Romas - on WordPress WooCommerce support

This topic has 2 replies, 2 voices, and was last updated 8 years ago ago by Eva Kemp

  • Avatar: Romas
    Romas
    Participant
    April 19, 2016 at 11:04

    I want to make alert messages when input of review text or author name are empty. Now when this fileds are empty submit button just dont work, but I want alert message to be popped up.
    I added thi code for that:

        jQuery('#commentform').submit(function(e){
    
            if(jQuery('#comment').val() == ''){
                alert('Please leave a message!');
                return false;
            }
            else
            if(jQuery('#author').val() == '' && jQuery('#author').val() !== undefined){
                alert('Please enter your name!');
                return false;
            }
        });

    But this does not work, I think thats because another jQuery(‘#commentform’).submit() method declared in another file. Please tell me how can handle this?

    Please, contact administrator
    for this information.
    1 Answer
    Avatar: Eva
    Eva Kemp
    Support staff
    April 19, 2016 at 11:23

    Hello,

    This requires additional customization which is beyond our basic support scope.
    You can send your query via this form https://www.8theme.com/customization-services/ to get additional support.

    Regards,
    Eva Kemp.

  • Viewing 2 results - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.Log in/Sign up

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.