Plugin Directory

Changeset 3447697


Ignore:
Timestamp:
01/27/2026 09:53:36 AM (6 weeks ago)
Author:
elementinvader
Message:

update v1.4.3

Location:
elementinvader-addons-for-elementor
Files:
230 added
4 edited

Legend:

Unmodified
Added
Removed
  • elementinvader-addons-for-elementor/trunk/README.txt

    r3441586 r3447697  
    66Requires PHP: 5.6
    77Tested up to: 6.9
    8 Stable tag: 1.4.2
     8Stable tag: 1.4.3
    99License: GPLv2 or later
    1010License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    8989== Changelog ==
    9090
     91= 1.4.3 =
     92* Security fix
     93
    9194= 1.4.2 =
    9295* Security fix
  • elementinvader-addons-for-elementor/trunk/elementinvader-addons-for-elementor.php

    r3441586 r3447697  
    55 * Description: Ready to use Elementor Addon Elements like Menu, Forms, Maps, Newsletter with many styling options
    66 * Plugin URI:  https://elementinvader.com
    7  * Version:     1.4.2
     7 * Version:     1.4.3
    88 * Author:      ElementInvader
    99 * Author URI:  https://elementinvader.com
  • elementinvader-addons-for-elementor/trunk/modules/mail_base/mail_base.php

    r3441586 r3447697  
    1717    include_once (ELEMENTINVADER_ADDONS_FOR_ELEMENTOR_PATH."pages/mail_base/index.php");
    1818}
    19 
    20 // Called from ajax
    21 // json for datatables
    22 function eli_mails_datatable()
    23 {
    24 
    25     if ( ! current_user_can( 'administrator' ) ) {
    26         exit();
    27     }
    28    
    29     check_ajax_referer('eli_secure_ajax', 'eli_secure');
    30 
    31     //$this->enable_error_reporting();
    32    // remove_action( 'shutdown', 'wp_ob_end_flush_all', 1 );
    33 
    34     // configuration
    35     $columns = array('id', 'date', 'email');
    36     //
    37 
    38     // Fetch parameters
    39     $parameters = eli_xss_clean($_POST);
    40     $draw = eli_xss_clean($_POST['draw']);
    41     $start = eli_xss_clean($_POST['start']);
    42     $length = eli_xss_clean($_POST['length']);
    43     $search = eli_xss_clean($_POST['search']);
    44 
    45    
    46     global $wpdb;
    47     $table = "{$wpdb->prefix}eli_newsletters";
    48 
    49     $where = 'WHERE 1=1';   
    50     foreach ($_POST['columns'] as $column) {
    51         if (in_array($column['data'], $column)) {
    52             $gen_search = $column['search']['value'];
    53             $col_name = $column['data'];
    54             if(!empty($gen_search))
    55                 if(substr_count($column['data'], 'date') > 0)
    56                 {
    57                     // DATE VALUES
    58                     $detect_date = strtotime($gen_search);
    59                     if(is_numeric($detect_date) && $detect_date > 1000)
    60                     {
    61                         $gen_search = date('Y-m-d H:i:s', $detect_date);
    62                         $where.=" AND ".$col_name." > '".$gen_search."' ";
    63                     }
    64                     else
    65                     {
    66                         $where.=" AND ".$col_name." LIKE '%".$gen_search."%' ";
    67                     }
    68                 } else {
    69                     $where.=" AND ".$col_name." LIKE '%".$gen_search."%' ";
    70                 }
    71         }
    72     }
    73 
    74     if(!empty($search['value']))
    75         $where.=" AND (id LIKE '%".$search['value']."%' OR email LIKE '%".$search['value']."%' ";
    76 
    77     $recordsTotal = eli_count($wpdb->get_results( "SELECT * FROM $table", OBJECT ));
    78 
    79     $data = $wpdb->get_results( "SELECT * FROM $table $where LIMIT $start, $length", OBJECT );
    80     $recordsFiltered = eli_count($data);
    81     $query = $wpdb->last_query;
    82     // Add buttons
    83     foreach($data as $key=>$row)
    84     {
    85         $row = eli_xss_clean_object($row);
    86 
    87         foreach($columns as $val)
    88         {
    89             if(isset($row->$val))
    90             {
    91                
    92             }
    93             elseif(isset($row->json_object))
    94             {
    95                 $json = json_decode($row->json_object);
    96                 if(isset($json->$val))
    97                 {
    98                     $row->$val = $json->$val;
    99                 }
    100                 else
    101                 {
    102                     $row->$val = '-';
    103                 }
    104             }
    105             else
    106             {
    107                 $row->$val = '-';
    108             }
    109         }
    110         $row->remove = eli_btn_open(admin_url("admin.php?page=wal_reports&function=report_edit&id=".$row->{"id"}), '');
    111         $row->checkbox = '';
    112     }
    113 
    114     //format array is optional
    115     $json = array(
    116             "parameters" => $parameters,
    117             "query" => $query,
    118             "draw" => $draw,
    119             "recordsTotal" => $recordsTotal,
    120             "recordsFiltered" => $recordsFiltered,
    121             "data" => $data
    122             );
    123 
    124     if(TRUE)
    125     {
    126         ob_clean();
    127         ob_start();
    128     }
    129     //$length = strlen(json_encode($data));
    130     header('Pragma: no-cache');
    131     header('Cache-Control: no-store, no-cache');
    132     header('Content-Type: application/json; charset=utf8');
    133     //header('Content-Length: '.$length);
    134     echo json_encode($json);
    135    
    136     exit();
    137 }
    138 add_filter('admin_action_eli_mails_datatable', 'eli_mails_datatable');
    13919
    14020function eli_export_email_base() {
  • elementinvader-addons-for-elementor/trunk/pages/mail_base/index.php

    r2863668 r3447697  
    3434    $columns = array('id', 'date', 'email');
    3535    // Fetch parameters
    36     $start = eli_xss_clean(eli_ch($_POST['start'], 0));
    37     $length = eli_xss_clean(eli_ch($_POST['length'], 9999));
    38     $search = eli_xss_clean(eli_ch($_POST['s'], false));
     36    $start = eli_xss_clean(sanitize_text_field(eli_ch($_POST['start'], 0)));
     37    $length = eli_xss_clean(sanitize_text_field(eli_ch($_POST['length'], 15)));
     38    $search = eli_xss_clean(sanitize_text_field(eli_ch($_POST['s'], false)));
    3939
    4040    global $wpdb;
     
    4343
    4444    if (!empty($search))
    45       $where .= " AND (id LIKE '%" . $search . "%' OR email LIKE '%" . $search . "%') ";
     45      $where .= " AND (id LIKE '%" . esc_sql($search) . "%' OR email LIKE '%" . esc_sql($search) . "%') ";
    4646
    4747    $results = $wpdb->get_results("SELECT * FROM $table $where LIMIT $start, $length", ARRAY_A);
     
    174174    usort($this->results, array(&$this, 'sort_data'));
    175175
    176     $per_page = 5;
     176    $per_page = 10;
    177177    $current_page = $this->get_pagenum();
    178178
Note: See TracChangeset for help on using the changeset viewer.