Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Filter digital displays by for sale only
add_filter( 'propertyhive_digital_display_query_args', 'available_only_in_digital_displays', 10, 2 );
function available_only_in_digital_displays($args, $digitaldisplay)
if ( !isset($args) )
$args['tax_query'] = array();
$args['tax_query'][] = array(
'taxonomy' => 'availability',
'field' => 'name',
'terms' => array( 'For Sale', 'To Let' ),
return $args;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment