Submit
Path:
~
/
home
/
getwphos
/
public_html
/
ppine
/
wp-content
/
plugins
/
trx_addons
/
components
/
cpt
/
properties
/
File Content:
properties.js
/* global jQuery, TRX_ADDONS_STORAGE */ // Init properties functionality jQuery(document).on('action.ready_trx_addons', function() { "use strict"; // Single Property's page: Change featured image on click on the gallery image jQuery('.properties_page_gallery:not(.inited)') .addClass('inited') .on('click', '.properties_page_gallery_item', function(e) { if (jQuery(this).hasClass('properties_page_gallery_item_active')) return false; jQuery(this).siblings().removeClass('properties_page_gallery_item_active'); jQuery(this).addClass('properties_page_gallery_item_active'); var image = jQuery(this).data('image'); if (!image) return false; var featured = jQuery(this).parent().prev('.properties_page_featured'); var img_old = featured.find('img'); var h = img_old.height(); featured.height(h); img_old.animate({'opacity': 0}, 300, function() { jQuery(this).attr({ 'src': image, 'srcset': '' }).animate({'opacity': 1}, 400, function() { featured.height('auto'); }); setTimeout(function() { featured.height(img_old.height()); }, 100); }); e.preventDefault(); return false; }); // Properties Compare: add item function trx_addons_properties_compare_list_add(id, cmp_icon) { var title = cmp_icon.siblings('.sc_properties_item_title').text(); var list = trx_addons_get_cookie('trx_addons_properties_compare_list'); if (!list) list = {}; else list = JSON.parse(list); list['id_'+id] = encodeURIComponent(title); trx_addons_set_cookie('trx_addons_properties_compare_list', JSON.stringify(list), 24 * 60 * 60 * 1000); // 24 hours cmp_icon.addClass('in_compare_list'); var widget_list = jQuery('.widget_properties_compare .properties_compare_list'); if (widget_list.length > 0) { widget_list.append('<li data-property-id="'+id+'">'+title+'</li>'); if (widget_list.find('li').length < 2) widget_list.addClass('properties_compare_list_empty'); else widget_list.toggleClass('properties_compare_list_empty', false); } } // Properties Compare: remove item function trx_addons_properties_compare_list_remove(id) { var list = trx_addons_get_cookie('trx_addons_properties_compare_list'); if (!list) list = {}; else list = JSON.parse(list); if (typeof list['id_'+id] != 'undefined') { delete list['id_'+id]; } trx_addons_set_cookie('trx_addons_properties_compare_list', JSON.stringify(list), 24 * 60 * 60 * 1000); // 24 hours jQuery('.sc_properties_item_compare.in_compare_list[data-property-id="'+id+'"]').removeClass('in_compare_list'); var widget_list = jQuery('.widget_properties_compare .properties_compare_list'); widget_list.find('li[data-property-id="'+id+'"]').remove(); if (widget_list.find('li').length < 2) widget_list.addClass('properties_compare_list_empty'); else widget_list.toggleClass('properties_compare_list_empty', false); } // Properties archive: Compare button jQuery('.sc_properties:not(.inited)') .addClass('inited') .on('click', '.sc_properties_item_compare', function(e) { // Remove item from the Compare list if (jQuery(this).hasClass('in_compare_list')) { trx_addons_properties_compare_list_remove(jQuery(this).data('property-id')); // Add item to the Compare list } else { trx_addons_properties_compare_list_add(jQuery(this).data('property-id'), jQuery(this)); } e.preventDefault(); return false; }); // Widget "Properties Compare": Remove item from the list jQuery('.widget_properties_compare .properties_compare_list:not(.inited)') .addClass('inited') .on('click', 'li', function(e) { trx_addons_properties_compare_list_remove(jQuery(this).data('property-id')); e.preventDefault(); return false; }); // Widget "Properties Order": Submit form on change sorting field jQuery('select[name="properties_order"]:not(.inited)') .addClass('inited') .on('change', function(e) { jQuery(this).parents('form').submit(); e.preventDefault(); return false; }); // Widget "Properties Advanced Search": Show/Hide Advanced fields jQuery('.properties_search_show_advanced:not(.inited)') .addClass('inited') .on('click', function () { jQuery(this).parents('.properties_search').toggleClass('properties_search_opened'); }); // Widget "Properties Advanced Search": Field "Country" is changed - refresh states jQuery('select[name="properties_country"]:not(.inited)') .addClass('inited') .on('change', function () { var fld = jQuery(this); var slave_fld = fld.parents('form').find('select[name="properties_state"]'); if (slave_fld.length > 0) { var slave_lbl = slave_fld.parents('label'); trx_addons_refresh_list('states', fld.val(), slave_fld, slave_lbl); } }); // Widget "Properties Advanced Search": Field "State" is changed - refresh cities jQuery('select[name="properties_state"]:not(.inited)') .addClass('inited') .on('change', function () { var fld = jQuery(this); var slave_fld = fld.parents('form').find('select[name="properties_city"]'); if (slave_fld.length > 0) { var slave_lbl = slave_fld.parents('label'); var country = 0; if (fld.val() == 0) country = fld.parents('form').find('select[name="properties_country"]').val(); trx_addons_refresh_list('cities', {'state': fld.val(), 'country': country}, slave_fld, slave_lbl); } }); // Widget "Properties Advanced Search": Field "City" is changed - refresh neighborhoods jQuery('select[name="properties_city"]:not(.inited)') .addClass('inited') .on('change', function () { var fld = jQuery(this); var slave_fld = fld.parents('form').find('select[name="properties_neighborhood"]'); if (slave_fld.length > 0) { var slave_lbl = slave_fld.parents('label'); trx_addons_refresh_list('neighborhoods', fld.val(), slave_fld, slave_lbl); } }); });
Submit
FILE
FOLDER
Name
Size
Permission
Action
gutenberg
---
0755
properties-sc-elementor.php
11408 bytes
0644
properties-sc-gutenberg.php
6485 bytes
0644
properties-sc-vc.php
9920 bytes
0644
properties-sc.php
3845 bytes
0644
properties.admin.js
6004 bytes
0644
properties.agents.php
27638 bytes
0644
properties.css
21447 bytes
0644
properties.css.map
11521 bytes
0644
properties.elementor.editor.js
4882 bytes
0644
properties.js
5843 bytes
0644
properties.php
63009 bytes
0644
properties.png
1722 bytes
0644
properties.responsive.css
3796 bytes
0644
properties.responsive.css.map
1767 bytes
0644
properties.responsive.scss
3632 bytes
0644
properties.scss
19033 bytes
0644
properties.taxonomy_city.php
13976 bytes
0644
properties.taxonomy_country.php
4756 bytes
0644
properties.taxonomy_features.php
4665 bytes
0644
properties.taxonomy_labels.php
4664 bytes
0644
properties.taxonomy_neighborhood.php
16837 bytes
0644
properties.taxonomy_state.php
9674 bytes
0644
properties.taxonomy_status.php
4628 bytes
0644
properties.taxonomy_type.php
8244 bytes
0644
tpe.widget.properties_compare.php
1712 bytes
0644
tpe.widget.properties_sort.php
1468 bytes
0644
tpl.agents.archive.php
1635 bytes
0644
tpl.agents.default-item.php
2153 bytes
0644
tpl.agents.single.php
2612 bytes
0644
tpl.author.php
1853 bytes
0644
tpl.properties.archive.php
243 bytes
0644
tpl.properties.compare.php
5776 bytes
0644
tpl.properties.default-item.php
11248 bytes
0644
tpl.properties.default.php
4324 bytes
0644
tpl.properties.map.php
6517 bytes
0644
tpl.properties.parts.address.php
1900 bytes
0644
tpl.properties.parts.agent.php
3958 bytes
0644
tpl.properties.parts.form.php
5998 bytes
0644
tpl.properties.parts.loop.php
2187 bytes
0644
tpl.properties.parts.price.php
1271 bytes
0644
tpl.properties.single.php
23483 bytes
0644
tpl.properties.slider-slide.php
3720 bytes
0644
tpl.properties.slider.php
3713 bytes
0644
tpl.widget.properties_compare.php
1304 bytes
0644
tpl.widget.properties_search.php
16251 bytes
0644
tpl.widget.properties_sort.php
2326 bytes
0644
widget.properties_compare-sc-elementor.php
3295 bytes
0644
widget.properties_compare-sc-vc.php
1799 bytes
0644
widget.properties_compare-sc.php
2022 bytes
0644
widget.properties_compare.php
3337 bytes
0644
widget.properties_compare.png
1602 bytes
0644
widget.properties_search-sc-elementor.php
4053 bytes
0644
widget.properties_search-sc-vc.php
3014 bytes
0644
widget.properties_search-sc.php
2132 bytes
0644
widget.properties_search.php
5130 bytes
0644
widget.properties_search.png
2047 bytes
0644
widget.properties_sort-sc-elementor.php
4099 bytes
0644
widget.properties_sort-sc-vc.php
2524 bytes
0644
widget.properties_sort-sc.php
2040 bytes
0644
widget.properties_sort.php
3831 bytes
0644
widget.properties_sort.png
1992 bytes
0644
N4ST4R_ID | Naxtarrr