Changeset 3438759
- Timestamp:
- 01/13/2026 03:51:46 PM (3 months ago)
- Location:
- searchcraft/trunk
- Files:
-
- 6 edited
-
admin/partials/searchcraft-admin-config-tab.php (modified) (2 diffs)
-
public/js/searchcraft-sdk-integration.js (modified) (1 diff)
-
public/templates/common-template-values.php (modified) (1 diff)
-
public/templates/search-header.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
searchcraft.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
searchcraft/trunk/admin/partials/searchcraft-admin-config-tab.php
r3429840 r3438759 229 229 $is_checked = in_array( $taxonomy_obj->name, $selected_taxonomies, true ); 230 230 ?> 231 <label style="display: block; margin-bottom: 8px;"> 232 <input 233 type="checkbox" 234 name="searchcraft_filter_taxonomies[]" 235 value="<?php echo esc_attr( $taxonomy_obj->name ); ?>" 236 <?php checked( $is_checked ); ?> 237 /> 238 <strong><?php echo esc_html( $taxonomy_obj->label ); ?></strong> 239 <?php if ( ! empty( $taxonomy_obj->description ) ) : ?> 240 - <?php echo esc_html( $taxonomy_obj->description ); ?> 241 <?php else : ?> 242 (<?php echo esc_html( $taxonomy_obj->name ); ?>) 243 <?php endif; ?> 244 </label> 231 <div style="margin-bottom: 8px;"> 232 <label style="display: inline-block; font-weight: 600; cursor: pointer;"> 233 <input 234 type="checkbox" 235 name="searchcraft_filter_taxonomies[]" 236 value="<?php echo esc_attr( $taxonomy_obj->name ); ?>" 237 style="margin-right: 4px;" 238 <?php checked( $is_checked ); ?> 239 /> 240 <?php echo esc_html( $taxonomy_obj->label ); ?> 241 <?php if ( ! empty( $taxonomy_obj->description ) ) : ?> 242 - <?php echo esc_html( $taxonomy_obj->description ); ?> 243 <?php else : ?> 244 (<?php echo esc_html( $taxonomy_obj->name ); ?>) 245 <?php endif; ?> 246 </label> 247 </div> 245 248 <?php endforeach; ?> 246 249 </fieldset> … … 264 267 <fieldset> 265 268 <legend class="screen-reader-text"><span>Select content types to include in search</span></legend> 266 <div style="margin-bottom: 12px; ">267 <label style="display: block; margin-bottom: 4px;">269 <div style="margin-bottom: 12px; position: relative; z-index: 1;"> 270 <label for="searchcraft_builtin_post_type_post" style="display: inline-block; margin-bottom: 4px; font-weight: 600; cursor: pointer;"> 268 271 <input 269 272 type="checkbox" 273 id="searchcraft_builtin_post_type_post" 270 274 name="searchcraft_builtin_post_types[]" 271 275 value="post" 276 style="margin-right: 4px;" 272 277 <?php checked( in_array( 'post', $selected_builtin_post_types, true ) ); ?> 273 278 /> 274 <strong>Posts</strong>279 Posts 275 280 </label> 276 281 </div> 277 <div style="margin-bottom: 12px; ">278 <label style="display: block; margin-bottom: 4px;">282 <div style="margin-bottom: 12px; position: relative; z-index: 1;"> 283 <label for="searchcraft_builtin_post_type_page" style="display: inline-block; margin-bottom: 4px; font-weight: 600; cursor: pointer;"> 279 284 <input 280 285 type="checkbox" 286 id="searchcraft_builtin_post_type_page" 281 287 name="searchcraft_builtin_post_types[]" 282 288 value="page" 289 style="margin-right: 4px;" 283 290 <?php checked( in_array( 'page', $selected_builtin_post_types, true ) ); ?> 284 291 /> 285 <strong>Pages</strong>292 Pages 286 293 </label> 287 294 </div> -
searchcraft/trunk/public/js/searchcraft-sdk-integration.js
r3429840 r3438759 179 179 const searchTerm = event?.data?.searchTerm; 180 180 if (searchTerm && searchTerm !== '*') { 181 const sanitizedQuery = encodeURIComponent(searchTerm);182 181 const url = new URL(window.location); 183 url.searchParams.set('s', s anitizedQuery);182 url.searchParams.set('s', searchTerm); 184 183 window.history.replaceState({}, '', url); 185 184 } -
searchcraft/trunk/public/templates/common-template-values.php
r3414637 r3438759 45 45 $search_query = get_search_query( true ); 46 46 if ( ! empty( $search_query ) ) { 47 $value_attr = ' value="' . $search_query. '"';47 $value_attr = ' value="' . esc_attr( $search_query ) . '"'; 48 48 } 49 49 } -
searchcraft/trunk/public/templates/search-header.php
r3429840 r3438759 471 471 <?php if ( 'stand_alone' === $search_behavior && ! is_search() ) : ?> 472 472 <div class="searchcraft-input-container searchcraft-input-form-inline-container"> 473 <form class="searchcraft-input-form searchcraft-input-form-inline" role="search" method="get" action="<?php echo site_url(); ?>">473 <form class="searchcraft-input-form searchcraft-input-form-inline" role="search" method="get" action="<?php echo site_url(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- site_url is safe ?>"> 474 474 <div class="searchcraft-input-form-grid searchcraft-input-form-grid-button-none searchcraft-input-form-grid-inline" style="gap: 0px 8px;"> 475 475 <div class="searchcraft-input-form-input-wrapper searchcraft-input-form-input-wrapper-inline"> … … 487 487 <?php else : ?> 488 488 <div class="searchcraft-input-container"> 489 <searchcraft-input-form <?php echo esc_attr( $value_attr );?> placeholder-value="<?php echo esc_attr( $search_placeholder ); ?>" auto-search></searchcraft-input-form>489 <searchcraft-input-form <?php echo $value_attr; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- escaped in common-template-values ?> placeholder-value="<?php echo esc_attr( $search_placeholder ); ?>" auto-search></searchcraft-input-form> 490 490 </div> 491 491 <?php endif; ?> -
searchcraft/trunk/readme.txt
r3429840 r3438759 5 5 Requires at least: 5.3 6 6 Tested up to: 6.9 7 Stable tag: 1.3. 07 Stable tag: 1.3.1 8 8 License: Apache 2.0 9 9 License URI: LICENSE.txt … … 69 69 70 70 == Changelog == 71 72 = 1.3.1 = 73 * Bugfix - Fixes issue where going back from clicking a search result to the results page inserted an encoded space instead of an actual space value into the input. 74 * Bugfix - Fixes issue where filter taxonomy was interfering with the default post type checkbox in admin configuration tab. 71 75 72 76 = 1.3.0 = -
searchcraft/trunk/searchcraft.php
r3429840 r3438759 11 11 * Plugin URI: https://github.com/searchcraft-inc/searchcraft-wordpress 12 12 * Description: Bring fast, relevant search to your site. Searchcraft replaces the default search with a customizable, tunable, highly relevant search experience. 13 * Version: 1.3. 013 * Version: 1.3.1 14 14 * Author: Searchcraft, Inc. 15 15 * Author URI: https://searchcraft.io/ … … 27 27 // Define plugin constants. 28 28 if ( ! defined( 'SEARCHCRAFT_VERSION' ) ) { 29 define( 'SEARCHCRAFT_VERSION', '1.3. 0' );29 define( 'SEARCHCRAFT_VERSION', '1.3.1' ); 30 30 } 31 31
Note: See TracChangeset
for help on using the changeset viewer.