I would like to do som additional checks when the user has submitted an order in Woocommerce. Have tried using different add_filter methods, but it seems that I can’t hook up to a place_order filter. I have tried with:
add_filter('woocommerce_place_order', 'checkFields'); //on ordersubmit
function checkFields(){
if($this != true){
//not allowed to place order because of data is not true
}else{
//continue order
}
}
But non of above is being triggered when I submit the checkout form.
Any suggestions? 🙂
try something like this..
$posted
is an array like this..You can try the dedicated action hook:
}