diff --git a/add-ons/listings/includes/class-listing-import.php b/add-ons/listings/includes/class-listing-import.php index a202fb39d..01ca4bc77 100755 --- a/add-ons/listings/includes/class-listing-import.php +++ b/add-ons/listings/includes/class-listing-import.php @@ -68,7 +68,7 @@ public static function wp_listings_idx_create_post( $listings ) { // Load IDX Broker API Class and retrieve featured properties. $_idx_api = new \IDX\Idx_Api(); - $properties = $_idx_api->client_properties( 'featured?disclaimers=true' ); + $properties = $_idx_api->client_properties( 'featured' ); // Load WP options. $wpl_import_options = get_option( 'wp_listings_idx_featured_listing_wp_options' ); @@ -179,7 +179,7 @@ public static function wp_listings_update_post() { // Load IDX Broker API Class and retrieve featured properties. $_idx_api = new \IDX\Idx_Api(); - $properties = $_idx_api->client_properties( 'featured?disclaimers=true' ); + $properties = $_idx_api->client_properties( 'featured' ); // Load WP options $idx_featured_listing_wp_options = get_option( 'wp_listings_idx_featured_listing_wp_options' ); diff --git a/add-ons/listings/includes/views/single-listing.php b/add-ons/listings/includes/views/single-listing.php index 6f542e88d..8d2b95122 100755 --- a/add-ons/listings/includes/views/single-listing.php +++ b/add-ons/listings/includes/views/single-listing.php @@ -123,9 +123,9 @@ function single_listing_post_content() { echo ( get_post_meta( $post->ID, '_listing_featured_on', true ) ) ? '
' . esc_html( get_post_meta( $post->ID, '_listing_featured_on', true ) ) . '
' : ''; if ( get_post_meta( $post->ID, '_listing_disclaimer', true ) ) { - echo '' . esc_html( get_post_meta( $post->ID, '_listing_disclaimer', true ) ) . '
'; + echo '' . get_post_meta( $post->ID, '_listing_disclaimer', true ) . '
'; } elseif ( ! empty( $options['wp_listings_global_disclaimer'] ) ) { - echo '' . esc_html( $options['wp_listings_global_disclaimer'] ) . '
'; + echo '' . $options['wp_listings_global_disclaimer'] . '
'; } if ( class_exists( 'Idx_Broker_Plugin' ) && ! empty( $options['wp_listings_display_idx_link'] ) && get_post_meta( $post->ID, '_listing_details_url', true ) ) { diff --git a/idx/idx-api.php b/idx/idx-api.php index 30210f936..836ced393 100755 --- a/idx/idx-api.php +++ b/idx/idx-api.php @@ -608,7 +608,7 @@ public function saved_link_properties_count( $saved_link_id ) { /** * Client_properties function. * Expected $type posibilities: featured, soldpending, supplemental. - * + * Note that ?disclaimers=true will be added to the end of the request, so there's no need to include it in $type * @access public * @param string $type * @return array @@ -650,7 +650,8 @@ public function client_properties( $type ) { continue; } // Explode $listing_data['next'] on '/clients/', index 1 of the resulting array will have the fragment needed to make the next API request. - $listing_data = $this->idx_api( explode( '/clients/', $listing_data['next'] )[1], IDX_API_DEFAULT_VERSION, 'clients', array(), 7200, 'GET', true ); + // Also add &disclaimers=true to the end of the query as it's not included on the next or prev values + $listing_data = $this->idx_api( explode( '/clients/', $listing_data['next'] )[1] . '&disclaimers=true', IDX_API_DEFAULT_VERSION, 'clients', array(), 7200, 'GET', true ); // If $listing_data['data'] is an array, merge it with the existing listings/properties array. if ( ! is_wp_error( $listing_data ) && isset( $listing_data['data'] ) && is_array( $listing_data['data'] ) ) { $properties = array_merge( $properties, $listing_data['data'] );