Plugin Directory

Changeset 3454044


Ignore:
Timestamp:
02/04/2026 07:06:31 PM (2 weeks ago)
Author:
danstanhope
Message:

fixed depreciation warnings

Location:
expertfile-expert-content-templates/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • expertfile-expert-content-templates/trunk/README.txt

    r3243436 r3454044  
    44Donate link: https://expertfile.com/
    55Tags: Experts, Staff Directory, Expert Profiles, Staff Profiles, Expert Directory
    6 Tested up to: 6.5
    7 Stable tag: 1.0.4
    8 Requires PHP: 7.0
     6Tested up to: 6.9.1
     7Stable tag: 1.0.50
     8Requires PHP: 7.4 or higher
    99License: GPLv2 or later
    1010License URI: http://www.gnu.org/licenses/gpl-2.0.html
  • expertfile-expert-content-templates/trunk/expertfile.php

    r3243920 r3454044  
    1111 * Plugin URI:        https://expertfile.com/wordpress
    1212 * Description:       The easiest most powerful way to add expert content to your website from directories to profiles & more...
    13  * Version:           1.0.49
     13 * Version:           1.0.50
    1414 * Author:            ExpertFile
    1515 * Author URI:        https://expertfile.com
     
    2020 */
    2121
    22 // error_reporting(E_ALL);
    23 // ini_set('display_errors', '1');
     22
    2423
    2524if ( ! defined( 'WPINC' ) ) {
     
    2726}
    2827
    29 define( 'EXPERTFILE_VERSION', '1.0.3' );
     28define( 'EXPERTFILE_VERSION', '1.0.50' );
    3029define( 'EXPERTFILE_PLUGIN_NAME', 'expertfile' );
    3130define( 'EXPERTFILE_API_ENDPOINT', 'https://public-api.expertfile.com' );
     
    8685function run_expertfile() {
    8786    $plugin = new Expertfile();
    88    
     87
    8988    $plugin->run();
    9089}
  • expertfile-expert-content-templates/trunk/public/class-expertfile-public.php

    r3084548 r3454044  
    55    private $plugin_name;
    66    private $version;
     7    private $expert_profile_data;
     8    private $spotlight_post_data;
     9    private $expertanswer_post_data;
     10    private $include_title_tag;
     11    private $expert_directory_access;
    712
    813    function __construct($plugin_name, $version)
     
    5560        $access_options = get_option($this->plugin_name . '-api-access');
    5661
    57         $token = $access_options['token'];
     62        $token = is_array($access) ? ($access['token'] ?? null) : null;
    5863        // phpcs:ignore
    5964        $sanitized =  ExpertFileECT\Utils::sanitize($_POST);
     
    151156        $options = get_option($this->plugin_name . '-api-credentials-settings');
    152157        $access_options = get_option($this->plugin_name . '-api-access');
    153         $token = $access_options['token'];
     158        $token = is_array($access) ? ($access['token'] ?? null) : null;
    154159
    155160        $qs = isset($_SERVER['REQUEST_URI']) ? ExpertFileECT\Utils::get_query_string_arr($_SERVER['REQUEST_URI']) : array();
     
    259264        $access_options = get_option($this->plugin_name . '-api-access');
    260265
    261         $token = $access_options['token'];
     266        $token = is_array($access) ? ($access['token'] ?? null) : null;
    262267        // phpcs:ignore
    263268        $sanitized =  ExpertFileECT\Utils::sanitize($_POST);
     
    304309        $access_options = get_option($this->plugin_name . '-api-access');
    305310
     311
    306312        $inquiry_page_url = ($inquiry_page_url == "" ? $url_options['inquiry-url'] : $inquiry_page_url);
    307313        $spotlight_page_url = ($spotlight_page_url == "" ? $url_options['spotlight-url'] : $spotlight_page_url);
    308314
    309         $token = $access_options['token'];
     315        $token = is_array($access_options) ? ($access_options['token'] ?? null) : null;
     316
    310317        $username = $qs['username'] ?? get_query_var('username') ?? null;
    311318
     
    359366        $sanitized =  ExpertFileECT\Utils::sanitize($_POST);
    360367
    361         $token = $access_options['token'];
     368        $token = is_array($access) ? ($access['token'] ?? null) : null;
    362369        $username = $sanitized['username'];
    363370        $page_number = $sanitized['page_number'] ?? 1;
     
    396403        $options = get_option($this->plugin_name . '-api-credentials-settings');
    397404        $access = get_option($this->plugin_name . '-api-access');
    398         $token = $access['token'];
     405        $token = is_array($access) ? ($access['token'] ?? null) : null;
    399406
    400407        $id = $options['organization-id'];
     
    448455        $options = get_option($this->plugin_name . '-api-credentials-settings');
    449456        $access = get_option($this->plugin_name . '-api-access');
    450         $token = $access['token'];
     457        $token = is_array($access) ? ($access['token'] ?? null) : null;
    451458
    452459        $spotlight = new ExpertFileECT\Spotlight(
     
    493500        $url_options = get_option($this->plugin_name . '-url-overrides-settings');
    494501
    495         $token = $access['token'];
     502        $token = is_array($access) ? ($access['token'] ?? null) : null;
    496503        $qs = isset($_SERVER['REQUEST_URI']) ? ExpertFileECT\Utils::get_query_string_arr(sanitize_text_field($_SERVER['REQUEST_URI'])) : array();
    497504
     
    551558        $options = get_option($this->plugin_name . '-api-credentials-settings');
    552559        $access = get_option($this->plugin_name . '-api-access');
    553         $token = $access['token'];
     560        $token = is_array($access) ? ($access['token'] ?? null) : null;
    554561        // phpcs:ignore
    555562        $sanitized =  ExpertFileECT\Utils::sanitize($_POST);
     
    597604        $qs = isset($_SERVER['REQUEST_URI']) ? ExpertFileECT\Utils::get_query_string_arr(sanitize_text_field($_SERVER['REQUEST_URI'])) : array();
    598605
    599         $token = $access['token'];
     606        $token = is_array($access) ? ($access['token'] ?? null) : null;
    600607
    601608        $expertanswer_page_url = ($expertanswer_page_url == "" ? $url_options['expertanswer-url'] : $expertanswer_page_url);
     
    645652        $profile_page_url = ($profile_page_url == "" ? $url_options['profile-url'] : $profile_page_url);
    646653        $qs = isset($_SERVER['REQUEST_URI']) ? ExpertFileECT\Utils::get_query_string_arr(sanitize_text_field($_SERVER['REQUEST_URI'])) : array();
    647         $token = $access['token'];
     654        $token = is_array($access) ? ($access['token'] ?? null) : null;
    648655
    649656        $post_id =  $qs['id'] ?? get_query_var('id') ?? null;;
     
    707714        $url_options = get_option($this->plugin_name . '-url-overrides-settings');
    708715
    709         $token = $access['token'];
     716        $token = is_array($access) ? ($access['token'] ?? null) : null;
    710717        $profile_page_url = ($profile_page_url == "" ? $url_options['profile-url'] : $profile_page_url);
    711718
     
    743750        $options = get_option($this->plugin_name . '-api-credentials-settings');
    744751        $access = get_option($this->plugin_name . '-api-access');
    745         $token = $access['token'];
     752        $token = is_array($access) ? ($access['token'] ?? null) : null;
    746753        // phpcs:ignore
    747754        $sanitized =  ExpertFileECT\Utils::sanitize($_POST);
  • expertfile-expert-content-templates/trunk/public/classes/Utils.php

    r2973941 r3454044  
    4444        // phpcs:ignore
    4545        $page = get_page_by_path($slug);
     46
     47   
    4648        $id = $page->ID;
    4749        $pos = (strpos($url, $parseKey) > strpos($url, '{{encoded}}') && !empty(strpos($url, '{{encoded}}')) ? 2 : 1);
Note: See TracChangeset for help on using the changeset viewer.