Plugin Directory

Changeset 2730935


Ignore:
Timestamp:
05/25/2022 03:35:38 PM (4 years ago)
Author:
pavlo.opanasenko
Message:

Version 1.6.3

Location:
searchwp-live-ajax-search
Files:
12 edited
1 copied

Legend:

Unmodified
Added
Removed
  • searchwp-live-ajax-search/tags/1.6.3/includes/class-client.php

    r2683712 r2730935  
    143143            $results = new \SWP_Query( array(
    144144                's'              => $query,
    145                 'engine'         => isset( $_REQUEST['swpengine'] ) ? sanitize_text_field( $_REQUEST['swpengine'] ) : 'default',
     145                'engine'         => isset( $_REQUEST['swpengine'] ) ? sanitize_key( $_REQUEST['swpengine'] ) : 'default',
    146146                'fields'         => 'ids',
    147147                'posts_per_page' => $this->get_posts_per_page(),
     
    162162            add_filter( 'searchwp_load_posts', '__return_false' );
    163163
    164             $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_text_field( $_REQUEST['swpengine'] ) : 'default';
     164            $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_key( $_REQUEST['swpengine'] ) : 'default';
    165165
    166166            // Grab our post IDs.
     
    185185     *
    186186     * @uses query_posts() to prep the WordPress environment in it's entirety for the template loader
    187      * @uses sanitize_text_field() to sanitize input
     187     * @uses sanitize_key() to sanitize input
    188188     * @uses SearchWP_Live_Search_Template
    189189     * @uses SearchWP_Live_Search_Template::get_template_part() to load the proper results template
     
    205205
    206206        // Optionally pass along the SearchWP engine if applicable.
    207         $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_text_field( $_REQUEST['swpengine'] ) : '';
     207        $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_key( $_REQUEST['swpengine'] ) : '';
    208208
    209209        // Output the results using the results template.
  • searchwp-live-ajax-search/tags/1.6.3/includes/class-relevanssi-bridge.php

    r946225 r2730935  
    11<?php
     2
     3// exit if accessed directly
     4if ( ! defined( 'ABSPATH' ) ) {
     5    exit;
     6}
    27
    38// class written by https://wordpress.org/plugins/daves-wordpress-live-search/
  • searchwp-live-ajax-search/tags/1.6.3/includes/class-template.php

    r2140136 r2730935  
    22
    33// exit if accessed directly
    4 if ( ! defined( 'ABSPATH' ) ) exit;
     4if ( ! defined( 'ABSPATH' ) ) {
     5    exit;
     6}
    57
    68/**
  • searchwp-live-ajax-search/tags/1.6.3/includes/class-widget.php

    r2455620 r2730935  
    11<?php
     2
     3// exit if accessed directly
     4if ( ! defined( 'ABSPATH' ) ) {
     5    exit;
     6}
    27
    38/**
  • searchwp-live-ajax-search/tags/1.6.3/readme.txt

    r2683712 r2730935  
    7777== Changelog ==
    7878
     79= 1.6.3 =
     80* Improves sanitization of the 'swpengine' search field argument.
     81* Standardizes direct access restrictions in classes throughout the plugin.
     82
    7983= 1.6.2 =
    8084* Limits the arguments passed to the query when used with the WordPress native search.
  • searchwp-live-ajax-search/tags/1.6.3/searchwp-live-ajax-search.php

    r2683712 r2730935  
    44Plugin URI: https://searchwp.com/
    55Description: Enhance your search forms with live search, powered by SearchWP (if installed)
    6 Version: 1.6.2
     6Version: 1.6.3
    77Requires PHP: 5.6
    88Author: SearchWP, LLC
     
    4545    public $dir;
    4646    public $url;
    47     public $version = '1.6.2';
     47    public $version = '1.6.3';
    4848    public $results = array();
    4949
     
    6666        }
    6767
    68         if ( version_compare( $this->last_version, '1.6.2', '<' ) ) {
     68        if ( version_compare( $this->last_version, '1.6.3', '<' ) ) {
    6969            update_option( 'searchwp_live_search_last_update', current_time( 'timestamp' ) );
    7070            $this->after_upgrade();
  • searchwp-live-ajax-search/trunk/includes/class-client.php

    r2683712 r2730935  
    143143            $results = new \SWP_Query( array(
    144144                's'              => $query,
    145                 'engine'         => isset( $_REQUEST['swpengine'] ) ? sanitize_text_field( $_REQUEST['swpengine'] ) : 'default',
     145                'engine'         => isset( $_REQUEST['swpengine'] ) ? sanitize_key( $_REQUEST['swpengine'] ) : 'default',
    146146                'fields'         => 'ids',
    147147                'posts_per_page' => $this->get_posts_per_page(),
     
    162162            add_filter( 'searchwp_load_posts', '__return_false' );
    163163
    164             $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_text_field( $_REQUEST['swpengine'] ) : 'default';
     164            $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_key( $_REQUEST['swpengine'] ) : 'default';
    165165
    166166            // Grab our post IDs.
     
    185185     *
    186186     * @uses query_posts() to prep the WordPress environment in it's entirety for the template loader
    187      * @uses sanitize_text_field() to sanitize input
     187     * @uses sanitize_key() to sanitize input
    188188     * @uses SearchWP_Live_Search_Template
    189189     * @uses SearchWP_Live_Search_Template::get_template_part() to load the proper results template
     
    205205
    206206        // Optionally pass along the SearchWP engine if applicable.
    207         $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_text_field( $_REQUEST['swpengine'] ) : '';
     207        $engine = isset( $_REQUEST['swpengine'] ) ? sanitize_key( $_REQUEST['swpengine'] ) : '';
    208208
    209209        // Output the results using the results template.
  • searchwp-live-ajax-search/trunk/includes/class-relevanssi-bridge.php

    r946225 r2730935  
    11<?php
     2
     3// exit if accessed directly
     4if ( ! defined( 'ABSPATH' ) ) {
     5    exit;
     6}
    27
    38// class written by https://wordpress.org/plugins/daves-wordpress-live-search/
  • searchwp-live-ajax-search/trunk/includes/class-template.php

    r2140136 r2730935  
    22
    33// exit if accessed directly
    4 if ( ! defined( 'ABSPATH' ) ) exit;
     4if ( ! defined( 'ABSPATH' ) ) {
     5    exit;
     6}
    57
    68/**
  • searchwp-live-ajax-search/trunk/includes/class-widget.php

    r2455620 r2730935  
    11<?php
     2
     3// exit if accessed directly
     4if ( ! defined( 'ABSPATH' ) ) {
     5    exit;
     6}
    27
    38/**
  • searchwp-live-ajax-search/trunk/readme.txt

    r2683712 r2730935  
    7777== Changelog ==
    7878
     79= 1.6.3 =
     80* Improves sanitization of the 'swpengine' search field argument.
     81* Standardizes direct access restrictions in classes throughout the plugin.
     82
    7983= 1.6.2 =
    8084* Limits the arguments passed to the query when used with the WordPress native search.
  • searchwp-live-ajax-search/trunk/searchwp-live-ajax-search.php

    r2683712 r2730935  
    44Plugin URI: https://searchwp.com/
    55Description: Enhance your search forms with live search, powered by SearchWP (if installed)
    6 Version: 1.6.2
     6Version: 1.6.3
    77Requires PHP: 5.6
    88Author: SearchWP, LLC
     
    4545    public $dir;
    4646    public $url;
    47     public $version = '1.6.2';
     47    public $version = '1.6.3';
    4848    public $results = array();
    4949
     
    6666        }
    6767
    68         if ( version_compare( $this->last_version, '1.6.2', '<' ) ) {
     68        if ( version_compare( $this->last_version, '1.6.3', '<' ) ) {
    6969            update_option( 'searchwp_live_search_last_update', current_time( 'timestamp' ) );
    7070            $this->after_upgrade();
Note: See TracChangeset for help on using the changeset viewer.