Skip to content

Instantly share code, notes, and snippets.

@propertyhive
Last active December 11, 2020 12:47
Show Gist options
  • Save propertyhive/25eec5c55ea123a305d387b79367c2ad to your computer and use it in GitHub Desktop.
Save propertyhive/25eec5c55ea123a305d387b79367c2ad to your computer and use it in GitHub Desktop.
Set Student Property in RTDF
add_filter( 'ph_rtdf_send_request_data', 'set_as_student_property', 10, 2 );
function set_as_student_property( $request_data, $post_id )
{
$request_data['property']['student_property'] = true;
return $request_data;
}
add_filter( 'ph_zoopla_rtdf_send_request_data', 'set_as_student_property_zoopla', 10, 2 );
function set_as_student_property_zoopla( $request_data, $post_id )
{
$request_data['tenant_eligibility'] = array();
$request_data['tenant_eligibility']['students'] = 'only'; // possible values: accepted, excluded, only
return $request_data;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment