Below is a differential between the unpatched vulnerable code and the patched update, for reference.
--- a/houzez-property-feed/houzez-property-feed.php
+++ b/houzez-property-feed/houzez-property-feed.php
@@ -3,7 +3,7 @@
* Plugin Name: Houzez Property Feed
* Plugin Uri: https://houzezpropertyfeed.com
* Description: Automatically import properties to Houzez from estate agency CRMs and export to portals
- * Version: 2.5.48
+ * Version: 2.5.49
* Author: PropertyHive
* Author URI: https://wp-property-hive.com
* License: GPLv3
@@ -19,7 +19,7 @@
/**
* @var string
*/
- public $version = '2.5.48';
+ public $version = '2.5.49';
/**
* @var Houzez Property Feed The single instance of the class
--- a/houzez-property-feed/includes/class-houzez-property-feed-admin-automatic-imports-table.php
+++ b/houzez-property-feed/includes/class-houzez-property-feed-admin-automatic-imports-table.php
@@ -640,7 +640,7 @@
if ( $running )
{
$nonce = wp_create_nonce('houzez_property_feed_import');
- $actions[] = '<span class="edit"><a href="' . admin_url('admin.php?page=houzez-property-feed-import&custom_property_import_cron=houzezpropertyfeedcronhook&orderby=' . $orderby . '&order=' . $order . '&hpf_filter=' . $hpf_filter . '&hpf_filter_format=' . $hpf_filter_format . '&import_id=' . (int)$key . '&_wpnonce=' . $nonce) . '" class="link-manually-execute-import" onclick="hpf_click_run_now();" aria-label="' . esc_attr( __( 'Run Now', 'houzezpropertyfeed' ) ) . '"' . ( $import_running_now === true ? ' style="pointer-events:none;"' : '' ) . '>' . esc_html( $import_running_now === true ? __( 'Processing...', 'houzezpropertyfeed' ) : __( 'Run Now', 'houzezpropertyfeed' ) ) . '</a></span>';
+ $actions[] = '<span class="edit"><a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-import&custom_property_import_cron=houzezpropertyfeedcronhook&orderby=' . $orderby . '&order=' . $order . '&hpf_filter=' . $hpf_filter . '&hpf_filter_format=' . $hpf_filter_format . '&import_id=' . (int)$key . '&_wpnonce=' . $nonce)) . '" class="link-manually-execute-import" onclick="hpf_click_run_now();" aria-label="' . esc_attr( __( 'Run Now', 'houzezpropertyfeed' ) ) . '"' . ( $import_running_now === true ? ' style="pointer-events:none;"' : '' ) . '>' . esc_html( $import_running_now === true ? __( 'Processing...', 'houzezpropertyfeed' ) : __( 'Run Now', 'houzezpropertyfeed' ) ) . '</a></span>';
}
$actions[] = '<span class="edit"><a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-import&tab=logs&import_id=' . (int)$key)) . '" aria-label="' . esc_attr( __( 'View Logs', 'houzezpropertyfeed' ) ) . '">' . esc_html( __( 'Logs', 'houzezpropertyfeed' ) ) . '</a></span>';
$actions[] = '<span class="edit"><a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-import&action=editimport&import_id=' . (int)$key)) . '" aria-label="' . esc_attr( __( 'Edit Import', 'houzezpropertyfeed' ) ) . '">' . esc_html( __( 'Edit', 'houzezpropertyfeed' ) ) . '</a></span>';
--- a/houzez-property-feed/includes/class-houzez-property-feed-admin.php
+++ b/houzez-property-feed/includes/class-houzez-property-feed-admin.php
@@ -145,10 +145,10 @@
public function plugin_add_settings_link( $links )
{
- $settings_link = '<a href="' . admin_url('admin.php?page=houzez-property-feed-import') . '">' . __( 'Manage Imports', 'houzezpropertyfeed' ) . '</a>';
+ $settings_link = '<a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-import')) . '">' . __( 'Manage Imports', 'houzezpropertyfeed' ) . '</a>';
array_push( $links, $settings_link );
- $settings_link = '<a href="' . admin_url('admin.php?page=houzez-property-feed-export') . '">' . __( 'Manage Exports', 'houzezpropertyfeed' ) . '</a>';
+ $settings_link = '<a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-export')) . '">' . __( 'Manage Exports', 'houzezpropertyfeed' ) . '</a>';
array_push( $links, $settings_link );
$docs_link = '<a href="https://houzezpropertyfeed.com/documentation/" target="_blank">' . __( 'Docs', 'houzezpropertyfeed' ) . '</a>';
@@ -762,6 +762,7 @@
$statuses = array();
$property_types = array();
+ $property_features = array();
if ( isset($_GET['page']) && ( sanitize_text_field($_GET['page']) == 'houzez-property-feed-import' || sanitize_text_field($_GET['page']) == 'houzez-property-feed-export' ) )
{
@@ -772,6 +773,8 @@
if ( isset($_GET['page']) && sanitize_text_field($_GET['page']) == 'houzez-property-feed-import' )
{
+ $formats = houzez_property_feed_get_import_formats();
+
$terms = get_terms( array(
'taxonomy' => 'property_status',
'hide_empty' => false,
@@ -788,6 +791,8 @@
$terms = get_terms( array(
'taxonomy' => 'property_type',
'hide_empty' => false,
+ 'orderby' => 'name',
+ 'order' => 'ASC',
) );
if ( is_array($terms) && !empty($terms) )
@@ -798,6 +803,34 @@
}
}
+ // Only if there is an import that supports features to save loading them every time
+ foreach ( $formats as $key => $format )
+ {
+ if (
+ isset($format['taxonomy_values']['property_feature']) &&
+ !empty($format['taxonomy_values']['property_feature'])
+ )
+ {
+ $terms = get_terms( array(
+ 'taxonomy' => 'property_feature',
+ 'hide_empty' => false,
+ 'orderby' => 'name',
+ 'order' => 'ASC',
+ 'number' => 1000,
+ ) );
+
+ if ( is_array($terms) && !empty($terms) )
+ {
+ foreach ( $terms as $term )
+ {
+ $property_features[$term->term_id] = $term->name;
+ }
+ }
+
+ break;
+ }
+ }
+
// enqueue draggable/droppable for XML field mapping
wp_enqueue_script( 'jquery-ui-draggable' );
wp_enqueue_script( 'jquery-ui-droppable' );
@@ -805,8 +838,6 @@
wp_register_script( 'houzez_property_feed_admin_import_script', untrailingslashit( plugins_url( '/', HOUZEZ_PROPERTY_FEED_PLUGIN_FILE ) ) . '/assets/js/admin-import.js', array( 'jquery' ), HOUZEZ_PROPERTY_FEED_VERSION );
- $formats = houzez_property_feed_get_import_formats();
-
$import_id = ( isset($_GET['import_id']) && !empty(sanitize_text_field($_GET['import_id'])) ) ? (int)$_GET['import_id'] : false;
$import_settings = array();
@@ -892,6 +923,7 @@
'import_settings' => $import_settings,
'statuses' => $statuses,
'property_types' => $property_types,
+ 'property_features' => $property_features,
'houzez_fields_for_field_mapping' => houzez_property_feed_get_fields_for_field_mapping(),
'ajax_nonce' => wp_create_nonce("hpf_ajax_nonce"),
'table_order' => ( isset($_GET['order']) ? sanitize_text_field($_GET['order']) : '' ),
--- a/houzez-property-feed/includes/views/admin-settings-automatic-exports.php
+++ b/houzez-property-feed/includes/views/admin-settings-automatic-exports.php
@@ -6,7 +6,7 @@
<?php include( dirname(HOUZEZ_PROPERTY_FEED_PLUGIN_FILE) . '/includes/views/admin-settings-notice.php' ); ?>
- <h1><?php echo __( 'Automatic Exports', 'houzezpropertyfeed' ); ?></h1>
+ <h1><?php echo esc_html( __( 'Automatic Exports', 'houzezpropertyfeed' ) ); ?></h1>
<?php
if ( $automatic_exports_table->has_items() )
@@ -17,7 +17,7 @@
if ( $run_now_button )
{
- echo '<a href="' . admin_url('admin.php?page=houzez-property-feed-export&custom_property_export_cron=houzezpropertyfeedcronhook') . '" class="button">Manually Execute Export</a>';
+ echo '<a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-export&custom_property_export_cron=houzezpropertyfeedcronhook')) . '" class="button">Manually Execute Export</a>';
}
}
else
@@ -26,11 +26,11 @@
<div class="no-imports-exports">
- <h2><?php echo __( 'Your automatic exports will appear here', 'houzezpropertyfeed' ); ?></h2>
+ <h2><?php echo esc_html( __( 'Your automatic exports will appear here', 'houzezpropertyfeed' ) ); ?></h2>
<p>You don't have any exports running at the moment. Why not go ahead and try creating one now?</p>
- <p><a href="<?php echo admin_url('admin.php?page=houzez-property-feed-export&action=addexport'); ?>" class="button button-primary button-hero"><span class="dashicons dashicons-plus-alt2" style="color:inherit;"></span> <?php echo __( 'Create New Export', 'houzezpropertyfeed' ); ?></a></p>
+ <p><a href="<?php echo esc_url(admin_url('admin.php?page=houzez-property-feed-export&action=addexport')); ?>" class="button button-primary button-hero"><span class="dashicons dashicons-plus-alt2" style="color:inherit;"></span> <?php echo esc_html( __( 'Create New Export', 'houzezpropertyfeed' ) ); ?></a></p>
<p><strong>Need help?</strong> Our <a href="https://houzezpropertyfeed.com/documentation/" target="_blank">in-depth documentation</a> will guide you through the process.</p>
--- a/houzez-property-feed/includes/views/admin-settings-automatic-imports.php
+++ b/houzez-property-feed/includes/views/admin-settings-automatic-imports.php
@@ -6,7 +6,7 @@
<?php include( dirname(HOUZEZ_PROPERTY_FEED_PLUGIN_FILE) . '/includes/views/admin-settings-notice.php' ); ?>
- <h1><?php echo __( 'Automatic Imports', 'houzezpropertyfeed' ); ?></h1>
+ <h1><?php echo esc_html( __( 'Automatic Imports', 'houzezpropertyfeed' ) ); ?></h1>
<?php
$all_imports_count = 0;
@@ -105,7 +105,7 @@
$nonce = wp_create_nonce('houzez_property_feed_import');
- echo '<a href="' . admin_url('admin.php?page=houzez-property-feed-import&custom_property_import_cron=houzezpropertyfeedcronhook&orderby=' . $orderby . '&order=' . $order . '&hpf_filter=' . $hpf_filter . '&hpf_filter_format=' . $hpf_filter_format . '&_wpnonce=' . $nonce) . '" class="button button-manually-execute" onclick="hpf_click_run_now();" rel="nofollow noopener noreferrer">Manually Execute Import</a>';
+ echo '<a href="' . esc_html( admin_url('admin.php?page=houzez-property-feed-import&custom_property_import_cron=houzezpropertyfeedcronhook&orderby=' . $orderby . '&order=' . $order . '&hpf_filter=' . $hpf_filter . '&hpf_filter_format=' . $hpf_filter_format . '&_wpnonce=' . $nonce) ) . '" class="button button-manually-execute" onclick="hpf_click_run_now();" rel="nofollow noopener noreferrer">Manually Execute Import</a>';
}
}
else
@@ -114,11 +114,11 @@
<div class="no-imports-exports">
- <h2><?php echo __( 'Your automatic imports will appear here', 'houzezpropertyfeed' ); ?></h2>
+ <h2><?php echo esc_html( __( 'Your automatic imports will appear here', 'houzezpropertyfeed' ) ); ?></h2>
<p>You don't have any imports running at the moment. Why not go ahead and try creating one now?</p>
- <p><a href="<?php echo admin_url('admin.php?page=houzez-property-feed-import&action=addimport'); ?>" class="button button-primary button-hero"><span class="dashicons dashicons-plus-alt2" style="color:inherit;"></span> <?php echo __( 'Create New Import', 'houzezpropertyfeed' ); ?></a></p>
+ <p><a href="<?php echo esc_url(admin_url('admin.php?page=houzez-property-feed-import&action=addimport')); ?>" class="button button-primary button-hero"><span class="dashicons dashicons-plus-alt2" style="color:inherit;"></span> <?php echo esc_html( __( 'Create New Import', 'houzezpropertyfeed' ) ); ?></a></p>
<p><strong>Need help?</strong> Our <a href="https://houzezpropertyfeed.com/documentation/" target="_blank">in-depth documentation</a> will guide you through the process.</p>
--- a/houzez-property-feed/includes/views/admin-settings-export-settings-taxonomies.php
+++ b/houzez-property-feed/includes/views/admin-settings-export-settings-taxonomies.php
@@ -11,12 +11,12 @@
<div id="taxonomy_mapping_status">
- <h3><?php echo __( 'Status Taxomomy', 'houzezpropertyfeed' ); ?></h3>
+ <h3><?php echo esc_html(__( 'Status Taxomomy', 'houzezpropertyfeed' )); ?></h3>
<table class="form-table" id="taxonomy_mapping_table_status">
<tbody>
<tr>
- <th>Value In Houzez <a href="<?php echo admin_url( 'edit-tags.php?taxonomy=property_status&post_type=property'); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></th>
+ <th>Value In Houzez <a href="<?php echo esc_url(admin_url( 'edit-tags.php?taxonomy=property_status&post_type=property')); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></th>
<td style="padding-left:0; font-weight:600">Value Sent In <span class="hpf-export-format-name"></span> Feed</td>
</tr>
<?php
@@ -31,7 +31,7 @@
{
?>
<tr>
- <td style="padding-left:0"><?php echo __( $term->name, 'houzezpropertyfeed' ); ?></td>
+ <td style="padding-left:0"><?php echo esc_html(__( $term->name, 'houzezpropertyfeed' )); ?></td>
<td style="padding-left:0">
<select name="taxonomy_mapping[property_status][<?php echo $term->term_id; ?>]">
<option value=""></option>
@@ -51,12 +51,12 @@
<div id="taxonomy_mapping_property_type">
- <h3><?php echo __( 'Property Type Taxomomy', 'houzezpropertyfeed' ); ?></h3>
+ <h3><?php echo esc_html(__( 'Property Type Taxomomy', 'houzezpropertyfeed' )); ?></h3>
<table class="form-table" id="taxonomy_mapping_table_property_type">
<tbody>
<tr>
- <th>Value In Houzez <a href="<?php echo admin_url( 'edit-tags.php?taxonomy=property_type&post_type=property'); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></th>
+ <th>Value In Houzez <a href="<?php echo esc_url(admin_url( 'edit-tags.php?taxonomy=property_type&post_type=property')); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></th>
<td style="padding-left:0; font-weight:600">Value Sent In <span class="hpf-export-format-name"></span> Feed</td>
</tr>
<?php
@@ -71,7 +71,7 @@
{
?>
<tr>
- <td style="padding-left:0"><?php echo __( $term->name, 'houzezpropertyfeed' ); ?></td>
+ <td style="padding-left:0"><?php echo esc_html(__( $term->name, 'houzezpropertyfeed' )); ?></td>
<td style="padding-left:0">
<select name="taxonomy_mapping[property_type][<?php echo $term->term_id; ?>]">
<option value=""></option>
@@ -89,7 +89,7 @@
<div id="taxonomy_mapping_price_qualifier">
- <h3><?php echo __( 'Price Qualifier', 'houzezpropertyfeed' ); ?></h3>
+ <h3><?php echo esc_html(__( 'Price Qualifier', 'houzezpropertyfeed' )); ?></h3>
<table class="form-table" id="taxonomy_mapping_table_price_qualifier">
<tbody>
--- a/houzez-property-feed/includes/views/admin-settings-export-settings.php
+++ b/houzez-property-feed/includes/views/admin-settings-export-settings.php
@@ -10,16 +10,16 @@
<div class="hpf-admin-settings-import-settings">
- <h1><?php echo ( $export_id !== false ) ? __( 'Edit Export', 'houzezpropertyfeed' ) : __( 'Create Export', 'houzezpropertyfeed' ); ?></h1>
+ <h1><?php echo ( $export_id !== false ) ? esc_html(__( 'Edit Export', 'houzezpropertyfeed' )) : esc_html(__( 'Create Export', 'houzezpropertyfeed' )); ?></h1>
<div class="settings-area">
<div class="left-tabs">
<ul>
- <li id="export_setting_tab_format" class="active"><a href="#format"><span class="dashicons dashicons-editor-code"></span> <?php echo __( 'Export Format', 'houzezpropertyfeed' ); ?></a></li>
- <li id="export_setting_tab_frequency" style="display:none"><a href="#frequency"><span class="dashicons dashicons-clock"></span> <?php echo __( 'Frequency', 'houzezpropertyfeed' ); ?></a></li>
- <li id="export_setting_tab_taxonomies"><a href="#taxonomies"><span class="dashicons dashicons-tag"></span> <?php echo __( 'Taxonomies', 'houzezpropertyfeed' ); ?></a></li>
- <li id="export_setting_tab_fieldmapping"><a href="#fieldmapping"><span class="dashicons dashicons-admin-links"></span></span> <?php echo __( 'Field Mapping', 'houzezpropertyfeed' ); ?><span id="field_mapping_warning" style="color:#999; display:none"> <span class="dashicons dashicons-warning"></span></span></a></li>
+ <li id="export_setting_tab_format" class="active"><a href="#format"><span class="dashicons dashicons-editor-code"></span> <?php echo esc_html(__( 'Export Format', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="export_setting_tab_frequency" style="display:none"><a href="#frequency"><span class="dashicons dashicons-clock"></span> <?php echo esc_html(__( 'Frequency', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="export_setting_tab_taxonomies"><a href="#taxonomies"><span class="dashicons dashicons-tag"></span> <?php echo esc_html(__( 'Taxonomies', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="export_setting_tab_fieldmapping"><a href="#fieldmapping"><span class="dashicons dashicons-admin-links"></span></span> <?php echo esc_html(__( 'Field Mapping', 'houzezpropertyfeed' )); ?><span id="field_mapping_warning" style="color:#999; display:none"> <span class="dashicons dashicons-warning"></span></span></a></li>
</ul>
</div>
@@ -38,8 +38,8 @@
</div>
- <input type="submit" value="<?php echo __( 'Save changes', 'houzezpropertyfeed' ); ?>" class="button button-primary">
- <a href="<?php echo admin_url('admin.php?page=houzez-property-feed-export'); ?>" class="button">Cancel</a>
+ <input type="submit" value="<?php echo esc_attr(__( 'Save changes', 'houzezpropertyfeed' )); ?>" class="button button-primary">
+ <a href="<?php echo esc_url(admin_url('admin.php?page=houzez-property-feed-export')); ?>" class="button">Cancel</a>
</div>
@@ -65,8 +65,8 @@
<div class="buttons bottom">
- <input type="submit" value="<?php echo __( 'Save changes', 'houzezpropertyfeed' ); ?>" class="button button-primary">
- <a href="<?php echo admin_url('admin.php?page=houzez-property-feed-export'); ?>" class="button">Cancel</a>
+ <input type="submit" value="<?php echo esc_attr(__( 'Save changes', 'houzezpropertyfeed' )); ?>" class="button button-primary">
+ <a href="<?php echo esc_url(admin_url('admin.php?page=houzez-property-feed-export')); ?>" class="button">Cancel</a>
</div>
--- a/houzez-property-feed/includes/views/admin-settings-import-settings-contact-information.php
+++ b/houzez-property-feed/includes/views/admin-settings-import-settings-contact-information.php
@@ -110,7 +110,7 @@
<?php
if ( empty($details['items']) )
{
- echo '<div class="notice notice-info inline"><p>No <a href="' . esc_attr($details['manage_link']) . '" target="_blank">' . esc_html($details['plural']) . '</a> exist. You'll need to add some to use this option.</p></div>';
+ echo '<div class="notice notice-info inline"><p>No <a href="' . esc_url($details['manage_link']) . '" target="_blank">' . esc_html($details['plural']) . '</a> exist. You'll need to add some to use this option.</p></div>';
}
?>
@@ -119,7 +119,7 @@
<tr>
<th>Rules</th>
<td>
- <div id="agent_display_option_rule_template_<?php echo $agent_display_option; ?>" style="display:none">
+ <div id="agent_display_option_rule_template_<?php echo esc_attr($agent_display_option); ?>" style="display:none">
<div class="agent-display-option-rule">
<div>
If
--- a/houzez-property-feed/includes/views/admin-settings-import-settings-taxonomies.php
+++ b/houzez-property-feed/includes/views/admin-settings-import-settings-taxonomies.php
@@ -19,7 +19,7 @@
<tbody>
<tr>
<th>Value Sent In <span class="hpf-import-format-name"></span> Feed</th>
- <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo admin_url( 'edit-tags.php?taxonomy=property_status&post_type=property'); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
+ <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo esc_url(admin_url( 'edit-tags.php?taxonomy=property_status&post_type=property')); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
</tr>
</tbody>
</table>
@@ -38,7 +38,7 @@
<tbody>
<tr>
<th>Value Sent In <span class="hpf-import-format-name"></span> Feed</th>
- <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo admin_url( 'edit-tags.php?taxonomy=property_status&post_type=property'); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
+ <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo esc_url(admin_url( 'edit-tags.php?taxonomy=property_status&post_type=property')); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Status Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
</tr>
</tbody>
</table>
@@ -57,7 +57,7 @@
<tbody>
<tr>
<th>Value Sent In <span class="hpf-import-format-name"></span> Feed</th>
- <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo admin_url( 'edit-tags.php?taxonomy=property_type&post_type=property'); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Type Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
+ <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo esc_url(admin_url( 'edit-tags.php?taxonomy=property_type&post_type=property')); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Type Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
</tr>
</tbody>
</table>
@@ -66,6 +66,25 @@
<hr>
+</div>
+
+<div id="taxonomy_mapping_property_feature">
+
+ <h3><?php echo esc_html(__( 'Property Feature Taxomomy', 'houzezpropertyfeed' )); ?></h3>
+
+ <table class="form-table" id="taxonomy_mapping_table_property_feature">
+ <tbody>
+ <tr>
+ <th>Value Sent In <span class="hpf-import-format-name"></span> Feed</th>
+ <td style="padding-left:0; font-weight:600">Value In Houzez <a href="<?php echo esc_url(admin_url( 'edit-tags.php?taxonomy=property_feature&post_type=property')); ?>" target="_blank" style="color:inherit; text-decoration:none; margin-right:4px;" title="Configure Property Feature Terms"><span class="dashicons dashicons-admin-tools"></span></a></td>
+ </tr>
+ </tbody>
+ </table>
+ <br>
+ <a href="#property_feature" class="button add-additional-mapping"><span class="dashicons dashicons-plus-alt2"></span> Add Additional Mapping</a>
+
+ <hr>
+
</div>
<?php
--- a/houzez-property-feed/includes/views/admin-settings-import-settings.php
+++ b/houzez-property-feed/includes/views/admin-settings-import-settings.php
@@ -16,14 +16,14 @@
<div class="left-tabs">
<ul>
- <li id="import_setting_tab_format" class="active"><a href="#format"><span class="dashicons dashicons-editor-code"></span> <?php echo __( 'Import Format', 'houzezpropertyfeed' ); ?></a></li>
- <li id="import_setting_tab_frequency"><a href="#frequency"><span class="dashicons dashicons-clock"></span> <?php echo __( 'Frequency', 'houzezpropertyfeed' ); ?></a></li>
- <li id="import_setting_tab_taxonomies"><a href="#taxonomies"><span class="dashicons dashicons-tag"></span> <?php echo __( 'Taxonomies', 'houzezpropertyfeed' ); ?></a></li>
- <li id="import_setting_tab_contactinfo"><a href="#contactinfo"><span class="dashicons dashicons-admin-users"></span> <?php echo __( 'Contact Information', 'houzezpropertyfeed' ); ?></a></li>
- <li id="import_setting_tab_fieldmapping"><a href="#fieldmapping"><span class="dashicons dashicons-admin-links"></span></span> <?php echo __( 'Field Mapping', 'houzezpropertyfeed' ); ?><span id="field_mapping_warning" style="color:#999; display:none"> <span class="dashicons dashicons-warning"></span></span></a></li>
- <li id="import_setting_tab_media"><a href="#media"><span class="dashicons dashicons-admin-media"></span> <?php echo __( 'Media', 'houzezpropertyfeed' ); ?></a></li>
- <li id="import_setting_tab_enquiries"><a href="#enquiries"><span class="dashicons dashicons-email"></span> <?php echo __( 'Export Enquiries', 'houzezpropertyfeed' ); ?></a></li>
- <li id="import_setting_tab_advanced"><a href="#advanced"><span class="dashicons dashicons-admin-settings"></span> <?php echo __( 'Advanced', 'houzezpropertyfeed' ); ?></a></li>
+ <li id="import_setting_tab_format" class="active"><a href="#format"><span class="dashicons dashicons-editor-code"></span> <?php echo esc_html(__( 'Import Format', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="import_setting_tab_frequency"><a href="#frequency"><span class="dashicons dashicons-clock"></span> <?php echo esc_html(__( 'Frequency', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="import_setting_tab_taxonomies"><a href="#taxonomies"><span class="dashicons dashicons-tag"></span> <?php echo esc_html(__( 'Taxonomies', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="import_setting_tab_contactinfo"><a href="#contactinfo"><span class="dashicons dashicons-admin-users"></span> <?php echo esc_html(__( 'Contact Information', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="import_setting_tab_fieldmapping"><a href="#fieldmapping"><span class="dashicons dashicons-admin-links"></span></span> <?php echo esc_html(__( 'Field Mapping', 'houzezpropertyfeed' )); ?><span id="field_mapping_warning" style="color:#999; display:none"> <span class="dashicons dashicons-warning"></span></span></a></li>
+ <li id="import_setting_tab_media"><a href="#media"><span class="dashicons dashicons-admin-media"></span> <?php echo esc_html(__( 'Media', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="import_setting_tab_enquiries"><a href="#enquiries"><span class="dashicons dashicons-email"></span> <?php echo esc_html(__( 'Export Enquiries', 'houzezpropertyfeed' )); ?></a></li>
+ <li id="import_setting_tab_advanced"><a href="#advanced"><span class="dashicons dashicons-admin-settings"></span> <?php echo esc_html(__( 'Advanced', 'houzezpropertyfeed' )); ?></a></li>
</ul>
</div>
@@ -42,8 +42,8 @@
</div>
- <input type="submit" value="<?php echo __( 'Save changes', 'houzezpropertyfeed' ); ?>" class="button button-primary">
- <a href="<?php echo admin_url('admin.php?page=houzez-property-feed-import'); ?>" class="button">Cancel</a>
+ <input type="submit" value="<?php echo esc_attr(__( 'Save changes', 'houzezpropertyfeed' )); ?>" class="button button-primary">
+ <a href="<?php echo esc_url(admin_url('admin.php?page=houzez-property-feed-import')); ?>" class="button">Cancel</a>
</div>
@@ -85,8 +85,8 @@
<div class="buttons bottom">
- <input type="submit" value="<?php echo __( 'Save changes', 'houzezpropertyfeed' ); ?>" class="button button-primary">
- <a href="<?php echo admin_url('admin.php?page=houzez-property-feed-import'); ?>" class="button">Cancel</a>
+ <input type="submit" value="<?php echo esc_attr(__( 'Save changes', 'houzezpropertyfeed' )); ?>" class="button button-primary">
+ <a href="<?php echo esc_url(admin_url('admin.php?page=houzez-property-feed-import')); ?>" class="button">Cancel</a>
</div>
--- a/houzez-property-feed/includes/views/admin-settings-notice.php
+++ b/houzez-property-feed/includes/views/admin-settings-notice.php
@@ -63,7 +63,7 @@
( !isset($options['lettings_statuses']) || ( isset($options['lettings_statuses']) && empty($options['lettings_statuses']) ) )
)
{
- echo '<div class="notice notice-info inline"><p>' . __( 'Please ensure that <a href="' . admin_url('admin.php?page=houzez-property-feed-export&tab=settings') . '">you have specified</a> which statuses determine whether a property is sales or lettings', 'houzezpropertyfeed' ) . '</p></div>';
+ echo '<div class="notice notice-info inline"><p>' . __( 'Please ensure that <a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-export&tab=settings')) . '">you have specified</a> which statuses determine whether a property is sales or lettings', 'houzezpropertyfeed' ) . '</p></div>';
}
}
?>
No newline at end of file
--- a/houzez-property-feed/includes/views/admin-settings-primary-nav-export.php
+++ b/houzez-property-feed/includes/views/admin-settings-primary-nav-export.php
@@ -7,7 +7,7 @@
<?php
foreach ( $tabs as $key => $value )
{
- echo '<li' . ( $key == $active_tab ? ' class="active"' : '' ) . '><a href="' . admin_url('admin.php?page=houzez-property-feed-export&tab=' . esc_attr($key)) . '">' . esc_html($value) . '</a></li>';
+ echo '<li' . ( $key == $active_tab ? ' class="active"' : '' ) . '><a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-export&tab=' . esc_attr($key))) . '">' . esc_html($value) . '</a></li>';
}
?>
</ul>
--- a/houzez-property-feed/includes/views/admin-settings-primary-nav-import.php
+++ b/houzez-property-feed/includes/views/admin-settings-primary-nav-import.php
@@ -7,7 +7,7 @@
<?php
foreach ( $tabs as $key => $value )
{
- echo '<li' . ( $key == $active_tab ? ' class="active"' : '' ) . '><a href="' . admin_url('admin.php?page=houzez-property-feed-import&tab=' . esc_attr($key)) . '">' . esc_html($value) . '</a></li>';
+ echo '<li' . ( $key == $active_tab ? ' class="active"' : '' ) . '><a href="' . esc_url(admin_url('admin.php?page=houzez-property-feed-import&tab=' . esc_attr($key))) . '">' . esc_html($value) . '</a></li>';
}
?>
</ul>
--- a/houzez-property-feed/includes/views/admin-settings-settings-export-department-statuses.php
+++ b/houzez-property-feed/includes/views/admin-settings-settings-export-department-statuses.php
@@ -1,15 +1,15 @@
<?php if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly ?>
-<h3><?php echo __( 'Department Statuses', 'houzezpropertyfeed' ); ?></h3>
+<h3><?php echo esc_html(__( 'Department Statuses', 'houzezpropertyfeed' )); ?></h3>
-<p>Here you can select which statuses determine whether a property should be sent in exports as a sales or lettings property. Statuses can be <a href="<?php echo admin_url('edit-tags.php?taxonomy=property_status&post_type=property'); ?>" target="_blank">configured here</a>.</p>
+<p>Here you can select which statuses determine whether a property should be sent in exports as a sales or lettings property. Statuses can be <a href="<?php echo esc_url(admin_url('edit-tags.php?taxonomy=property_status&post_type=property')); ?>" target="_blank">configured here</a>.</p>
<div class="notice notice-info inline" id="duplicate_department_statuses" style="display:none"><p><?php echo __( 'You have the same status ticked in both Sales Statuses and Lettings Statuses. These should be unique so we know which department a property belongs to when exporting it.', 'houzezpropertyfeed' ); ?></p></div>
<table class="form-table">
<tbody>
<tr>
- <th><label for="sales_statuses"><?php echo __( 'Sales Statuses', 'houzezpropertyfeed' ); ?></label></th>
+ <th><label for="sales_statuses"><?php echo esc_html(__( 'Sales Statuses', 'houzezpropertyfeed' )); ?></label></th>
<td>
<select name="sales_statuses[]" id="sales_statuses" multiple style="width:100%; max-width:250px; height:130px;">
@@ -39,7 +39,7 @@
</td>
</tr>
<tr>
- <th><label for="lettings_statuses"><?php echo __( 'Lettings Statuses', 'houzezpropertyfeed' ); ?></label></th>
+ <th><label for="lettings_statuses"><?php echo esc_html(__( 'Lettings Statuses', 'houzezpropertyfeed' )); ?></label></th>
<td>
<select name="lettings_statuses[]" id="lettings_statuses" multiple style="width:100%; max-width:250px; height:130px;">