Commit inicial - WordPress Análisis de Precios Unitarios

- WordPress core y plugins
- Tema Twenty Twenty-Four configurado
- Plugin allow-unfiltered-html.php simplificado
- .gitignore configurado para excluir wp-config.php y uploads

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
root
2025-11-03 21:04:30 -06:00
commit a22573bf0b
24068 changed files with 4993111 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
// $tax_term_filters = asp_parse_tax_term_filters($style);
foreach ( wd_asp()->front_filters->get('position', 'taxonomy') as $k => $filter ) {
// $filter variable is an instance of aspTaxFilter object
// $filter->get() will return the array of filter objects (of stdClass)
// Some local variables for ease of use within the theme
$taxonomy = $filter->data['taxonomy'];
$ch_class = $filter->isMixed() ? 'terms' : preg_replace('/[^a-zA-Z0-9]+/', '', $taxonomy);
include Plugin::templateFilePath('filters/taxonomy/asp-tax-header.php');
switch ( $filter->display_mode ) {
case 'checkbox':
case 'checkboxes':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-checkboxes.php');
break;
case 'dropdown':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-dropdown.php');
break;
case 'dropdownsearch':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-dropdownsearch.php');
break;
case 'multisearch':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-multisearch.php');
break;
case 'radio':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-radio.php');
break;
default:
include Plugin::templateFilePath('filters/taxonomy/asp-tax-checkboxes.php');
break;
}
include Plugin::templateFilePath('filters/taxonomy/asp-tax-footer.php');
}

View File

@@ -0,0 +1,24 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
foreach ( wd_asp()->front_filters->get('position', 'content_type') as $filter ) {
include( Plugin::templateFilePath('filters/content_type/asp-content_type-header.php') );
switch ($filter->display_mode) {
case 'checkboxes':
include(Plugin::templateFilePath('filters/content_type/asp-content_type-checkboxes.php'));
break;
case 'radio':
include(Plugin::templateFilePath('filters/content_type/asp-content_type-radio.php'));
break;
default:
include(Plugin::templateFilePath('filters/content_type/asp-content_type-dropdown.php'));
break;
}
include(Plugin::templateFilePath('filters/content_type/asp-content_type-footer.php'));
}

View File

@@ -0,0 +1,69 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
foreach ( wd_asp()->front_filters->get('position', 'custom_field') as $k => $filter ) {
// $filter variable is an instance of aspTaxFilter object
// $filter->get() will return the array of filter objects (of stdClass)
// Unique fieldset identifier ID, for cases, when there are multiple filters used on the same field
//$fieldset_id = $id.$k;
$fieldset_id = $id.$filter->id;
// Field name, supporting brackets
/*$field_name = str_replace(
array('[', ']'),
array('!_brktl_!', '!_brktr_!'),
$filter->data['field']
) . "_" . $fieldset_id;*/
$field_name = $filter->getUniqueFieldName(true);
// Field name without white space
$field_name_nws = preg_replace('/\s+/', '', $field_name);
include(Plugin::templateFilePath('filters/custom_field/asp-cf-header.php'));
switch ($filter->display_mode) {
case 'checkboxes':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-checkboxes.php'));
break;
case 'dropdown':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-dropdown.php'));
break;
case 'dropdownsearch':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-dropdownsearch.php'));
break;
case 'multisearch':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-multisearch.php'));
break;
case 'radio':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-radio.php'));
break;
case 'slider':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-slider.php'));
break;
case 'range':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-range.php'));
break;
case 'number_range':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-number_range.php'));
break;
case 'datepicker':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-datepicker.php'));
break;
case 'text':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-text.php'));
break;
case 'hidden':
include(Plugin::templateFilePath('filters/custom_field/asp-cf-hidden.php'));
break;
default:
include(Plugin::templateFilePath('filters/custom_field/asp-cf-checkboxes.php'));
break;
}
include(Plugin::templateFilePath('filters/custom_field/asp-cf-footer.php'));
}

View File

@@ -0,0 +1,31 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
$hidden_types = array();
$displayed_custom_types = array();
foreach ( wd_asp()->front_filters->get('position', 'post_type') as $filter ) {
include( Plugin::templateFilePath('filters/post_type/asp-post-type-header.php') );
switch ( $filter->display_mode ) {
case 'checkboxes':
include(Plugin::templateFilePath('filters/post_type/asp-post-type-checkboxes.php'));
break;
case 'radio':
include(Plugin::templateFilePath('filters/post_type/asp-post-type-radio.php'));
break;
default:
include(Plugin::templateFilePath('filters/post_type/asp-post-type-dropdown.php'));
break;
}
foreach ( $filter->get() as $item ) {
$displayed_custom_types[] = $item->value;
}
include(Plugin::templateFilePath('filters/post_type/asp-post-type-footer.php'));
}

View File

@@ -0,0 +1,20 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
?>
<div class='asp_hidden_data' style="display:none !important;">
<div class='asp_item_overlay'>
<div class='asp_item_inner'>
<?php
if (w_isset_def($style['i_res_custom_magnifierimage'], "") == "" &&
pathinfo(w_isset_def($style['i_res_magnifierimage'], "/ajax-search-pro/img/svg/magnifiers/magn4.svg"), PATHINFO_EXTENSION) == 'svg'
) {
echo file_get_contents(WP_PLUGIN_DIR . '/' . w_isset_def($style['i_res_magnifierimage'], "/ajax-search-pro/img/svg/magnifiers/magn4.svg") );
} else if (w_isset_def($style['i_res_custom_magnifierimage'], "") != "") {
echo "<img src='".$style['i_res_custom_magnifierimage']."'>";
}
?>
<?php do_action('asp_layout_in_loading', $id); ?>
</div>
</div>
</div>

View File

@@ -0,0 +1,14 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
foreach ( wd_asp()->front_filters->get('position', 'date') as $filter ) {
include( Plugin::templateFilePath('filters/date/asp-date-header.php') );
include( Plugin::templateFilePath('filters/date/asp-date-filter.php') );
include( Plugin::templateFilePath('filters/date/asp-date-footer.php') );
}

View File

@@ -0,0 +1,24 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
foreach ( wd_asp()->front_filters->get('position', 'generic') as $filter ) {
include( Plugin::templateFilePath('filters/generic/asp-generic-header.php') );
switch ($filter->display_mode) {
case 'checkboxes':
include(Plugin::templateFilePath('filters/generic/asp-generic-checkboxes.php'));
break;
case 'radio':
include(Plugin::templateFilePath('filters/generic/asp-generic-radio.php'));
break;
default:
include(Plugin::templateFilePath('filters/generic/asp-generic-dropdown.php'));
break;
}
include(Plugin::templateFilePath('filters/generic/asp-generic-footer.php'));
}

View File

@@ -0,0 +1,74 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Hooks\AjaxManager;
defined('ABSPATH') or die("You can't access this file directly.");
$real_id = $id;
$id = $id . '_' . self::$perInstanceCount[$real_id];
$ana_options = wd_asp()->o['asp_analytics'];
$comp_options = wd_asp()->o['asp_compatibility'];
$extra_container_class = $style['box_compact_layout'] == 1 ? ' asp_compact' : '';
$extra_class .= $style['box_compact_layout'] == 1 ? ' asp_compact' : ' asp_non_compact';
$extra_class .= $style['box_sett_hide_box'] == 1 ? ' hiddend' : '';
$extra_attrs = $style['box_compact_layout'] == 1 ? ' data-asp-compact="closed"' : '';
?>
<div class="asp_w_container asp_w_container_<?php echo $real_id; ?> asp_w_container_<?php echo $id; ?><?php echo $extra_container_class; ?>" data-id="<?php echo $real_id; ?>" data-instance="<?php echo self::$perInstanceCount[$real_id]; ?>">
<div class='asp_w asp_m asp_m_<?php echo $real_id; ?> asp_m_<?php echo $id; ?> wpdreams_asp_sc wpdreams_asp_sc-<?php echo $real_id; ?> ajaxsearchpro asp_main_container <?php echo $extra_class; ?>'
data-id="<?php echo $real_id; ?>"
data-name="<?php echo esc_attr($search['name']); ?>"
<?php echo $extra_attrs; ?>
data-instance="<?php echo self::$perInstanceCount[$real_id]; ?>"
id='ajaxsearchpro<?php echo $id; ?>'>
<?php
/******************** PROBOX INCLUDE ********************/
include('asp.shortcode.probox.php');
?>
</div>
<div class='asp_data_container' style="display:none !important;">
<?php
/******************** SCRIPT INCLUDE (hidden) ********************/
include('asp.shortcode.script.php');
/******************** DATA INCLUDE (hidden) ********************/
include('asp.shortcode.data.php');
?>
</div>
<?php
/******************** RESULTS INCLUDE ********************/
include('asp.shortcode.results.php');
$blocking = w_isset_def($style['frontend_search_settings_position'], 'hover');
if ($blocking == 'block'): ?>
<?php include('asp.shortcode.suggested.php'); ?>
<div id='__original__ajaxsearchprobsettings<?php echo $id; ?>'
class="asp_w asp_ss asp_ss_<?php echo $real_id; ?> asp_sb asp_sb_<?php echo $real_id; ?> asp_sb_<?php echo $id; ?> asp_sb wpdreams_asp_sc wpdreams_asp_sc-<?php echo $real_id; ?> ajaxsearchpro searchsettings"
data-id="<?php echo $real_id; ?>"
data-instance="<?php echo self::$perInstanceCount[$real_id]; ?>">
<?php else: ?>
<div id='__original__ajaxsearchprosettings<?php echo $id; ?>'
class="asp_w asp_ss asp_ss_<?php echo $real_id; ?> asp_s asp_s_<?php echo $real_id; ?> asp_s_<?php echo $id; ?> wpdreams_asp_sc wpdreams_asp_sc-<?php echo $real_id; ?> ajaxsearchpro searchsettings"
data-id="<?php echo $real_id; ?>"
data-instance="<?php echo self::$perInstanceCount[$real_id]; ?>">
<?php endif;
/******************* SETTINGS INCLUDE *******************/
include('asp.shortcode.settings.php');
?>
</div>
<?php if ($blocking != 'block'): ?>
<?php include('asp.shortcode.suggested.php'); ?>
<?php endif;
/******************* CLEARFIX *******************/
if (w_isset_def($style['box_compact_float'], 'none') != 'none') {
echo '<div class="wpdreams_clear"></div>';
}
?>
</div>

View File

@@ -0,0 +1,40 @@
<?php
/* Prevent direct access */
use WPDRMS\ASP\Utils\Plugin;
defined('ABSPATH') or die("You can't access this file directly.");
foreach ( wd_asp()->front_filters->get('position', 'post_tags') as $k => $filter ) {
// $filter variable is an instance of aspPostTagsFilter object
// $filter->get() will return the array of filter objects (of stdClass)
// Some local variables for ease of use within the theme
$taxonomy = 'post_tag';
$ch_class = $filter->isMixed() ? 'terms' : preg_replace('/[^a-zA-Z0-9]+/', '', $taxonomy);
include Plugin::templateFilePath('filters/taxonomy/asp-tax-header.php');
switch ( $filter->display_mode ) {
case 'checkboxes':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-checkboxes.php');
break;
case 'dropdown':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-dropdown.php');
break;
case 'dropdownsearch':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-dropdownsearch.php');
break;
case 'multisearch':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-multisearch.php');
break;
case 'radio':
include Plugin::templateFilePath('filters/taxonomy/asp-tax-radio.php');
break;
default:
include Plugin::templateFilePath('filters/taxonomy/asp-tax-checkboxes.php');
break;
}
include Plugin::templateFilePath('filters/taxonomy/asp-tax-footer.php');
}

View File

@@ -0,0 +1,132 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* The loader class is not accessible from here,
* as this is a front-end request and types.inc.php is not included.
*
* As an exception, the loading icon values are copied here.
*/
$asp_loaders = array(
"ball-pulse" => 3,
"ball-grid-pulse" => 9,
"simple-circle" => 0,
"ball-clip-rotate" => 1,
"ball-clip-rotate-simple" => 2,
"ball-clip-rotate-multiple" => 2,
"ball-rotate" => 1,
"cube-transition" => 2,
"ball-scale" => 1,
"line-scale" => 5,
"line-scale-party" => 4,
"ball-scale-multiple" => 3,
"ball-pulse-sync" => 3,
"ball-beat" => 3,
"line-scale-pulse-out" => 5,
"line-scale-pulse-out-rapid" => 5,
"ball-scale-ripple" => 1,
"ball-scale-ripple-multiple" => 3,
"ball-spin-fade-loader" => 8,
"line-spin-fade-loader" => 8,
"ball-grid-beat" => 9,
);
?>
<div class="probox">
<?php do_action('asp_layout_before_settings', $id); ?>
<div class='prosettings<?php echo w_isset_def($style['box_compact_layout'], 0)==1?' hiddend':''; ?>' <?php echo($settingsHidden ? "style='display:none;'" : ""); ?> data-opened=0>
<?php do_action('asp_layout_in_settings', $id); ?>
<div class='innericon'>
<?php
if (w_isset_def($style['settingsimage_custom'], "") == "" &&
pathinfo($style['settingsimage'], PATHINFO_EXTENSION) == 'svg'
) {
echo file_get_contents(WP_PLUGIN_DIR . '/' . $style['settingsimage']);
}
?>
</div>
</div>
<?php do_action('asp_layout_after_settings', $id); ?>
<?php do_action('asp_layout_before_input', $id); ?>
<div class='proinput<?php echo w_isset_def($style['box_compact_layout'], 0)==1?' hiddend':''; ?>'>
<form role="search" action='#' autocomplete="off"
aria-label="<?php echo esc_attr(asp_icl_t('Search form aria-Label', $style['aria_search_form_label'])); ?>">
<input type='search' class='orig'
placeholder='<?php echo esc_attr(asp_icl_t( "Search bar placeholder text" . " ($real_id)", $style['defaultsearchtext'] )); ?>'
name='phrase' value='<?php echo esc_attr(apply_filters('asp_print_search_query', asp_get_search_query(), $id, $real_id)); ?>'
aria-label="<?php echo esc_attr(asp_icl_t('Search input aria-Label', $style['aria_search_input_label'])); ?>"
autocomplete="off"/>
<input type='text' class='autocomplete' name='phrase' value=''
aria-label="<?php echo esc_attr(asp_icl_t('Search autocomplete input aria-Label', $style['aria_search_autocomplete_label'])); ?>"
aria-hidden="true"
tabindex="-1"
autocomplete="off" disabled/>
</form>
</div>
<?php do_action('asp_layout_after_input', $id); ?>
<?php do_action('asp_layout_before_magnifier', $id); ?>
<button class='promagnifier' aria-label="<?php echo esc_attr(asp_icl_t('Search magnifier button aria-Label', $style['aria_magnifier_label'])); ?>">
<?php do_action('asp_layout_in_magnifier', $id); ?>
<span class='asp_text_button<?php echo w_isset_def($style['display_search_text'], 0) == 1 ? "" : " hiddend"; ?>'>
<?php echo asp_icl_t( "Search button text ($real_id)", $style['search_text']); ?>
</span>
<span class='innericon<?php echo w_isset_def($style['hide_magnifier'], 0) == 1 ? " hiddend" : ""; ?>'>
<?php
if (w_isset_def($style['magnifierimage_custom'], "") == "" &&
pathinfo($style['magnifierimage'], PATHINFO_EXTENSION) == 'svg'
) {
echo file_get_contents(WP_PLUGIN_DIR . '/' . $style['magnifierimage']);
}
?>
</span>
<span class="asp_clear"></span>
</button>
<?php do_action('asp_layout_after_magnifier', $id); ?>
<?php do_action('asp_layout_before_loading', $id); ?>
<div class='proloading<?php echo w_isset_def($style['box_compact_layout'], 0)==1?' hiddend':''; ?>'>
<?php
$asp_loader_class = w_isset_def($style['loader_image'], "simple-circle");
?>
<?php if ( trim($style['loadingimage_custom']) == '' ): ?>
<div class="asp_loader">
<div class="asp_loader-inner asp_<?php echo $asp_loader_class; ?>">
<?php
for($i=0;$i<$asp_loaders[$asp_loader_class];$i++) {
echo "
<div></div>
";
}
?>
</div>
</div>
<?php endif; ?>
<?php
do_action('asp_layout_in_loading', $id);
?>
</div>
<?php if ($style['show_close_icon']): ?>
<div class='proclose<?php echo w_isset_def($style['box_compact_layout'], 0)==1?' hiddend':''; ?>'>
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px"
y="0px"
width="512px" height="512px" viewBox="0 0 512 512" enable-background="new 0 0 512 512"
xml:space="preserve">
<polygon points="438.393,374.595 319.757,255.977 438.378,137.348 374.595,73.607 255.995,192.225 137.375,73.622 73.607,137.352 192.246,255.983 73.622,374.625 137.352,438.393 256.002,319.734 374.652,438.378 "/>
</svg>
</div>
<?php endif; ?>
<?php do_action('asp_layout_after_loading', $id); ?>
</div>

View File

@@ -0,0 +1,102 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
$_pagination_arrow = file_get_contents(WP_PLUGIN_DIR . '/' . $style['i_pagination_arrow']);
?>
<div id='__original__ajaxsearchprores<?php echo $id; ?>' class='asp_w asp_r asp_r_<?php echo $real_id; ?> asp_r_<?php echo $id; ?> <?php echo $style['resultstype']; ?> ajaxsearchpro wpdreams_asp_sc wpdreams_asp_sc-<?php echo $real_id; ?>'
data-id="<?php echo $real_id; ?>"
data-instance="<?php echo self::$perInstanceCount[$real_id]; ?>">
<?php if ( $style['results_top_box'] == 1 && $style['results_top_box_text'] != '' ): ?>
<div class="asp_results_top" style="display:none;">
<div class="asp_rt_phrase"><?php echo stripslashes( asp_icl_t("Results header information box text, whith search phrase" . " ($id)", $style['results_top_box_text'] ) ); ?></div>
<div class="asp_rt_nophrase"><?php echo stripslashes( asp_icl_t("Results header information box text, without search phrase" . " ($id)", $style['results_top_box_text_nophrase'] ) ); ?></div>
</div>
<?php endif; ?>
<?php if ($style['resultstype'] == "isotopic" &&
($style['i_pagination_position'] == 'top' || $style['i_pagination_position'] == 'both')): ?>
<nav class="asp_navigation">
<a class="asp_prev" role="button">
<?php echo $_pagination_arrow; ?>
</a>
<a class="asp_next" role="button">
<?php echo $_pagination_arrow; ?>
</a>
<ul></ul>
<div class="clear"></div>
</nav>
<?php endif; ?>
<?php do_action('asp_layout_before_results', $id); ?>
<div class="results">
<?php do_action('asp_layout_before_first_result', $id); ?>
<div class="resdrg">
</div>
<?php do_action('asp_layout_after_last_result', $id); ?>
</div>
<?php do_action('asp_layout_after_results', $id); ?>
<?php if ($style['showmoreresults'] == 1): ?>
<?php do_action('asp_layout_before_showmore', $id); ?>
<div class="asp_showmore_container">
<p class='showmore'>
<a class='asp_showmore' role="button" href="<?php echo esc_url(get_site_url()); ?>"><?php echo asp_icl_t("More results text" . " ($real_id)", $style['showmoreresultstext']) . " <span></span>"; ?></a>
</p>
<div class="asp_moreres_loader" style="display: none;">
<div class="asp_moreres_loader-inner"></div>
</div>
</div>
<?php do_action('asp_layout_after_showmore', $id); ?>
<?php endif; ?>
<?php if ($style['resultstype'] == "isotopic" &&
($style['i_pagination_position'] == 'bottom' || $style['i_pagination_position'] == 'both')): ?>
<nav class="asp_navigation">
<a class="asp_prev" role="button">
<?php echo $_pagination_arrow; ?>
</a>
<ul></ul>
<a class="asp_next" role="button">
<?php echo $_pagination_arrow; ?>
</a>
<div class="clear"></div>
</nav>
<?php endif; ?>
<div class="asp_res_loader hiddend">
<?php if ( trim($style['loadingimage_custom']) == '' ): ?>
<div class="asp_loader">
<div class="asp_loader-inner asp_<?php echo $asp_loader_class; ?>">
<?php
for($i=0;$i<$asp_loaders[$asp_loader_class];$i++) {
echo "
<div></div>
";
}
?>
</div>
</div>
<?php else: ?>
<div class='asp_custom_loader'></div>
<?php endif; ?>
</div>
</div>

View File

@@ -0,0 +1,205 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* A better method to store the init data.
*
* The JSON data is stored inside this invisible element, the it is parsed
* and passed as an argument to the initialization method.
*/
$options_array = array(
'animations' => array(
'pc' => array(
'settings' => array(
'anim' => $style['sett_box_animation'],
'dur' => intval($style['sett_box_animation_duration']),
),
'results' => array(
'anim' => $style['res_box_animation'],
'dur' => intval($style['res_box_animation_duration']),
),
'items' => $style['res_items_animation'],
),
'mob' => array(
'settings' => array(
'anim' => $style['sett_box_animation_m'],
'dur' => $style['sett_box_animation_duration_m'],
),
'results' => array(
'anim' => $style['res_box_animation_m'],
'dur' => $style['res_box_animation_duration_m'],
),
'items' => $style['res_items_animation_m'],
),
),
'autocomplete' => array(
'enabled' => $style['autocomplete'] == 1 || $style['autocomplete'] == 2 ? 1 : 0,
'trigger_charcount' => intval($style['autoc_trigger_charcount']),
'googleOnly' => $style['autocomplete_source'] == 'google' ? 1 : 0,
'lang' => $style['autocomplete_google_lang'],
'mobile' => $style['autocomplete'] == 1 || $style['autocomplete'] == 3 ? 1 : 0,
),
'autop' => array(
'state' => $style['auto_populate'],
'phrase' => stripslashes($style['auto_populate_phrase']),
'count' => intval($style['auto_populate_count']),
),
'charcount' => intval($style['charcount']),
'closeOnDocClick' => intval($style['close_on_document_click']),
'compact' => array(
'enabled' => intval($style['box_compact_layout']),
'focus' => intval($style['box_compact_layout_focus_on_open']),
'width' => $style['box_compact_width'],
'width_tablet' => $style['box_compact_width_tablet'],
'width_phone' => $style['box_compact_width_phone'],
'closeOnMagnifier' => intval($style['box_compact_close_on_magn']),
'closeOnDocument' => intval($style['box_compact_close_on_document']),
'position' => $style['box_compact_position'],
'overlay' => intval($style['box_compact_overlay']),
),
'cptArchive' => array(
'useAjax' => ( \WPDRMS\ASP\Utils\Archive::isPostTypeArchive() && $style['cpt_archive_live_search'] ) ? 1 : 0,
'selector' => $style['cpt_archive_live_selector'],
'url' => \WPDRMS\ASP\Utils\Archive::getCurrentArchiveURL(),
),
'detectVisibility' => intval($style['visual_detect_visbility']),
'divi' => array(
'bodycommerce' => defined('DE_DB_WOO_VERSION') ? 1 : 0,
),
'focusOnPageload' => intval($style['focus_on_pageload']),
'fss_layout' => $style['fss_column_layout'],
'highlight' => intval($style['highlight']),
'highlightWholewords' => intval($style['highlightwholewords']),
'homeurl' => is_admin()
? home_url('/')
: ( function_exists('pll_home_url')
? PLL()->links->get_home_url('', true)
: home_url('/') ),
'is_results_page' => isset($_GET['s']) ? 1 : 0,
'isotopic' => array(
'itemWidth' => is_numeric($style['i_item_width']) ? $style['i_item_width'] . 'px' : $style['i_item_width'],
'itemWidthTablet' => is_numeric($style['i_item_width_tablet']) ? $style['i_item_width_tablet'] . 'px' : $style['i_item_width_tablet'],
'itemWidthPhone' => is_numeric($style['i_item_width_phone']) ? $style['i_item_width_phone'] . 'px' : $style['i_item_width_phone'],
'itemHeight' => is_numeric($style['i_item_height']) ? $style['i_item_height'] . 'px' : $style['i_item_height'],
'itemHeightTablet' => is_numeric($style['i_item_height_tablet']) ? $style['i_item_height_tablet'] . 'px' : $style['i_item_height_tablet'],
'itemHeightPhone' => is_numeric($style['i_item_height_phone']) ? $style['i_item_height_phone'] . 'px' : $style['i_item_height_phone'],
'pagination' => intval($style['i_pagination']),
'rows' => intval($style['i_rows']),
'gutter' => intval($style['i_item_margin']),
'showOverlay' => intval($style['i_overlay']),
'blurOverlay' => intval($style['i_overlay_blur']),
'hideContent' => intval($style['i_hide_content']),
),
'itemscount' => intval($style['v_res_show_scrollbar'] == 1 ? $style['itemscount'] : '0'),
'loaderLocation' => $style['loader_display_location'],
'mobile' => array(
'trigger_on_type' => intval($style['mob_trigger_on_type']),
'click_action' => $style['mob_click_action'] == 'same' ? $style['click_action'] : $style['mob_click_action'],
'return_action' => apply_filters('asp_show_more_url', $style['mob_return_action'] == 'same' ? $style['return_action'] : $style['mob_return_action'], $real_id),
'click_action_location' => $style['mob_click_action'] == 'same' ? $style['click_action_location'] : $style['mob_click_action_location'],
'return_action_location' => $style['mob_return_action'] == 'same' ? $style['return_action_location'] : $style['mob_return_action_location'],
'redirect_url' => $style['mob_click_action'] == 'custom_url' || $style['mob_return_action'] == 'custom_url' ? $style['mob_redirect_url'] : $style['redirect_url'],
'elementor_url' => $style['mob_click_action'] == 'same' ? $style['redirect_elementor'] : $style['mob_redirect_elementor'],
'menu_selector' => $style['mob_auto_focus_menu_selector'],
'hide_keyboard' => intval($style['mob_hide_keyboard']),
'force_res_hover' => intval($style['mob_force_res_hover']),
'force_sett_hover' => intval($style['mob_force_sett_hover']),
'force_sett_state' => $style['mob_force_sett_state'],
),
'override_method' => $style['override_method'],
'overridewpdefault' => intval($style['override_default_results']),
'prescontainerheight' => $style['prescontainerheight'],
'preventBodyScroll' => intval(wd_asp()->o['asp_compatibility']['js_prevent_body_scroll']),
'preventEvents' => intval($prevent_events),
'rb' => array(
'action' => $style['fe_rb_action'],
),
'resPage' => array(
'useAjax' => is_search() && $style['res_live_search'] ? 1 : 0,
'selector' => $style['res_live_selector'],
'trigger_type' => intval($style['res_live_trigger_type']),
'trigger_facet' => intval($style['res_live_trigger_facet']),
'trigger_magnifier' => intval($style['res_live_trigger_click']),
'trigger_return' => intval($style['res_live_trigger_return']),
),
'results' => array(
'width' => $style['results_width'],
'width_tablet' => $style['results_width_tablet'],
'width_phone' => $style['results_width_phone'],
),
'resultsSnapTo' => $style['results_snap_to'],
'resultsposition' => $style['resultsposition'],
'resultstype' => $style['resultstype'],
'sb' => array(
'redirect_action' => $style['fe_sb_action'],
'redirect_location' => $style['fe_sb_action_location'],
'redirect_url' => $style['fe_sb_redirect_url'],
'elementor_url' => $style['fe_sb_redirect_elementor'],
),
'scrollBar' => array(
'horizontal' => array(
'enabled' => intval($style['h_res_show_scrollbar']),
),
),
'scrollToResults' => array(
'enabled' => intval($style['scroll_to_results']),
'offset' => intval($style['scroll_to_results_offset']),
),
'select2' => array(
'nores' => esc_html(asp_icl_t('Searchable select filter placeholder' . " ($real_id)", $style['jquery_select2_nores'])),
),
'settings' => array(
'unselectChildren' => intval($style['frontend_terms_parent_unselect_children']),
'hideChildren' => intval($style['frontend_terms_hide_children']),
),
'settingsHideOnRes' => intval($style['fss_hide_on_results']),
'settingsimagepos' => $style['settingsimagepos'],
'settingsVisible' => intval($style['frontend_search_settings_visible']),
'show_more' => array(
'enabled' => intval($style['showmoreresults']),
'url' => apply_filters('asp_show_more_url', $style['more_redirect_url'], $real_id),
'elementor_url' => $style['more_redirect_elementor'],
'action' => $style['more_results_action'],
'location' => $style['more_redirect_location'],
'infinite' => $style['more_results_infinite'] && $style['more_results_action'] == 'ajax' ? 1 : 0,
),
'singleHighlight' => intval($style['single_highlight']),
'statistics' => get_option('asp_stat', 0) ? 0 : 1,
'taxArchive' => array(
'useAjax' => ( \WPDRMS\ASP\Utils\Archive::isTaxonomyArchive() && $style['taxonomy_archive_live_search'] ) ? 1 : 0,
'selector' => $style['taxonomy_archive_live_selector'],
'url' => \WPDRMS\ASP\Utils\Archive::getCurrentArchiveURL(),
),
'trigger' => array(
'delay' => $style['trigger_delay'],
'autocomplete_delay' => $style['autocomplete_trigger_delay'],
'update_href' => intval($style['trigger_update_href']),
'facet' => intval($style['trigger_on_facet']),
'type' => $style['triggerontype'] == 1 ? 1 : 0,
'click' => $style['click_action'],
'click_location' => $style['click_action_location'],
'return' => $style['return_action'],
'return_location' => $style['return_action_location'],
'redirect_url' => apply_filters('asp_redirect_url', $style['redirect_url'], $real_id),
'elementor_url' => $style['redirect_elementor'],
'minWordLength' => intval($style['min_word_length']),
),
'wooShop' => array(
'useAjax' => ( \WPDRMS\ASP\Utils\WooCommerce::isShop() && $style['woo_shop_live_search'] ) ? 1 : 0,
'selector' => $style['woo_shop_live_selector'],
'url' => ( \WPDRMS\ASP\Utils\WooCommerce::isShop() && $style['woo_shop_live_search'] ) ? get_permalink(wc_get_page_id('shop')) : '',
),
);
$_asp_script_out = json_encode($options_array);
wd_asp()->instances->add_script_data($real_id, $_asp_script_out);
?>
<div class="asp_init_data"
style="display:none !important;"
id="asp_init_id_<?php echo $id; ?>"
data-asp-id="<?php echo $real_id; ?>"
data-asp-instance="<?php echo self::$perInstanceCount[ $real_id ]; ?>"
data-aspdata="<?php echo base64_encode($_asp_script_out); ?>"></div>

View File

@@ -0,0 +1,13 @@
<?php
use WPDRMS\ASP\Utils\Plugin;
foreach (wd_asp()->front_filters->get('position', 'button') as $k => $filter ) {
include(Plugin::templateFilePath('filters/button/asp-button-header.php'));
include(Plugin::templateFilePath('filters/button/asp-button-filter.php'));
include(Plugin::templateFilePath('filters/button/asp-button-footer.php'));
}
return;

View File

@@ -0,0 +1,55 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
if ( function_exists('qtranxf_getLanguage') ) {
$qtr_lg = qtranxf_getLanguage();
} else if ( function_exists('qtrans_getLanguage') ) {
$qtr_lg = qtrans_getLanguage();
} else {
$qtr_lg = 0;
}
?>
<form name='options' class="asp-fss-<?php echo $style['fss_column_layout']; ?>"
aria-label="<?php echo esc_attr(asp_icl_t('Search Settings form aria-Label', $style['aria_settings_form_label'])); ?>"
autocomplete = 'off'>
<?php do_action('asp_layout_in_form', $real_id); ?>
<input type="hidden" name="current_page_id" value="<?php echo get_the_ID() !== false ? get_the_ID() : '-1'; ?>">
<?php if ( function_exists('get_woocommerce_currency') ): ?>
<input type="hidden" name="woo_currency" value="<?php echo get_woocommerce_currency(); ?>">
<?php endif; ?>
<?php if ( class_exists('PeepSo') ): ?>
<input type="hidden" name="peepso_object_type" value="<?php echo apply_filters('peepso_object_type', 0); ?>">
<input type="hidden" name="peepso_object_id" value="<?php echo apply_filters('peepso_object_id', 0); ?>">
<?php endif; ?>
<?php if ( $style['result_page_highlight'] == 1 ): ?>
<input type="hidden" name="asp_highlight" value="1">
<?php endif; ?>
<input type='hidden' name='qtranslate_lang'
value='<?php echo $qtr_lg; ?>'/>
<?php if ( function_exists("pll_current_language") ): ?>
<input type='hidden' name='polylang_lang' style="display:none;"
value='<?php echo pll_current_language(); ?>'/>
<?php endif; ?>
<?php if (defined('ICL_LANGUAGE_CODE')
&& !empty(ICL_LANGUAGE_CODE)
&& defined('ICL_SITEPRESS_VERSION')
): ?>
<input type='hidden' name='wpml_lang'
value='<?php echo esc_attr(ICL_LANGUAGE_CODE); ?>'/>
<?php endif; ?>
<input type="hidden" name="filters_changed" value="0">
<input type="hidden" name="filters_initial" value="1">
<?php
do_action('asp_layout_settings_before_first_item', $id);
$fields = w_isset_def($style['field_order'], 'general|custom_post_types|custom_fields|categories_terms');
if (strpos($fields, "general") === false) $fields = "general|" . $fields;
if (strpos($fields, "post_tags") === false) $fields .= "|post_tags";
if (strpos($fields, "date_filters") === false) $fields .= "|date_filters";
$field_order = explode( '|', $fields );
foreach ($field_order as $field)
include("asp.shortcode.$field.php");
?>
<div style="clear:both;"></div>
</form>

View File

@@ -0,0 +1,20 @@
<?php
/***************** SUGGESTED PHRASES ******************/
if (w_isset_def($style['frontend_show_suggestions'], 0) == 1) {
$sugg_keywords = trim(preg_replace('/[\s\t\n\r\s]+/', ' ', $style['frontend_suggestions_keywords']));
$sugg_keywords = str_replace(array(" ,", ", ", " , "), ",", $sugg_keywords);
$sugg_keywords = stripslashes(esc_html($sugg_keywords));
$sugg_keywords_arr = apply_filters("asp_suggested_phrases", explode(",", $sugg_keywords), $real_id);
foreach ( $sugg_keywords_arr as $skk => &$skv ) {
$skv = asp_icl_t('Keyword suggestion ['.$skv.'] ' . '(' . $real_id . ')', $skv);
}
$s_phrases = implode('</a><a href="#">', $sugg_keywords_arr);
?>
<p id="asp-try-<?php echo $id; ?>"
class="asp-try asp-try-<?php echo $real_id; ?><?php echo $style['box_compact_layout'] == 1 ? ' asp_compact' : ' asp_non_compact'; ?>"
>
<?php echo asp_icl_t('Keyword suggestions text', $style['frontend_suggestions_text']).' <a href="#">'.$s_phrases.'</a>'; ?>
</p><?php
}

View File

@@ -0,0 +1,14 @@
<?php foreach ( $filter->get() as $button ): ?>
<div class="<?php echo $button->container_class; ?>">
<?php
/**
* The type="button" is REQUIRED!
* Otherwise it defaults back to type="submit", which will cause a "click" event to fire when the user
* focuses an input in the settings form and then hints "Enter".
*
* @see https://jsfiddle.net/b7oandjw/
*/
?>
<button type="button" class="<?php echo $button->button_class; ?>"><?php echo esc_html($button->label); ?></button>
</div>
<?php endforeach; ?>

View File

@@ -0,0 +1,2 @@
</div>
</fieldset>

View File

@@ -0,0 +1,2 @@
<fieldset class="asp_s_btn_container">
<div class="asp_sr_btn_flex">

View File

@@ -0,0 +1,21 @@
<?php foreach ( $filter->get() as $ctfield ): ?>
<div class="asp_option asp_option_cat
asp_option_content_type asp_option_content_type_<?php echo esc_attr($ctfield->field); ?> <?php echo $ctfield->value == -1 ? 'asp_option_selectall' : ''; ?>"
role="checkbox"
aria-checked="<?php echo $ctfield->selected ? 'true' : 'false'; ?>"
tabindex="0">
<div class="asp_option_inner">
<input type="checkbox" value="<?php echo esc_attr($ctfield->value); ?>" id="set_<?php echo esc_attr($ctfield->field).$id; ?>"
aria-label="<?php echo esc_html($ctfield->label); ?>"
<?php echo $ctfield->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $ctfield->value == -1 ?
" data-targetclass='asp_ctf_cbx' " :
" class='asp_ctf_cbx' "; ?>
name="asp_ctf[]" <?php echo $ctfield->selected ? ' checked="checked"' : ''; ?>/>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label">
<?php echo esc_html($ctfield->label); ?>
</div>
</div>
<?php endforeach; ?>

View File

@@ -0,0 +1,12 @@
<div class='asp_select_label asp_select_single'>
<select name="asp_ctf[]"
aria-label="<?php echo esc_html($filter->label); ?>">
<?php foreach ( $filter->get() as $ctfield ): ?>
<option value="<?php echo esc_attr($ctfield->value); ?>" class="asp_option"
<?php echo $ctfield->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $ctfield->selected ? "selected='selected'" : ""; ?>>
<?php echo esc_html($ctfield->label); ?>
</option>
<?php endforeach; ?>
</select>
</div>

View File

@@ -0,0 +1,6 @@
<fieldset
data-asp_invalid_msg="<?php echo asp_icl_t("Content type filter invalid input text", $filter->data['invalid_input_text'], true); ?>"
class="asp_filter_content_type asp_content_type_filters asp_filter_id_<?php echo $filter->id; ?> asp_filter_n_<?php echo $filter->position; ?><?php echo $filter->data['required'] ? ' asp_required' : ''; ?>">
<?php if ($filter->label != ''): ?>
<legend><?php echo asp_icl_t("Content type filter label", $filter->label, true); ?></legend>
<?php endif; ?>

View File

@@ -0,0 +1,10 @@
<div>
<?php foreach ( $filter->get() as $ctfield ): ?>
<label class="asp_label">
<input type="radio" class="asp_radio" name="asp_ctf[]"
<?php echo $ctfield->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $ctfield->selected ? "checked='checked'" : ""; ?> value="<?php echo esc_attr($ctfield->value); ?>">
<?php echo esc_html($ctfield->label); ?>
</label><br>
<?php endforeach; ?>
</div>

View File

@@ -0,0 +1,20 @@
<?php foreach($filter->get() as $k => $checkbox): ?>
<div class="asp_option asp_option_cff asp_option_cff_<?php echo esc_attr($field_name_nws); ?>"
role="checkbox"
aria-checked="<?php echo $checkbox->selected ? 'true' : 'false'; ?>"
tabindex="0">
<div class="asp_option_inner">
<input type="checkbox" value="<?php echo esc_attr($checkbox->value); ?>"
id="aspf<?php echo $fieldset_id; ?>[<?php echo $field_name; ?>][<?php echo $k; ?>]"
aria-label="<?php echo esc_attr( $checkbox->label ); ?>"
<?php echo $checkbox->default ? 'data-origvalue="1"' : ''; ?>
<?php echo !empty($checkbox->select_all) ?
" data-targetclass='asp_cf_select_".esc_attr($field_name_nws)."' " :
" class='asp_cf_select_".esc_attr($field_name_nws)."' "; ?>
name="<?php echo !empty($checkbox->select_all) ? '' : "aspf[$field_name][$k]"; ?>"
<?php echo $checkbox->selected ? ' checked="checked"' : ''; ?>>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label"><?php echo esc_html($checkbox->label); ?></div>
</div>
<?php endforeach; ?>

View File

@@ -0,0 +1,15 @@
<?php foreach($filter->get() as $date): ?>
<textarea class="asp_datepicker_format" style="display:none !important;"><?php echo $filter->data['date_format']; ?></textarea>
<input type="text"
aria-label="<?php echo esc_html($filter->label); ?>"
class="asp_datepicker asp_datepicker_field"
placeholder="<?php echo esc_html($filter->data['placeholder']); ?>"
value="<?php echo esc_attr($date->value); ?>"
<?php echo 'data-origvalue="'.esc_attr($date->default).'"'; ?>
id="aspf<?php echo $fieldset_id; ?><?php echo $field_name; ?>_real"
name="aspf[<?php echo $field_name; ?>_real]">
<input type="hidden" class="asp_datepicker_hidden"
value=""
id="aspf<?php echo $fieldset_id; ?>[<?php echo $field_name; ?>]"
name="aspf[<?php echo $field_name; ?>]">
<?php endforeach; ?>

View File

@@ -0,0 +1,27 @@
<div class="asp_select_label asp_select_<?php echo $filter->data['multiple'] ? 'multiple' : 'single'; ?>">
<select class="asp_nochosen asp_noselect2"
aria-label="<?php echo esc_html($filter->label); ?>"
data-placeholder="<?php echo esc_attr($filter->data['placeholder']); ?>"
<?php echo $filter->data['multiple'] ? 'name="aspf['.$field_name.'][]" multiple' : 'name="aspf['.$field_name.']"'; ?>>
<?php $optgroup_open = false; ?>
<?php foreach($filter->get() as $dropdown): ?>
<?php if ( $dropdown->option_group ): ?>
<?php if ( $optgroup_open ): ?>
</optgroup><optgroup label="<?php echo esc_html( $dropdown->label ); ?>">
<?php $optgroup_open = false; ?>
<?php else: ?>
<optgroup label="<?php echo esc_html( $dropdown->label ); ?>">
<?php $optgroup_open = true; ?>
<?php endif; ?>
<?php else: ?>
<option value="<?php echo esc_attr( $dropdown->value ); ?>"
<?php echo $dropdown->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $dropdown->selected ? ' selected="selected"' : ''; ?>><?php echo esc_html( $dropdown->label ); ?></option>
<?php endif; ?>
<?php endforeach; ?>
<?php if ( $optgroup_open ): ?>
</optgroup>
<?php $optgroup_open = false; ?>
<?php endif; ?>
</select>
</div>

View File

@@ -0,0 +1,27 @@
<div class="asp_select_label asp_select_single">
<select class="asp_gochosen asp_goselect2"
aria-label="<?php echo esc_html($filter->label); ?>"
data-placeholder="<?php echo esc_attr($filter->data['placeholder']); ?>"
<?php echo 'name="aspf['.$field_name.']"'; ?>>
<?php $optgroup_open = false; ?>
<?php foreach($filter->get() as $dropdown): ?>
<?php if ( $dropdown->option_group ): ?>
<?php if ( $optgroup_open ): ?>
</optgroup><optgroup label="<?php echo esc_html( $dropdown->label ); ?>">
<?php $optgroup_open = false; ?>
<?php else: ?>
<optgroup label="<?php echo esc_html( $dropdown->label ); ?>">
<?php $optgroup_open = true; ?>
<?php endif; ?>
<?php else: ?>
<option value="<?php echo esc_attr( $dropdown->value ); ?>"
<?php echo $dropdown->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $dropdown->selected ? ' selected="selected"' : ''; ?>><?php echo esc_html( $dropdown->label ); ?></option>
<?php endif; ?>
<?php endforeach; ?>
<?php if ( $optgroup_open ): ?>
</optgroup>
<?php $optgroup_open = false; ?>
<?php endif; ?>
</select>
</div>

View File

@@ -0,0 +1,4 @@
<?php if ($filter->display_mode != 'hidden'): ?>
</div>
</fieldset>
<?php endif; ?>

View File

@@ -0,0 +1,7 @@
<?php if ($filter->display_mode != 'hidden'): ?>
<fieldset
data-asp_invalid_msg="<?php echo asp_icl_t("CF [".$filter->data['field']."] invalid input text" . " ($real_id)", $filter->data['invalid_input_text'], true); ?>"
class="asp_custom_f asp_filter_cf_<?php echo esc_attr($filter->data['field']); ?> asp_filter_id_<?php echo $filter->id; ?> asp_filter_n_<?php echo $filter->position; ?><?php echo $filter->data['required'] ? ' asp_required' : ''; ?>">
<legend><?php echo $filter->label; ?></legend>
<div class='<?php echo esc_attr($filter->data['field']); ?>_filter_box<?php echo in_array($filter->display_mode, array('checkboxes', 'radio')) ? ' asp_sett_scroll' : ''; ?>'>
<?php endif; ?>

View File

@@ -0,0 +1,6 @@
<?php foreach($filter->get() as $hidden): ?>
<input type="hidden"
value="<?php echo esc_attr($hidden->value); ?>"
<?php echo $hidden->default ? 'data-origvalue="'.esc_attr($hidden->value).'"' : ''; ?>
id="aspf<?php echo $fieldset_id; ?>[<?php echo $field_name; ?>]" name="aspf[<?php echo $field_name; ?>]">
<?php endforeach; ?>

View File

@@ -0,0 +1,28 @@
<div class="asp_select_label asp_select_multiple">
<select class="asp_gochosen asp_goselect2"
multiple
aria-label="<?php echo esc_html($filter->label); ?>"
data-placeholder="<?php echo esc_attr($filter->data['placeholder']); ?>"
<?php echo 'name="aspf['.$field_name.'][]"'; ?> >
<?php $optgroup_open = false; ?>
<?php foreach($filter->get() as $dropdown): ?>
<?php if ( $dropdown->option_group ): ?>
<?php if ( $optgroup_open ): ?>
</optgroup><optgroup label="<?php echo esc_html( $dropdown->label ); ?>">
<?php $optgroup_open = false; ?>
<?php else: ?>
<optgroup label="<?php echo esc_html( $dropdown->label ); ?>">
<?php $optgroup_open = true; ?>
<?php endif; ?>
<?php else: ?>
<option value="<?php echo esc_attr( $dropdown->value ); ?>"
<?php echo $dropdown->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $dropdown->selected ? ' selected="selected"' : ''; ?>><?php echo esc_html( $dropdown->label ); ?></option>
<?php endif; ?>
<?php endforeach; ?>
<?php if ( $optgroup_open ): ?>
</optgroup>
<?php $optgroup_open = false; ?>
<?php endif; ?>
</select>
</div>

View File

@@ -0,0 +1,22 @@
<?php foreach($filter->get() as $range): ?>
<div class="asp-nr-container">
<input type="text" class="asp-number-range"
data-asp-type="number"
data-asp-tsep="<?php echo esc_attr($filter->data['range_t_separator']); ?>"
data-asp-min="<?php echo esc_attr($filter->data['range_from']); ?>"
data-asp-max="<?php echo esc_attr($filter->data['range_to']); ?>"
id="number-range-low-<?php echo $fieldset_id; ?>"
aria-label="<?php echo esc_attr($filter->data['placeholder1']); ?>"
placeholder="<?php echo esc_attr($filter->data['placeholder1']); ?>"
name="aspf[<?php echo $field_name; ?>][lower]" value="<?php echo $range->value[0]; ?>">
<input type="text" class="asp-number-range"
data-asp-type="number"
data-asp-tsep="<?php echo esc_attr($filter->data['range_t_separator']); ?>"
data-asp-min="<?php echo esc_attr($filter->data['range_from']); ?>"
data-asp-max="<?php echo esc_attr($filter->data['range_to']); ?>"
id="number-range-high-<?php echo $fieldset_id; ?>"
aria-label="<?php echo esc_attr($filter->data['placeholder2']); ?>"
placeholder="<?php echo esc_attr($filter->data['placeholder2']); ?>"
name="aspf[<?php echo $field_name; ?>][upper]" value="<?php echo $range->value[1]; ?>">
</div>
<?php endforeach; ?>

View File

@@ -0,0 +1,9 @@
<?php foreach($filter->get() as $radio): ?>
<label class="asp_label">
<input type="radio" class="asp_radio" name="aspf[<?php echo $field_name; ?>]"
<?php echo $radio->default ? 'data-origvalue="1"' : ''; ?>
value="<?php echo esc_attr($radio->value); ?>"
<?php echo $radio->selected ? "checked='checked'" : ""; ?>/>
<?php echo esc_html($radio->label); ?>
</label><br>
<?php endforeach; ?>

View File

@@ -0,0 +1,69 @@
<?php foreach($filter->get() as $range): ?>
<div id="range-handles-<?php echo $fieldset_id; ?>"></div>
<div class="asp_noui_lu">
<span class="asp_noui_l_pre"><?php echo $filter->data['range_prefix']; ?></span>
<span class="slider-handles-low" id="slider-handles-low-<?php echo $fieldset_id; ?>"></span>
<span class="asp_noui_l_suff"><?php echo $filter->data['range_suffix']; ?></span>
<span class="asp_noui_u_suff"><?php echo $filter->data['range_suffix']; ?></span>
<span class="slider-handles-up" id="slider-handles-up-<?php echo $fieldset_id; ?>"></span>
<span class="asp_noui_u_pre"><?php echo $filter->data['range_prefix']; ?></span>
<div class="clear"></div>
</div>
<input type="hidden" class="asp_slider_hidden"
id="slider-values-low-<?php echo $fieldset_id; ?>"
name="aspf[<?php echo $field_name; ?>][lower]" value="<?php echo $range->value[0]; ?>">
<input type="hidden" class="asp_slider_hidden"
id="slider-values-up-<?php echo $fieldset_id; ?>"
name="aspf[<?php echo $field_name; ?>][upper]" value="<?php echo $range->value[1]; ?>">
<?php ob_start(); ?>
{
"node": "#range-handles-<?php echo $fieldset_id; ?>",
"main": {
"start": [ <?php echo $range->value[0]; ?>, <?php echo $range->value[1]; ?> ],
"step": <?php echo $filter->data['range_step']; ?>,
"range": {
"min": [ <?php echo $filter->data['range_from']; ?> ],
"max": [ <?php echo $filter->data['range_to']; ?> ]
}
},
"links": [
{
"handle": "lower",
"target": "#slider-handles-low-<?php echo $fieldset_id; ?>",
"wNumb": {
"decimals": <?php echo $filter->data['range_decimals']; ?>,
"thousand": "<?php echo $filter->data['range_t_separator']; ?>"
}
},
{
"handle": "upper",
"target": "#slider-handles-up-<?php echo $fieldset_id; ?>",
"wNumb": {
"decimals": <?php echo $filter->data['range_decimals']; ?>,
"thousand": "<?php echo $filter->data['range_t_separator']; ?>"
}
},
{
"handle": "lower",
"target": "#slider-values-low-<?php echo $fieldset_id; ?>",
"wNumb": {
"decimals": <?php echo $filter->data['range_decimals']; ?>,
"thousand": "<?php echo $filter->data['range_t_separator']; ?>"
}
},
{
"handle": "upper",
"target": "#slider-values-up-<?php echo $fieldset_id; ?>",
"wNumb": {
"decimals": <?php echo $filter->data['range_decimals']; ?>,
"thousand": "<?php echo $filter->data['range_t_separator']; ?>"
}
}
]
}
<?php $_asp_noui_out = ob_get_clean(); ?>
<div id="noui-slider-json<?php echo $fieldset_id; ?>" class="noui-slider-json noui-slider-json<?php echo $id; ?>" data-aspnoui="<?php echo base64_encode($_asp_noui_out); ?>" style="display: none !important;"></div>
<?php endforeach; ?>

View File

@@ -0,0 +1,44 @@
<?php foreach($filter->get() as $slider): ?>
<div id="slider-handles-<?php echo $fieldset_id; ?>"></div>
<div class="asp_noui_lu">
<span class="asp_noui_l_pre"><?php echo $filter->data['slider_prefix']; ?></span>
<span class="slider-handles-low" id="slider-handles-low-<?php echo $fieldset_id; ?>"></span>
<span class="asp_noui_l_suff"><?php echo $filter->data['slider_suffix']; ?></span>
<div class="clear"></div>
</div>
<input type="hidden" class="asp_slider_hidden" id="slider-values-low-<?php echo $fieldset_id; ?>" name="aspf[<?php echo $field_name; ?>]" value="<?php echo $slider->value; ?>">
<?php ob_start(); ?>
{
"node": "#slider-handles-<?php echo $fieldset_id; ?>",
"main": {
"start": [ <?php echo $slider->value; ?> ],
"step": <?php echo $filter->data['slider_step']; ?>,
"range": {
"min": [ <?php echo $filter->data['slider_from']; ?> ],
"max": [ <?php echo $filter->data['slider_to']; ?> ]
}
},
"links": [
{
"handle": "lower",
"target": "#slider-handles-low-<?php echo $fieldset_id; ?>",
"wNumb": {
"decimals": <?php echo $filter->data['slider_decimals']; ?>,
"thousand": "<?php echo $filter->data['slider_t_separator']; ?>"
}
},
{
"handle": "lower",
"target": "#slider-values-low-<?php echo $fieldset_id; ?>",
"wNumb": {
"decimals": <?php echo $filter->data['slider_decimals']; ?>,
"thousand": "<?php echo $filter->data['slider_t_separator']; ?>"
}
}
]
}
<?php $_asp_noui_out = ob_get_clean(); ?>
<div id="noui-slider-json<?php echo $fieldset_id; ?>" class="noui-slider-json noui-slider-json<?php echo $id; ?>" data-aspnoui="<?php echo base64_encode($_asp_noui_out); ?>" style="display: none !important;"></div>
<?php endforeach; ?>

View File

@@ -0,0 +1,7 @@
<?php foreach($filter->get() as $text): ?>
<input type="text"
aria-label="<?php echo esc_html($text->label); ?>"
value="<?php echo esc_attr($text->value); ?>"
<?php echo $text->default ? 'data-origvalue="'.esc_attr($text->default).'"' : ''; ?>
id="aspf<?php echo $fieldset_id; ?>[<?php echo $field_name; ?>]" name="aspf[<?php echo $field_name; ?>]">
<?php endforeach; ?>

View File

@@ -0,0 +1,19 @@
<?php foreach($filter->get() as $date): ?>
<div class="asp_<?php echo esc_attr($date->name); ?>">
<?php if ( $date->label != "" ): ?>
<legend><?php echo esc_html($date->label); ?></legend>
<?php endif; ?>
<textarea class="asp_datepicker_format"
aria-hidden="true"
aria-label="<?php echo esc_attr($date->label); ?>"
style="display:none !important;"><?php echo esc_html($date->format); ?></textarea>
<input type="text"
aria-label="<?php echo esc_attr($date->label); ?>"
placeholder="<?php echo esc_attr($date->placeholder); ?>"
class="asp_datepicker"
name="<?php echo esc_attr($date->name); ?>_real"
data-origvalue="<?php echo esc_attr($date->default); ?>"
value="<?php echo esc_attr($date->value); ?>">
<input type="hidden" class="asp_datepicker_hidden" name="<?php echo esc_attr($date->name); ?>" value="">
</div>
<?php endforeach; ?>

View File

@@ -0,0 +1 @@
</fieldset>

View File

@@ -0,0 +1,3 @@
<fieldset
data-asp_invalid_msg="<?php echo asp_icl_t("Date filter invalid input text" . " ($real_id)", $filter->data['invalid_input_text'], true); ?>"
class="asp_filter_date<?php echo $filter->data['required'] ? ' asp_required' : ''; ?>">

View File

@@ -0,0 +1,17 @@
<?php foreach ( $filter->get() as $fe_field ): ?>
<div class="asp_option asp_option_generic asp_option_generic_<?php echo esc_attr($fe_field->value); ?>"
role="checkbox"
aria-checked="<?php echo $fe_field->selected ? 'true' : 'false'; ?>"
tabindex="0">
<div class="asp_option_inner">
<input type="checkbox" value="<?php echo esc_attr($fe_field->value); ?>" id="set_<?php echo esc_attr($fe_field->value).$id; ?>"
<?php echo $fe_field->default ? 'data-origvalue="1"' : ''; ?>
aria-label="<?php echo esc_attr($fe_field->label); ?>"
name="asp_gen[]" <?php echo $fe_field->selected ? ' checked="checked"' : ''; ?>/>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label">
<?php echo esc_html($fe_field->label); ?>
</div>
</div>
<?php endforeach; ?>

View File

@@ -0,0 +1,13 @@
<div class='asp_select_label asp_select_single'>
<select
aria-label="<?php echo esc_html($filter->label); ?>"
name="asp_gen[]">
<?php foreach ( $filter->get() as $fe_field ): ?>
<option value="<?php echo esc_attr($fe_field->value); ?>" class="asp_option"
<?php echo $fe_field->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $fe_field->selected ? "selected='selected'" : ""; ?>>
<?php echo esc_attr($fe_field->label); ?>
</option>
<?php endforeach; ?>
</select>
</div>

View File

@@ -0,0 +1,4 @@
<fieldset class="asp_filter_generic asp_filter_id_<?php echo $filter->id; ?> asp_filter_n_<?php echo $filter->position; ?><?php echo ($filter->data['visible']) ? "" : " hiddend"; ?>">
<?php if ($filter->label != ''): ?>
<legend><?php echo asp_icl_t("Generic filter label", $filter->label, true); ?></legend>
<?php endif; ?>

View File

@@ -0,0 +1,10 @@
<div>
<?php foreach ( $filter->get() as $fe_field ): ?>
<label class="asp_label">
<input type="radio" class="asp_radio" name="asp_gen[]"
<?php echo $fe_field->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $fe_field->selected ? "checked='checked'" : ""; ?> value="<?php echo esc_attr($fe_field->value); ?>">
<?php echo esc_html($fe_field->label); ?>
</label><br>
<?php endforeach; ?>
</div>

View File

@@ -0,0 +1,35 @@
<?php foreach ( $filter->get() as $ck => $cpt_field ): ?>
<?php if ( $cpt_field->value == -1 ): ?>
<div class="asp_option asp_option_cat asp_option_selectall"
role="checkbox"
aria-checked="true"
tabindex="0">
<div class="asp_option_inner">
<input type="checkbox" id="<?php echo $id; ?>customset_selectall"
aria-label="<?php echo esc_attr($cpt_field->label); ?>"
data-targetclass="asp_post_type_checkbox" checked="checked"/>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label">
<?php echo esc_attr($cpt_field->label); ?>
</div>
</div>
<?php else: ?>
<div class="asp_option asp_option_post_type asp_option_post_type_<?php echo esc_attr($cpt_field->value); ?>"
role="checkbox"
aria-checked="<?php echo $cpt_field->selected ? 'true' : 'false'; ?>"
tabindex="0">
<div class="asp_option_inner">
<input type="checkbox" value="<?php echo esc_attr($cpt_field->value); ?>" id="<?php echo $id; ?>customset_<?php echo $id . $ck; ?>"
aria-label="<?php echo esc_attr($cpt_field->label); ?>"
class="asp_post_type_checkbox"
<?php echo $cpt_field->default ? 'data-origvalue="1"' : ''; ?>
name="customset[]" <?php echo $cpt_field->selected ? 'checked="checked"' : ''; ?>/>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label">
<?php echo esc_attr($cpt_field->label); ?>
</div>
</div>
<?php endif; ?>
<?php endforeach; ?>

View File

@@ -0,0 +1,11 @@
<div class="asp_select_label asp_select_single">
<select name="customset[]" aria-label="<?php echo esc_attr($filter->label); ?>">
<?php foreach ( $filter->get() as $ck => $cpt_field ): ?>
<option
<?php echo $cpt_field->default ? 'data-origvalue="1"' : ''; ?>
value="<?php echo esc_attr($cpt_field->value); ?>" <?php echo $cpt_field->selected ? 'selected="selected"' : ''; ?>>
<?php echo esc_attr($cpt_field->label); ?>
</option>
<?php endforeach; ?>
</select>
</div>

View File

@@ -0,0 +1,6 @@
<fieldset
data-asp_invalid_msg="<?php echo asp_icl_t("Post type filter invalid input text" . " ($real_id)", $filter->data['invalid_input_text'], true); ?>"
class="asp_filter_cpt asp_sett_scroll<?php echo !$filter->isEmpty() ? '' : ' hiddend'; ?><?php echo $filter->display_mode == 'checkboxes' ? ' asp_checkboxes_filter_box' : ''; ?><?php echo $filter->data['required'] ? ' asp_required' : ''; ?>">
<?php if ($filter->label != ''): ?>
<legend><?php echo esc_html($filter->label); ?></legend>
<?php endif; ?>

View File

@@ -0,0 +1,11 @@
<?php foreach ( $filter->get() as $ck => $cpt_field ): ?>
<label class="asp_label">
<input name="customset[]"
type="radio"
class="asp_radio"
<?php echo $cpt_field->default ? 'data-origvalue="1"' : ''; ?>
value="<?php echo esc_attr($cpt_field->value); ?>"
<?php echo $cpt_field->selected ? 'checked="checked"' : ''; ?>>
<?php echo esc_attr($cpt_field->label); ?>
</label>
<?php endforeach; ?>

View File

@@ -0,0 +1,42 @@
<?php foreach ($filter->get() as $kk => $term): ?>
<?php if ($term->id == 0): ?>
<div class="asp_option_cat asp_option asp_option asp_option_cat_level-0 asp_option_selectall"
role="checkbox"
aria-checked="<?php echo $term->selected ? 'true' : 'false'; ?>"
tabindex="0">
<div class="asp_option_inner">
<input id="asp_<?php echo $ch_class; ?>_all<?php echo $id; ?>"
aria-label="<?php echo asp_icl_t("Select all text [" . $taxonomy . "]" . " ($real_id)", $term->label, true); ?>"
type="checkbox" data-targetclass="asp_<?php echo $ch_class; ?>_checkbox"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php echo($term->selected ? 'checked="checked"' : ''); ?>/>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label"><?php echo asp_icl_t("Select all text [" . $taxonomy . "]" . " ($real_id)", $term->label); ?></div>
</div>
<div class="asp_select_spacer"></div>
<?php else: ?>
<div class="asp_option_cat asp_option asp_option asp_option_cat_level-<?php echo $term->level; ?>"
data-lvl="<?php echo $term->level; ?>"
role="checkbox"
aria-checked="<?php echo $term->selected ? 'true' : 'false'; ?>"
asp_cat_parent="<?php echo $term->parent; ?>" tabindex="0">
<div class="asp_option_inner">
<input type="checkbox" value="<?php echo $term->id; ?>" class="asp_<?php echo $ch_class; ?>_checkbox"
aria-label="<?php echo esc_html($term->label); ?>"
<?php if (isset($filter->data['custom_name'])): ?>
name="<?php echo $filter->data['custom_name']; ?>"
<?php else: ?>
name="<?php echo "termset[" . $term->taxonomy . "]"; ?>[]"
<?php endif; ?>
id="<?php echo $id; ?>termset_<?php echo $term->id; ?>"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php echo($term->selected ? 'checked="checked"' : ''); ?>/>
<div class="asp_option_checkbox"></div>
</div>
<div class="asp_option_label">
<?php echo $term->label; ?>
</div>
</div>
<?php endif; ?>
<?php endforeach; ?>

View File

@@ -0,0 +1,27 @@
<div class='asp_select_label asp_select_single'>
<select aria-label="<?php echo asp_icl_t('Taxonomy select [' . $taxonomy . "] ($real_id)", 'Taxonomy select for ' . $taxonomy, true) ?>"
class='asp_nochosen asp_noselect2'
<?php if (isset($filter->data['custom_name'])): ?>
name="<?php echo $filter->data['custom_name']; ?>"
<?php else: ?>
name="<?php echo $filter->isMixed() ? "termset_single" : "termset[".$taxonomy."][]"; ?>"
<?php endif; ?>>
<?php foreach ( $filter->get() as $kk => $term ): ?>
<?php if ( $term->id <= 0 ): ?>
<option value="-1" class="asp_option_cat asp_option_cat_level-0"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $term->selected ? "selected='selected'" : ""; ?>>
<?php echo asp_icl_t("Chose one option [".$taxonomy."]" . " ($real_id)", $term->label); ?>
</option>
<?php else: ?>
<option class="asp_option_cat asp_option_cat_level-<?php echo $term->level; ?>"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
asp_cat_parent="<?php echo $term->parent; ?>"
value="<?php echo $term->id; ?>"
<?php echo $term->selected ? "selected='selected'" : ""; ?>>
<?php echo str_repeat("&nbsp;&nbsp;", $term->level) . $term->label; ?>
</option>
<?php endif; ?>
<?php endforeach; ?>
</select>
</div>

View File

@@ -0,0 +1,27 @@
<div class='asp_select_label asp_select_single'>
<select aria-label="<?php echo asp_icl_t('Taxonomy select [' . $taxonomy . "] ($real_id)", 'Taxonomy select for ' . $taxonomy, true) ?>"
class='asp_gochosen asp_goselect2'
<?php if (isset($filter->data['custom_name'])): ?>
name="<?php echo $filter->data['custom_name']; ?>"
<?php else: ?>
name="<?php echo $filter->isMixed() ? "termset_single" : "termset[".$taxonomy."][]"; ?>"
<?php endif; ?>>
<?php foreach ( $filter->get() as $kk => $term ): ?>
<?php if ( $term->id <= 0 ): ?>
<option value="-1" class="asp_option_cat asp_option_cat_level-0"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $term->selected ? "selected='selected'" : ""; ?>>
<?php echo asp_icl_t("Chose one option [".$taxonomy."]" . " ($real_id)", $term->label); ?>
</option>
<?php else: ?>
<option class="asp_option_cat asp_option_cat_level-<?php echo $term->level; ?>"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
asp_cat_parent="<?php echo $term->parent; ?>"
value="<?php echo $term->id; ?>"
<?php echo $term->selected ? "selected='selected'" : ""; ?>>
<?php echo str_repeat("&nbsp;&nbsp;", $term->level) . $term->label; ?>
</option>
<?php endif; ?>
<?php endforeach; ?>
</select>
</div>

View File

@@ -0,0 +1,2 @@
</div>
</fieldset>

View File

@@ -0,0 +1,9 @@
<?php if ( $filter->isMixed() ): ?>
<fieldset data-asp_invalid_msg="<?php echo asp_icl_t("Taxonomy [".$taxonomy."] invalid input text" . " ($real_id)", $filter->data['invalid_input_text'], true); ?>"
class="asp_filter_tax asp_filter_tax_mixed asp_cat_filter_field<?php echo $filter->display_mode == 'checkboxes' ? ' asp_checkboxes_filter_box' : ''; ?> asp_filter_id_<?php echo $filter->id; ?> asp_filter_n_<?php echo $filter->position; ?><?php echo $filter->data['required'] ? ' asp_required' : ''; ?>">
<?php else: ?>
<fieldset data-asp_invalid_msg="<?php echo asp_icl_t("Taxonomy [".$taxonomy."] invalid input text" . " ($real_id)", $filter->data['invalid_input_text'], true); ?>"
class="asp_filter_tax asp_filter_tax_<?php echo esc_attr($filter->data['taxonomy']); ?> asp_<?php echo $filter->display_mode; ?>_filter_box asp_filter_id_<?php echo $filter->id; ?> asp_filter_n_<?php echo $filter->position; ?><?php echo $filter->data['required'] ? ' asp_required' : ''; ?>">
<?php endif; ?>
<legend><?php echo asp_icl_t("Taxonomy [".$taxonomy."] filter box text" . " ($real_id)", $filter->label); ?></legend>
<div class='<?php echo $taxonomy; ?>_filter_box categoryfilter<?php echo $filter->display_mode != 'checkboxes' ? '' : ' asp_sett_scroll'; ?>'>

View File

@@ -0,0 +1,30 @@
<div class='asp_select_label asp_select_multiple'>
<select aria-label="<?php echo asp_icl_t('Taxonomy select [' . $taxonomy . "] ($real_id)", 'Taxonomy select for ' . $taxonomy, true) ?>"
class='asp_gochosen asp_goselect2'
multiple
data-placeholder="<?php echo !empty($filter->data['placeholder']) ?
asp_icl_t("Multiselect placeholder [".$taxonomy."]" . " ($real_id)", $filter->data['placeholder']) : ''; ?>"
<?php if (isset($filter->data['custom_name'])): ?>
name="<?php echo $filter->data['custom_name']; ?>"
<?php else: ?>
name="<?php echo $filter->isMixed() ? "termset_single" : "termset[".$taxonomy."][]"; ?>"
<?php endif; ?>>
<?php foreach ( $filter->get() as $kk => $term ): ?>
<?php if ( $term->id <= 0 ): ?>
<option value="-1" class="asp_option_cat asp_option_cat_level-0"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $term->selected ? "selected='selected'" : ""; ?>>
<?php echo asp_icl_t("Chose one option [".$taxonomy."]" . " ($real_id)", $term->label); ?>
</option>
<?php else: ?>
<option class="asp_option_cat asp_option_cat_level-<?php echo $term->level; ?>"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
asp_cat_parent="<?php echo $term->parent; ?>"
value="<?php echo $term->id; ?>"
<?php echo $term->selected ? "selected='selected'" : ""; ?>>
<?php echo str_repeat("&nbsp;&nbsp;", $term->level) . $term->label; ?>
</option>
<?php endif; ?>
<?php endforeach; ?>
</select>
</div>

View File

@@ -0,0 +1,30 @@
<div class='term_filter_box asp_sett_scroll'>
<?php foreach ($filter->get() as $kk => $term): ?>
<?php if ($term->id <= 0): ?>
<label class="asp_label">
<input type="radio" class="asp_radio"
<?php if (isset($filter->data['custom_name'])): ?>
name="<?php echo $filter->data['custom_name']; ?>"
<?php else: ?>
name="<?php echo $filter->isMixed() ? "termset_single" : "termset[" . $taxonomy . "][]"; ?>"
<?php endif; ?>
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php echo $term->selected ? "checked='checked'" : ""; ?> value="-1">
<?php echo asp_icl_t("Chose one option [" . $taxonomy . "]" . " ($real_id)", $term->label); ?>
</label><br>
<?php else: ?>
<label class="asp_label">
<input type="radio" class="asp_radio"
value="<?php echo $term->id; ?>"
<?php echo $term->default ? 'data-origvalue="1"' : ''; ?>
<?php if (isset($filter->data['custom_name'])): ?>
name="<?php echo $filter->data['custom_name']; ?>"
<?php else: ?>
name="<?php echo $filter->isMixed() ? "termset_single" : "termset[" . $taxonomy . "][]"; ?>"
<?php endif; ?>
<?php echo $term->selected ? ' checked="checked"' : ''; ?>>
<?php echo $term->label; ?>
</label><br>
<?php endif; ?>
<?php endforeach; ?>
</div>

View File

@@ -0,0 +1,42 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for the keyword suggestions
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/no-results.php
*
* The keyword should must always hold the 'asp_keyword' class and only
* contain the keyword text as the content.
*
* You can use any WordPress function here.
* Variables to mention:
* Array[] $s_keywords - array of the keywords
* Array[] $s_options - holding the search options
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.18
*/
?>
<div class="elementor-posts-nothing-found asp_elementor_nores">
<?php
echo wp_kses_post(
stripslashes(
\WPDRMS\ASP\Utils\Str::resolveBracketSyntax(
asp_icl_t(
'No results text' . " ($id)",
$s_options['noresultstext']
),
array( 'phrase' => $phrase )
)
)
);
?>
</div>

View File

@@ -0,0 +1,25 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is printed as the group footer - only works with vertical results
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/group-footer.php
*
* You can use any WordPress function here.
* Variables to mention:
* String $group_name - the group name (including post count)
* Array[] $s_options - holding the search options
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
</div>

View File

@@ -0,0 +1,32 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is printed as the group header - only works with vertical results
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/group-header.php
*
* You can use any WordPress function here.
* Variables to mention:
* String $group_name - the group name (including post count)
* Array[] $s_options - holding the search options
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<div class="asp_results_group <?php echo esc_attr($group_class); ?>">
<?php if ($group_url): ?>
<div class="asp_group_header">
<a href="<?php echo $group_url;?>"><?php echo wp_kses_post($group_name); ?></a>
</div>
<?php else: ?>
<div class="asp_group_header"><?php echo wp_kses_post($group_name); ?></div>
<?php endif; ?>

View File

@@ -0,0 +1,81 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for one horizontal result
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/horizontal.php
*
* It's also a good idea to use the actions to insert content instead of modifications.
*
* You can use any WordPress function here.
* Variables to mention:
* Object() $r - holding the result details
* Array[] $s_options - holding the search options
*
* DO NOT OUTPUT ANYTHING BEFORE OR AFTER THE <div class='item'>..</div> element
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<div id="asp-res-<?php echo esc_attr($r->id); ?>"
class='item<?php echo esc_attr(apply_filters('asp_result_css_class', $asp_res_css_class, $r->id, $r)); ?>'>
<?php do_action('asp_res_horizontal_begin_item'); ?>
<?php if (!empty($r->image)): ?>
<a class='asp_res_image_url' href='<?php echo esc_attr($r->link); ?>'<?php echo ($s_options['results_click_blank'])?" target='_blank'":""; ?>>
<div class='asp_image<?php echo $s_options['image_display_mode'] == "contain" ? " asp_image_auto" : ""; ?>'>
<img loading="lazy" alt="<?php echo esc_attr($r->title); ?>" src="<?php echo esc_attr($r->image); ?>" />
<div class="void"></div>
</div>
</a>
<?php endif; ?>
<?php do_action('asp_res_horizontal_after_image'); ?>
<div class='asp_content'>
<h3><a class="asp_res_url" href='<?php echo esc_attr($r->link); ?>'<?php echo ($s_options['results_click_blank'])?" target='_blank'":""; ?>><?php echo wp_kses_post($r->title); ?>
<?php if ($s_options['resultareaclickable'] == 1): ?>
<span class='overlap'></span>
<?php endif; ?>
</a></h3>
<div class='etc'>
<?php if ($s_options['showauthor'] == 1): ?>
<span class='asp_author'><?php echo esc_html($r->author); ?></span>
<?php endif; ?>
<?php if ($s_options['showdate'] == 1): ?>
<span class='asp_date'><?php echo esc_html($r->date); ?></span>
<?php endif; ?>
</div>
<?php if ($show_description == 1): ?>
<?php if ( empty($r->image) || $s_options['hhidedesc'] == 0 ): ?>
<div class="asp_res_text">
<?php echo asp_kses_content($r->content); ?>
</div>
<?php endif; ?>
<?php endif; ?>
</div>
<?php do_action('asp_res_horizontal_after_content'); ?>
<div class='clear'></div>
<?php do_action('asp_res_horizontal_end_item'); ?>
</div>

View File

@@ -0,0 +1,80 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for one isotopic result
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/isotopic.php
*
* It's also a good idea to use the actions to insert content instead of modifications.
*
* You can use any WordPress function here.
* Variables to mention:
* Object() $r - holding the result details
* Array[] $s_options - holding the search options
*
* DO NOT OUTPUT ANYTHING BEFORE OR AFTER THE <div class='item'>..</div> element
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<div id="asp-res-<?php echo esc_attr($r->id); ?>"
class='item asp_isotopic_item<?php echo esc_attr(apply_filters('asp_result_css_class', $asp_res_css_class, $r->id, $r)); ?>'>
<?php do_action('asp_res_isotopic_begin_item'); ?>
<?php if ( !empty($r->image) ) : ?>
<div class='asp_image' data-src="<?php echo esc_attr($r->image); ?>">
<img loading="lazy" alt="<?php echo esc_attr($r->title); ?>" src="<?php echo esc_attr($r->image); ?>" />
</div>
<?php endif; ?>
<?php do_action('asp_res_isotopic_after_image'); ?>
<div class='asp_content<?php echo $s_options['i_hide_content'] ? ' asp_content_hide_on_overlay' : ''; ?>'>
<h3><a class="asp_res_url" href='<?php echo esc_attr($r->link); ?>'<?php echo ( $s_options['results_click_blank'] ) ?" target='_blank'" :''; ?>>
<?php echo wp_kses_post($r->title); ?>
<?php if ( $s_options['resultareaclickable'] == 1 ) : ?>
<span class='overlap'></span>
<?php endif; ?>
</a></h3>
<div class='etc'>
<?php if ( $s_options['showauthor'] == 1 ) : ?>
<span class='asp_author'><?php echo esc_html($r->author); ?></span>
<?php endif; ?>
<?php if ( $s_options['showdate'] == 1 ) : ?>
<span class='asp_date'><?php echo esc_html($r->date); ?></span>
<?php endif; ?>
</div>
<?php
if (
$show_description == 1 ||
( empty($r->image) && $s_options['i_ifnoimage'] == 'description' )
) :
?>
<p class='asp_res_text'><?php echo asp_kses_content($r->content); ?></p>
<?php endif; ?>
</div>
<?php do_action('asp_res_isotopic_after_content'); ?>
<div class='clear'></div>
<?php do_action('asp_res_isotopic_end_item'); ?>
</div>

View File

@@ -0,0 +1,57 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for the keyword suggestions
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/keyword-suggestions.php
*
* The keyword must always hold the 'asp_keyword' class and only
* contain the keyword text as the content.
*
* You can use any WordPress function here.
* Variables to mention:
* String $phrase - the search phrase
* Array[] $s_keywords - array of the keywords
* Array[] $s_options - holding the search options
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<div class="asp_nores">
<div class="asp_nores_header">
<?php
echo wp_kses_post(
stripslashes(
\WPDRMS\ASP\Utils\Str::resolveBracketSyntax(
asp_icl_t(
'No results text' . " ($id)",
$s_options['noresultstext']
),
array( 'phrase' => $phrase )
)
)
);
?>
</div>
<div class="asp_nores_kw_suggestions">
<?php
echo wp_kses_post(
stripslashes(
asp_icl_t('Did you mean? text' . " ($id)", $s_options['didyoumeantext'])
)
);
?>
<?php foreach ( $s_keywords as $keyword ) : ?>
<span class='asp_keyword'><?php echo wp_kses_post($keyword); ?></span>
<?php endforeach; ?>
</div>
</div>

View File

@@ -0,0 +1,44 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for the keyword suggestions
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/no-results.php
*
* The keyword should must always hold the 'asp_keyword' class and only
* contain the keyword text as the content.
*
* You can use any WordPress function here.
* Variables to mention:
* Array[] $s_keywords - array of the keywords
* Array[] $s_options - holding the search options
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<div class="asp_nores">
<span class="asp_nores_header">
<?php
echo wp_kses_post(
stripslashes(
\WPDRMS\ASP\Utils\Str::resolveBracketSyntax(
asp_icl_t(
'No results text' . " ($id)",
$s_options['noresultstext']
),
array( 'phrase' => $phrase )
)
)
);
?>
</span>
</div>

View File

@@ -0,0 +1,67 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for one polaroid result
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/polaroid.php
*
* It's also a good idea to use the actions to insert content instead of modifications.
*
* You can use any WordPress function here.
* Variables to mention:
* Object() $r - holding the result details
* Array[] $s_options - holding the search options
*
* DO NOT OUTPUT ANYTHING BEFORE OR AFTER THE <figure> element!!
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<figure id="asp-res-<?php echo esc_attr($r->id); ?>"
class='photostack-flip photostack-current<?php echo esc_attr(apply_filters('asp_result_css_class', $asp_res_css_class, $r->id, $r)); ?>'>
<?php if ( isset($r->image) ): ?>
<a class="asp_res_url" href='<?php echo $r->link; ?>'<?php echo ($s_options['results_click_blank'])?" target='_blank'":""; ?>>
<div class='asp_image' style='background-image: url("<?php echo $r->image; ?>");' data-src="<?php echo esc_attr($r->image); ?>"></div>
</a>
<?php elseif ($s_options['pifnoimage'] == 'descinstead'): ?>
<a class="asp_res_url" href='<?php echo esc_attr($r->link); ?>'<?php echo ($s_options['results_click_blank'])?" target='_blank'":""; ?>><?php echo asp_kses_content($r->content); ?></a>
<?php endif; ?>
<figcaption>
<h2 class='photostack-title'><a href='<?php echo esc_attr($r->link); ?>'<?php echo ($s_options['results_click_blank'])?" target='_blank'":""; ?>>
<?php echo wp_kses_post($r->title); ?>
<?php if ($s_options['resultareaclickable'] == 1): ?>
<span class='overlap'></span>
<?php endif; ?>
</a></h2>
<div class='etc'>
<?php if ($s_options['pshowsubtitle']): ?>
<?php if ($s_options['showauthor'] == 1): ?>
<span class='asp_author'><?php echo esc_html($r->author); ?></span>
<?php endif; ?>
<?php if ($s_options['showdate'] == 1): ?>
<span class='asp_date'><?php echo esc_html($r->date); ?></span>
<?php endif; ?>
<?php endif; ?>
</div>
<?php if ($s_options['pshowdesc'] && !empty($r->content)): ?>
<div class='photostack-back'><?php echo asp_kses_content($r->content); ?></div>
<?php endif; ?>
</figcaption>
</figure>

View File

@@ -0,0 +1,90 @@
<?php
/* Prevent direct access */
defined('ABSPATH') or die("You can't access this file directly.");
/**
* This is the default template for one vertical result
*
* !!!IMPORTANT!!!
* Do not make changes directly to this file! To have permanent changes copy this
* file to your theme directory under the "asp" folder like so:
* wp-content/themes/your-theme-name/asp/vertical.php
*
* It's also a good idea to use the actions to insert content instead of modifications.
*
* WARNING: Modifying anything in this file might result in search malfunctioning,
* so be careful and use your test environment.
*
* You can use any WordPress function here.
* Variables to mention:
* Object() $r - holding the result details
* Array[] $s_options - holding the search options
*
* I DO NOT RECOMMEND PUTTING ANYTHING BEFORE OR AFTER THE
* <div class='item'>..</div><div class="asp_spacer"></div> structure
*
* You can leave empty lines for better visibility, they are cleared before output.
*
* MORE INFO: https://knowledgebase.ajaxsearchpro.com/hooks/templating/result-templating
*
* @since: 4.0
*/
?>
<div id="asp-res-<?php echo esc_attr($r->id); ?>"
class='item<?php echo esc_attr(apply_filters('asp_result_css_class', $asp_res_css_class, $r->id, $r)); ?>'>
<?php do_action('asp_res_vertical_begin_item'); ?>
<div class='asp_content'>
<?php if ( !empty($r->image) ) : ?>
<?php do_action('asp_res_vertical_before_image'); ?>
<a class='asp_res_image_url' href='<?php echo esc_attr($r->link); ?>'<?php echo ( $s_options['results_click_blank'] ) ?" target='_blank'" :''; ?>>
<div class='asp_image' data-src="<?php echo esc_attr($r->image); ?>">
<img loading="lazy" alt="<?php echo esc_attr($r->title); ?>" src="<?php echo esc_attr($r->image); ?>" />
<div class="void"></div>
</div>
</a>
<?php do_action('asp_res_vertical_after_image'); ?>
<?php endif; ?>
<h3><a class="asp_res_url" href='<?php echo esc_attr($r->link); ?>'<?php echo ( $s_options['results_click_blank'] ) ?" target='_blank'" :''; ?>>
<?php echo wp_kses_post($r->title); ?>
<?php if ( $s_options['resultareaclickable'] == 1 ) : ?>
<span class='overlap'></span>
<?php endif; ?>
</a></h3>
<div class='etc'>
<?php if ( $s_options['showauthor'] == 1 && !empty($r->author) ) : ?>
<span class='asp_author'><?php echo esc_html($r->author); ?></span>
<?php endif; ?>
<?php if ( $s_options['showdate'] == 1 && !empty($r->date) ) : ?>
<span class='asp_date'><?php echo esc_html($r->date); ?></span>
<?php endif; ?>
</div>
<?php if ( $show_description == 1 ) : ?>
<div class="asp_res_text">
<?php echo asp_kses_content($r->content); ?>
</div>
<?php endif; ?>
</div>
<?php do_action('asp_res_vertical_after_content'); ?>
<div class='clear'></div>
<?php do_action('asp_res_vertical_end_item'); ?>
</div>