Changeset 3467631
- Timestamp:
- 02/23/2026 11:33:22 AM (5 weeks ago)
- Location:
- houzez-property-feed/trunk
- Files:
-
- 8 edited
-
README.txt (modified) (2 diffs)
-
houzez-property-feed.php (modified) (2 diffs)
-
includes/class-houzez-property-feed-import.php (modified) (2 diffs)
-
includes/export-formats/class-houzez-property-feed-format-facebook.php (modified) (1 diff)
-
includes/export-formats/class-houzez-property-feed-format-thinkspain.php (modified) (2 diffs)
-
includes/export-formats/class-houzez-property-feed-format-zoopla.php (modified) (3 diffs)
-
includes/import-formats/class-houzez-property-feed-format-apimo.php (modified) (2 diffs)
-
includes/import-formats/class-houzez-property-feed-format-resales-online.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
houzez-property-feed/trunk/README.txt
r3457031 r3467631 4 4 Requires at least: 3.8 5 5 Tested up to: 6.9 6 Stable tag: 2.5.4 17 Version: 2.5.4 16 Stable tag: 2.5.42 7 Version: 2.5.42 8 8 Homepage: https://houzezpropertyfeed.com 9 9 License: GPLv3 … … 147 147 == Changelog == 148 148 149 = 2.5.42 - 2026-02-23 = 150 * Added EPC ratings to Zoopla exports 151 * Added support for youTube videos in Apimo imports 152 * Added support for energy fields from Apimo 153 * Updated ReSales Online XML imports to respect any limits set during the parsing phase 154 * Updated ReSales Online XML imports to cater for differing lat/lng field structure 155 * Updated Zoopla exports by passing through brochure captions 156 * Updated field rules using JSONPath to cater for field being arrays 157 * Corrected issue with currency being wrong in thinkSPAIN exports 158 * Corrected wrong variable name in Facebook export filters 159 149 160 = 2.5.41 - 2026-02-09 = 150 161 * Added office and location filters to Bridge MLS import settings -
houzez-property-feed/trunk/houzez-property-feed.php
r3457031 r3467631 4 4 * Plugin Uri: https://houzezpropertyfeed.com 5 5 * Description: Automatically import properties to Houzez from estate agency CRMs and export to portals 6 * Version: 2.5.4 16 * Version: 2.5.42 7 7 * Author: PropertyHive 8 8 * Author URI: https://wp-property-hive.com … … 20 20 * @var string 21 21 */ 22 public $version = '2.5.4 1';22 public $version = '2.5.42'; 23 23 24 24 /** -
houzez-property-feed/trunk/includes/class-houzez-property-feed-import.php
r3389138 r3467631 737 737 $path = new Flow\JSONPath\JSONPath($json); 738 738 739 $results = $path->find($rule['field']) ;739 $results = $path->find($rule['field'])->getData(); 740 740 741 741 if ( count($results) === 0 ) … … 763 763 } 764 764 elseif ( 765 ( !isset($rule['operator']) || ( isset($rule['operator']) && $rule['operator'] == '=' ) ) && trim($value_to_check) == $rule['equal'] 766 ) 767 { 768 $found = true; 769 } 770 elseif ( 771 ( isset($rule['operator']) && $rule['operator'] == '!=' ) && trim($value_to_check) != $rule['equal'] 765 766 ( !isset($rule['operator']) || ( isset($rule['operator']) && $rule['operator'] == '=' ) ) 767 && ( 768 ( is_array($value_to_check) && (function() use ($value_to_check, $rule) { 769 foreach ($value_to_check as $v) { 770 if (trim((string)$v) == $rule['equal']) return true; 771 } 772 return false; 773 })() ) 774 || ( !is_array($value_to_check) && trim((string)$value_to_check) == $rule['equal'] ) 775 ) 776 ) 777 { 778 $found = true; 779 } 780 elseif ( 781 ( isset($rule['operator']) && $rule['operator'] == '!=' ) 782 && ( 783 ( is_array($value_to_check) && (function() use ($value_to_check, $rule) { 784 foreach ($value_to_check as $v) { 785 if (trim((string)$v) == $rule['equal']) return false; // any equal ⇒ fail 786 } 787 return true; // none equal ⇒ pass 788 })() ) 789 || ( !is_array($value_to_check) && trim((string)$value_to_check) != $rule['equal'] ) 790 ) 772 791 ) 773 792 { -
houzez-property-feed/trunk/includes/export-formats/class-houzez-property-feed-format-facebook.php
r3389596 r3467631 332 332 //$listing_xml->addChild('parking_type', $parking); 333 333 334 $ property_xml = apply_filters( 'houzez_property_feed_export_property_data', $property_xml, $post->ID, $this->export_id );335 $ property_xml = apply_filters( 'houzez_property_feed_export_facebook_property_data', $property_xml, $post->ID, $this->export_id );334 $listing_xml = apply_filters( 'houzez_property_feed_export_property_data', $listing_xml, $post->ID, $this->export_id ); 335 $listing_xml = apply_filters( 'houzez_property_feed_export_facebook_property_data', $listing_xml, $post->ID, $this->export_id ); 336 336 $this->log("Property written to Facebook XML file", '', $post->ID); 337 337 -
houzez-property-feed/trunk/includes/export-formats/class-houzez-property-feed-format-thinkspain.php
r3418321 r3467631 140 140 $currency = 'EUR'; 141 141 142 if ( houzez_option('multi_currency') == '1' )143 { 144 $default_multi_currency = houzez_option('default_multi_currency');142 if ( fave_option('multi_currency') == '1' ) 143 { 144 $default_multi_currency = fave_option('default_multi_currency'); 145 145 if ( !empty($default_multi_currency) && strlen($default_multi_currency) == 3 ) 146 146 { … … 155 155 else 156 156 { 157 $symbol = houzez_option('currency_symbol');157 $symbol = fave_option('currency_symbol'); 158 158 switch ($symbol) 159 159 { -
houzez-property-feed/trunk/includes/export-formats/class-houzez-property-feed-format-zoopla.php
r3389596 r3467631 312 312 $request_data['display_address'] = get_the_title($post_id); 313 313 314 $epc_ratings = array(); 315 $eer_current_rating = (int)get_post_meta( $post_id, 'fave_epc_current_rating', TRUE ); 316 if ( !empty($eer_current_rating) ) 317 { 318 $epc_ratings['eer_current_rating'] = $eer_current_rating; 319 } 320 $eer_potential_rating = (int)get_post_meta( $post_id, 'fave_epc_potential_rating', TRUE ); 321 if ( !empty($eer_potential_rating) ) 322 { 323 $epc_ratings['eer_potential_rating'] = $eer_potential_rating; 324 } 325 if ( !empty($epc_ratings) ) 326 { 327 $request_data['epc_ratings'] = $epc_ratings; 328 } 329 314 330 $features = array(); 315 331 $term_list = wp_get_post_terms($post_id, 'property_feature', array("fields" => "all")); … … 614 630 if ($url !== FALSE) 615 631 { 616 $attachment_data = wp_prepare_attachment_for_js( $attachment_id ); 632 $attachment = get_post( $attachment_id ); 633 634 $caption = ''; 635 636 if ( $attachment ) 637 { 638 if ( ! empty( $attachment->post_excerpt ) ) 639 { 640 $caption = $attachment->post_excerpt; 641 } 642 elseif ( ! empty( $attachment->post_title ) ) 643 { 644 $caption = $attachment->post_title; 645 } 646 } 617 647 618 648 $media = array( … … 620 650 'type' => 'brochure', 621 651 ); 622 if ( isset( $attachment_data['alt'] ) && $attachment_data['alt'] != '')623 { 624 $media['caption'] = trim($ attachment_data['alt']);652 if ( !empty($caption) ) 653 { 654 $media['caption'] = trim($caption); 625 655 } 626 656 -
houzez-property-feed/trunk/includes/import-formats/class-houzez-property-feed-format-apimo.php
r3457031 r3467631 628 628 } 629 629 } 630 631 $fave_energy_class = ''; 632 if ( isset($property['regulations']) && is_array($property['regulations']) ) 633 { 634 foreach ( $property['regulations'] as $regulation ) 635 { 636 if ( isset($regulation['type']) && $regulation['type'] == 79 && isset($regulation['value']) && !empty($regulation['value']) ) 637 { 638 $fave_energy_class = $regulation['value']; 639 } 640 } 641 } 642 update_post_meta( $post_id, 'fave_energy_class', $fave_energy_class ); 643 644 $fave_epc_current_rating = ''; 645 if ( isset($property['regulations']) && is_array($property['regulations']) ) 646 { 647 foreach ( $property['regulations'] as $regulation ) 648 { 649 if ( isset($regulation['type']) && $regulation['type'] == 89 && isset($regulation['value']) && !empty($regulation['value']) ) 650 { 651 $fave_epc_current_rating = $regulation['value']; 652 } 653 } 654 } 655 update_post_meta( $post_id, 'fave_epc_current_rating', $fave_epc_current_rating ); 656 657 $fave_epc_potential_rating = ''; 658 if ( isset($property['regulations']) && is_array($property['regulations']) ) 659 { 660 foreach ( $property['regulations'] as $regulation ) 661 { 662 if ( isset($regulation['type']) && $regulation['type'] == 90 && isset($regulation['value']) && !empty($regulation['value']) ) 663 { 664 $fave_epc_potential_rating = $regulation['value']; 665 } 666 } 667 } 668 update_post_meta( $post_id, 'fave_epc_potential_rating', $fave_epc_potential_rating ); 630 669 631 670 $mappings = ( isset($import_settings['mappings']) && is_array($import_settings['mappings']) && !empty($import_settings['mappings']) ) ? $import_settings['mappings'] : array(); … … 998 1037 } 999 1038 1039 update_post_meta( $post_id, 'fave_video_url', '' ); 1040 update_post_meta( $post_id, 'fave_virtual_tour', '' ); 1041 1042 if ( isset($property['medias']) && !empty($property['medias']) ) 1043 { 1044 foreach ( $property['medias'] as $media ) 1045 { 1046 if ( 1047 isset($media['internet']) && $media['internet'] === "1" && 1048 isset($media['value']) && 1049 preg_match('~^(https?:\/\/)?(www\.)?(youtube\.com|youtu\.be)\/~i', $media['value']) 1050 ) 1051 { 1052 update_post_meta( $post_id, 'fave_video_url', $media['value'] ); 1053 break; 1054 } 1055 } 1056 } 1057 1000 1058 do_action( "houzez_property_feed_property_imported", $post_id, $property, $this->import_id, $this->instance_id ); 1001 1059 do_action( "houzez_property_feed_property_imported_apimo", $post_id, $property, $this->import_id, $this->instance_id ); -
houzez-property-feed/trunk/includes/import-formats/class-houzez-property-feed-format-resales-online.php
r3389596 r3467631 48 48 if ( $xml !== FALSE ) 49 49 { 50 $limit = apply_filters( "houzez_property_feed_property_limit", 25 ); 51 if ( $limit !== false ) 52 { 53 54 } 55 else 56 { 57 // using pro, but check for limit setting 58 if ( 59 $pro_active === true && 60 isset($import_settings['limit']) && 61 !empty((int)$import_settings['limit']) && 62 is_numeric($import_settings['limit']) 63 ) 64 { 65 $limit = (int)$import_settings['limit']; 66 } 67 } 68 50 69 foreach ( $xml->property as $property ) 51 70 { 52 71 if ( !isset($property->status) || ( isset($property->status) && (string)$property->status != 'Off Market' ) ) 53 72 { 73 if ( $test === false && $limit !== FALSE && count($this->properties) >= $limit ) 74 { 75 return true; 76 } 77 54 78 $this->properties[] = $property; 55 79 } … … 356 380 $lng = (string)$property->location->longitude; 357 381 } 382 if ( isset($property->latitude) && !empty((string)$property->latitude) && isset($property->longitude) && !empty((string)$property->longitude) ) 383 { 384 $lat = (string)$property->latitude; 385 $lng = (string)$property->longitude; 386 } 358 387 update_post_meta( $post_id, 'fave_property_location', $lat . "," . $lng . ",14" ); 359 388 $country = 'ES';
Note: See TracChangeset
for help on using the changeset viewer.