Magento Expert Forum - Improve your Magento experience

Results 1 to 5 of 5

how to disable validation ?

  1. #1

  2. #2
    New member
    Join Date
    Jan 2017
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    don't like to bump, but BUMP.
    Thank you.

  3. #3
    Junior Member aishwaryaV's Avatar
    Join Date
    Sep 2018
    Location
    Noida, India
    Posts
    31
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    Hi. I would be able to provide you the right solution if you provide me with the right question. Which platform you have used to create your site. I am currently working on WooCommerce so I can tell code for that only.

    if( true ){ // pass conditional statement here
    unset($fields['billing']['add_house_name']); // remove field
    $fields['billing']['add_building_name']['required'] = false; // remove required validation
    }
    return $fields;

    Hope it works for your store.

  4. #4
    Junior Member
    Join Date
    Mar 2016
    Location
    USA
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    For woocommerce .


    Hope this code work.

    add_filter( 'woocommerce_checkout_fields', 'misha_remove_fields', 9999 );

    function misha_remove_fields( $woo_checkout_fields_array )
    {

    unset( $woo_checkout_fields_array['billing']['billing_purchase_orderno'] );
    return $woo_checkout_fields_array;
    }

  5. #5
    Junior Member
    Join Date
    Sep 2018
    Location
    United Kingdom
    Posts
    171
    Thanks
    0
    Thanked 3 Times in 3 Posts

    Default

    Snap Window > Preferences and select Validation in the left sheet.

    To debilitate individual validators, clear the check boxes beside each validator that you need to impair.

    Discretionary: You can likewise change the accompanying check box alternatives on this page:

    Snap OK.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •