This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

Reply To: load order problems

#27655
Ernest MarcinkoErnest Marcinko
Keymaster

Hi,

I checked the 403 error body response, and it contains something about Sucuri Firewall – possibly an IP block, or IP range block. We are behind a VPN and sucuri probably blocks it.

Your tickets are automatically closing, because your support period was expired over 30 days ago.

You can try the variation below, but I don’t know how exactly WooCommerce handles the back-order statuses, so this may not work:

add_filter('asp_results', 'asp_order_out_of_scock', 10, 1);
function asp_order_out_of_scock($results) {
	$first = array();
	$last = array();
	foreach ( $results as $k => &$r ) {
		if ( in_array( get_post_meta($r->id, '_stock_status', true), 
		array('instock', 'backorder', 'onbackorder', 'onrequest') ) ) {
			$first[] = $r;
		} else {
			$last[] = $r;
		}
	}
	return array_merge($first, $last);
}