Last active
December 29, 2020 07:54
-
-
Save digitalchild/f900dbf8bf0bd2d44872d8955adc46df to your computer and use it in GitHub Desktop.
Set a range on the price field for WC Vendors Pro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter ('wcv_product_price', 'price_min_max'); | |
add_filter ('wcv_product_sale_price', 'price_min_max'); | |
function price_min_max ($args) { | |
$args ['custom_attributes'] = array ( | |
'data-parsley-range' => '[10, 100]' | |
); | |
return $args; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment