name]) && !empty($_POST['sf_' . $post_type->name])) { $AjaxyLiveSearch->set_templates($post_type->name, $_POST['sf_' . $post_type->name]); } $values = array( 'title' => sanitize_text_field($_POST['sf_title_' . $post_type->name]), 'show' => sanitize_text_field($_POST['sf_show_' . $post_type->name] ?? 0), 'search_content' => sanitize_text_field($_POST['sf_search_content_' . $post_type->name] ?? ''), 'limit' => sanitize_text_field($_POST['sf_limit_' . $post_type->name] ?? ''), 'order' => sanitize_text_field($_POST['sf_order_' . $post_type->name] ?? ''), 'excludes' => array_map('sanitize_text_field', $_POST['sf_exclude_' . $post_type->name] ?? []), ); if (isset($_POST['sf_order_results_' . $post_type->name]) && !empty($_POST['sf_order_results_' . $post_type->name])) { $values['order_results'] = sanitize_text_field(trim($_POST['sf_order_results_' . $post_type->name])); } if (isset($_POST['sf_ushow_' . $post_type->name]) && !empty($_POST['sf_ushow_' . $post_type->name])) { $values['ushow'] = sanitize_text_field(trim($_POST['sf_ushow_' . $post_type->name])); } $AjaxyLiveSearch->set_setting($post_type->name, $values); $message = esc_html__("Settings saved", "ajaxy-instant-search"); } else { $message = esc_html__("Settings have been already saved", "ajaxy-instant-search"); } } $setting = (array)$AjaxyLiveSearch->get_setting($post_type->name); $allowed_tags = array('id', 'post_title', 'post_author', 'post_date', 'post_date_formatted', 'post_content', 'post_excerpt', 'post_image', 'post_image_html', 'post_link', 'custom_field_(YOUR_CUSTOM_FIELD_NAME)'); /* translators: %s is replaced with the post type labe */ $title = esc_html(sprintf(__('Edit %s template & settings', "ajaxy-instant-search"), $post_type->label)); $notice = ''; ?>

">

" tabindex="5" accesskey="p">
0 ? $setting['excludes'] : array()); ?>
">

label)); ?>

label)) . ' post_types="' . esc_attr($post_type->name) . '" name="sf_exclude_' . esc_attr($post_type->name) . '" show_category="0" value="{ID}"]'); ?>

$post_type->name, 'post__in' => (array)$excludes)); if (sizeof($posts) > 0) { ?>
  • ID, (array)$excludes), true); ?> value="ID); ?>" /> post_title); ?>
label)); } ?>

label)); ?>

label)); ?>

get_templates($post_type->name, $type), 'sf_' . $post_type->name); ?>
{} name, Ajaxy\LiveSearch\SF::$woocommerce_post_types)) { $wootags = array('price_html', 'add_to_cart_button', 'sale_price', 'regular_price', 'price', 'price_including_tax', 'price_excluding_tax', 'price_suffix', 'price_html', 'price_html_from_text', 'average_rating', 'rating_count', 'rating_html', 'dimensions', 'shipping_class', 'add_to_cart_text', 'single_add_to_cart_text', 'add_to_cart_url', 'title'); ?>

{}