WP Security Audit Log - Version 3.3.1.2

Version Description

(2019-02-25) =

  • New Activity Log Events for WooCommerce

    • Event ID 9078: Changed the option to include / exclude taxes in product prices.
    • Event ID 9079: Changed the option on what type of shipping to calculate tax on.
    • Event ID 9080: Changed the shipping tax class.
    • Event ID 9081: Enabled / Disabled the rounding of the sub total.
    • Event ID 9082: Added / Deleted / Modified a shipping zone on WooCommerce.
  • Plugin Improvements

    • Better handling of plugin activation on multisite - plugin can only be activated from the network dashboard.
  • Bug Fixes

    • Updated Freemius SDK which includes a security fix.
Download this release

Release Info

Developer WPWhiteSecurity
Plugin Icon 128x128 WP Security Audit Log
Version 3.3.1.2
Comparing to
See all releases

Code changes from version 3.3.1.1 to 3.3.1.2

classes/Adapters/MySQL/ActiveRecordAdapter.php CHANGED
@@ -65,10 +65,10 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
65
  /**
66
  * Returns the model class for adapter.
67
  *
68
- * @return WSAL_Models_ActiveRecord
69
  */
70
  public function GetModel() {
71
- throw new RuntimeException('GetModel() should have been overridden in ' . get_class($this));
72
  }
73
 
74
  /**
@@ -251,9 +251,9 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
251
  * @param array $args (Optional) Load condition arguments.
252
  */
253
  public function LoadArray( $cond, $args = array() ) {
254
- $_wpdb = $this->connection;
255
  $result = array();
256
- $sql = $_wpdb->prepare( 'SELECT * FROM ' . $this->GetTable() . ' WHERE ' . $cond, $args );
257
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
258
  $result[] = $this->getModel()->LoadData( $data );
259
  }
@@ -267,7 +267,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
267
  * @return int|boolean - Either the amount of deleted rows or False on error.
268
  */
269
  public function Delete( $active_record ) {
270
- $_wpdb = $this->connection;
271
  $result = $_wpdb->delete(
272
  $this->GetTable(),
273
  $active_record->getId()
@@ -282,8 +282,8 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
282
  * @param array $args (Optional) Query arguments.
283
  */
284
  public function DeleteQuery( $query, $args = array() ) {
285
- $_wpdb = $this->connection;
286
- $sql = count( $args ) ? $_wpdb->prepare( $query, $args ) : $query;
287
  $result = $_wpdb->query( $sql );
288
  return $result;
289
  }
@@ -296,10 +296,10 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
296
  * @return self[] List of loaded records.
297
  */
298
  public function LoadMulti( $cond, $args = array() ) {
299
- $_wpdb = $this->connection;
300
  $result = array();
301
- $sql = ( ! is_array( $args ) || ! count( $args )) // Do we really need to prepare() or not?
302
- ? ($cond)
303
  : $_wpdb->prepare( $cond, $args );
304
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
305
  $result[] = $this->getModel()->LoadData( $data );
@@ -318,7 +318,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
318
  public function LoadAndCallForEach( $callback, $cond = '%d', $args = array( 1 ) ) {
319
  $_wpdb = $this->connection;
320
  $class = get_called_class();
321
- $sql = $_wpdb->prepare( 'SELECT * FROM ' . $this->GetTable() . ' WHERE ' . $cond, $args );
322
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
323
  call_user_func( $callback, new $class( $data ) );
324
  }
@@ -335,7 +335,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
335
  public function Count( $cond = '%d', $args = array( 1 ) ) {
336
  $_wpdb = $this->connection;
337
  $class = get_called_class();
338
- $sql = $_wpdb->prepare( 'SELECT COUNT(*) FROM ' . $this->GetTable() . ' WHERE ' . $cond, $args );
339
  return (int) $_wpdb->get_var( $sql );
340
  }
341
 
@@ -348,7 +348,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
348
  */
349
  public function CountQuery( $query, $args = array() ) {
350
  $_wpdb = $this->connection;
351
- $sql = count( $args ) ? $_wpdb->prepare( $query, $args ) : $query;
352
  return (int) $_wpdb->get_var( $sql );
353
  }
354
 
@@ -360,10 +360,10 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
360
  * @return array List of loaded records.
361
  */
362
  public function LoadMultiQuery( $query, $args = array() ) {
363
- $_wpdb = $this->connection;
364
- $class = get_called_class();
365
  $result = array();
366
- $sql = count( $args ) ? $_wpdb->prepare( $query, $args ) : $query;
367
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
368
  $result[] = $this->getModel()->LoadData( $data );
369
  }
@@ -389,7 +389,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
389
  case $key == $copy->_idkey:
390
  $sql .= $key . ' BIGINT NOT NULL AUTO_INCREMENT,' . PHP_EOL;
391
  break;
392
- case is_integer( $copy->$key ):
393
  $sql .= $key . ' BIGINT NOT NULL,' . PHP_EOL;
394
  break;
395
  case is_float( $copy->$key ):
@@ -398,7 +398,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
398
  case is_string( $copy->$key ):
399
  $maxlength = $key . '_maxlength';
400
  if ( property_exists( $class, $maxlength ) ) {
401
- $sql .= $key . ' VARCHAR(' . intval( $class::$$maxlength ) . ') NOT NULL,' . PHP_EOL;
402
  } else {
403
  $sql .= $key . ' LONGTEXT NOT NULL,' . PHP_EOL;
404
  }
@@ -443,7 +443,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
443
  * @return string
444
  */
445
  protected function _GetUninstallQuery() {
446
- return 'DROP TABLE ' . $this->GetTable();
447
  }
448
 
449
  /**
@@ -459,7 +459,7 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
459
  if ( ! empty( $_user_id ) && 'null' != $_user_id ) {
460
  $sql = 'SELECT user_login FROM ' . $wpdb->users . ' WHERE find_in_set(ID, @userId) > 0';
461
  $wpdb->query( "SET @userId = $_user_id" );
462
- $result = $wpdb->get_results( $sql, ARRAY_A );
463
  $users_array = array();
464
  foreach ( $result as $item ) {
465
  $users_array[] = '"' . $item['user_login'] . '"';
@@ -472,16 +472,16 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
472
  /**
473
  * Function used in WSAL reporting extension.
474
  *
475
- * @param int $_site_id - Site ID.
476
- * @param int $_user_id - User ID.
477
- * @param string $_role_name - User role.
478
- * @param int $_alert_code - Alert code.
479
- * @param timestamp $_start_timestamp - From created_on.
480
- * @param timestamp $_end_timestamp - To created_on.
481
- * @param timestamp $_next_date - (Optional) Created on >.
482
- * @param int $_limit - (Optional) Limit.
483
- * @param string $_post_types - (Optional) Post types.
484
- * @param string $_post_statuses - (Optional) Post statuses.
485
  * @return array Report results
486
  */
487
  public function GetReporting( $_site_id, $_user_id, $_role_name, $_alert_code, $_start_timestamp, $_end_timestamp, $_next_date = null, $_limit = 0, $_post_types = '', $_post_statuses = '' ) {
@@ -492,10 +492,10 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
492
  $_wpdb->set_charset( $_wpdb->dbh, 'utf8mb4', 'utf8mb4_general_ci' );
493
 
494
  // Tables.
495
- $meta = new WSAL_Adapters_MySQL_Meta( $this->connection );
496
  $table_meta = $meta->GetTable(); // Metadata.
497
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $this->connection );
498
- $table_occ = $occurrence->GetTable(); // Occurrences.
499
 
500
  $condition_date = ! empty( $_next_date ) ? ' AND occ.created_on < ' . $_next_date : '';
501
 
@@ -604,13 +604,13 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
604
 
605
  if ( ! empty( $results ) ) {
606
  foreach ( $results as $row ) {
607
- $sql = "SELECT t6.ID FROM $wpdb->users AS t6 WHERE t6.user_login = \"$row->user_id\"";
608
  $user_id = $wpdb->get_var( $sql );
609
  if ( null == $user_id ) {
610
- $sql = "SELECT t4.ID FROM $wpdb->users AS t4 WHERE t4.ID = \"$row->user_id\"";
611
  $user_id = $wpdb->get_var( $sql );
612
  }
613
- $row->user_id = $user_id;
614
  $results['lastDate'] = $row->created_on;
615
  }
616
  }
@@ -626,23 +626,23 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
626
  * @return int count of distinct values
627
  */
628
  public function CheckMatchReportCriteria( $criteria ) {
629
- $_site_id = $criteria['siteId'];
630
- $_user_id = $criteria['userId'];
631
- $_post_types = $criteria['post_types'];
632
- $_post_statuses = $criteria['post_statuses'];
633
- $_role_name = $criteria['roleName'];
634
- $_alert_code = $criteria['alertCode'];
635
  $_start_timestamp = $criteria['startTimestamp'];
636
- $_end_timestamp = $criteria['endTimestamp'];
637
- $_ip_address = $criteria['ipAddress'];
638
 
639
  $_wpdb = $this->connection;
640
  $_wpdb->set_charset( $_wpdb->dbh, 'utf8mb4', 'utf8mb4_general_ci' );
641
  // Tables.
642
- $meta = new WSAL_Adapters_MySQL_Meta( $this->connection );
643
  $table_meta = $meta->GetTable(); // Metadata.
644
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $this->connection );
645
- $table_occ = $occurrence->GetTable(); // Occurrences.
646
 
647
  $user_names = $this->GetUserNames( $_user_id );
648
 
@@ -720,14 +720,14 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
720
  * Function used in WSAL reporting extension.
721
  * List of unique IP addresses used by the same user.
722
  *
723
- * @param int $_site_id - Site ID.
724
- * @param timestamp $_start_timestamp - From created_on.
725
- * @param timestamp $_end_timestamp - To created_on.
726
- * @param int $_user_id - (Optional) User ID.
727
- * @param string $_role_name - (Optional) User role.
728
- * @param string $_ip_address - (Optional) IP address.
729
- * @param int $_alert_code - (Optional) Alert code.
730
- * @param int $_limit - (Optional) Limit.
731
  * @return array Report results grouped by IP and Username
732
  */
733
  public function GetReportGrouped( $_site_id, $_start_timestamp, $_end_timestamp, $_user_id = 'null', $_role_name = 'null', $_ip_address = 'null', $_alert_code = 'null', $_limit = 0 ) {
@@ -737,10 +737,10 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
737
  $_wpdb = $this->connection;
738
  $_wpdb->set_charset( $_wpdb->dbh, 'utf8mb4', 'utf8mb4_general_ci' );
739
  // Tables.
740
- $meta = new WSAL_Adapters_MySQL_Meta( $this->connection );
741
  $table_meta = $meta->GetTable(); // Metadata.
742
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $this->connection );
743
- $table_occ = $occurrence->GetTable(); // Occurrences.
744
  // Get temp table `wsal_tmp_users`.
745
  $tmp_users = new WSAL_Adapters_MySQL_TmpUser( $this->connection );
746
  // If the table exist.
@@ -814,22 +814,22 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
814
  }
815
 
816
  $grouped_types = array();
817
- $results = $_wpdb->get_results( $sql );
818
  if ( ! empty( $results ) ) {
819
  foreach ( $results as $key => $row ) {
820
  // Get the display_name only for the first row & if the user_login changed from the previous row.
821
- if ( 0 == $key || ($key > 1 && $results[ ($key - 1) ]->user_login != $row->user_login) ) {
822
- $sql = "SELECT t5.display_name FROM $wpdb->users AS t5 WHERE t5.user_login = \"$row->user_login\"";
823
  $display_name = $wpdb->get_var( $sql );
824
  }
825
  $row->display_name = $display_name;
826
 
827
  if ( ! isset( $grouped_types[ $row->user_login ] ) ) {
828
  $grouped_types[ $row->user_login ] = array(
829
- 'site_id' => $row->site_id,
830
- 'user_login' => $row->user_login,
831
  'display_name' => $row->display_name,
832
- 'ips' => array(),
833
  );
834
  }
835
 
@@ -848,10 +848,10 @@ class WSAL_Adapters_MySQL_ActiveRecord implements WSAL_Adapters_ActiveRecordInte
848
  */
849
  private function TempUsers( $table_users ) {
850
  $_wpdb = $this->connection;
851
- $sql = "DELETE FROM $table_users";
852
  $_wpdb->query( $sql );
853
 
854
- $sql = "INSERT INTO $table_users (ID, user_login) VALUES " ;
855
  $users = get_users(
856
  array(
857
  'fields' => array( 'ID', 'user_login' ),
65
  /**
66
  * Returns the model class for adapter.
67
  *
68
+ * @throws RuntimeException - Throw exception if the function is not overriden.
69
  */
70
  public function GetModel() {
71
+ throw new RuntimeException( 'GetModel() should have been overridden in ' . get_class( $this ) );
72
  }
73
 
74
  /**
251
  * @param array $args (Optional) Load condition arguments.
252
  */
253
  public function LoadArray( $cond, $args = array() ) {
254
+ $_wpdb = $this->connection;
255
  $result = array();
256
+ $sql = $_wpdb->prepare( 'SELECT * FROM ' . $this->GetTable() . ' WHERE ' . $cond, $args );
257
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
258
  $result[] = $this->getModel()->LoadData( $data );
259
  }
267
  * @return int|boolean - Either the amount of deleted rows or False on error.
268
  */
269
  public function Delete( $active_record ) {
270
+ $_wpdb = $this->connection;
271
  $result = $_wpdb->delete(
272
  $this->GetTable(),
273
  $active_record->getId()
282
  * @param array $args (Optional) Query arguments.
283
  */
284
  public function DeleteQuery( $query, $args = array() ) {
285
+ $_wpdb = $this->connection;
286
+ $sql = count( $args ) ? $_wpdb->prepare( $query, $args ) : $query;
287
  $result = $_wpdb->query( $sql );
288
  return $result;
289
  }
296
  * @return self[] List of loaded records.
297
  */
298
  public function LoadMulti( $cond, $args = array() ) {
299
+ $_wpdb = $this->connection;
300
  $result = array();
301
+ $sql = ( ! is_array( $args ) || ! count( $args ) ) // Do we really need to prepare() or not?
302
+ ? ( $cond )
303
  : $_wpdb->prepare( $cond, $args );
304
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
305
  $result[] = $this->getModel()->LoadData( $data );
318
  public function LoadAndCallForEach( $callback, $cond = '%d', $args = array( 1 ) ) {
319
  $_wpdb = $this->connection;
320
  $class = get_called_class();
321
+ $sql = $_wpdb->prepare( 'SELECT * FROM ' . $this->GetTable() . ' WHERE ' . $cond, $args );
322
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
323
  call_user_func( $callback, new $class( $data ) );
324
  }
335
  public function Count( $cond = '%d', $args = array( 1 ) ) {
336
  $_wpdb = $this->connection;
337
  $class = get_called_class();
338
+ $sql = $_wpdb->prepare( 'SELECT COUNT(*) FROM ' . $this->GetTable() . ' WHERE ' . $cond, $args );
339
  return (int) $_wpdb->get_var( $sql );
340
  }
341
 
348
  */
349
  public function CountQuery( $query, $args = array() ) {
350
  $_wpdb = $this->connection;
351
+ $sql = count( $args ) ? $_wpdb->prepare( $query, $args ) : $query;
352
  return (int) $_wpdb->get_var( $sql );
353
  }
354
 
360
  * @return array List of loaded records.
361
  */
362
  public function LoadMultiQuery( $query, $args = array() ) {
363
+ $_wpdb = $this->connection;
364
+ $class = get_called_class();
365
  $result = array();
366
+ $sql = count( $args ) ? $_wpdb->prepare( $query, $args ) : $query;
367
  foreach ( $_wpdb->get_results( $sql, ARRAY_A ) as $data ) {
368
  $result[] = $this->getModel()->LoadData( $data );
369
  }
389
  case $key == $copy->_idkey:
390
  $sql .= $key . ' BIGINT NOT NULL AUTO_INCREMENT,' . PHP_EOL;
391
  break;
392
+ case is_int( $copy->$key ):
393
  $sql .= $key . ' BIGINT NOT NULL,' . PHP_EOL;
394
  break;
395
  case is_float( $copy->$key ):
398
  case is_string( $copy->$key ):
399
  $maxlength = $key . '_maxlength';
400
  if ( property_exists( $class, $maxlength ) ) {
401
+ $sql .= $key . ' VARCHAR(' . (int) $class::$$maxlength . ') NOT NULL,' . PHP_EOL;
402
  } else {
403
  $sql .= $key . ' LONGTEXT NOT NULL,' . PHP_EOL;
404
  }
443
  * @return string
444
  */
445
  protected function _GetUninstallQuery() {
446
+ return 'DROP TABLE ' . $this->GetTable();
447
  }
448
 
449
  /**
459
  if ( ! empty( $_user_id ) && 'null' != $_user_id ) {
460
  $sql = 'SELECT user_login FROM ' . $wpdb->users . ' WHERE find_in_set(ID, @userId) > 0';
461
  $wpdb->query( "SET @userId = $_user_id" );
462
+ $result = $wpdb->get_results( $sql, ARRAY_A );
463
  $users_array = array();
464
  foreach ( $result as $item ) {
465
  $users_array[] = '"' . $item['user_login'] . '"';
472
  /**
473
  * Function used in WSAL reporting extension.
474
  *
475
+ * @param int $_site_id - Site ID.
476
+ * @param int $_user_id - User ID.
477
+ * @param string $_role_name - User role.
478
+ * @param int $_alert_code - Alert code.
479
+ * @param int $_start_timestamp - From created_on.
480
+ * @param int $_end_timestamp - To created_on.
481
+ * @param int $_next_date - (Optional) Created on >.
482
+ * @param int $_limit - (Optional) Limit.
483
+ * @param string $_post_types - (Optional) Post types.
484
+ * @param string $_post_statuses - (Optional) Post statuses.
485
  * @return array Report results
486
  */
487
  public function GetReporting( $_site_id, $_user_id, $_role_name, $_alert_code, $_start_timestamp, $_end_timestamp, $_next_date = null, $_limit = 0, $_post_types = '', $_post_statuses = '' ) {
492
  $_wpdb->set_charset( $_wpdb->dbh, 'utf8mb4', 'utf8mb4_general_ci' );
493
 
494
  // Tables.
495
+ $meta = new WSAL_Adapters_MySQL_Meta( $this->connection );
496
  $table_meta = $meta->GetTable(); // Metadata.
497
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $this->connection );
498
+ $table_occ = $occurrence->GetTable(); // Occurrences.
499
 
500
  $condition_date = ! empty( $_next_date ) ? ' AND occ.created_on < ' . $_next_date : '';
501
 
604
 
605
  if ( ! empty( $results ) ) {
606
  foreach ( $results as $row ) {
607
+ $sql = "SELECT t6.ID FROM $wpdb->users AS t6 WHERE t6.user_login = \"$row->user_id\"";
608
  $user_id = $wpdb->get_var( $sql );
609
  if ( null == $user_id ) {
610
+ $sql = "SELECT t4.ID FROM $wpdb->users AS t4 WHERE t4.ID = \"$row->user_id\"";
611
  $user_id = $wpdb->get_var( $sql );
612
  }
613
+ $row->user_id = $user_id;
614
  $results['lastDate'] = $row->created_on;
615
  }
616
  }
626
  * @return int count of distinct values
627
  */
628
  public function CheckMatchReportCriteria( $criteria ) {
629
+ $_site_id = $criteria['siteId'];
630
+ $_user_id = $criteria['userId'];
631
+ $_post_types = $criteria['post_types'];
632
+ $_post_statuses = $criteria['post_statuses'];
633
+ $_role_name = $criteria['roleName'];
634
+ $_alert_code = $criteria['alertCode'];
635
  $_start_timestamp = $criteria['startTimestamp'];
636
+ $_end_timestamp = $criteria['endTimestamp'];
637
+ $_ip_address = $criteria['ipAddress'];
638
 
639
  $_wpdb = $this->connection;
640
  $_wpdb->set_charset( $_wpdb->dbh, 'utf8mb4', 'utf8mb4_general_ci' );
641
  // Tables.
642
+ $meta = new WSAL_Adapters_MySQL_Meta( $this->connection );
643
  $table_meta = $meta->GetTable(); // Metadata.
644
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $this->connection );
645
+ $table_occ = $occurrence->GetTable(); // Occurrences.
646
 
647
  $user_names = $this->GetUserNames( $_user_id );
648
 
720
  * Function used in WSAL reporting extension.
721
  * List of unique IP addresses used by the same user.
722
  *
723
+ * @param int $_site_id - Site ID.
724
+ * @param int $_start_timestamp - From created_on.
725
+ * @param int $_end_timestamp - To created_on.
726
+ * @param string|int $_user_id - (Optional) User ID.
727
+ * @param string $_role_name - (Optional) User role.
728
+ * @param string $_ip_address - (Optional) IP address.
729
+ * @param string|int $_alert_code - (Optional) Alert code.
730
+ * @param int $_limit - (Optional) Limit.
731
  * @return array Report results grouped by IP and Username
732
  */
733
  public function GetReportGrouped( $_site_id, $_start_timestamp, $_end_timestamp, $_user_id = 'null', $_role_name = 'null', $_ip_address = 'null', $_alert_code = 'null', $_limit = 0 ) {
737
  $_wpdb = $this->connection;
738
  $_wpdb->set_charset( $_wpdb->dbh, 'utf8mb4', 'utf8mb4_general_ci' );
739
  // Tables.
740
+ $meta = new WSAL_Adapters_MySQL_Meta( $this->connection );
741
  $table_meta = $meta->GetTable(); // Metadata.
742
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $this->connection );
743
+ $table_occ = $occurrence->GetTable(); // Occurrences.
744
  // Get temp table `wsal_tmp_users`.
745
  $tmp_users = new WSAL_Adapters_MySQL_TmpUser( $this->connection );
746
  // If the table exist.
814
  }
815
 
816
  $grouped_types = array();
817
+ $results = $_wpdb->get_results( $sql );
818
  if ( ! empty( $results ) ) {
819
  foreach ( $results as $key => $row ) {
820
  // Get the display_name only for the first row & if the user_login changed from the previous row.
821
+ if ( 0 == $key || ( $key > 1 && $results[ ( $key - 1 ) ]->user_login != $row->user_login ) ) {
822
+ $sql = "SELECT t5.display_name FROM $wpdb->users AS t5 WHERE t5.user_login = \"$row->user_login\"";
823
  $display_name = $wpdb->get_var( $sql );
824
  }
825
  $row->display_name = $display_name;
826
 
827
  if ( ! isset( $grouped_types[ $row->user_login ] ) ) {
828
  $grouped_types[ $row->user_login ] = array(
829
+ 'site_id' => $row->site_id,
830
+ 'user_login' => $row->user_login,
831
  'display_name' => $row->display_name,
832
+ 'ips' => array(),
833
  );
834
  }
835
 
848
  */
849
  private function TempUsers( $table_users ) {
850
  $_wpdb = $this->connection;
851
+ $sql = "DELETE FROM $table_users";
852
  $_wpdb->query( $sql );
853
 
854
+ $sql = "INSERT INTO $table_users (ID, user_login) VALUES ";
855
  $users = get_users(
856
  array(
857
  'fields' => array( 'ID', 'user_login' ),
classes/Alert.php CHANGED
@@ -98,7 +98,7 @@ final class WSAL_Alert {
98
  * @param mixed $highlight - (Optional) Highlight format.
99
  * @return string The expanded message.
100
  */
101
- protected function GetFormattedMesg( $orig_mesg, $meta_data = array(), $meta_formatter = null, $occurrence_id = 0, $highlight ) {
102
  // Tokenize message with regex.
103
  $mesg = preg_split( '/(%.*?%)/', (string) $orig_mesg, -1, PREG_SPLIT_DELIM_CAPTURE );
104
  if ( ! is_array( $mesg ) ) {
98
  * @param mixed $highlight - (Optional) Highlight format.
99
  * @return string The expanded message.
100
  */
101
+ protected function GetFormattedMesg( $orig_mesg, $meta_data = array(), $meta_formatter = null, $occurrence_id = 0, $highlight = null ) {
102
  // Tokenize message with regex.
103
  $mesg = preg_split( '/(%.*?%)/', (string) $orig_mesg, -1, PREG_SPLIT_DELIM_CAPTURE );
104
  if ( ! is_array( $mesg ) ) {
classes/AlertManager.php CHANGED
@@ -133,6 +133,7 @@ final class WSAL_AlertManager {
133
  'custom_css', // Custom CSS CPT.
134
  'shop_order', // WooCommerce Order CPT.
135
  'shop_order_refund', // WooCommerce Order Refund CPT.
 
136
  )
137
  );
138
  }
@@ -207,8 +208,8 @@ final class WSAL_AlertManager {
207
  /**
208
  * Trigger an alert.
209
  *
210
- * @param integer $type - Alert type.
211
- * @param array $data - Alert data.
212
  * @param mixed $delayed - False if delayed, function if not.
213
  */
214
  public function Trigger( $type, $data = array(), $delayed = false ) {
@@ -719,8 +720,8 @@ final class WSAL_AlertManager {
719
  * Method: Returns if IP is disabled or not.
720
  */
721
  private function IsDisabledIP() {
722
- $is_disabled = false;
723
- $ip = $this->plugin->settings->GetMainClientIP();
724
  $excluded_ips = $this->plugin->settings->GetExcludedMonitoringIP();
725
  if ( in_array( $ip, $excluded_ips ) ) {
726
  $is_disabled = true;
133
  'custom_css', // Custom CSS CPT.
134
  'shop_order', // WooCommerce Order CPT.
135
  'shop_order_refund', // WooCommerce Order Refund CPT.
136
+ 'product_variation', // WooCommerce Product Variation CPT.
137
  )
138
  );
139
  }
208
  /**
209
  * Trigger an alert.
210
  *
211
+ * @param integer $type - Alert type.
212
+ * @param array $data - Alert data.
213
  * @param mixed $delayed - False if delayed, function if not.
214
  */
215
  public function Trigger( $type, $data = array(), $delayed = false ) {
720
  * Method: Returns if IP is disabled or not.
721
  */
722
  private function IsDisabledIP() {
723
+ $is_disabled = false;
724
+ $ip = $this->plugin->settings->GetMainClientIP();
725
  $excluded_ips = $this->plugin->settings->GetExcludedMonitoringIP();
726
  if ( in_array( $ip, $excluded_ips ) ) {
727
  $is_disabled = true;
classes/AuditLogListView.php CHANGED
@@ -183,6 +183,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
183
 
184
  if ( 'top' !== $which && $this->_plugin->settings->is_infinite_scroll() ) :
185
  ?>
 
186
  <div id="wsal-event-loader"><div class="wsal-lds-ellipsis"><div></div><div></div><div></div><div></div></div></div>
187
  <?php
188
  endif;
@@ -378,8 +379,8 @@ class WSAL_AuditLogListView extends WP_List_Table {
378
  /**
379
  * Method: Get default column values.
380
  *
381
- * @param object $item - Column item.
382
- * @param string $column_name - Name of the column.
383
  */
384
  public function column_default( $item, $column_name ) {
385
  // Get date format.
@@ -606,7 +607,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
606
  * Method: Meta data formater.
607
  *
608
  * @param string $name - Name of the data.
609
- * @param mix $value - Value of the data.
610
  * @return string
611
  * @deprecated 3.3
612
  */
@@ -694,7 +695,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
694
  return '<a href="javascript:;" onclick="download_failed_login_log( this )" data-download-nonce="' . esc_attr( wp_create_nonce( 'wsal-download-failed-logins' ) ) . '" title="' . esc_html__( 'Download the log file.', 'wp-security-audit-log' ) . '">' . esc_html__( 'Download the log file.', 'wp-security-audit-log' ) . '</a>';
695
 
696
  case strncmp( $value, 'http://', 7 ) === 0:
697
- case strncmp( $value, 'https://', 7 ) === 0:
698
  return '<a href="' . esc_html( $value ) . '" title="' . esc_html( $value ) . '" target="_blank">' . esc_html( $value ) . '</a>';
699
 
700
  case '%PostStatus%' === $name:
@@ -904,7 +905,7 @@ class WSAL_AuditLogListView extends WP_List_Table {
904
  $id = $with_id ? "id='$column_key'" : '';
905
 
906
  if ( ! empty( $class ) ) {
907
- $class = "class='" . join( ' ', $class ) . "'";
908
  }
909
 
910
  echo "<$tag $scope $id $class>";
183
 
184
  if ( 'top' !== $which && $this->_plugin->settings->is_infinite_scroll() ) :
185
  ?>
186
+ <div id="wsal-auditlog-end"><p><?php esc_html_e( '— End of Activity Log —', 'wp-security-audit-log' ); ?></p></div>
187
  <div id="wsal-event-loader"><div class="wsal-lds-ellipsis"><div></div><div></div><div></div><div></div></div></div>
188
  <?php
189
  endif;
379
  /**
380
  * Method: Get default column values.
381
  *
382
+ * @param WSAL_Models_Occurrence $item - Column item.
383
+ * @param string $column_name - Name of the column.
384
  */
385
  public function column_default( $item, $column_name ) {
386
  // Get date format.
607
  * Method: Meta data formater.
608
  *
609
  * @param string $name - Name of the data.
610
+ * @param mixed $value - Value of the data.
611
  * @return string
612
  * @deprecated 3.3
613
  */
695
  return '<a href="javascript:;" onclick="download_failed_login_log( this )" data-download-nonce="' . esc_attr( wp_create_nonce( 'wsal-download-failed-logins' ) ) . '" title="' . esc_html__( 'Download the log file.', 'wp-security-audit-log' ) . '">' . esc_html__( 'Download the log file.', 'wp-security-audit-log' ) . '</a>';
696
 
697
  case strncmp( $value, 'http://', 7 ) === 0:
698
+ case strncmp( $value, 'https://', 8 ) === 0:
699
  return '<a href="' . esc_html( $value ) . '" title="' . esc_html( $value ) . '" target="_blank">' . esc_html( $value ) . '</a>';
700
 
701
  case '%PostStatus%' === $name:
905
  $id = $with_id ? "id='$column_key'" : '';
906
 
907
  if ( ! empty( $class ) ) {
908
+ $class = "class='" . implode( ' ', $class ) . "'";
909
  }
910
 
911
  echo "<$tag $scope $id $class>";
classes/Connector/MySQLDB.php CHANGED
@@ -36,7 +36,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
36
  public function __construct( $connection_config = null ) {
37
  $this->connectionConfig = $connection_config;
38
  parent::__construct( 'MySQL' );
39
- require_once( $this->getAdaptersDirectory() . '/OptionAdapter.php' );
40
  }
41
 
42
  /**
@@ -62,7 +62,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
62
  /**
63
  * Creates a connection and returns it
64
  *
65
- * @return wpdb Instance of WPDB
66
  */
67
  private function createConnection() {
68
  if ( ! empty( $this->connectionConfig ) ) {
@@ -97,7 +97,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
97
  */
98
  public function closeConnection() {
99
  $current_wpdb = $this->getConnection();
100
- $result = $current_wpdb->close();
101
  return $result;
102
  }
103
 
@@ -197,9 +197,9 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
197
  * @return integer MAX(id)
198
  */
199
  private function GetIncreaseOccurrence() {
200
- $_wpdb = $this->getConnection();
201
  $occurrence_new = new WSAL_Adapters_MySQL_Occurrence( $_wpdb );
202
- $sql = 'SELECT MAX(id) FROM ' . $occurrence_new->GetTable();
203
  return (int) $_wpdb->get_var( $sql );
204
  }
205
 
@@ -211,7 +211,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
211
  */
212
  public function MigrateMeta( $index, $limit ) {
213
  $result = null;
214
- $offset = ($index * $limit);
215
  global $wpdb;
216
  $_wpdb = $this->getConnection();
217
  // Add +1 because an alert is generated after delete the metadata table.
@@ -223,7 +223,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
223
  $result['empty'] = true;
224
  return $result;
225
  }
226
- $sql = 'SELECT * FROM ' . $meta->GetWPTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
227
  $metadata = $wpdb->get_results( $sql, ARRAY_A );
228
 
229
  // Insert data to External DB.
@@ -231,10 +231,10 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
231
  $meta_new = new WSAL_Adapters_MySQL_Meta( $_wpdb );
232
 
233
  $index++;
234
- $sql = 'INSERT INTO ' . $meta_new->GetTable() . ' (occurrence_id, name, value) VALUES ' ;
235
  foreach ( $metadata as $entry ) {
236
  $occurrence_id = intval( $entry['occurrence_id'] ) + $increase_occurrence_id;
237
- $sql .= '(' . $occurrence_id . ', \'' . $entry['name'] . '\', \'' . str_replace( array( "'", "\'" ), "\'", $entry['value'] ) . '\'), ';
238
  }
239
  $sql = rtrim( $sql, ', ' );
240
  $_wpdb->query( $sql );
@@ -256,7 +256,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
256
  */
257
  public function MigrateOccurrence( $index, $limit ) {
258
  $result = null;
259
- $offset = ($index * $limit);
260
  global $wpdb;
261
  $_wpdb = $this->getConnection();
262
 
@@ -266,7 +266,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
266
  $result['empty'] = true;
267
  return $result;
268
  }
269
- $sql = 'SELECT * FROM ' . $occurrence->GetWPTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
270
  $occurrences = $wpdb->get_results( $sql, ARRAY_A );
271
 
272
  // Insert data to External DB.
@@ -274,7 +274,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
274
  $occurrence_new = new WSAL_Adapters_MySQL_Occurrence( $_wpdb );
275
 
276
  $index++;
277
- $sql = 'INSERT INTO ' . $occurrence_new->GetTable() . ' (site_id, alert_id, created_on, is_read) VALUES ' ;
278
  foreach ( $occurrences as $entry ) {
279
  $sql .= '(' . $entry['site_id'] . ', ' . $entry['alert_id'] . ', ' . $entry['created_on'] . ', ' . $entry['is_read'] . '), ';
280
  }
@@ -298,7 +298,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
298
  */
299
  public function MigrateBackOccurrence( $index, $limit ) {
300
  $result = null;
301
- $offset = ($index * $limit);
302
  global $wpdb;
303
  $_wpdb = $this->getConnection();
304
 
@@ -308,7 +308,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
308
  $result['empty'] = true;
309
  return $result;
310
  }
311
- $sql = 'SELECT * FROM ' . $occurrence->GetTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
312
  $occurrences = $_wpdb->get_results( $sql, ARRAY_A );
313
 
314
  // Insert data to WP.
@@ -316,7 +316,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
316
  $occurrence_wp = new WSAL_Adapters_MySQL_Occurrence( $wpdb );
317
 
318
  $index++;
319
- $sql = 'INSERT INTO ' . $occurrence_wp->GetWPTable() . ' (id, site_id, alert_id, created_on, is_read) VALUES ' ;
320
  foreach ( $occurrences as $entry ) {
321
  $sql .= '(' . $entry['id'] . ', ' . $entry['site_id'] . ', ' . $entry['alert_id'] . ', ' . $entry['created_on'] . ', ' . $entry['is_read'] . '), ';
322
  }
@@ -339,7 +339,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
339
  */
340
  public function MigrateBackMeta( $index, $limit ) {
341
  $result = null;
342
- $offset = ($index * $limit);
343
  global $wpdb;
344
  $_wpdb = $this->getConnection();
345
 
@@ -349,7 +349,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
349
  $result['empty'] = true;
350
  return $result;
351
  }
352
- $sql = 'SELECT * FROM ' . $meta->GetTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
353
  $metadata = $_wpdb->get_results( $sql, ARRAY_A );
354
 
355
  // Insert data to WP.
@@ -357,7 +357,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
357
  $meta_wp = new WSAL_Adapters_MySQL_Meta( $wpdb );
358
 
359
  $index++;
360
- $sql = 'INSERT INTO ' . $meta_wp->GetWPTable() . ' (occurrence_id, name, value) VALUES ' ;
361
  foreach ( $metadata as $entry ) {
362
  $sql .= '(' . $entry['occurrence_id'] . ', \'' . $entry['name'] . '\', \'' . str_replace( array( "'", "\'" ), "\'", $entry['value'] ) . '\'), ';
363
  }
@@ -539,7 +539,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
539
  * @param array $args - Archive Database and limit by count OR by date.
540
  */
541
  public function ArchiveOccurrence( $args ) {
542
- $_wpdb = $this->getConnection();
543
  $archive_db = $args['archive_db'];
544
 
545
  // Load data Occurrences from WP.
@@ -568,15 +568,15 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
568
 
569
  // Insert data to Archive DB.
570
  if ( ! empty( $occurrences ) ) {
571
- $last = end( $occurrences );
572
  $args['last_created_on'] = $last['created_on'];
573
- $args['occurence_ids'] = array();
574
 
575
  $occurrence_new = new WSAL_Adapters_MySQL_Occurrence( $archive_db );
576
 
577
- $sql = 'INSERT INTO ' . $occurrence_new->GetTable() . ' (id, site_id, alert_id, created_on, is_read) VALUES ' ;
578
  foreach ( $occurrences as $entry ) {
579
- $sql .= '(' . $entry['id'] . ', ' . $entry['site_id'] . ', ' . $entry['alert_id'] . ', ' . $entry['created_on'] . ', ' . $entry['is_read'] . '), ';
580
  $args['occurence_ids'][] = $entry['id'];
581
  }
582
  $sql = rtrim( $sql, ', ' );
@@ -594,7 +594,7 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
594
  * @param array $args - Archive Database and occurrences IDs.
595
  */
596
  public function ArchiveMeta( $args ) {
597
- $_wpdb = $this->getConnection();
598
  $archive_db = $args['archive_db'];
599
 
600
  // Load data Meta from WP.
@@ -603,14 +603,14 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
603
  return null;
604
  }
605
  $s_occurence_ids = implode( ', ', $args['occurence_ids'] );
606
- $sql = 'SELECT * FROM ' . $meta->GetTable() . ' WHERE occurrence_id IN (' . $s_occurence_ids . ')';
607
- $metadata = $_wpdb->get_results( $sql, ARRAY_A );
608
 
609
  // Insert data to Archive DB.
610
  if ( ! empty( $metadata ) ) {
611
  $meta_new = new WSAL_Adapters_MySQL_Meta( $archive_db );
612
 
613
- $sql = 'INSERT INTO ' . $meta_new->GetTable() . ' (occurrence_id, name, value) VALUES ' ;
614
  foreach ( $metadata as $entry ) {
615
  $sql .= '(' . $entry['occurrence_id'] . ', \'' . $entry['name'] . '\', \'' . str_replace( array( "'", "\'" ), "\'", $entry['value'] ) . '\'), ';
616
  }
@@ -628,17 +628,17 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
628
  * @param array $args - Archive Database and occurrences IDs.
629
  */
630
  public function DeleteAfterArchive( $args ) {
631
- $_wpdb = $this->getConnection();
632
  $archive_db = $args['archive_db'];
633
 
634
  $s_occurence_ids = implode( ', ', $args['occurence_ids'] );
635
 
636
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $_wpdb );
637
- $sql = 'DELETE FROM ' . $occurrence->GetTable() . ' WHERE id IN (' . $s_occurence_ids . ')';
638
  $_wpdb->query( $sql );
639
 
640
  $meta = new WSAL_Adapters_MySQL_Meta( $_wpdb );
641
- $sql = 'DELETE FROM ' . $meta->GetTable() . ' WHERE occurrence_id IN (' . $s_occurence_ids . ')';
642
  $_wpdb->query( $sql );
643
  }
644
 
@@ -696,9 +696,6 @@ class WSAL_Connector_MySQLDB extends WSAL_Connector_AbstractConnector implements
696
  $query_meta = $wpdb->query( $sql );
697
 
698
  // If both queries are successful, then return true.
699
- if ( $query_occ && $query_meta ) {
700
- return true;
701
- }
702
- return false;
703
  }
704
  }
36
  public function __construct( $connection_config = null ) {
37
  $this->connectionConfig = $connection_config;
38
  parent::__construct( 'MySQL' );
39
+ require_once $this->getAdaptersDirectory() . '/OptionAdapter.php';
40
  }
41
 
42
  /**
62
  /**
63
  * Creates a connection and returns it
64
  *
65
+ * @return wpdb Instance of WPDB.
66
  */
67
  private function createConnection() {
68
  if ( ! empty( $this->connectionConfig ) ) {
97
  */
98
  public function closeConnection() {
99
  $current_wpdb = $this->getConnection();
100
+ $result = $current_wpdb->close();
101
  return $result;
102
  }
103
 
197
  * @return integer MAX(id)
198
  */
199
  private function GetIncreaseOccurrence() {
200
+ $_wpdb = $this->getConnection();
201
  $occurrence_new = new WSAL_Adapters_MySQL_Occurrence( $_wpdb );
202
+ $sql = 'SELECT MAX(id) FROM ' . $occurrence_new->GetTable();
203
  return (int) $_wpdb->get_var( $sql );
204
  }
205
 
211
  */
212
  public function MigrateMeta( $index, $limit ) {
213
  $result = null;
214
+ $offset = ( $index * $limit );
215
  global $wpdb;
216
  $_wpdb = $this->getConnection();
217
  // Add +1 because an alert is generated after delete the metadata table.
223
  $result['empty'] = true;
224
  return $result;
225
  }
226
+ $sql = 'SELECT * FROM ' . $meta->GetWPTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
227
  $metadata = $wpdb->get_results( $sql, ARRAY_A );
228
 
229
  // Insert data to External DB.
231
  $meta_new = new WSAL_Adapters_MySQL_Meta( $_wpdb );
232
 
233
  $index++;
234
+ $sql = 'INSERT INTO ' . $meta_new->GetTable() . ' (occurrence_id, name, value) VALUES ';
235
  foreach ( $metadata as $entry ) {
236
  $occurrence_id = intval( $entry['occurrence_id'] ) + $increase_occurrence_id;
237
+ $sql .= '(' . $occurrence_id . ', \'' . $entry['name'] . '\', \'' . str_replace( array( "'", "\'" ), "\'", $entry['value'] ) . '\'), ';
238
  }
239
  $sql = rtrim( $sql, ', ' );
240
  $_wpdb->query( $sql );
256
  */
257
  public function MigrateOccurrence( $index, $limit ) {
258
  $result = null;
259
+ $offset = ( $index * $limit );
260
  global $wpdb;
261
  $_wpdb = $this->getConnection();
262
 
266
  $result['empty'] = true;
267
  return $result;
268
  }
269
+ $sql = 'SELECT * FROM ' . $occurrence->GetWPTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
270
  $occurrences = $wpdb->get_results( $sql, ARRAY_A );
271
 
272
  // Insert data to External DB.
274
  $occurrence_new = new WSAL_Adapters_MySQL_Occurrence( $_wpdb );
275
 
276
  $index++;
277
+ $sql = 'INSERT INTO ' . $occurrence_new->GetTable() . ' (site_id, alert_id, created_on, is_read) VALUES ';
278
  foreach ( $occurrences as $entry ) {
279
  $sql .= '(' . $entry['site_id'] . ', ' . $entry['alert_id'] . ', ' . $entry['created_on'] . ', ' . $entry['is_read'] . '), ';
280
  }
298
  */
299
  public function MigrateBackOccurrence( $index, $limit ) {
300
  $result = null;
301
+ $offset = ( $index * $limit );
302
  global $wpdb;
303
  $_wpdb = $this->getConnection();
304
 
308
  $result['empty'] = true;
309
  return $result;
310
  }
311
+ $sql = 'SELECT * FROM ' . $occurrence->GetTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
312
  $occurrences = $_wpdb->get_results( $sql, ARRAY_A );
313
 
314
  // Insert data to WP.
316
  $occurrence_wp = new WSAL_Adapters_MySQL_Occurrence( $wpdb );
317
 
318
  $index++;
319
+ $sql = 'INSERT INTO ' . $occurrence_wp->GetWPTable() . ' (id, site_id, alert_id, created_on, is_read) VALUES ';
320
  foreach ( $occurrences as $entry ) {
321
  $sql .= '(' . $entry['id'] . ', ' . $entry['site_id'] . ', ' . $entry['alert_id'] . ', ' . $entry['created_on'] . ', ' . $entry['is_read'] . '), ';
322
  }
339
  */
340
  public function MigrateBackMeta( $index, $limit ) {
341
  $result = null;
342
+ $offset = ( $index * $limit );
343
  global $wpdb;
344
  $_wpdb = $this->getConnection();
345
 
349
  $result['empty'] = true;
350
  return $result;
351
  }
352
+ $sql = 'SELECT * FROM ' . $meta->GetTable() . ' LIMIT ' . $limit . ' OFFSET ' . $offset;
353
  $metadata = $_wpdb->get_results( $sql, ARRAY_A );
354
 
355
  // Insert data to WP.
357
  $meta_wp = new WSAL_Adapters_MySQL_Meta( $wpdb );
358
 
359
  $index++;
360
+ $sql = 'INSERT INTO ' . $meta_wp->GetWPTable() . ' (occurrence_id, name, value) VALUES ';
361
  foreach ( $metadata as $entry ) {
362
  $sql .= '(' . $entry['occurrence_id'] . ', \'' . $entry['name'] . '\', \'' . str_replace( array( "'", "\'" ), "\'", $entry['value'] ) . '\'), ';
363
  }
539
  * @param array $args - Archive Database and limit by count OR by date.
540
  */
541
  public function ArchiveOccurrence( $args ) {
542
+ $_wpdb = $this->getConnection();
543
  $archive_db = $args['archive_db'];
544
 
545
  // Load data Occurrences from WP.
568
 
569
  // Insert data to Archive DB.
570
  if ( ! empty( $occurrences ) ) {
571
+ $last = end( $occurrences );
572
  $args['last_created_on'] = $last['created_on'];
573
+ $args['occurence_ids'] = array();
574
 
575
  $occurrence_new = new WSAL_Adapters_MySQL_Occurrence( $archive_db );
576
 
577
+ $sql = 'INSERT INTO ' . $occurrence_new->GetTable() . ' (id, site_id, alert_id, created_on, is_read) VALUES ';
578
  foreach ( $occurrences as $entry ) {
579
+ $sql .= '(' . $entry['id'] . ', ' . $entry['site_id'] . ', ' . $entry['alert_id'] . ', ' . $entry['created_on'] . ', ' . $entry['is_read'] . '), ';
580
  $args['occurence_ids'][] = $entry['id'];
581
  }
582
  $sql = rtrim( $sql, ', ' );
594
  * @param array $args - Archive Database and occurrences IDs.
595
  */
596
  public function ArchiveMeta( $args ) {
597
+ $_wpdb = $this->getConnection();
598
  $archive_db = $args['archive_db'];
599
 
600
  // Load data Meta from WP.
603
  return null;
604
  }
605
  $s_occurence_ids = implode( ', ', $args['occurence_ids'] );
606
+ $sql = 'SELECT * FROM ' . $meta->GetTable() . ' WHERE occurrence_id IN (' . $s_occurence_ids . ')';
607
+ $metadata = $_wpdb->get_results( $sql, ARRAY_A );
608
 
609
  // Insert data to Archive DB.
610
  if ( ! empty( $metadata ) ) {
611
  $meta_new = new WSAL_Adapters_MySQL_Meta( $archive_db );
612
 
613
+ $sql = 'INSERT INTO ' . $meta_new->GetTable() . ' (occurrence_id, name, value) VALUES ';
614
  foreach ( $metadata as $entry ) {
615
  $sql .= '(' . $entry['occurrence_id'] . ', \'' . $entry['name'] . '\', \'' . str_replace( array( "'", "\'" ), "\'", $entry['value'] ) . '\'), ';
616
  }
628
  * @param array $args - Archive Database and occurrences IDs.
629
  */
630
  public function DeleteAfterArchive( $args ) {
631
+ $_wpdb = $this->getConnection();
632
  $archive_db = $args['archive_db'];
633
 
634
  $s_occurence_ids = implode( ', ', $args['occurence_ids'] );
635
 
636
  $occurrence = new WSAL_Adapters_MySQL_Occurrence( $_wpdb );
637
+ $sql = 'DELETE FROM ' . $occurrence->GetTable() . ' WHERE id IN (' . $s_occurence_ids . ')';
638
  $_wpdb->query( $sql );
639
 
640
  $meta = new WSAL_Adapters_MySQL_Meta( $_wpdb );
641
+ $sql = 'DELETE FROM ' . $meta->GetTable() . ' WHERE occurrence_id IN (' . $s_occurence_ids . ')';
642
  $_wpdb->query( $sql );
643
  }
644
 
696
  $query_meta = $wpdb->query( $sql );
697
 
698
  // If both queries are successful, then return true.
699
+ return $query_occ && $query_meta;
 
 
 
700
  }
701
  }
classes/Models/ActiveRecord.php CHANGED
@@ -184,7 +184,7 @@ abstract class WSAL_Models_ActiveRecord {
184
  case is_array( $copy->$key ):
185
  case is_object( $copy->$key ):
186
  $json_decoded_val = WSAL_Helpers_DataHelper::JsonDecode( $val );
187
- $this->$key = ( null == $json_decoded_val ) ? $val : $json_decoded_val;
188
  break;
189
  case is_int( $copy->$key ):
190
  $this->$key = (int) $val;
@@ -220,10 +220,10 @@ abstract class WSAL_Models_ActiveRecord {
220
  $this->created_on = $this->GetMicrotime();
221
  }
222
  $update_id = $this->getId();
223
- $result = $this->getAdapter()->Save( $this );
224
 
225
  if ( false !== $result ) {
226
- $this->_state = ( ! empty( $update_id )) ? self::STATE_UPDATED : self::STATE_CREATED;
227
  }
228
  return $result;
229
  }
@@ -236,7 +236,7 @@ abstract class WSAL_Models_ActiveRecord {
236
  */
237
  public function Delete() {
238
  $this->_state = self::STATE_UNKNOWN;
239
- $result = $this->getAdapter()->Delete( $this );
240
  if ( false !== $result ) {
241
  $this->_state = self::STATE_DELETED;
242
  }
@@ -362,13 +362,13 @@ abstract class WSAL_Models_ActiveRecord {
362
  * Function used in WSAL reporting extension.
363
  *
364
  * @see WSAL_Adapters_MySQL_ActiveRecord::GetReporting()
365
- * @param int $_site_id - Site ID.
366
- * @param int $_user_id - User ID.
367
- * @param string $_role_name - User role.
368
- * @param int $_alert_code - Alert code.
369
- * @param timestamp $_start_timestamp - From created_on.
370
- * @param timestamp $_end_timestamp - To created_on.
371
- * @return array - Report results.
372
  */
373
  public function GetReporting( $_site_id, $_user_id, $_role_name, $_alert_code, $_start_timestamp, $_end_timestamp ) {
374
  return $this->getAdapter()->GetReporting( $_site_id, $_user_id, $_role_name, $_alert_code, $_start_timestamp, $_end_timestamp );
184
  case is_array( $copy->$key ):
185
  case is_object( $copy->$key ):
186
  $json_decoded_val = WSAL_Helpers_DataHelper::JsonDecode( $val );
187
+ $this->$key = ( null == $json_decoded_val ) ? $val : $json_decoded_val;
188
  break;
189
  case is_int( $copy->$key ):
190
  $this->$key = (int) $val;
220
  $this->created_on = $this->GetMicrotime();
221
  }
222
  $update_id = $this->getId();
223
+ $result = $this->getAdapter()->Save( $this );
224
 
225
  if ( false !== $result ) {
226
+ $this->_state = ( ! empty( $update_id ) ) ? self::STATE_UPDATED : self::STATE_CREATED;
227
  }
228
  return $result;
229
  }
236
  */
237
  public function Delete() {
238
  $this->_state = self::STATE_UNKNOWN;
239
+ $result = $this->getAdapter()->Delete( $this );
240
  if ( false !== $result ) {
241
  $this->_state = self::STATE_DELETED;
242
  }
362
  * Function used in WSAL reporting extension.
363
  *
364
  * @see WSAL_Adapters_MySQL_ActiveRecord::GetReporting()
365
+ * @param int $_site_id - Site ID.
366
+ * @param int $_user_id - User ID.
367
+ * @param string $_role_name - User role.
368
+ * @param int $_alert_code - Alert code.
369
+ * @param int $_start_timestamp - From created_on.
370
+ * @param int $_end_timestamp - To created_on.
371
+ * @return array Report results.
372
  */
373
  public function GetReporting( $_site_id, $_user_id, $_role_name, $_alert_code, $_start_timestamp, $_end_timestamp ) {
374
  return $this->getAdapter()->GetReporting( $_site_id, $_user_id, $_role_name, $_alert_code, $_start_timestamp, $_end_timestamp );
classes/Sensors/Content.php CHANGED
@@ -802,16 +802,16 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
802
  * @param integer $post_id - Post ID.
803
  */
804
  public function EventPublishFuture( $post_id ) {
805
- $post = get_post( $post_id );
806
  $editor_link = $this->GetEditorLink( $post );
807
  $this->plugin->alerts->Trigger(
808
  2001, array(
809
- 'PostID' => $post->ID,
810
- 'PostType' => $post->post_type,
811
- 'PostTitle' => $post->post_title,
812
- 'PostStatus' => $post->post_status,
813
- 'PostDate' => $post->post_date,
814
- 'PostUrl' => get_permalink( $post->ID ),
815
  $editor_link['name'] => $editor_link['value'],
816
  )
817
  );
@@ -916,12 +916,12 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
916
  $editor_link = $this->GetEditorLink( $post );
917
  $this->plugin->alerts->Trigger(
918
  2014, array(
919
- 'PostID' => $post->ID,
920
- 'PostType' => $post->post_type,
921
- 'PostTitle' => $post->post_title,
922
- 'PostStatus' => $post->post_status,
923
- 'PostDate' => $post->post_date,
924
- 'PostUrl' => get_permalink( $post->ID ),
925
  $editor_link['name'] => $editor_link['value'],
926
  )
927
  );
@@ -1261,15 +1261,15 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1261
  $editor_link = $this->GetEditorLink( $oldpost );
1262
  $this->plugin->alerts->Trigger(
1263
  $event, array(
1264
- 'PostID' => $oldpost->ID,
1265
- 'PostType' => $oldpost->post_type,
1266
- 'PostTitle' => $oldpost->post_title,
1267
- 'PostStatus' => $oldpost->post_status,
1268
- 'PostDate' => $oldpost->post_date,
1269
- 'OldParent' => $oldpost->post_parent,
1270
- 'NewParent' => $newpost->post_parent,
1271
- 'OldParentName' => $oldpost->post_parent ? get_the_title( $oldpost->post_parent ) : 'no parent',
1272
- 'NewParentName' => $newpost->post_parent ? get_the_title( $newpost->post_parent ) : 'no parent',
1273
  $editor_link['name'] => $editor_link['value'],
1274
  )
1275
  );
@@ -1290,15 +1290,15 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1290
  $editor_link = $this->GetEditorLink( $post );
1291
  $this->plugin->alerts->Trigger(
1292
  2017, array(
1293
- 'PostID' => $post->ID,
1294
- 'PostType' => $post->post_type,
1295
- 'PostTitle' => $post->post_title,
1296
- 'PostStatus' => $post->post_status,
1297
- 'PostDate' => $post->post_date,
1298
- 'OldUrl' => $old_link,
1299
- 'NewUrl' => $new_link,
1300
  $editor_link['name'] => $editor_link['value'],
1301
- 'ReportText' => '"' . $old_link . '"|"' . $new_link . '"',
1302
  )
1303
  );
1304
  return 1;
@@ -1338,18 +1338,18 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1338
  $new_visibility = __( 'Private', 'wp-security-audit-log' );
1339
  }
1340
 
1341
- if ( $old_visibility && $new_visibility && ($old_visibility != $new_visibility) ) {
1342
  $editor_link = $this->GetEditorLink( $oldpost );
1343
  $this->plugin->alerts->Trigger(
1344
  2025, array(
1345
- 'PostID' => $oldpost->ID,
1346
- 'PostType' => $oldpost->post_type,
1347
- 'PostTitle' => $oldpost->post_title,
1348
- 'PostStatus' => $newpost->post_status,
1349
- 'PostDate' => $oldpost->post_date,
1350
- 'PostUrl' => get_permalink( $oldpost->ID ),
1351
- 'OldVisibility' => $old_visibility,
1352
- 'NewVisibility' => $new_visibility,
1353
  $editor_link['name'] => $editor_link['value'],
1354
  )
1355
  );
@@ -1371,15 +1371,15 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1371
  $editor_link = $this->GetEditorLink( $post );
1372
  $this->plugin->alerts->Trigger(
1373
  $event, array(
1374
- 'PostID' => $post->ID,
1375
- 'PostType' => $post->post_type,
1376
- 'PostTitle' => $post->post_title,
1377
- 'PostStatus' => $post->post_status,
1378
- 'PostDate' => $post->post_date,
1379
- 'OldTemplate' => ucwords( str_replace( array( '-', '_' ), ' ', basename( $old_tmpl, '.php' ) ) ),
1380
- 'NewTemplate' => ucwords( str_replace( array( '-', '_' ), ' ', basename( $new_tmpl, '.php' ) ) ),
1381
- 'OldTemplatePath' => $old_tmpl,
1382
- 'NewTemplatePath' => $new_tmpl,
1383
  $editor_link['name'] => $editor_link['value'],
1384
  )
1385
  );
@@ -1530,15 +1530,15 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1530
  protected function CheckCategoryDeletion() {
1531
  // Set filter input args.
1532
  $filter_input_args = array(
1533
- '_wpnonce' => FILTER_SANITIZE_STRING,
1534
- 'action' => FILTER_SANITIZE_STRING,
1535
- 'action2' => FILTER_SANITIZE_STRING,
1536
- 'taxonomy' => FILTER_SANITIZE_STRING,
1537
  'delete_tags' => array(
1538
  'filter' => FILTER_SANITIZE_STRING,
1539
  'flags' => FILTER_REQUIRE_ARRAY,
1540
  ),
1541
- 'tag_ID' => FILTER_VALIDATE_INT,
1542
  );
1543
 
1544
  // Filter $_POST array for security.
@@ -1548,7 +1548,7 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1548
  return;
1549
  }
1550
  $action = ! empty( $post_array['action'] ) ? $post_array['action']
1551
- : ( ! empty( $post_array['action2'] ) ? $post_array['action2'] : '');
1552
  if ( ! $action ) {
1553
  return;
1554
  }
@@ -1574,13 +1574,13 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1574
  }
1575
 
1576
  foreach ( $category_ids as $category_id ) {
1577
- $category = get_category( $category_id );
1578
  $category_link = $this->getCategoryLink( $category_id );
1579
  $this->plugin->alerts->Trigger(
1580
  2024, array(
1581
- 'CategoryID' => $category_id,
1582
  'CategoryName' => $category->cat_name,
1583
- 'Slug' => $category->slug,
1584
  'CategoryLink' => $category_link,
1585
  )
1586
  );
@@ -1626,9 +1626,9 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1626
  // Set filter input args.
1627
  $filter_input_args = array(
1628
  '_wpnonce' => FILTER_SANITIZE_STRING,
1629
- 'name' => FILTER_SANITIZE_STRING,
1630
- 'parent' => FILTER_SANITIZE_STRING,
1631
- 'tag_ID' => FILTER_VALIDATE_INT,
1632
  );
1633
 
1634
  // Filter $_POST array for security.
@@ -1644,25 +1644,25 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1644
  && isset( $post_array['name'] )
1645
  && isset( $post_array['tag_ID'] )
1646
  && wp_verify_nonce( $post_array['_wpnonce'], 'update-tag_' . $post_array['tag_ID'] ) ) {
1647
- $category = get_category( $post_array['tag_ID'] );
1648
  $category_link = $this->getCategoryLink( $post_array['tag_ID'] );
1649
  if ( 0 != $category->parent ) {
1650
- $old_parent = get_category( $category->parent );
1651
- $old_parent_name = (empty( $old_parent )) ? 'no parent' : $old_parent->name;
1652
  } else {
1653
  $old_parent_name = 'no parent';
1654
  }
1655
  if ( isset( $post_array['parent'] ) ) {
1656
- $new_parent = get_category( $post_array['parent'] );
1657
- $new_parent_name = (empty( $new_parent )) ? 'no parent' : $new_parent->name;
1658
  }
1659
 
1660
  if ( $old_parent_name !== $new_parent_name ) {
1661
  $this->plugin->alerts->Trigger(
1662
  2052, array(
1663
  'CategoryName' => $category->name,
1664
- 'OldParent' => $old_parent_name,
1665
- 'NewParent' => $new_parent_name,
1666
  'CategoryLink' => $category_link,
1667
  )
1668
  );
@@ -1680,14 +1680,9 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1680
  private function CheckAutoDraft( $code, $title ) {
1681
  if ( 2008 == $code && 'auto-draft' == $title ) {
1682
  // To do: Check setting else return false.
1683
- if ( 1 == $this->plugin->settings->IsWPBackend() ) {
1684
- return true;
1685
- } else {
1686
- return false;
1687
- }
1688
- } else {
1689
- return false;
1690
  }
 
1691
  }
1692
 
1693
  /**
@@ -1699,9 +1694,8 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1699
  private function getRevisionLink( $revision_id ) {
1700
  if ( ! empty( $revision_id ) ) {
1701
  return admin_url( 'revision.php?revision=' . $revision_id );
1702
- } else {
1703
- return null;
1704
  }
 
1705
  }
1706
 
1707
  /**
@@ -1936,7 +1930,7 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1936
  * @param stdClass $newpost - New post.
1937
  */
1938
  private function CheckCommentsPings( $oldpost, $newpost ) {
1939
- $result = 0;
1940
  $editor_link = $this->GetEditorLink( $newpost );
1941
 
1942
  // Comments.
@@ -1951,14 +1945,13 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1951
 
1952
  $this->plugin->alerts->Trigger(
1953
  $event, array(
1954
- 'Type' => $type,
1955
- 'PostID' => $newpost->ID,
1956
- 'PostType' => $newpost->post_type,
1957
- 'PostStatus' => $newpost->post_status,
1958
- 'PostDate' => $newpost->post_date,
1959
- 'PostTitle' => $newpost->post_title,
1960
- 'PostStatus' => $newpost->post_status,
1961
- 'PostUrl' => get_permalink( $newpost->ID ),
1962
  $editor_link['name'] => $editor_link['value'],
1963
  )
1964
  );
@@ -1976,13 +1969,13 @@ class WSAL_Sensors_Content extends WSAL_AbstractSensor {
1976
 
1977
  $this->plugin->alerts->Trigger(
1978
  $event, array(
1979
- 'Type' => $type,
1980
- 'PostID' => $newpost->ID,
1981
- 'PostType' => $newpost->post_type,
1982
- 'PostTitle' => $newpost->post_title,
1983
- 'PostStatus' => $newpost->post_status,
1984
- 'PostDate' => $newpost->post_date,
1985
- 'PostUrl' => get_permalink( $newpost->ID ),
1986
  $editor_link['name'] => $editor_link['value'],
1987
  )
1988
  );
802
  * @param integer $post_id - Post ID.
803
  */
804
  public function EventPublishFuture( $post_id ) {
805
+ $post = get_post( $post_id );
806
  $editor_link = $this->GetEditorLink( $post );
807
  $this->plugin->alerts->Trigger(
808
  2001, array(
809
+ 'PostID' => $post->ID,
810
+ 'PostType' => $post->post_type,
811
+ 'PostTitle' => $post->post_title,
812
+ 'PostStatus' => $post->post_status,
813
+ 'PostDate' => $post->post_date,
814
+ 'PostUrl' => get_permalink( $post->ID ),
815
  $editor_link['name'] => $editor_link['value'],
816
  )
817
  );
916
  $editor_link = $this->GetEditorLink( $post );
917
  $this->plugin->alerts->Trigger(
918
  2014, array(
919
+ 'PostID' => $post->ID,
920
+ 'PostType' => $post->post_type,
921
+ 'PostTitle' => $post->post_title,
922
+ 'PostStatus' => $post->post_status,
923
+ 'PostDate' => $post->post_date,
924
+ 'PostUrl' => get_permalink( $post->ID ),
925
  $editor_link['name'] => $editor_link['value'],
926
  )
927
  );
1261
  $editor_link = $this->GetEditorLink( $oldpost );
1262
  $this->plugin->alerts->Trigger(
1263
  $event, array(
1264
+ 'PostID' => $oldpost->ID,
1265
+ 'PostType' => $oldpost->post_type,
1266
+ 'PostTitle' => $oldpost->post_title,
1267
+ 'PostStatus' => $oldpost->post_status,
1268
+ 'PostDate' => $oldpost->post_date,
1269
+ 'OldParent' => $oldpost->post_parent,
1270
+ 'NewParent' => $newpost->post_parent,
1271
+ 'OldParentName' => $oldpost->post_parent ? get_the_title( $oldpost->post_parent ) : 'no parent',
1272
+ 'NewParentName' => $newpost->post_parent ? get_the_title( $newpost->post_parent ) : 'no parent',
1273
  $editor_link['name'] => $editor_link['value'],
1274
  )
1275
  );
1290
  $editor_link = $this->GetEditorLink( $post );
1291
  $this->plugin->alerts->Trigger(
1292
  2017, array(
1293
+ 'PostID' => $post->ID,
1294
+ 'PostType' => $post->post_type,
1295
+ 'PostTitle' => $post->post_title,
1296
+ 'PostStatus' => $post->post_status,
1297
+ 'PostDate' => $post->post_date,
1298
+ 'OldUrl' => $old_link,
1299
+ 'NewUrl' => $new_link,
1300
  $editor_link['name'] => $editor_link['value'],
1301
+ 'ReportText' => '"' . $old_link . '"|"' . $new_link . '"',
1302
  )
1303
  );
1304
  return 1;
1338
  $new_visibility = __( 'Private', 'wp-security-audit-log' );
1339
  }
1340
 
1341
+ if ( $old_visibility && $new_visibility && ( $old_visibility != $new_visibility ) ) {
1342
  $editor_link = $this->GetEditorLink( $oldpost );
1343
  $this->plugin->alerts->Trigger(
1344
  2025, array(
1345
+ 'PostID' => $oldpost->ID,
1346
+ 'PostType' => $oldpost->post_type,
1347
+ 'PostTitle' => $oldpost->post_title,
1348
+ 'PostStatus' => $newpost->post_status,
1349
+ 'PostDate' => $oldpost->post_date,
1350
+ 'PostUrl' => get_permalink( $oldpost->ID ),
1351
+ 'OldVisibility' => $old_visibility,
1352
+ 'NewVisibility' => $new_visibility,
1353
  $editor_link['name'] => $editor_link['value'],
1354
  )
1355
  );
1371
  $editor_link = $this->GetEditorLink( $post );
1372
  $this->plugin->alerts->Trigger(
1373
  $event, array(
1374
+ 'PostID' => $post->ID,
1375
+ 'PostType' => $post->post_type,
1376
+ 'PostTitle' => $post->post_title,
1377
+ 'PostStatus' => $post->post_status,
1378
+ 'PostDate' => $post->post_date,
1379
+ 'OldTemplate' => ucwords( str_replace( array( '-', '_' ), ' ', basename( $old_tmpl, '.php' ) ) ),
1380
+ 'NewTemplate' => ucwords( str_replace( array( '-', '_' ), ' ', basename( $new_tmpl, '.php' ) ) ),
1381
+ 'OldTemplatePath' => $old_tmpl,
1382
+ 'NewTemplatePath' => $new_tmpl,
1383
  $editor_link['name'] => $editor_link['value'],
1384
  )
1385
  );
1530
  protected function CheckCategoryDeletion() {
1531
  // Set filter input args.
1532
  $filter_input_args = array(
1533
+ '_wpnonce' => FILTER_SANITIZE_STRING,
1534
+ 'action' => FILTER_SANITIZE_STRING,
1535
+ 'action2' => FILTER_SANITIZE_STRING,
1536
+ 'taxonomy' => FILTER_SANITIZE_STRING,
1537
  'delete_tags' => array(
1538
  'filter' => FILTER_SANITIZE_STRING,
1539
  'flags' => FILTER_REQUIRE_ARRAY,
1540
  ),
1541
+ 'tag_ID' => FILTER_VALIDATE_INT,
1542
  );
1543
 
1544
  // Filter $_POST array for security.
1548
  return;
1549
  }
1550
  $action = ! empty( $post_array['action'] ) ? $post_array['action']
1551
+ : ( ! empty( $post_array['action2'] ) ? $post_array['action2'] : '' );
1552
  if ( ! $action ) {
1553
  return;
1554
  }
1574
  }
1575
 
1576
  foreach ( $category_ids as $category_id ) {
1577
+ $category = get_category( $category_id );
1578
  $category_link = $this->getCategoryLink( $category_id );
1579
  $this->plugin->alerts->Trigger(
1580
  2024, array(
1581
+ 'CategoryID' => $category_id,
1582
  'CategoryName' => $category->cat_name,
1583
+ 'Slug' => $category->slug,
1584
  'CategoryLink' => $category_link,
1585
  )
1586
  );
1626
  // Set filter input args.
1627
  $filter_input_args = array(
1628
  '_wpnonce' => FILTER_SANITIZE_STRING,
1629
+ 'name' => FILTER_SANITIZE_STRING,
1630
+ 'parent' => FILTER_SANITIZE_STRING,
1631
+ 'tag_ID' => FILTER_VALIDATE_INT,
1632
  );
1633
 
1634
  // Filter $_POST array for security.
1644
  && isset( $post_array['name'] )
1645
  && isset( $post_array['tag_ID'] )
1646
  && wp_verify_nonce( $post_array['_wpnonce'], 'update-tag_' . $post_array['tag_ID'] ) ) {
1647
+ $category = get_category( $post_array['tag_ID'] );
1648
  $category_link = $this->getCategoryLink( $post_array['tag_ID'] );
1649
  if ( 0 != $category->parent ) {
1650
+ $old_parent = get_category( $category->parent );
1651
+ $old_parent_name = ( empty( $old_parent ) ) ? 'no parent' : $old_parent->name;
1652
  } else {
1653
  $old_parent_name = 'no parent';
1654
  }
1655
  if ( isset( $post_array['parent'] ) ) {
1656
+ $new_parent = get_category( $post_array['parent'] );
1657
+ $new_parent_name = ( empty( $new_parent ) ) ? 'no parent' : $new_parent->name;
1658
  }
1659
 
1660
  if ( $old_parent_name !== $new_parent_name ) {
1661
  $this->plugin->alerts->Trigger(
1662
  2052, array(
1663
  'CategoryName' => $category->name,
1664
+ 'OldParent' => $old_parent_name,
1665
+ 'NewParent' => $new_parent_name,
1666
  'CategoryLink' => $category_link,
1667
  )
1668
  );
1680
  private function CheckAutoDraft( $code, $title ) {
1681
  if ( 2008 == $code && 'auto-draft' == $title ) {
1682
  // To do: Check setting else return false.
1683
+ return 1 == $this->plugin->settings->IsWPBackend();
 
 
 
 
 
 
1684
  }
1685
+ return false;
1686
  }
1687
 
1688
  /**
1694
  private function getRevisionLink( $revision_id ) {
1695
  if ( ! empty( $revision_id ) ) {
1696
  return admin_url( 'revision.php?revision=' . $revision_id );
 
 
1697
  }
1698
+ return null;
1699
  }
1700
 
1701
  /**
1930
  * @param stdClass $newpost - New post.
1931
  */
1932
  private function CheckCommentsPings( $oldpost, $newpost ) {
1933
+ $result = 0;
1934
  $editor_link = $this->GetEditorLink( $newpost );
1935
 
1936
  // Comments.
1945
 
1946
  $this->plugin->alerts->Trigger(
1947
  $event, array(
1948
+ 'Type' => $type,
1949
+ 'PostID' => $newpost->ID,
1950
+ 'PostType' => $newpost->post_type,
1951
+ 'PostStatus' => $newpost->post_status,
1952
+ 'PostDate' => $newpost->post_date,
1953
+ 'PostTitle' => $newpost->post_title,
1954
+ 'PostUrl' => get_permalink( $newpost->ID ),
 
1955
  $editor_link['name'] => $editor_link['value'],
1956
  )
1957
  );
1969
 
1970
  $this->plugin->alerts->Trigger(
1971
  $event, array(
1972
+ 'Type' => $type,
1973
+ 'PostID' => $newpost->ID,
1974
+ 'PostType' => $newpost->post_type,
1975
+ 'PostTitle' => $newpost->post_title,
1976
+ 'PostStatus' => $newpost->post_status,
1977
+ 'PostDate' => $newpost->post_date,
1978
+ 'PostUrl' => get_permalink( $newpost->ID ),
1979
  $editor_link['name'] => $editor_link['value'],
1980
  )
1981
  );
classes/Sensors/Database.php CHANGED
@@ -60,13 +60,14 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
60
  $alert_options = $this->GetActionType( $actype );
61
  $type_query = 'delete';
62
  } elseif ( preg_match( '|CREATE TABLE IF NOT EXISTS ([^ ]*)|', $query ) ) {
63
- if ( $str[5] !== $wpdb->get_var( "SHOW TABLES LIKE '" . $str[5] . "'" ) ) {
 
64
  /**
65
  * Some plugins keep trying to create tables even
66
  * when they already exist- would result in too
67
  * many alerts.
68
  */
69
- array_push( $table_names, $str[5] );
70
  $actype = isset( $_SERVER['SCRIPT_NAME'] ) ? basename( sanitize_text_field( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ), '.php' ) : false;
71
  $alert_options = $this->GetActionType( $actype );
72
  $type_query = 'create';
@@ -95,9 +96,10 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
95
  global $wpdb;
96
 
97
  foreach ( $queries as $qry ) {
 
98
  $str = explode( ' ', $qry );
99
  if ( preg_match( '|CREATE TABLE ([^ ]*)|', $qry ) ) {
100
- if ( $wpdb->get_var( "SHOW TABLES LIKE '" . $str[2] . "'" ) != $str[2] ) {
101
  /**
102
  * Some plugins keep trying to create tables even
103
  * when they already exist- would result in too
@@ -147,7 +149,8 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
147
  } elseif ( 'delete' === $type_query ) {
148
  return 5012;
149
  }
150
- // In case of plugins.
 
151
  case 'themes':
152
  if ( 'create' === $type_query ) {
153
  return 5013;
@@ -156,7 +159,8 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
156
  } elseif ( 'delete' === $type_query ) {
157
  return 5015;
158
  }
159
- // In case of themes.
 
160
  default:
161
  if ( 'create' === $type_query ) {
162
  return 5016;
@@ -165,6 +169,7 @@ class WSAL_Sensors_Database extends WSAL_AbstractSensor {
165
  } elseif ( 'delete' === $type_query ) {
166
  return 5018;
167
  }
 
168
  }
169
  }
170
 
60
  $alert_options = $this->GetActionType( $actype );
61
  $type_query = 'delete';
62
  } elseif ( preg_match( '|CREATE TABLE IF NOT EXISTS ([^ ]*)|', $query ) ) {
63
+ $table_name = str_replace( '`', '', $str[5] );
64
+ if ( $table_name !== $wpdb->get_var( "SHOW TABLES LIKE '" . $table_name . "'" ) ) {
65
  /**
66
  * Some plugins keep trying to create tables even
67
  * when they already exist- would result in too
68
  * many alerts.
69
  */
70
+ array_push( $table_names, $table_name );
71
  $actype = isset( $_SERVER['SCRIPT_NAME'] ) ? basename( sanitize_text_field( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ), '.php' ) : false;
72
  $alert_options = $this->GetActionType( $actype );
73
  $type_query = 'create';
96
  global $wpdb;
97
 
98
  foreach ( $queries as $qry ) {
99
+ $qry = str_replace( '`', '', $qry );
100
  $str = explode( ' ', $qry );
101
  if ( preg_match( '|CREATE TABLE ([^ ]*)|', $qry ) ) {
102
+ if ( $str[2] !== $wpdb->get_var( "SHOW TABLES LIKE '" . $str[2] . "'" ) ) {
103
  /**
104
  * Some plugins keep trying to create tables even
105
  * when they already exist- would result in too
149
  } elseif ( 'delete' === $type_query ) {
150
  return 5012;
151
  }
152
+ break;
153
+
154
  case 'themes':
155
  if ( 'create' === $type_query ) {
156
  return 5013;
159
  } elseif ( 'delete' === $type_query ) {
160
  return 5015;
161
  }
162
+ break;
163
+
164
  default:
165
  if ( 'create' === $type_query ) {
166
  return 5016;
169
  } elseif ( 'delete' === $type_query ) {
170
  return 5018;
171
  }
172
+ break;
173
  }
174
  }
175
 
classes/Sensors/PluginsThemes.php CHANGED
@@ -125,9 +125,9 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
125
  public function mainwp_child_init() {
126
  // $_POST array arguments.
127
  $post_array_args = array(
128
- 'function' => FILTER_SANITIZE_STRING,
129
- 'action' => FILTER_SANITIZE_STRING,
130
- 'theme' => FILTER_SANITIZE_STRING,
131
  'mainwpsignature' => FILTER_SANITIZE_STRING,
132
  );
133
 
@@ -179,18 +179,19 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
179
  if ( in_array( $action, array( 'install-plugin', 'upload-plugin' ) ) && current_user_can( 'install_plugins' ) ) {
180
  $plugin = array_values( array_diff( array_keys( get_plugins() ), array_keys( $this->old_plugins ) ) );
181
  if ( count( $plugin ) != 1 ) {
182
- return $this->LogError(
183
  'Expected exactly one new plugin but found ' . count( $plugin ),
184
  array(
185
- 'NewPlugin' => $plugin,
186
  'OldPlugins' => $this->old_plugins,
187
  'NewPlugins' => get_plugins(),
188
  )
189
  );
 
190
  }
191
  $plugin_path = $plugin[0];
192
- $plugin = get_plugins();
193
- $plugin = $plugin[ $plugin_path ];
194
 
195
  // Get plugin directory name.
196
  $plugin_dir = $this->get_plugin_dir( $plugin_path );
@@ -202,11 +203,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
202
  $this->plugin->alerts->Trigger(
203
  5000, array(
204
  'Plugin' => (object) array(
205
- 'Name' => $plugin['Name'],
206
- 'PluginURI' => $plugin['PluginURI'],
207
- 'Version' => $plugin['Version'],
208
- 'Author' => $plugin['Author'],
209
- 'Network' => $plugin['Network'] ? 'True' : 'False',
210
  'plugin_dir_path' => $plugin_path,
211
  ),
212
  )
@@ -239,11 +240,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
239
  5001, array(
240
  'PluginFile' => $plugin_file,
241
  'PluginData' => (object) array(
242
- 'Name' => $plugin_data['Name'],
243
  'PluginURI' => $plugin_data['PluginURI'],
244
- 'Version' => $plugin_data['Version'],
245
- 'Author' => $plugin_data['Author'],
246
- 'Network' => $plugin_data['Network'] ? 'True' : 'False',
247
  ),
248
  )
249
  );
@@ -256,11 +257,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
256
  5001, array(
257
  'PluginFile' => $plugin_file,
258
  'PluginData' => (object) array(
259
- 'Name' => $plugin_data['Name'],
260
  'PluginURI' => $plugin_data['PluginURI'],
261
- 'Version' => $plugin_data['Version'],
262
- 'Author' => $plugin_data['Author'],
263
- 'Network' => $plugin_data['Network'] ? 'True' : 'False',
264
  ),
265
  )
266
  );
@@ -294,11 +295,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
294
  5002, array(
295
  'PluginFile' => $plugin_file,
296
  'PluginData' => (object) array(
297
- 'Name' => $plugin_data['Name'],
298
  'PluginURI' => $plugin_data['PluginURI'],
299
- 'Version' => $plugin_data['Version'],
300
- 'Author' => $plugin_data['Author'],
301
- 'Network' => $plugin_data['Network'] ? 'True' : 'False',
302
  ),
303
  )
304
  );
@@ -311,11 +312,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
311
  5002, array(
312
  'PluginFile' => $plugin_file,
313
  'PluginData' => (object) array(
314
- 'Name' => $plugin_data['Name'],
315
  'PluginURI' => $plugin_data['PluginURI'],
316
- 'Version' => $plugin_data['Version'],
317
- 'Author' => $plugin_data['Author'],
318
- 'Network' => $plugin_data['Network'] ? 'True' : 'False',
319
  ),
320
  )
321
  );
@@ -406,11 +407,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
406
  5004, array(
407
  'PluginFile' => $plugin_file,
408
  'PluginData' => (object) array(
409
- 'Name' => $plugin_data['Name'],
410
  'PluginURI' => $plugin_data['PluginURI'],
411
- 'Version' => $plugin_data['Version'],
412
- 'Author' => $plugin_data['Author'],
413
- 'Network' => $plugin_data['Network'] ? 'True' : 'False',
414
  ),
415
  )
416
  );
@@ -442,11 +443,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
442
  $this->plugin->alerts->Trigger(
443
  5031, array(
444
  'Theme' => (object) array(
445
- 'Name' => $theme->Name,
446
- 'ThemeURI' => $theme->ThemeURI,
447
- 'Description' => $theme->Description,
448
- 'Author' => $theme->Author,
449
- 'Version' => $theme->Version,
450
  'get_template_directory' => $theme->get_template_directory(),
451
  ),
452
  )
@@ -465,11 +466,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
465
  $this->plugin->alerts->Trigger(
466
  5005, array(
467
  'Theme' => (object) array(
468
- 'Name' => $theme->Name,
469
- 'ThemeURI' => $theme->ThemeURI,
470
- 'Description' => $theme->Description,
471
- 'Author' => $theme->Author,
472
- 'Version' => $theme->Version,
473
  'get_template_directory' => $theme->get_template_directory(),
474
  ),
475
  )
@@ -485,11 +486,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
485
  $this->plugin->alerts->Trigger(
486
  5007, array(
487
  'Theme' => (object) array(
488
- 'Name' => $theme->Name,
489
- 'ThemeURI' => $theme->ThemeURI,
490
- 'Description' => $theme->Description,
491
- 'Author' => $theme->Author,
492
- 'Version' => $theme->Version,
493
  'get_template_directory' => $theme->get_template_directory(),
494
  ),
495
  )
@@ -518,22 +519,23 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
518
  }
519
  }
520
  if ( null == $theme ) {
521
- return $this->LogError(
522
  'Could not locate theme named "' . $theme . '".',
523
  array(
524
  'ThemeName' => $theme_name,
525
- 'Themes' => wp_get_themes(),
526
  )
527
  );
 
528
  }
529
  $this->plugin->alerts->Trigger(
530
  5006, array(
531
  'Theme' => (object) array(
532
- 'Name' => $theme->Name,
533
- 'ThemeURI' => $theme->ThemeURI,
534
- 'Description' => $theme->Description,
535
- 'Author' => $theme->Author,
536
- 'Version' => $theme->Version,
537
  'get_template_directory' => $theme->get_template_directory(),
538
  ),
539
  )
@@ -720,11 +722,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
720
  $this->plugin->alerts->Trigger(
721
  5005, array(
722
  'Theme' => (object) array(
723
- 'Name' => $theme_obj->Name,
724
- 'ThemeURI' => $theme_obj->ThemeURI,
725
- 'Description' => $theme_obj->Description,
726
- 'Author' => $theme_obj->Author,
727
- 'Version' => $theme_obj->Version,
728
  'get_template_directory' => $theme_obj->get_template_directory(),
729
  ),
730
  )
@@ -981,11 +983,11 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
981
  $this->plugin->alerts->Trigger(
982
  5031, array(
983
  'Theme' => (object) array(
984
- 'Name' => $theme->Name,
985
- 'ThemeURI' => $theme->ThemeURI,
986
- 'Description' => $theme->Description,
987
- 'Author' => $theme->Author,
988
- 'Version' => $theme->Version,
989
  'get_template_directory' => $theme->get_template_directory(),
990
  ),
991
  )
@@ -1061,9 +1063,9 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1061
  * @return array $editor_link name and value link.
1062
  */
1063
  private function GetEditorLink( $post ) {
1064
- $name = 'EditorLink';
1065
- $name .= ( 'page' == $post->post_type ) ? 'Page' : 'Post' ;
1066
- $value = get_edit_post_link( $post->ID );
1067
  $editor_link = array(
1068
  'name' => $name,
1069
  'value' => $value,
@@ -1119,18 +1121,18 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1119
  */
1120
  if ( false === $this->site_content ) {
1121
  $this->site_content = new stdClass(); // New stdClass object.
1122
- $plugins = $this->get_site_plugins(); // Get plugins on the site.
1123
- $themes = $this->get_site_themes(); // Get themes on the site.
1124
 
1125
  // Assign the plugins to content object.
1126
  foreach ( $plugins as $index => $plugin ) {
1127
- $this->site_content->plugins[] = strtolower( $plugin );
1128
  $this->site_content->skip_plugins[] = strtolower( $plugin );
1129
  }
1130
 
1131
  // Assign the themes to content object.
1132
  foreach ( $themes as $index => $theme ) {
1133
- $this->site_content->themes[] = strtolower( $theme );
1134
  $this->site_content->skip_themes[] = strtolower( $theme );
1135
  }
1136
 
@@ -1142,7 +1144,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1142
  // If the plugin is not already present in the current list then.
1143
  if ( ! in_array( $content, $this->site_content->plugins, true ) ) {
1144
  // Add the plugin to the list and save it.
1145
- $this->site_content->plugins[] = strtolower( $content );
1146
  $this->site_content->skip_plugins[] = strtolower( $content );
1147
  $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1148
  }
@@ -1150,7 +1152,7 @@ class WSAL_Sensors_PluginsThemes extends WSAL_AbstractSensor {
1150
  // If the theme is not already present in the current list then.
1151
  if ( ! in_array( $content, $this->site_content->themes, true ) ) {
1152
  // Add the theme to the list and save it.
1153
- $this->site_content->themes[] = strtolower( $content );
1154
  $this->site_content->skip_themes[] = strtolower( $content );
1155
  $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1156
  }
125
  public function mainwp_child_init() {
126
  // $_POST array arguments.
127
  $post_array_args = array(
128
+ 'function' => FILTER_SANITIZE_STRING,
129
+ 'action' => FILTER_SANITIZE_STRING,
130
+ 'theme' => FILTER_SANITIZE_STRING,
131
  'mainwpsignature' => FILTER_SANITIZE_STRING,
132
  );
133
 
179
  if ( in_array( $action, array( 'install-plugin', 'upload-plugin' ) ) && current_user_can( 'install_plugins' ) ) {
180
  $plugin = array_values( array_diff( array_keys( get_plugins() ), array_keys( $this->old_plugins ) ) );
181
  if ( count( $plugin ) != 1 ) {
182
+ $this->LogError(
183
  'Expected exactly one new plugin but found ' . count( $plugin ),
184
  array(
185
+ 'NewPlugin' => $plugin,
186
  'OldPlugins' => $this->old_plugins,
187
  'NewPlugins' => get_plugins(),
188
  )
189
  );
190
+ return;
191
  }
192
  $plugin_path = $plugin[0];
193
+ $plugin = get_plugins();
194
+ $plugin = $plugin[ $plugin_path ];
195
 
196
  // Get plugin directory name.
197
  $plugin_dir = $this->get_plugin_dir( $plugin_path );
203
  $this->plugin->alerts->Trigger(
204
  5000, array(
205
  'Plugin' => (object) array(
206
+ 'Name' => $plugin['Name'],
207
+ 'PluginURI' => $plugin['PluginURI'],
208
+ 'Version' => $plugin['Version'],
209
+ 'Author' => $plugin['Author'],
210
+ 'Network' => $plugin['Network'] ? 'True' : 'False',
211
  'plugin_dir_path' => $plugin_path,
212
  ),
213
  )
240
  5001, array(
241
  'PluginFile' => $plugin_file,
242
  'PluginData' => (object) array(
243
+ 'Name' => $plugin_data['Name'],
244
  'PluginURI' => $plugin_data['PluginURI'],
245
+ 'Version' => $plugin_data['Version'],
246
+ 'Author' => $plugin_data['Author'],
247
+ 'Network' => $plugin_data['Network'] ? 'True' : 'False',
248
  ),
249
  )
250
  );
257
  5001, array(
258
  'PluginFile' => $plugin_file,
259
  'PluginData' => (object) array(
260
+ 'Name' => $plugin_data['Name'],
261
  'PluginURI' => $plugin_data['PluginURI'],
262
+ 'Version' => $plugin_data['Version'],
263
+ 'Author' => $plugin_data['Author'],
264
+ 'Network' => $plugin_data['Network'] ? 'True' : 'False',
265
  ),
266
  )
267
  );
295
  5002, array(
296
  'PluginFile' => $plugin_file,
297
  'PluginData' => (object) array(
298
+ 'Name' => $plugin_data['Name'],
299
  'PluginURI' => $plugin_data['PluginURI'],
300
+ 'Version' => $plugin_data['Version'],
301
+ 'Author' => $plugin_data['Author'],
302
+ 'Network' => $plugin_data['Network'] ? 'True' : 'False',
303
  ),
304
  )
305
  );
312
  5002, array(
313
  'PluginFile' => $plugin_file,
314
  'PluginData' => (object) array(
315
+ 'Name' => $plugin_data['Name'],
316
  'PluginURI' => $plugin_data['PluginURI'],
317
+ 'Version' => $plugin_data['Version'],
318
+ 'Author' => $plugin_data['Author'],
319
+ 'Network' => $plugin_data['Network'] ? 'True' : 'False',
320
  ),
321
  )
322
  );
407
  5004, array(
408
  'PluginFile' => $plugin_file,
409
  'PluginData' => (object) array(
410
+ 'Name' => $plugin_data['Name'],
411
  'PluginURI' => $plugin_data['PluginURI'],
412
+ 'Version' => $plugin_data['Version'],
413
+ 'Author' => $plugin_data['Author'],
414
+ 'Network' => $plugin_data['Network'] ? 'True' : 'False',
415
  ),
416
  )
417
  );
443
  $this->plugin->alerts->Trigger(
444
  5031, array(
445
  'Theme' => (object) array(
446
+ 'Name' => $theme->Name,
447
+ 'ThemeURI' => $theme->ThemeURI,
448
+ 'Description' => $theme->Description,
449
+ 'Author' => $theme->Author,
450
+ 'Version' => $theme->Version,
451
  'get_template_directory' => $theme->get_template_directory(),
452
  ),
453
  )
466
  $this->plugin->alerts->Trigger(
467
  5005, array(
468
  'Theme' => (object) array(
469
+ 'Name' => $theme->Name,
470
+ 'ThemeURI' => $theme->ThemeURI,
471
+ 'Description' => $theme->Description,
472
+ 'Author' => $theme->Author,
473
+ 'Version' => $theme->Version,
474
  'get_template_directory' => $theme->get_template_directory(),
475
  ),
476
  )
486
  $this->plugin->alerts->Trigger(
487
  5007, array(
488
  'Theme' => (object) array(
489
+ 'Name' => $theme->Name,
490
+ 'ThemeURI' => $theme->ThemeURI,
491
+ 'Description' => $theme->Description,
492
+ 'Author' => $theme->Author,
493
+ 'Version' => $theme->Version,
494
  'get_template_directory' => $theme->get_template_directory(),
495
  ),
496
  )
519
  }
520
  }
521
  if ( null == $theme ) {
522
+ $this->LogError(
523
  'Could not locate theme named "' . $theme . '".',
524
  array(
525
  'ThemeName' => $theme_name,
526
+ 'Themes' => wp_get_themes(),
527
  )
528
  );
529
+ return;
530
  }
531
  $this->plugin->alerts->Trigger(
532
  5006, array(
533
  'Theme' => (object) array(
534
+ 'Name' => $theme->Name,
535
+ 'ThemeURI' => $theme->ThemeURI,
536
+ 'Description' => $theme->Description,
537
+ 'Author' => $theme->Author,
538
+ 'Version' => $theme->Version,
539
  'get_template_directory' => $theme->get_template_directory(),
540
  ),
541
  )
722
  $this->plugin->alerts->Trigger(
723
  5005, array(
724
  'Theme' => (object) array(
725
+ 'Name' => $theme_obj->Name,
726
+ 'ThemeURI' => $theme_obj->ThemeURI,
727
+ 'Description' => $theme_obj->Description,
728
+ 'Author' => $theme_obj->Author,
729
+ 'Version' => $theme_obj->Version,
730
  'get_template_directory' => $theme_obj->get_template_directory(),
731
  ),
732
  )
983
  $this->plugin->alerts->Trigger(
984
  5031, array(
985
  'Theme' => (object) array(
986
+ 'Name' => $theme->Name,
987
+ 'ThemeURI' => $theme->ThemeURI,
988
+ 'Description' => $theme->Description,
989
+ 'Author' => $theme->Author,
990
+ 'Version' => $theme->Version,
991
  'get_template_directory' => $theme->get_template_directory(),
992
  ),
993
  )
1063
  * @return array $editor_link name and value link.
1064
  */
1065
  private function GetEditorLink( $post ) {
1066
+ $name = 'EditorLink';
1067
+ $name .= ( 'page' == $post->post_type ) ? 'Page' : 'Post';
1068
+ $value = get_edit_post_link( $post->ID );
1069
  $editor_link = array(
1070
  'name' => $name,
1071
  'value' => $value,
1121
  */
1122
  if ( false === $this->site_content ) {
1123
  $this->site_content = new stdClass(); // New stdClass object.
1124
+ $plugins = $this->get_site_plugins(); // Get plugins on the site.
1125
+ $themes = $this->get_site_themes(); // Get themes on the site.
1126
 
1127
  // Assign the plugins to content object.
1128
  foreach ( $plugins as $index => $plugin ) {
1129
+ $this->site_content->plugins[] = strtolower( $plugin );
1130
  $this->site_content->skip_plugins[] = strtolower( $plugin );
1131
  }
1132
 
1133
  // Assign the themes to content object.
1134
  foreach ( $themes as $index => $theme ) {
1135
+ $this->site_content->themes[] = strtolower( $theme );
1136
  $this->site_content->skip_themes[] = strtolower( $theme );
1137
  }
1138
 
1144
  // If the plugin is not already present in the current list then.
1145
  if ( ! in_array( $content, $this->site_content->plugins, true ) ) {
1146
  // Add the plugin to the list and save it.
1147
+ $this->site_content->plugins[] = strtolower( $content );
1148
  $this->site_content->skip_plugins[] = strtolower( $content );
1149
  $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1150
  }
1152
  // If the theme is not already present in the current list then.
1153
  if ( ! in_array( $content, $this->site_content->themes, true ) ) {
1154
  // Add the theme to the list and save it.
1155
+ $this->site_content->themes[] = strtolower( $content );
1156
  $this->site_content->skip_themes[] = strtolower( $content );
1157
  $this->plugin->SetGlobalOption( $content_option, $this->site_content );
1158
  }
classes/Sensors/Public.php CHANGED
@@ -35,6 +35,20 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
35
  */
36
  protected $visitor_events;
37
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
38
  /**
39
  * Listening to events using WP hooks.
40
  */
@@ -49,6 +63,7 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
49
  add_action( 'woocommerce_new_order', array( $this, 'event_new_order' ), 10, 1 );
50
  add_filter( 'woocommerce_order_item_quantity', array( $this, 'set_old_stock' ), 10, 3 );
51
  add_action( 'woocommerce_product_set_stock', array( $this, 'product_stock_changed' ), 10, 1 );
 
52
  }
53
  }
54
  }
@@ -302,7 +317,7 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
302
  * @param string $username - Username.
303
  * @param string $url - 404 URL.
304
  */
305
- private function write_log( $attempts, $ip, $username = '', $url ) {
306
  $name_file = null;
307
 
308
  if ( 'on' === $this->plugin->GetGlobalOption( 'log-visitor-404', 'off' ) ) {
@@ -448,7 +463,7 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
448
  if ( ! $order ) {
449
  return false;
450
  }
451
- if ( is_integer( $order ) ) {
452
  $order = new WC_Order( $order );
453
  }
454
  if ( ! $order instanceof WC_Order ) {
@@ -486,12 +501,14 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
486
  $order_title = ( null !== $order_post && $order_post instanceof WP_Post ) ? $order_post->post_title : false;
487
  $editor_link = $this->get_editor_link( $order_post );
488
 
489
- $this->plugin->alerts->Trigger( 9035, array(
490
- 'OrderID' => $order_id,
491
- 'OrderTitle' => $this->get_order_title( $new_order ),
492
- 'OrderStatus' => $new_order->get_status(),
493
- $editor_link['name'] => $editor_link['value'],
494
- ) );
 
 
495
  }
496
  }
497
 
@@ -531,8 +548,16 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
531
  * @param WC_Product $product - WooCommerce product object.
532
  */
533
  public function product_stock_changed( $product ) {
534
- // Get product id.
535
- $product_id = $product->get_id();
 
 
 
 
 
 
 
 
536
 
537
  // Return if current screen is edit post page.
538
  global $pagenow;
@@ -570,7 +595,6 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
570
 
571
  $new_stock = $product->get_stock_quantity(); // Get new stock quantity.
572
  $new_stock_status = $product->get_stock_status(); // Get new stock status.
573
- $product_title = $product->get_title(); // Get product title.
574
 
575
  // Set post object.
576
  $post = get_post( $product_id );
@@ -589,7 +613,7 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
589
  $this->plugin->alerts->Trigger(
590
  9018, array(
591
  'ProductTitle' => $product_title,
592
- 'ProductStatus' => $post->post_status,
593
  'OldStatus' => $this->get_stock_status( $old_stock_status ),
594
  'NewStatus' => $this->get_stock_status( $new_stock_status ),
595
  'Username' => $username,
@@ -606,7 +630,7 @@ class WSAL_Sensors_Public extends WSAL_AbstractSensor {
606
  $this->plugin->alerts->Trigger(
607
  9019, array(
608
  'ProductTitle' => $product_title,
609
- 'ProductStatus' => $post->post_status,
610
  'OldValue' => ( ! empty( $old_stock ) ? $old_stock : 0 ),
611
  'NewValue' => $new_stock,
612
  'Username' => $username,
35
  */
36
  protected $visitor_events;
37
 
38
+ /**
39
+ * Old Product Stock Quantity.
40
+ *
41
+ * @var int
42
+ */
43
+ protected $_old_stock = null;
44
+
45
+ /**
46
+ * Old Product Stock Status.
47
+ *
48
+ * @var string
49
+ */
50
+ protected $_old_stock_status = null;
51
+
52
  /**
53
  * Listening to events using WP hooks.
54
  */
63
  add_action( 'woocommerce_new_order', array( $this, 'event_new_order' ), 10, 1 );
64
  add_filter( 'woocommerce_order_item_quantity', array( $this, 'set_old_stock' ), 10, 3 );
65
  add_action( 'woocommerce_product_set_stock', array( $this, 'product_stock_changed' ), 10, 1 );
66
+ add_action( 'woocommerce_variation_set_stock', array( $this, 'product_stock_changed' ), 10, 1 );
67
  }
68
  }
69
  }
317
  * @param string $username - Username.
318
  * @param string $url - 404 URL.
319
  */
320
+ private function write_log( $attempts, $ip, $username = '', $url = null ) {
321
  $name_file = null;
322
 
323
  if ( 'on' === $this->plugin->GetGlobalOption( 'log-visitor-404', 'off' ) ) {
463
  if ( ! $order ) {
464
  return false;
465
  }
466
+ if ( is_int( $order ) ) {
467
  $order = new WC_Order( $order );
468
  }
469
  if ( ! $order instanceof WC_Order ) {
501
  $order_title = ( null !== $order_post && $order_post instanceof WP_Post ) ? $order_post->post_title : false;
502
  $editor_link = $this->get_editor_link( $order_post );
503
 
504
+ $this->plugin->alerts->Trigger(
505
+ 9035, array(
506
+ 'OrderID' => $order_id,
507
+ 'OrderTitle' => $this->get_order_title( $new_order ),
508
+ 'OrderStatus' => $new_order->get_status(),
509
+ $editor_link['name'] => $editor_link['value'],
510
+ )
511
+ );
512
  }
513
  }
514
 
548
  * @param WC_Product $product - WooCommerce product object.
549
  */
550
  public function product_stock_changed( $product ) {
551
+ // Get product data.
552
+ $product_status = false;
553
+ if ( $product->is_type( 'variation' ) ) {
554
+ $product_id = $product->get_parent_id();
555
+ $product_title = $product->get_name(); // Get product title.
556
+ $product_status = $product->get_status();
557
+ } else {
558
+ $product_id = $product->get_id();
559
+ $product_title = $product->get_title(); // Get product title.
560
+ }
561
 
562
  // Return if current screen is edit post page.
563
  global $pagenow;
595
 
596
  $new_stock = $product->get_stock_quantity(); // Get new stock quantity.
597
  $new_stock_status = $product->get_stock_status(); // Get new stock status.
 
598
 
599
  // Set post object.
600
  $post = get_post( $product_id );
613
  $this->plugin->alerts->Trigger(
614
  9018, array(
615
  'ProductTitle' => $product_title,
616
+ 'ProductStatus' => ( ! $product_status ) ? $post->post_status : $product_status,
617
  'OldStatus' => $this->get_stock_status( $old_stock_status ),
618
  'NewStatus' => $this->get_stock_status( $new_stock_status ),
619
  'Username' => $username,
630
  $this->plugin->alerts->Trigger(
631
  9019, array(
632
  'ProductTitle' => $product_title,
633
+ 'ProductStatus' => ( ! $product_status ) ? $post->post_status : $product_status,
634
  'OldValue' => ( ! empty( $old_stock ) ? $old_stock : 0 ),
635
  'NewValue' => $new_stock,
636
  'Username' => $username,
classes/Sensors/Request.php CHANGED
@@ -42,10 +42,10 @@ class WSAL_Sensors_Request extends WSAL_AbstractSensor {
42
  */
43
  public function EventShutdown() {
44
  // Filter global arrays for security.
45
- $post_array = filter_input_array( INPUT_POST );
46
  $server_array = filter_input_array( INPUT_SERVER );
47
 
48
- $upload_dir = wp_upload_dir();
49
  $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log/';
50
  if ( ! $this->CheckDirectory( $uploads_dir_path ) ) {
51
  wp_mkdir_p( $uploads_dir_path );
@@ -54,21 +54,22 @@ class WSAL_Sensors_Request extends WSAL_AbstractSensor {
54
  $file = $uploads_dir_path . 'Request.log.php';
55
 
56
  $request_method = isset( $server_array['REQUEST_METHOD'] ) ? $server_array['REQUEST_METHOD'] : false;
57
- $request_uri = isset( $server_array['REQUEST_URI'] ) ? $server_array['REQUEST_URI'] : false;
58
 
59
  $line = '[' . date( 'Y-m-d H:i:s' ) . '] '
60
  . $request_method . ' '
61
  . $request_uri . ' '
62
- . ( ! empty( $post_array ) ? str_pad( PHP_EOL, 24 ) . json_encode( $post_array ) : '')
63
- . ( ! empty( self::$envvars ) ? str_pad( PHP_EOL, 24 ) . json_encode( self::$envvars ) : '')
64
  . PHP_EOL;
65
 
66
  if ( ! file_exists( $file ) && ! file_put_contents( $file, '<' . '?php die(\'Access Denied\'); ?>' . PHP_EOL ) ) {
67
- return $this->LogError(
68
  'Could not initialize request log file', array(
69
  'file' => $file,
70
  )
71
  );
 
72
  }
73
 
74
  $f = fopen( $file, 'a' );
42
  */
43
  public function EventShutdown() {
44
  // Filter global arrays for security.
45
+ $post_array = filter_input_array( INPUT_POST );
46
  $server_array = filter_input_array( INPUT_SERVER );
47
 
48
+ $upload_dir = wp_upload_dir();
49
  $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log/';
50
  if ( ! $this->CheckDirectory( $uploads_dir_path ) ) {
51
  wp_mkdir_p( $uploads_dir_path );
54
  $file = $uploads_dir_path . 'Request.log.php';
55
 
56
  $request_method = isset( $server_array['REQUEST_METHOD'] ) ? $server_array['REQUEST_METHOD'] : false;
57
+ $request_uri = isset( $server_array['REQUEST_URI'] ) ? $server_array['REQUEST_URI'] : false;
58
 
59
  $line = '[' . date( 'Y-m-d H:i:s' ) . '] '
60
  . $request_method . ' '
61
  . $request_uri . ' '
62
+ . ( ! empty( $post_array ) ? str_pad( PHP_EOL, 24 ) . json_encode( $post_array ) : '' )
63
+ . ( ! empty( self::$envvars ) ? str_pad( PHP_EOL, 24 ) . json_encode( self::$envvars ) : '' )
64
  . PHP_EOL;
65
 
66
  if ( ! file_exists( $file ) && ! file_put_contents( $file, '<' . '?php die(\'Access Denied\'); ?>' . PHP_EOL ) ) {
67
+ $this->LogError(
68
  'Could not initialize request log file', array(
69
  'file' => $file,
70
  )
71
  );
72
+ return;
73
  }
74
 
75
  $f = fopen( $file, 'a' );
classes/Sensors/System.php CHANGED
@@ -134,8 +134,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
134
  if ( $old_value != $new_value ) {
135
  $this->plugin->alerts->Trigger(
136
  6003, array(
137
- 'OldEmail' => $old_value,
138
- 'NewEmail' => $new_value,
139
  'CurrentUserID' => wp_get_current_user()->ID,
140
  )
141
  );
@@ -187,7 +187,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
187
  protected function IsPast404Limit( $site_id, $username, $ip ) {
188
  $get_fn = $this->IsMultisite() ? 'get_site_transient' : 'get_transient';
189
  $data = $get_fn( self::TRANSIENT_404 );
190
- return ( false !== $data ) && isset( $data[ $site_id . ':' . $username . ':' . $ip ] ) && ($data[ $site_id . ':' . $username . ':' . $ip ] > $this->Get404LogLimit());
191
  }
192
 
193
  /**
@@ -281,7 +281,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
281
  $new = ( (int) $occ->GetMetaValue( 'Attempts', 0 ) ) + 1;
282
 
283
  if ( $new > $this->Get404LogLimit() ) {
284
- $new = 'more than ' . $this->Get404LogLimit();
285
  $msg .= ' This could possible be a scan, therefore keep an eye on the activity from this IP Address';
286
  }
287
 
@@ -335,8 +335,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
335
  */
336
  public function EventAdminInit() {
337
  // Filter global arrays for security.
338
- $post_array = filter_input_array( INPUT_POST );
339
- $get_array = filter_input_array( INPUT_GET );
340
  $server_array = filter_input_array( INPUT_SERVER );
341
 
342
  // Destroy all the session of the same user from user profile page.
@@ -358,9 +358,9 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
358
  $actype = basename( $server_array['SCRIPT_NAME'], '.php' );
359
  }
360
 
361
- $is_option_page = 'options' === $actype;
362
  $is_network_settings = 'settings' === $actype;
363
- $is_permalink_page = 'options-permalink' === $actype;
364
 
365
  // WordPress URL changed.
366
  if ( $is_option_page
@@ -371,8 +371,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
371
  if ( $old_siteurl !== $new_siteurl ) {
372
  $this->plugin->alerts->Trigger(
373
  6024, array(
374
- 'old_url' => $old_siteurl,
375
- 'new_url' => $new_siteurl,
376
  'CurrentUserID' => wp_get_current_user()->ID,
377
  )
378
  );
@@ -388,8 +388,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
388
  if ( $old_url !== $new_url ) {
389
  $this->plugin->alerts->Trigger(
390
  6025, array(
391
- 'old_url' => $old_url,
392
- 'new_url' => $new_url,
393
  'CurrentUserID' => wp_get_current_user()->ID,
394
  )
395
  );
@@ -405,8 +405,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
405
  if ( $old != $new ) {
406
  $this->plugin->alerts->Trigger(
407
  6001, array(
408
- 'OldValue' => $old,
409
- 'NewValue' => $new,
410
  'CurrentUserID' => wp_get_current_user()->ID,
411
  )
412
  );
@@ -420,8 +420,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
420
  if ( $old != $new ) {
421
  $this->plugin->alerts->Trigger(
422
  6002, array(
423
- 'OldRole' => $old,
424
- 'NewRole' => $new,
425
  'CurrentUserID' => wp_get_current_user()->ID,
426
  )
427
  );
@@ -435,8 +435,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
435
  if ( $old != $new ) {
436
  $this->plugin->alerts->Trigger(
437
  6003, array(
438
- 'OldEmail' => $old,
439
- 'NewEmail' => $new,
440
  'CurrentUserID' => wp_get_current_user()->ID,
441
  )
442
  );
@@ -450,8 +450,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
450
  if ( $old != $new ) {
451
  $this->plugin->alerts->Trigger(
452
  6003, array(
453
- 'OldEmail' => $old,
454
- 'NewEmail' => $new,
455
  'CurrentUserID' => wp_get_current_user()->ID,
456
  )
457
  );
@@ -465,8 +465,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
465
  if ( $old != $new ) {
466
  $this->plugin->alerts->Trigger(
467
  6005, array(
468
- 'OldPattern' => $old,
469
- 'NewPattern' => $new,
470
  'CurrentUserID' => wp_get_current_user()->ID,
471
  )
472
  );
@@ -513,8 +513,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
513
  if ( isset( $post_array['action'] ) && 'update' === $post_array['action'] && isset( $post_array['option_page'] ) && ( 'bbpress' === $post_array['option_page'] ) ) {
514
  // Anonymous posting.
515
  $allow_anonymous = get_option( '_bbp_allow_anonymous' );
516
- $old_status = ! empty( $allow_anonymous ) ? 1 : 0;
517
- $new_status = ! empty( $post_array['_bbp_allow_anonymous'] ) ? 1 : 0;
518
  if ( $old_status !== $new_status ) {
519
  $status = ( 1 === $new_status ) ? 'Enabled' : 'Disabled';
520
  $this->plugin->alerts->Trigger(
@@ -526,8 +526,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
526
 
527
  // Disallow editing after.
528
  $bbp_edit_lock = get_option( '_bbp_edit_lock' );
529
- $old_time = ! empty( $bbp_edit_lock ) ? $bbp_edit_lock : '';
530
- $new_time = ! empty( $post_array['_bbp_edit_lock'] ) ? $post_array['_bbp_edit_lock'] : '';
531
  if ( $old_time != $new_time ) {
532
  $this->plugin->alerts->Trigger(
533
  8012, array(
@@ -539,8 +539,8 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
539
 
540
  // Throttle posting every.
541
  $bbp_throttle_time = get_option( '_bbp_throttle_time' );
542
- $old_time2 = ! empty( $bbp_throttle_time ) ? $bbp_throttle_time : '';
543
- $new_time2 = ! empty( $post_array['_bbp_throttle_time'] ) ? $post_array['_bbp_throttle_time'] : '';
544
  if ( $old_time2 != $new_time2 ) {
545
  $this->plugin->alerts->Trigger(
546
  8013, array(
@@ -559,7 +559,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
559
  */
560
  public function WPUpdate( $automatic ) {
561
  if ( isset( $automatic['core'][0] ) ) {
562
- $obj = $automatic['core'][0];
563
  $old_version = get_bloginfo( 'version' );
564
  $this->plugin->alerts->Trigger(
565
  6004, array(
@@ -584,11 +584,11 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
584
  */
585
  public function LogFilesPruning() {
586
  if ( $this->plugin->GetGlobalOption( 'purge-404-log', 'off' ) == 'on' ) {
587
- $upload_dir = wp_upload_dir();
588
  $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log/404s/';
589
  if ( is_dir( $uploads_dir_path ) ) {
590
  if ( $handle = opendir( $uploads_dir_path ) ) {
591
- while ( false !== ($entry = readdir( $handle )) ) {
592
  if ( '.' != $entry && '..' != $entry ) {
593
  if ( strpos( $entry, '6007' ) && file_exists( $uploads_dir_path . $entry ) ) {
594
  $modified = filemtime( $uploads_dir_path . $entry );
@@ -604,7 +604,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
604
  }
605
  }
606
  if ( 'on' == $this->plugin->GetGlobalOption( 'purge-visitor-404-log', 'off' ) ) {
607
- $upload_dir = wp_upload_dir();
608
  $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log/404s/';
609
  if ( is_dir( $uploads_dir_path ) ) {
610
  if ( $handle = opendir( $uploads_dir_path ) ) {
@@ -633,7 +633,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
633
  public function EventOptions( $whitelist = null ) {
634
  // Filter global arrays for security.
635
  $post_array = filter_input_array( INPUT_POST );
636
- $get_array = filter_input_array( INPUT_GET );
637
 
638
  if ( isset( $post_array['option_page'] ) && 'reading' === $post_array['option_page'] ) {
639
  $old_status = (int) get_option( 'blog_public', 1 );
@@ -685,7 +685,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
685
  $this->plugin->alerts->Trigger(
686
  6012, array(
687
  'Status' => ( 1 === $new_status ) ? 'Enabled' : 'Disabled',
688
- 'Value' => $value,
689
  )
690
  );
691
  }
@@ -759,7 +759,7 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
759
  * @param bool $logged_in - True if logged in.
760
  * @param string $url - 404 URL.
761
  */
762
- private function WriteLog( $attempts, $ip, $username = '', $logged_in = true, $url ) {
763
  $name_file = null;
764
 
765
  if ( $logged_in && 'on' === $this->plugin->GetGlobalOption( 'log-404', 'off' ) ) {
@@ -848,18 +848,18 @@ class WSAL_Sensors_System extends WSAL_AbstractSensor {
848
  * @return string $latest_filename - File name.
849
  */
850
  private function GetLastModified( $uploads_dir_path, $filename ) {
851
- $filename = substr( $filename, 0, -4 );
852
- $latest_mtime = 0;
853
  $latest_filename = '';
854
  if ( $handle = opendir( $uploads_dir_path ) ) {
855
- while ( false !== ($entry = readdir( $handle )) ) {
856
  if ( '.' != $entry && '..' != $entry ) {
857
  $entry = strip_tags( $entry ); // Strip HTML Tags.
858
  $entry = preg_replace( '/[\r\n\t ]+/', ' ', $entry ); // Remove Break/Tabs/Return Carriage.
859
  $entry = preg_replace( '/[\"\*\/\:\<\>\?\'\|]+/', ' ', $entry ); // Remove Illegal Chars for folder and filename.
860
  if ( preg_match( '/^' . $filename . '/i', $entry ) > 0 ) {
861
  if ( filemtime( $uploads_dir_path . $entry ) > $latest_mtime ) {
862
- $latest_mtime = filemtime( $uploads_dir_path . $entry );
863
  $latest_filename = $entry;
864
  }
865
  }
134
  if ( $old_value != $new_value ) {
135
  $this->plugin->alerts->Trigger(
136
  6003, array(
137
+ 'OldEmail' => $old_value,
138
+ 'NewEmail' => $new_value,
139
  'CurrentUserID' => wp_get_current_user()->ID,
140
  )
141
  );
187
  protected function IsPast404Limit( $site_id, $username, $ip ) {
188
  $get_fn = $this->IsMultisite() ? 'get_site_transient' : 'get_transient';
189
  $data = $get_fn( self::TRANSIENT_404 );
190
+ return ( false !== $data ) && isset( $data[ $site_id . ':' . $username . ':' . $ip ] ) && ( $data[ $site_id . ':' . $username . ':' . $ip ] > $this->Get404LogLimit() );
191
  }
192
 
193
  /**
281
  $new = ( (int) $occ->GetMetaValue( 'Attempts', 0 ) ) + 1;
282
 
283
  if ( $new > $this->Get404LogLimit() ) {
284
+ $new = 'more than ' . $this->Get404LogLimit();
285
  $msg .= ' This could possible be a scan, therefore keep an eye on the activity from this IP Address';
286
  }
287
 
335
  */
336
  public function EventAdminInit() {
337
  // Filter global arrays for security.
338
+ $post_array = filter_input_array( INPUT_POST );
339
+ $get_array = filter_input_array( INPUT_GET );
340
  $server_array = filter_input_array( INPUT_SERVER );
341
 
342
  // Destroy all the session of the same user from user profile page.
358
  $actype = basename( $server_array['SCRIPT_NAME'], '.php' );
359
  }
360
 
361
+ $is_option_page = 'options' === $actype;
362
  $is_network_settings = 'settings' === $actype;
363
+ $is_permalink_page = 'options-permalink' === $actype;
364
 
365
  // WordPress URL changed.
366
  if ( $is_option_page
371
  if ( $old_siteurl !== $new_siteurl ) {
372
  $this->plugin->alerts->Trigger(
373
  6024, array(
374
+ 'old_url' => $old_siteurl,
375
+ 'new_url' => $new_siteurl,
376
  'CurrentUserID' => wp_get_current_user()->ID,
377
  )
378
  );
388
  if ( $old_url !== $new_url ) {
389
  $this->plugin->alerts->Trigger(
390
  6025, array(
391
+ 'old_url' => $old_url,
392
+ 'new_url' => $new_url,
393
  'CurrentUserID' => wp_get_current_user()->ID,
394
  )
395
  );
405
  if ( $old != $new ) {
406
  $this->plugin->alerts->Trigger(
407
  6001, array(
408
+ 'OldValue' => $old,
409
+ 'NewValue' => $new,
410
  'CurrentUserID' => wp_get_current_user()->ID,
411
  )
412
  );
420
  if ( $old != $new ) {
421
  $this->plugin->alerts->Trigger(
422
  6002, array(
423
+ 'OldRole' => $old,
424
+ 'NewRole' => $new,
425
  'CurrentUserID' => wp_get_current_user()->ID,
426
  )
427
  );
435
  if ( $old != $new ) {
436
  $this->plugin->alerts->Trigger(
437
  6003, array(
438
+ 'OldEmail' => $old,
439
+ 'NewEmail' => $new,
440
  'CurrentUserID' => wp_get_current_user()->ID,
441
  )
442
  );
450
  if ( $old != $new ) {
451
  $this->plugin->alerts->Trigger(
452
  6003, array(
453
+ 'OldEmail' => $old,
454
+ 'NewEmail' => $new,
455
  'CurrentUserID' => wp_get_current_user()->ID,
456
  )
457
  );
465
  if ( $old != $new ) {
466
  $this->plugin->alerts->Trigger(
467
  6005, array(
468
+ 'OldPattern' => $old,
469
+ 'NewPattern' => $new,
470
  'CurrentUserID' => wp_get_current_user()->ID,
471
  )
472
  );
513
  if ( isset( $post_array['action'] ) && 'update' === $post_array['action'] && isset( $post_array['option_page'] ) && ( 'bbpress' === $post_array['option_page'] ) ) {
514
  // Anonymous posting.
515
  $allow_anonymous = get_option( '_bbp_allow_anonymous' );
516
+ $old_status = ! empty( $allow_anonymous ) ? 1 : 0;
517
+ $new_status = ! empty( $post_array['_bbp_allow_anonymous'] ) ? 1 : 0;
518
  if ( $old_status !== $new_status ) {
519
  $status = ( 1 === $new_status ) ? 'Enabled' : 'Disabled';
520
  $this->plugin->alerts->Trigger(
526
 
527
  // Disallow editing after.
528
  $bbp_edit_lock = get_option( '_bbp_edit_lock' );
529
+ $old_time = ! empty( $bbp_edit_lock ) ? $bbp_edit_lock : '';
530
+ $new_time = ! empty( $post_array['_bbp_edit_lock'] ) ? $post_array['_bbp_edit_lock'] : '';
531
  if ( $old_time != $new_time ) {
532
  $this->plugin->alerts->Trigger(
533
  8012, array(
539
 
540
  // Throttle posting every.
541
  $bbp_throttle_time = get_option( '_bbp_throttle_time' );
542
+ $old_time2 = ! empty( $bbp_throttle_time ) ? $bbp_throttle_time : '';
543
+ $new_time2 = ! empty( $post_array['_bbp_throttle_time'] ) ? $post_array['_bbp_throttle_time'] : '';
544
  if ( $old_time2 != $new_time2 ) {
545
  $this->plugin->alerts->Trigger(
546
  8013, array(
559
  */
560
  public function WPUpdate( $automatic ) {
561
  if ( isset( $automatic['core'][0] ) ) {
562
+ $obj = $automatic['core'][0];
563
  $old_version = get_bloginfo( 'version' );
564
  $this->plugin->alerts->Trigger(
565
  6004, array(
584
  */
585
  public function LogFilesPruning() {
586
  if ( $this->plugin->GetGlobalOption( 'purge-404-log', 'off' ) == 'on' ) {
587
+ $upload_dir = wp_upload_dir();
588
  $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log/404s/';
589
  if ( is_dir( $uploads_dir_path ) ) {
590
  if ( $handle = opendir( $uploads_dir_path ) ) {
591
+ while ( false !== ( $entry = readdir( $handle ) ) ) {
592
  if ( '.' != $entry && '..' != $entry ) {
593
  if ( strpos( $entry, '6007' ) && file_exists( $uploads_dir_path . $entry ) ) {
594
  $modified = filemtime( $uploads_dir_path . $entry );
604
  }
605
  }
606
  if ( 'on' == $this->plugin->GetGlobalOption( 'purge-visitor-404-log', 'off' ) ) {
607
+ $upload_dir = wp_upload_dir();
608
  $uploads_dir_path = trailingslashit( $upload_dir['basedir'] ) . 'wp-security-audit-log/404s/';
609
  if ( is_dir( $uploads_dir_path ) ) {
610
  if ( $handle = opendir( $uploads_dir_path ) ) {
633
  public function EventOptions( $whitelist = null ) {
634
  // Filter global arrays for security.
635
  $post_array = filter_input_array( INPUT_POST );
636
+ $get_array = filter_input_array( INPUT_GET );
637
 
638
  if ( isset( $post_array['option_page'] ) && 'reading' === $post_array['option_page'] ) {
639
  $old_status = (int) get_option( 'blog_public', 1 );
685
  $this->plugin->alerts->Trigger(
686
  6012, array(
687
  'Status' => ( 1 === $new_status ) ? 'Enabled' : 'Disabled',
688
+ 'Value' => $value,
689
  )
690
  );
691
  }
759
  * @param bool $logged_in - True if logged in.
760
  * @param string $url - 404 URL.
761
  */
762
+ private function WriteLog( $attempts, $ip, $username = '', $logged_in = true, $url = null ) {
763
  $name_file = null;
764
 
765
  if ( $logged_in && 'on' === $this->plugin->GetGlobalOption( 'log-404', 'off' ) ) {
848
  * @return string $latest_filename - File name.
849
  */
850
  private function GetLastModified( $uploads_dir_path, $filename ) {
851
+ $filename = substr( $filename, 0, -4 );
852
+ $latest_mtime = 0;
853
  $latest_filename = '';
854
  if ( $handle = opendir( $uploads_dir_path ) ) {
855
+ while ( false !== ( $entry = readdir( $handle ) ) ) {
856
  if ( '.' != $entry && '..' != $entry ) {
857
  $entry = strip_tags( $entry ); // Strip HTML Tags.
858
  $entry = preg_replace( '/[\r\n\t ]+/', ' ', $entry ); // Remove Break/Tabs/Return Carriage.
859
  $entry = preg_replace( '/[\"\*\/\:\<\>\?\'\|]+/', ' ', $entry ); // Remove Illegal Chars for folder and filename.
860
  if ( preg_match( '/^' . $filename . '/i', $entry ) > 0 ) {
861
  if ( filemtime( $uploads_dir_path . $entry ) > $latest_mtime ) {
862
+ $latest_mtime = filemtime( $uploads_dir_path . $entry );
863
  $latest_filename = $entry;
864
  }
865
  }
classes/Sensors/Widgets.php CHANGED
@@ -59,7 +59,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
59
 
60
  if ( isset( $post_array ) && ! empty( $post_array['sidebars'] ) ) {
61
  $current_sidebars = $post_array['sidebars'];
62
- $sidebars = array();
63
  foreach ( $current_sidebars as $key => $val ) {
64
  $sb = array();
65
  if ( ! empty( $val ) ) {
@@ -74,14 +74,13 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
74
  $sidebars[ $key ] = $sb;
75
  }
76
  $current_sidebars = $sidebars;
77
- $db_sidebars = get_option( 'sidebars_widgets' );
78
- $widget_name = $from_sidebar = $to_sidebar = '';
79
  foreach ( $current_sidebars as $sidebar_name => $values ) {
80
  if ( is_array( $values ) && ! empty( $values ) && isset( $db_sidebars[ $sidebar_name ] ) ) {
81
  foreach ( $values as $widget_name ) {
82
  if ( ! in_array( $widget_name, $db_sidebars[ $sidebar_name ] ) ) {
83
  $to_sidebar = $sidebar_name;
84
- $widget_name = $widget_name;
85
  foreach ( $db_sidebars as $name => $v ) {
86
  if ( is_array( $v ) && ! empty( $v ) && in_array( $widget_name, $v ) ) {
87
  $from_sidebar = $name;
@@ -104,8 +103,8 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
104
  // we will then check for this variable in the EventWidgetPostMove() event.
105
  $this->_widget_move_data = array(
106
  'widget' => $widget_name,
107
- 'from' => $from_sidebar,
108
- 'to' => $to_sidebar,
109
  );
110
  return;
111
  }
@@ -129,7 +128,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
129
  $post_array = filter_input_array( INPUT_POST );
130
 
131
  // #!-- generates the event 2071
132
- if ( isset( $post_array['action'] ) && ('widgets-order' == $post_array['action']) ) {
133
  if ( isset( $post_array['sidebars'] ) ) {
134
  // Get the sidebars from $post_array.
135
  $request_sidebars = array();
@@ -167,10 +166,10 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
167
  }
168
  $this->plugin->alerts->Trigger(
169
  2071, array(
170
- 'WidgetName' => $widget_name,
171
  'OldPosition' => $i + 1,
172
  'NewPosition' => $index + 1,
173
- 'Sidebar' => $sn,
174
  )
175
  );
176
  }
@@ -182,24 +181,22 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
182
  }
183
  // #!--
184
  if ( $this->_widget_move_data ) {
185
- $widget_name = $this->_widget_move_data['widget'];
186
  $from_sidebar = $this->_widget_move_data['from'];
187
- $to_sidebar = $this->_widget_move_data['to'];
188
 
189
  global $wp_registered_sidebars;
190
 
191
  if ( preg_match( '/^sidebar-/', $from_sidebar ) ) {
192
  $from_sidebar = isset( $wp_registered_sidebars[ $from_sidebar ] )
193
  ? $wp_registered_sidebars[ $from_sidebar ]['name']
194
- : $from_sidebar
195
- ;
196
  }
197
 
198
  if ( preg_match( '/^sidebar-/', $to_sidebar ) ) {
199
  $to_sidebar = isset( $wp_registered_sidebars[ $to_sidebar ] )
200
  ? $wp_registered_sidebars[ $to_sidebar ]['name']
201
- : $to_sidebar
202
- ;
203
  }
204
 
205
  $this->plugin->alerts->Trigger(
@@ -228,7 +225,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
228
  }
229
 
230
  global $wp_registered_sidebars;
231
- $can_check_sidebar = (empty( $wp_registered_sidebars ) ? false : true);
232
 
233
  switch ( true ) {
234
  // Added widget.
@@ -240,7 +237,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
240
  $this->plugin->alerts->Trigger(
241
  2042, array(
242
  'WidgetName' => $post_array['id_base'],
243
- 'Sidebar' => $sidebar,
244
  )
245
  );
246
  break;
@@ -253,7 +250,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
253
  $this->plugin->alerts->Trigger(
254
  2044, array(
255
  'WidgetName' => $post_array['id_base'],
256
- 'Sidebar' => $sidebar,
257
  )
258
  );
259
  break;
@@ -270,7 +267,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
270
  }
271
 
272
  $widget_name = $post_array['id_base'];
273
- $sidebar = isset( $post_array['sidebar'] ) ? $post_array['sidebar'] : null;
274
  $widget_data = isset( $post_array[ "widget-$widget_name" ][ $widget_id ] )
275
  ? $post_array[ "widget-$widget_name" ][ $widget_id ]
276
  : null;
@@ -292,7 +289,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
292
  }
293
 
294
  // Compare - checks for any changes inside widgets.
295
- $diff = array_diff_assoc( $widget_data, $widget_db_data[ $widget_id ] );
296
  $count = count( $diff );
297
  if ( $count > 0 ) {
298
  if ( $can_check_sidebar && preg_match( '/^sidebar-/', $sidebar ) ) {
@@ -301,7 +298,7 @@ class WSAL_Sensors_Widgets extends WSAL_AbstractSensor {
301
  $this->plugin->alerts->Trigger(
302
  2043, array(
303
  'WidgetName' => $widget_name,
304
- 'Sidebar' => $sidebar,
305
  )
306
  );
307
  }
59
 
60
  if ( isset( $post_array ) && ! empty( $post_array['sidebars'] ) ) {
61
  $current_sidebars = $post_array['sidebars'];
62
+ $sidebars = array();
63
  foreach ( $current_sidebars as $key => $val ) {
64
  $sb = array();
65
  if ( ! empty( $val ) ) {
74
  $sidebars[ $key ] = $sb;
75
  }
76
  $current_sidebars = $sidebars;
77
+ $db_sidebars = get_option( 'sidebars_widgets' );
78
+ $widget_name = $from_sidebar = $to_sidebar = '';
79
  foreach ( $current_sidebars as $sidebar_name => $values ) {
80
  if ( is_array( $values ) && ! empty( $values ) && isset( $db_sidebars[ $sidebar_name ] ) ) {
81
  foreach ( $values as $widget_name ) {
82
  if ( ! in_array( $widget_name, $db_sidebars[ $sidebar_name ] ) ) {
83
  $to_sidebar = $sidebar_name;
 
84
  foreach ( $db_sidebars as $name => $v ) {
85
  if ( is_array( $v ) && ! empty( $v ) && in_array( $widget_name, $v ) ) {
86
  $from_sidebar = $name;
103
  // we will then check for this variable in the EventWidgetPostMove() event.
104
  $this->_widget_move_data = array(
105
  'widget' => $widget_name,
106
+ 'from' => $from_sidebar,
107
+ 'to' => $to_sidebar,
108
  );
109
  return;
110
  }
128
  $post_array = filter_input_array( INPUT_POST );
129
 
130
  // #!-- generates the event 2071
131
+ if ( isset( $post_array['action'] ) && ( 'widgets-order' == $post_array['action'] ) ) {
132
  if ( isset( $post_array['sidebars'] ) ) {
133
  // Get the sidebars from $post_array.
134
  $request_sidebars = array();
166
  }
167
  $this->plugin->alerts->Trigger(
168
  2071, array(
169
+ 'WidgetName' => $widget_name,
170
  'OldPosition' => $i + 1,
171
  'NewPosition' => $index + 1,
172
+ 'Sidebar' => $sn,
173
  )
174
  );
175
  }
181
  }
182
  // #!--
183
  if ( $this->_widget_move_data ) {
184
+ $widget_name = $this->_widget_move_data['widget'];
185
  $from_sidebar = $this->_widget_move_data['from'];
186
+ $to_sidebar = $this->_widget_move_data['to'];
187
 
188
  global $wp_registered_sidebars;
189
 
190
  if ( preg_match( '/^sidebar-/', $from_sidebar ) ) {
191
  $from_sidebar = isset( $wp_registered_sidebars[ $from_sidebar ] )
192
  ? $wp_registered_sidebars[ $from_sidebar ]['name']
193
+ : $from_sidebar;
 
194
  }
195
 
196
  if ( preg_match( '/^sidebar-/', $to_sidebar ) ) {
197
  $to_sidebar = isset( $wp_registered_sidebars[ $to_sidebar ] )
198
  ? $wp_registered_sidebars[ $to_sidebar ]['name']
199
+ : $to_sidebar;
 
200
  }
201
 
202
  $this->plugin->alerts->Trigger(
225
  }
226
 
227
  global $wp_registered_sidebars;
228
+ $can_check_sidebar = ( empty( $wp_registered_sidebars ) ? false : true );
229
 
230
  switch ( true ) {
231
  // Added widget.
237
  $this->plugin->alerts->Trigger(
238
  2042, array(
239
  'WidgetName' => $post_array['id_base'],
240
+ 'Sidebar' => $sidebar,
241
  )
242
  );
243
  break;
250
  $this->plugin->alerts->Trigger(
251
  2044, array(
252
  'WidgetName' => $post_array['id_base'],
253
+ 'Sidebar' => $sidebar,
254
  )
255
  );
256
  break;
267
  }
268
 
269
  $widget_name = $post_array['id_base'];
270
+ $sidebar = isset( $post_array['sidebar'] ) ? $post_array['sidebar'] : null;
271
  $widget_data = isset( $post_array[ "widget-$widget_name" ][ $widget_id ] )
272
  ? $post_array[ "widget-$widget_name" ][ $widget_id ]
273
  : null;
289
  }
290
 
291
  // Compare - checks for any changes inside widgets.
292
+ $diff = array_diff_assoc( $widget_data, $widget_db_data[ $widget_id ] );
293
  $count = count( $diff );
294
  if ( $count > 0 ) {
295
  if ( $can_check_sidebar && preg_match( '/^sidebar-/', $sidebar ) ) {
298
  $this->plugin->alerts->Trigger(
299
  2043, array(
300
  'WidgetName' => $widget_name,
301
+ 'Sidebar' => $sidebar,
302
  )
303
  );
304
  }
classes/Sensors/WooCommerce.php CHANGED
@@ -272,7 +272,18 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
272
  // Global variable which returns current page.
273
  global $pagenow;
274
 
275
- if ( 'post.php' === $pagenow && $this->CheckWooCommerce( $oldpost ) && is_admin() ) {
 
 
 
 
 
 
 
 
 
 
 
276
  $changes = 0 + $this->EventCreation( $oldpost, $newpost );
277
  if ( ! $changes ) {
278
  // Change Categories.
@@ -335,45 +346,39 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
335
  * @param object $new_post - New Post.
336
  */
337
  private function EventCreation( $old_post, $new_post ) {
338
- // Filter POST global array.
339
- $post_array = filter_input_array( INPUT_POST );
340
-
341
- // @codingStandardsIgnoreStart
342
- $wpnonce = isset( $_POST['_wpnonce'] ) ? sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ) : false;
343
- $post_id = isset( $_POST['post_ID'] ) ? sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) : false;
344
- // @codingStandardsIgnoreEnd
345
-
346
- if ( ! empty( $post_id ) && ! empty( $wpnonce ) && wp_verify_nonce( $wpnonce, 'update-post_' . $post_id ) ) {
347
- // Original post status.
348
- $original = isset( $_POST['original_post_status'] ) ? sanitize_text_field( wp_unslash( $_POST['original_post_status'] ) ) : '';
349
 
350
- // Ignore if original or new post type is draft.
351
- if ( 'draft' === $original && 'draft' === $new_post->post_status ) {
352
- return 0;
353
- }
354
 
355
- if ( 'draft' === $old_post->post_status || 'auto-draft' === $original ) {
356
- if ( 'product' === $old_post->post_type ) {
357
- $editor_link = $this->GetEditorLink( $new_post );
358
- if ( 'draft' === $new_post->post_status ) {
359
- $this->plugin->alerts->Trigger( 9000, array(
 
360
  'ProductTitle' => $new_post->post_title,
361
  $editor_link['name'] => $editor_link['value'],
362
- ) );
363
- return 1;
364
- } elseif ( 'publish' === $new_post->post_status ) {
365
- $this->plugin->alerts->Trigger( 9001, array(
 
 
366
  'ProductTitle' => $new_post->post_title,
367
  'ProductUrl' => get_post_permalink( $new_post->ID ),
368
  $editor_link['name'] => $editor_link['value'],
369
- ) );
370
- return 1;
371
- }
372
- } elseif ( 'shop_coupon' === $old_post->post_type && 'publish' === $new_post->post_status ) {
373
- $coupon_data = $this->get_coupon_event_data( $new_post );
374
- $this->plugin->alerts->Trigger( 9063, $coupon_data );
375
  return 1;
376
  }
 
 
 
 
377
  }
378
  }
379
  return 0;
@@ -497,7 +502,7 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
497
  * @return int
498
  */
499
  protected function CheckPermalinkChange( $old_link, $new_link, $post ) {
500
- if ( ( $old_link && $new_link ) && ( $old_link != $new_link ) ) {
501
  $editor_link = $this->GetEditorLink( $post );
502
  $this->plugin->alerts->Trigger(
503
  9006, array(
@@ -522,33 +527,25 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
522
  * @return int
523
  */
524
  protected function CheckProductDataChange( $old_data, $post ) {
525
- // Check nonce.
526
- if (
527
- isset( $_POST['post_ID'] )
528
- && isset( $_POST['_wpnonce'] )
529
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
530
- ) {
531
- if ( isset( $_POST['product-type'] ) ) {
532
- $old_data = is_array( $old_data ) ? implode( ', ', $old_data ) : $old_data;
533
- $new_data = sanitize_text_field( wp_unslash( $_POST['product-type'] ) );
534
 
535
- if ( $old_data !== $new_data ) {
536
- $editor_link = $this->GetEditorLink( $post );
537
- $this->plugin->alerts->Trigger(
538
- 9007, array(
539
- 'ProductTitle' => $post->post_title,
540
- 'ProductStatus' => $post->post_status,
541
- 'OldType' => $old_data,
542
- 'NewType' => $new_data,
543
- $editor_link['name'] => $editor_link['value'],
544
- )
545
- );
546
- return 1;
547
- }
548
  }
549
- return 0;
550
  }
551
- return false;
552
  }
553
 
554
  /**
@@ -589,44 +586,38 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
589
  * @return int
590
  */
591
  protected function CheckVisibilityChange( $oldpost ) {
592
- // Filter POST global array.
593
- $post_array = filter_input_array( INPUT_POST );
594
-
595
- if (
596
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
597
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
598
- ) {
599
- $old_visibility = isset( $post_array['hidden_post_visibility'] ) ? $post_array['hidden_post_visibility'] : null;
600
- $new_visibility = isset( $post_array['visibility'] ) ? $post_array['visibility'] : null;
601
 
602
- if ( 'password' === $old_visibility ) {
603
- $old_visibility = __( 'Password Protected', 'wp-security-audit-log' );
604
- } else {
605
- $old_visibility = ucfirst( $old_visibility );
606
- }
607
 
608
- if ( 'password' === $new_visibility ) {
609
- $new_visibility = __( 'Password Protected', 'wp-security-audit-log' );
610
- } else {
611
- $new_visibility = ucfirst( $new_visibility );
612
- }
613
 
614
- if ( ( $old_visibility && $new_visibility ) && ( $old_visibility != $new_visibility ) ) {
615
- $editor_link = $this->GetEditorLink( $oldpost );
616
- $this->plugin->alerts->Trigger(
617
- 9009, array(
618
- 'ProductTitle' => $oldpost->post_title,
619
- 'ProductStatus' => $oldpost->post_status,
620
- 'OldVisibility' => $old_visibility,
621
- 'NewVisibility' => $new_visibility,
622
- $editor_link['name'] => $editor_link['value'],
623
- )
624
- );
625
- return 1;
626
- }
627
- return 0;
628
  }
629
- return false;
630
  }
631
 
632
  /**
@@ -687,34 +678,28 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
687
  * @return int
688
  */
689
  protected function check_catalog_visibility_change( $oldpost ) {
690
- if (
691
- isset( $_POST['post_ID'] ) && isset( $_POST['_wpnonce'] )
692
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
693
- ) {
694
- // Get product data.
695
- $product_object = new WC_Product( $oldpost->ID );
696
- $old_visibility = $product_object->get_catalog_visibility();
697
- $new_visibility = isset( $_POST['_visibility'] ) ? sanitize_text_field( wp_unslash( $_POST['_visibility'] ) ) : false;
698
 
699
- // Get WooCommerce visibility options.
700
- $visibility_options = wc_get_product_visibility_options();
701
 
702
- if ( ( $old_visibility && $new_visibility ) && ( $old_visibility !== $new_visibility ) ) {
703
- $editor_link = $this->GetEditorLink( $oldpost );
704
- $this->plugin->alerts->Trigger(
705
- 9042, array(
706
- 'ProductTitle' => $oldpost->post_title,
707
- 'ProductStatus' => $oldpost->post_status,
708
- 'OldVisibility' => isset( $visibility_options[ $old_visibility ] ) ? $visibility_options[ $old_visibility ] : false,
709
- 'NewVisibility' => isset( $visibility_options[ $new_visibility ] ) ? $visibility_options[ $new_visibility ] : false,
710
- $editor_link['name'] => $editor_link['value'],
711
- )
712
- );
713
- return 1;
714
- }
715
- return 0;
716
  }
717
- return false;
718
  }
719
 
720
  /**
@@ -726,30 +711,24 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
726
  * @return int
727
  */
728
  protected function check_featured_product( $oldpost ) {
729
- if (
730
- isset( $_POST['post_ID'] ) && isset( $_POST['_wpnonce'] )
731
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
732
- ) {
733
- // Get product data.
734
- $product_object = new WC_Product( $oldpost->ID );
735
- $old_featured = $product_object->get_featured();
736
- $new_featured = isset( $_POST['_featured'] );
737
 
738
- if ( $old_featured !== $new_featured ) {
739
- $editor_link = $this->GetEditorLink( $oldpost );
740
- $this->plugin->alerts->Trigger(
741
- 9043, array(
742
- 'ProductTitle' => $oldpost->post_title,
743
- 'ProductStatus' => $oldpost->post_status,
744
- 'Status' => ( $new_featured ) ? 'Enabled' : 'Disabled',
745
- $editor_link['name'] => $editor_link['value'],
746
- )
747
- );
748
- return 1;
749
- }
750
- return 0;
751
  }
752
- return false;
753
  }
754
 
755
  /**
@@ -757,34 +736,34 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
757
  *
758
  * @since 3.3.1
759
  *
760
- * @param object $oldpost - Old product object.
 
 
761
  * @return int
762
  */
763
- protected function check_backorders_setting( $oldpost ) {
764
- if (
765
- isset( $_POST['post_ID'] ) && isset( $_POST['_wpnonce'] )
766
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
767
- ) {
768
- // Get product data.
769
  $old_backorder = get_post_meta( $oldpost->ID, '_backorders', true );
770
- $new_backorder = isset( $_POST['_backorders'] ) ? sanitize_text_field( wp_unslash( $_POST['_backorders'] ) ) : false;
 
 
 
771
 
772
- if ( $old_backorder !== $new_backorder ) {
773
- $editor_link = $this->GetEditorLink( $oldpost );
774
- $this->plugin->alerts->Trigger(
775
- 9044, array(
776
- 'ProductTitle' => $oldpost->post_title,
777
- 'ProductStatus' => $oldpost->post_status,
778
- 'OldStatus' => $old_backorder,
779
- 'NewStatus' => $new_backorder,
780
- $editor_link['name'] => $editor_link['value'],
781
- )
782
- );
783
- return 1;
784
- }
785
- return 0;
786
  }
787
- return false;
788
  }
789
 
790
  /**
@@ -796,66 +775,60 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
796
  * @return int
797
  */
798
  protected function check_upsells_change( $oldpost ) {
799
- if (
800
- isset( $_POST['post_ID'] ) && isset( $_POST['_wpnonce'] )
801
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
802
- ) {
803
- // Get product data.
804
- $old_upsell_ids = get_post_meta( $oldpost->ID, '_upsell_ids', true );
805
- $new_upsell_ids = isset( $_POST['upsell_ids'] ) ? array_map( 'sanitize_text_field', wp_unslash( $_POST['upsell_ids'] ) ) : false;
806
-
807
- // Compute the difference.
808
- $added_upsells = array();
809
- $removed_upsells = array();
810
- if ( is_array( $new_upsell_ids ) && is_array( $old_upsell_ids ) ) {
811
- $added_upsells = array_diff( $new_upsell_ids, $old_upsell_ids );
812
- $removed_upsells = array_diff( $old_upsell_ids, $new_upsell_ids );
813
- }
814
 
815
- // Get editor link.
816
- $editor_link = $this->GetEditorLink( $oldpost );
 
 
 
 
 
817
 
818
- // Return.
819
- $return = 0;
820
 
821
- // Added upsell products.
822
- if ( ! empty( $added_upsells ) && is_array( $added_upsells ) ) {
823
- foreach ( $added_upsells as $added_upsell ) {
824
- $upsell_title = get_the_title( $added_upsell );
825
- $this->plugin->alerts->Trigger(
826
- 9045, array(
827
- 'Status' => 'Added',
828
- 'ProductTitle' => $oldpost->post_title,
829
- 'ProductStatus' => $oldpost->post_status,
830
- 'UpsellTitle' => $upsell_title,
831
- 'UpsellID' => $added_upsell,
832
- $editor_link['name'] => $editor_link['value'],
833
- )
834
- );
835
- }
836
- $return = 1;
 
837
  }
 
 
838
 
839
- // Removed upsell products.
840
- if ( ! empty( $removed_upsells ) && is_array( $removed_upsells ) ) {
841
- foreach ( $removed_upsells as $removed_upsell ) {
842
- $upsell_title = get_the_title( $removed_upsell );
843
- $this->plugin->alerts->Trigger(
844
- 9045, array(
845
- 'Status' => 'Removed',
846
- 'ProductTitle' => $oldpost->post_title,
847
- 'ProductStatus' => $oldpost->post_status,
848
- 'UpsellTitle' => $upsell_title,
849
- 'UpsellID' => $removed_upsell,
850
- $editor_link['name'] => $editor_link['value'],
851
- )
852
- );
853
- }
854
- $return = 1;
855
  }
856
- return $return;
857
  }
858
- return false;
859
  }
860
 
861
  /**
@@ -867,66 +840,60 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
867
  * @return int
868
  */
869
  protected function check_cross_sell_change( $oldpost ) {
870
- if (
871
- isset( $_POST['post_ID'] ) && isset( $_POST['_wpnonce'] )
872
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
873
- ) {
874
- // Get product data.
875
- $old_cross_sell_ids = get_post_meta( $oldpost->ID, '_crosssell_ids', true );
876
- $new_cross_sell_ids = isset( $_POST['crosssell_ids'] ) ? array_map( 'sanitize_text_field', wp_unslash( $_POST['crosssell_ids'] ) ) : false;
877
-
878
- // Compute the difference.
879
- $added_cross_sells = array();
880
- $removed_cross_sells = array();
881
- if ( is_array( $new_cross_sell_ids ) && is_array( $old_cross_sell_ids ) ) {
882
- $added_cross_sells = array_diff( $new_cross_sell_ids, $old_cross_sell_ids );
883
- $removed_cross_sells = array_diff( $old_cross_sell_ids, $new_cross_sell_ids );
884
- }
885
 
886
- // Get editor link.
887
- $editor_link = $this->GetEditorLink( $oldpost );
 
 
 
 
 
888
 
889
- // Return.
890
- $return = 0;
891
 
892
- // Added cross-sell products.
893
- if ( ! empty( $added_cross_sells ) && is_array( $added_cross_sells ) ) {
894
- foreach ( $added_cross_sells as $added_cross_sell ) {
895
- $cross_sell_title = get_the_title( $added_cross_sell );
896
- $this->plugin->alerts->Trigger(
897
- 9046, array(
898
- 'Status' => 'Added',
899
- 'ProductTitle' => $oldpost->post_title,
900
- 'ProductStatus' => $oldpost->post_status,
901
- 'CrossSellTitle' => $cross_sell_title,
902
- 'CrossSellID' => $added_cross_sell,
903
- $editor_link['name'] => $editor_link['value'],
904
- )
905
- );
906
- }
907
- $return = 1;
 
908
  }
 
 
909
 
910
- // Removed cross-sell products.
911
- if ( ! empty( $removed_cross_sells ) && is_array( $removed_cross_sells ) ) {
912
- foreach ( $removed_cross_sells as $removed_cross_sell ) {
913
- $cross_sell_title = get_the_title( $removed_cross_sell );
914
- $this->plugin->alerts->Trigger(
915
- 9046, array(
916
- 'Status' => 'Removed',
917
- 'ProductTitle' => $oldpost->post_title,
918
- 'ProductStatus' => $oldpost->post_status,
919
- 'CrossSellTitle' => $cross_sell_title,
920
- 'CrossSellID' => $removed_cross_sell,
921
- $editor_link['name'] => $editor_link['value'],
922
- )
923
- );
924
- }
925
- $return = 1;
926
  }
927
- return $return;
928
  }
929
- return false;
930
  }
931
 
932
  /**
@@ -974,17 +941,21 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
974
  }
975
 
976
  if ( 'product' === $post->post_type ) {
977
- $this->plugin->alerts->Trigger( 9012, array(
978
- 'ProductTitle' => $post->post_title,
979
- 'ProductStatus' => $post->post_status,
980
- 'ProductUrl' => get_post_permalink( $post->ID ),
981
- ) );
 
 
982
  } elseif ( 'shop_order' === $post->post_type ) {
983
- $this->plugin->alerts->Trigger( 9037, array(
984
- 'OrderID' => $post->ID,
985
- 'OrderTitle' => $this->get_order_title( $post->ID ),
986
- 'OrderStatus' => $post->post_status,
987
- ) );
 
 
988
  }
989
  }
990
 
@@ -1019,18 +990,22 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1019
 
1020
  if ( 'product' === $post->post_type ) {
1021
  $editor_link = $this->GetEditorLink( $post );
1022
- $this->plugin->alerts->Trigger( 9014, array(
1023
- 'ProductTitle' => $post->post_title,
1024
- $editor_link['name'] => $editor_link['value'],
1025
- ) );
 
 
1026
  } elseif ( 'shop_order' === $post->post_type ) {
1027
  $editor_link = $this->GetEditorLink( $post );
1028
- $this->plugin->alerts->Trigger( 9038, array(
1029
- 'OrderID' => $post->ID,
1030
- 'OrderTitle' => $this->get_order_title( $post_id ),
1031
- 'OrderStatus' => $post->post_status,
1032
- $editor_link['name'] => $editor_link['value'],
1033
- ) );
 
 
1034
  }
1035
  }
1036
 
@@ -1123,28 +1098,22 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1123
  * @return int
1124
  */
1125
  protected function CheckPriceChange( $oldpost ) {
1126
- // Filter POST global array.
1127
- $post_array = filter_input_array( INPUT_POST );
 
1128
 
1129
- if (
1130
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
1131
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1132
- ) {
1133
- $result = 0;
1134
- $old_price = get_post_meta( $oldpost->ID, '_regular_price', true );
1135
- $old_sale_price = get_post_meta( $oldpost->ID, '_sale_price', true );
1136
- $new_price = isset( $post_array['_regular_price'] ) ? $post_array['_regular_price'] : null;
1137
- $new_sale_price = isset( $post_array['_sale_price'] ) ? $post_array['_sale_price'] : null;
1138
-
1139
- if ( ( $new_price ) && ( $old_price != $new_price ) ) {
1140
- $result = $this->EventPrice( $oldpost, 'Regular price', $old_price, $new_price );
1141
- }
1142
- if ( ( $new_sale_price ) && ( $old_sale_price != $new_sale_price ) ) {
1143
- $result = $this->EventPrice( $oldpost, 'Sale price', $old_sale_price, $new_sale_price );
1144
- }
1145
- return $result;
1146
  }
1147
- return false;
 
 
 
1148
  }
1149
 
1150
  /**
@@ -1176,103 +1145,88 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1176
  * Trigger events 9017
1177
  *
1178
  * @param object $oldpost - Old product object.
 
 
1179
  * @return int
1180
  */
1181
- protected function CheckSKUChange( $oldpost ) {
1182
- // Filter POST global array.
1183
- $post_array = filter_input_array( INPUT_POST );
1184
-
1185
- if (
1186
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
1187
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1188
- ) {
1189
  $old_sku = get_post_meta( $oldpost->ID, '_sku', true );
1190
- $new_sku = isset( $post_array['_sku'] ) ? $post_array['_sku'] : null;
 
1191
 
1192
- if ( ( $new_sku ) && ( $old_sku != $new_sku ) ) {
1193
- $editor_link = $this->GetEditorLink( $oldpost );
1194
- $this->plugin->alerts->Trigger(
1195
- 9017, array(
1196
- 'ProductTitle' => $oldpost->post_title,
1197
- 'ProductStatus' => $oldpost->post_status,
1198
- 'OldSku' => ( ! empty( $old_sku ) ? $old_sku : 0 ),
1199
- 'NewSku' => $new_sku,
1200
- $editor_link['name'] => $editor_link['value'],
1201
- )
1202
- );
1203
- return 1;
1204
- }
1205
- return 0;
1206
  }
1207
- return false;
1208
  }
1209
 
1210
  /**
1211
  * Trigger events 9018
1212
  *
1213
- * @param object $oldpost - Old product object.
 
 
1214
  * @return int
1215
  */
1216
- protected function CheckStockStatusChange( $oldpost ) {
1217
- // Filter POST global array.
1218
- $post_array = filter_input_array( INPUT_POST );
1219
-
1220
- if (
1221
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
1222
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1223
- ) {
1224
  $old_status = $this->_old_stock_status;
1225
- $new_status = isset( $post_array['_stock_status'] ) ? $post_array['_stock_status'] : null;
 
1226
 
1227
- if ( ( $old_status && $new_status ) && ( $old_status != $new_status ) ) {
1228
- $editor_link = $this->GetEditorLink( $oldpost );
1229
- $this->plugin->alerts->Trigger(
1230
- 9018, array(
1231
- 'ProductTitle' => $oldpost->post_title,
1232
- 'ProductStatus' => $oldpost->post_status,
1233
- 'OldStatus' => $this->GetStockStatusName( $old_status ),
1234
- 'NewStatus' => $this->GetStockStatusName( $new_status ),
1235
- $editor_link['name'] => $editor_link['value'],
1236
- )
1237
- );
1238
- return 1;
1239
- }
1240
- return 0;
1241
  }
1242
- return false;
1243
  }
1244
 
1245
  /**
1246
  * Trigger events 9019
1247
  *
1248
- * @param object $oldpost - Old product object.
 
 
1249
  * @return int
1250
  */
1251
- protected function CheckStockQuantityChange( $oldpost ) {
1252
- // Filter POST global array.
1253
- $post_array = filter_input_array( INPUT_POST );
1254
-
1255
- if (
1256
- isset( $post_array['post_ID'] )
1257
- && isset( $post_array['_wpnonce'] )
1258
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1259
- ) {
1260
  $old_value = (int) get_post_meta( $oldpost->ID, '_stock', true );
1261
- $new_value = isset( $post_array['_stock'] ) ? (int) $post_array['_stock'] : null;
 
1262
 
1263
- if ( $new_value && ( $old_value !== $new_value ) ) {
1264
- $editor_link = $this->GetEditorLink( $oldpost );
1265
- $this->plugin->alerts->Trigger(
1266
- 9019, array(
1267
- 'ProductTitle' => $oldpost->post_title,
1268
- 'ProductStatus' => $oldpost->post_status,
1269
- 'OldValue' => ( ! empty( $old_value ) ? $old_value : 0 ),
1270
- 'NewValue' => $new_value,
1271
- $editor_link['name'] => $editor_link['value'],
1272
- )
1273
- );
1274
- return 1;
1275
- }
1276
  }
1277
  return 0;
1278
  }
@@ -1280,59 +1234,76 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1280
  /**
1281
  * Trigger events 9020
1282
  *
1283
- * @param object $oldpost - Old product object.
1284
- * @param object $newpost - New product object.
 
 
1285
  * @return int
1286
  */
1287
- protected function CheckTypeChange( $oldpost, $newpost ) {
1288
- if (
1289
- isset( $_POST['post_ID'] ) && isset( $_POST['_wpnonce'] )
1290
- && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ), 'update-post_' . sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) )
1291
- ) {
1292
- if ( 'trash' !== $oldpost->post_status && 'trash' !== $newpost->post_status ) {
1293
- // Get simple product virtual data.
1294
- $old_virtual = get_post_meta( $oldpost->ID, '_virtual', true );
1295
- $new_virtual = isset( $_POST['_virtual'] ) ? 'yes' : 'no';
1296
 
1297
- // Get simple product downloadable data.
1298
- $old_download = get_post_meta( $oldpost->ID, '_downloadable', true );
1299
- $new_download = isset( $_POST['_downloadable'] ) ? 'yes' : 'no';
1300
 
1301
- // Return variable.
1302
- $result = 0;
 
 
 
1303
 
1304
- if ( $old_virtual && $new_virtual && $old_virtual !== $new_virtual ) {
1305
- $editor_link = $this->GetEditorLink( $oldpost );
1306
- $this->plugin->alerts->Trigger(
1307
- 9020, array(
1308
- 'ProductTitle' => $oldpost->post_title,
1309
- 'ProductStatus' => $oldpost->post_status,
1310
- 'OldType' => ( 'yes' === $old_virtual ) ? 'Virtual' : 'Non-Virtual',
1311
- 'NewType' => ( 'yes' === $new_virtual ) ? 'Virtual' : 'Non-Virtual',
1312
- $editor_link['name'] => $editor_link['value'],
1313
- )
1314
- );
1315
- $result = 1;
1316
- }
1317
 
1318
- if ( $old_download && $new_download && $old_download !== $new_download ) {
1319
- $editor_link = $this->GetEditorLink( $oldpost );
1320
- $this->plugin->alerts->Trigger(
1321
- 9020, array(
1322
- 'ProductTitle' => $oldpost->post_title,
1323
- 'ProductStatus' => $oldpost->post_status,
1324
- 'OldType' => ( 'yes' === $old_download ) ? 'Downloadable' : 'Non-Downloadable',
1325
- 'NewType' => ( 'yes' === $new_download ) ? 'Downloadable' : 'Non-Downloadable',
1326
- $editor_link['name'] => $editor_link['value'],
1327
- )
1328
- );
1329
- $result = 1;
1330
- }
1331
- return $result;
1332
- }
1333
- return 0;
1334
  }
1335
- return false;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1336
  }
1337
 
1338
  /**
@@ -1359,79 +1330,98 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1359
  /**
1360
  * Trigger events 9021
1361
  *
1362
- * @param object $oldpost - Old product object.
 
 
1363
  * @return int
1364
  */
1365
- protected function CheckWeightChange( $oldpost ) {
1366
- // Filter POST global array.
1367
- $post_array = filter_input_array( INPUT_POST );
1368
-
1369
- if (
1370
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
1371
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1372
- ) {
1373
  $old_weight = get_post_meta( $oldpost->ID, '_weight', true );
1374
- $new_weight = isset( $post_array['_weight'] ) ? $post_array['_weight'] : null;
 
1375
 
1376
- if ( ( $new_weight ) && ( $old_weight != $new_weight ) ) {
1377
- $editor_link = $this->GetEditorLink( $oldpost );
1378
- $this->plugin->alerts->Trigger(
1379
- 9021, array(
1380
- 'ProductTitle' => $oldpost->post_title,
1381
- 'ProductStatus' => $oldpost->post_status,
1382
- 'OldWeight' => ( ! empty( $old_weight ) ? $old_weight : 0 ),
1383
- 'NewWeight' => $new_weight,
1384
- $editor_link['name'] => $editor_link['value'],
1385
- )
1386
- );
1387
- return 1;
1388
- }
1389
- return 0;
1390
  }
1391
- return false;
1392
  }
1393
 
1394
  /**
1395
  * Trigger events 9022
1396
  *
1397
  * @param object $oldpost - Old product object.
 
 
 
1398
  * @return int
1399
  */
1400
- protected function CheckDimensionsChange( $oldpost ) {
1401
- // Filter POST global array.
1402
- $post_array = filter_input_array( INPUT_POST );
1403
 
1404
- if (
1405
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
1406
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1407
- ) {
1408
- $result = 0;
 
 
 
 
1409
  $old_length = get_post_meta( $oldpost->ID, '_length', true );
1410
- $new_length = isset( $post_array['_length'] ) ? $post_array['_length'] : null;
1411
- $old_width = get_post_meta( $oldpost->ID, '_width', true );
1412
- $new_width = isset( $post_array['_width'] ) ? $post_array['_width'] : null;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1413
  $old_height = get_post_meta( $oldpost->ID, '_height', true );
1414
- $new_height = isset( $post_array['_height'] ) ? $post_array['_height'] : null;
 
 
 
 
1415
 
1416
- if ( ( $new_length ) && ( $old_length != $new_length ) ) {
1417
- $result = $this->EventDimension( $oldpost, 'Length', $old_length, $new_length );
1418
- }
1419
- if ( ( $new_width ) && ( $old_width != $new_width ) ) {
1420
- $result = $this->EventDimension( $oldpost, 'Width', $old_width, $new_width );
1421
- }
1422
- if ( ( $new_height ) && ( $old_height != $new_height ) ) {
1423
- $result = $this->EventDimension( $oldpost, 'Height', $old_height, $new_height );
1424
- }
1425
- return $result;
1426
  }
1427
- return false;
 
 
 
 
 
 
1428
  }
1429
 
1430
  /**
1431
  * Group the Dimension changes in one function.
1432
  *
1433
- * @param object $oldpost - Old Product object.
1434
- * @param string $type - Dimension type.
1435
  * @param string $old_dimension - Old dimension.
1436
  * @param string $new_dimension - New dimension.
1437
  * @return int
@@ -1444,8 +1434,8 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1444
  'ProductTitle' => $oldpost->post_title,
1445
  'ProductStatus' => $oldpost->post_status,
1446
  'DimensionType' => $type,
1447
- 'OldDimension' => ( ! empty( $old_dimension ) ? $dimension_unit . ' ' . $old_dimension : 0 ),
1448
- 'NewDimension' => $dimension_unit . ' ' . $new_dimension,
1449
  $editor_link['name'] => $editor_link['value'],
1450
  )
1451
  );
@@ -1455,105 +1445,110 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1455
  /**
1456
  * Trigger events 9023, 9024, 9025, 9026
1457
  *
1458
- * @param object $oldpost - Old product object.
 
 
1459
  * @return int
1460
  */
1461
- protected function CheckDownloadableFileChange( $oldpost ) {
1462
- // Filter POST global array.
1463
- $post_array = filter_input_array( INPUT_POST );
 
 
 
1464
 
1465
- if (
1466
- isset( $post_array['post_ID'] ) && isset( $post_array['_wpnonce'] )
1467
- && wp_verify_nonce( $post_array['_wpnonce'], 'update-post_' . $post_array['post_ID'] )
1468
- ) {
1469
- $result = 0;
1470
- $is_url_changed = false;
1471
- $is_name_changed = false;
1472
- $new_file_names = ! empty( $post_array['_wc_file_names'] ) ? $post_array['_wc_file_names'] : array();
1473
- $new_file_urls = ! empty( $post_array['_wc_file_urls'] ) ? $post_array['_wc_file_urls'] : array();
1474
- $editor_link = $this->GetEditorLink( $oldpost );
1475
- $added_urls = array_diff( $new_file_urls, $this->_old_file_urls );
1476
-
1477
- // Added files to the product.
1478
- if ( count( $added_urls ) > 0 ) {
1479
- // If the file has only changed URL.
1480
- if ( count( $new_file_urls ) == count( $this->_old_file_urls ) ) {
1481
- $is_url_changed = true;
1482
- } else {
1483
- foreach ( $added_urls as $key => $url ) {
1484
- $this->plugin->alerts->Trigger(
1485
- 9023, array(
1486
- 'ProductTitle' => $oldpost->post_title,
1487
- 'ProductStatus' => $oldpost->post_status,
1488
- 'FileName' => $new_file_names[ $key ],
1489
- 'FileUrl' => $url,
1490
- $editor_link['name'] => $editor_link['value'],
1491
- )
1492
- );
1493
- }
1494
- $result = 1;
1495
- }
1496
- }
1497
 
1498
- $removed_urls = array_diff( $this->_old_file_urls, $new_file_urls );
1499
- // Removed files from the product.
1500
- if ( count( $removed_urls ) > 0 ) {
1501
- // If the file has only changed URL.
1502
- if ( count( $new_file_urls ) == count( $this->_old_file_urls ) ) {
1503
- $is_url_changed = true;
1504
- } else {
1505
- foreach ( $removed_urls as $key => $url ) {
1506
- $this->plugin->alerts->Trigger(
1507
- 9024, array(
1508
- 'ProductTitle' => $oldpost->post_title,
1509
- 'ProductStatus' => $oldpost->post_status,
1510
- 'FileName' => $this->_old_file_names[ $key ],
1511
- 'FileUrl' => $url,
1512
- $editor_link['name'] => $editor_link['value'],
1513
- )
1514
- );
1515
- }
1516
- $result = 1;
 
 
 
 
 
 
 
1517
  }
 
1518
  }
 
1519
 
1520
- $added_names = array_diff( $new_file_names, $this->_old_file_names );
1521
- if ( count( $added_names ) > 0 ) {
1522
- // If the file has only changed Name.
1523
- if ( count( $new_file_names ) == count( $this->_old_file_names ) ) {
1524
- foreach ( $added_names as $key => $name ) {
1525
- $this->plugin->alerts->Trigger(
1526
- 9025, array(
1527
- 'ProductTitle' => $oldpost->post_title,
1528
- 'ProductStatus' => $oldpost->post_status,
1529
- 'OldName' => $this->_old_file_names[ $key ],
1530
- 'NewName' => $name,
1531
- $editor_link['name'] => $editor_link['value'],
1532
- )
1533
- );
1534
- }
1535
- $result = 1;
1536
  }
 
1537
  }
 
1538
 
1539
- if ( $is_url_changed ) {
1540
- foreach ( $added_urls as $key => $url ) {
 
 
1541
  $this->plugin->alerts->Trigger(
1542
- 9026, array(
1543
  'ProductTitle' => $oldpost->post_title,
1544
  'ProductStatus' => $oldpost->post_status,
1545
- 'FileName' => $new_file_names[ $key ],
1546
- 'OldUrl' => $removed_urls[ $key ],
1547
- 'NewUrl' => $url,
1548
  $editor_link['name'] => $editor_link['value'],
1549
  )
1550
  );
1551
  }
1552
  $result = 1;
1553
  }
1554
- return $result;
1555
  }
1556
- return false;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1557
  }
1558
 
1559
  /**
@@ -1570,10 +1565,12 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1570
  $old_unit = $this->GetConfig( 'weight_unit' );
1571
  $new_unit = sanitize_text_field( wp_unslash( $_POST['woocommerce_weight_unit'] ) );
1572
  if ( $old_unit !== $new_unit ) {
1573
- $this->plugin->alerts->Trigger( 9027, array(
1574
- 'OldUnit' => $old_unit,
1575
- 'NewUnit' => $new_unit,
1576
- ) );
 
 
1577
  }
1578
  }
1579
 
@@ -1582,10 +1579,12 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1582
  $old_unit = $this->GetConfig( 'dimension_unit' );
1583
  $new_unit = sanitize_text_field( wp_unslash( $_POST['woocommerce_dimension_unit'] ) );
1584
  if ( $old_unit !== $new_unit ) {
1585
- $this->plugin->alerts->Trigger( 9028, array(
1586
- 'OldUnit' => $old_unit,
1587
- 'NewUnit' => $new_unit,
1588
- ) );
 
 
1589
  }
1590
  }
1591
  } elseif ( isset( $_GET['tab'] ) && 'account' === sanitize_text_field( wp_unslash( $_GET['tab'] ) ) ) {
@@ -1626,16 +1625,20 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1626
  if ( $old_gateway_status !== $new_gateway_status ) {
1627
  if ( 'yes' === $new_gateway_status ) {
1628
  // Gateway enabled.
1629
- $this->plugin->alerts->Trigger( 9074, array(
1630
- 'GatewayID' => $gateway,
1631
- 'GatewayName' => isset( $gateway_settings['title'] ) ? $gateway_settings['title'] : false,
1632
- ) );
 
 
1633
  } else {
1634
  // Gateway disabled.
1635
- $this->plugin->alerts->Trigger( 9075, array(
1636
- 'GatewayID' => $gateway,
1637
- 'GatewayName' => isset( $gateway_settings['title'] ) ? $gateway_settings['title'] : false,
1638
- ) );
 
 
1639
  }
1640
  $status_change = true;
1641
  }
@@ -1643,10 +1646,80 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1643
 
1644
  if ( $gateway && ! $status_change ) {
1645
  $gateway_settings = $this->GetConfig( $gateway . '_settings' );
1646
- $this->plugin->alerts->Trigger( 9076, array(
1647
- 'GatewayID' => $gateway,
1648
- 'GatewayName' => isset( $gateway_settings['title'] ) ? $gateway_settings['title'] : false,
1649
- ) );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1650
  }
1651
  } else {
1652
  // "Enable Coupon" event.
@@ -1662,10 +1735,12 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1662
  $old_location = $this->GetConfig( 'default_country' );
1663
  $new_location = sanitize_text_field( wp_unslash( $_POST['woocommerce_default_country'] ) );
1664
  if ( $old_location !== $new_location ) {
1665
- $this->plugin->alerts->Trigger( 9029, array(
1666
- 'OldLocation' => $old_location,
1667
- 'NewLocation' => $new_location,
1668
- ) );
 
 
1669
  }
1670
 
1671
  // Calculate taxes event.
@@ -1682,10 +1757,12 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1682
  $old_currency = $this->GetConfig( 'currency' );
1683
  $new_currency = sanitize_text_field( wp_unslash( $_POST['woocommerce_currency'] ) );
1684
  if ( $old_currency !== $new_currency ) {
1685
- $this->plugin->alerts->Trigger( 9031, array(
1686
- 'OldCurrency' => $old_currency,
1687
- 'NewCurrency' => $new_currency,
1688
- ) );
 
 
1689
  }
1690
  }
1691
  }
@@ -1719,22 +1796,77 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1719
  } else {
1720
  if ( ! wc_string_to_bool( $enabled ) ) {
1721
  // Gateway enabled.
1722
- $this->plugin->alerts->Trigger( 9074, array(
1723
- 'GatewayID' => $gateway->id,
1724
- 'GatewayName' => $gateway->title,
1725
- ) );
 
 
1726
  } else {
1727
  // Gateway disabled.
1728
- $this->plugin->alerts->Trigger( 9075, array(
1729
- 'GatewayID' => $gateway->id,
1730
- 'GatewayName' => $gateway->title,
1731
- ) );
 
 
1732
  }
1733
  }
1734
  }
1735
  }
1736
  }
1737
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1738
  }
1739
 
1740
  /**
@@ -1760,11 +1892,7 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
1760
  * @return array
1761
  */
1762
  protected function GetProductCategories( $post ) {
1763
- return wp_get_post_terms(
1764
- $post->ID, 'product_cat', array(
1765
- 'fields' => 'names',
1766
- )
1767
- );
1768
  }
1769
 
1770
  /**
@@ -2110,7 +2238,7 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2110
  if ( ! $order ) {
2111
  return false;
2112
  }
2113
- if ( is_integer( $order ) ) {
2114
  $order = new WC_Order( $order );
2115
  }
2116
  if ( ! $order instanceof WC_Order ) {
@@ -2217,12 +2345,14 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2217
  $edit_link = $this->GetEditorLink( $order_post );
2218
 
2219
  // Log event.
2220
- $this->plugin->alerts->Trigger( 9040, array(
2221
- 'OrderID' => $order_id,
2222
- 'OrderTitle' => $this->get_order_title( $order_id ),
2223
- 'OrderStatus' => $order_post->post_status,
2224
- $edit_link['name'] => $edit_link['value'],
2225
- ) );
 
 
2226
  }
2227
  }
2228
  return $order_ids;
@@ -2241,13 +2371,15 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2241
  $order_obj = get_post( $order_id );
2242
  $edit_link = $this->GetEditorLink( $order_obj );
2243
 
2244
- $this->plugin->alerts->Trigger( 9041, array(
2245
- 'OrderID' => $order_id,
2246
- 'RefundID' => $refund_id,
2247
- 'OrderTitle' => $this->get_order_title( $order_id ),
2248
- 'OrderStatus' => $order_obj->post_status,
2249
- $edit_link['name'] => $edit_link['value'],
2250
- ) );
 
 
2251
  }
2252
 
2253
  /**
@@ -2279,15 +2411,17 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2279
 
2280
  // Check id and attribute object.
2281
  if ( $id && ! is_null( $attribute ) ) {
2282
- $this->plugin->alerts->Trigger( 9058, array(
2283
- 'AttributeID' => $id,
2284
- 'AttributeName' => isset( $attribute->name ) ? $attribute->name : false,
2285
- 'AttributeSlug' => isset( $attribute->slug ) ? str_replace( 'pa_', '', $attribute->slug ) : false,
2286
- 'AttributeType' => isset( $attribute->type ) ? $attribute->type : false,
2287
- 'AttributeOrderby' => isset( $attribute->order_by ) ? $attribute->order_by : false,
2288
- 'AttributePublic' => isset( $attribute->has_archives ) ? $attribute->has_archives : '0',
2289
- 'Taxonomy' => $taxonomy,
2290
- ) );
 
 
2291
  }
2292
  }
2293
 
@@ -2413,6 +2547,20 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2413
  // Get the attributes data.
2414
  parse_str( $_POST['data'], $data );
2415
  $this->check_attributes_change( $post, $data );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2416
  } elseif ( in_array( $action, $wc_order_actions, true ) ) {
2417
  // Check nonce.
2418
  check_ajax_referer( 'order-item', 'security' );
@@ -2430,12 +2578,14 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2430
  $edit_link = $this->GetEditorLink( $order );
2431
 
2432
  // Log event.
2433
- $this->plugin->alerts->Trigger( 9040, array(
2434
- 'OrderID' => $order_id,
2435
- 'OrderTitle' => $this->get_order_title( $order_id ),
2436
- 'OrderStatus' => isset( $order->post_status ) ? $order->post_status : false,
2437
- $edit_link['name'] => $edit_link['value'],
2438
- ) );
 
 
2439
  }
2440
  }
2441
 
@@ -2489,14 +2639,16 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2489
  if ( ! empty( $added_attributes ) ) {
2490
  foreach ( $added_attributes as $added_attribute ) {
2491
  if ( $added_attribute && ! empty( $added_attribute['name'] ) ) {
2492
- $this->plugin->alerts->Trigger( 9047, array(
2493
- 'AttributeName' => $added_attribute['name'],
2494
- 'AttributeValue' => $added_attribute['value'],
2495
- 'ProductID' => $oldpost->ID,
2496
- 'ProductTitle' => $oldpost->post_title,
2497
- 'ProductStatus' => $oldpost->post_status,
2498
- $editor_link['name'] => $editor_link['value'],
2499
- ) );
 
 
2500
  $result = 1;
2501
  }
2502
  }
@@ -2505,15 +2657,17 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2505
  // Event 9050.
2506
  if ( ! empty( $deleted_attributes ) ) {
2507
  foreach ( $deleted_attributes as $deleted_attribute ) {
2508
- $this->plugin->alerts->Trigger( 9050, array(
2509
- 'AttributeName' => $deleted_attribute['name'],
2510
- 'AttributeValue' => $deleted_attribute['value'],
2511
- 'ProductID' => $oldpost->ID,
2512
- 'ProductTitle' => $oldpost->post_title,
2513
- 'ProductStatus' => $oldpost->post_status,
2514
- 'ProductUrl' => get_permalink( $oldpost->ID ),
2515
- $editor_link['name'] => $editor_link['value'],
2516
- ) );
 
 
2517
  $result = 1;
2518
  }
2519
  }
@@ -2540,43 +2694,49 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2540
 
2541
  // Value change.
2542
  if ( $old_value && $new_value && $old_value !== $new_value ) {
2543
- $this->plugin->alerts->Trigger( 9048, array(
2544
- 'AttributeName' => $new_attr['name'],
2545
- 'OldValue' => $old_value,
2546
- 'NewValue' => $new_value,
2547
- 'ProductID' => $oldpost->ID,
2548
- 'ProductTitle' => $oldpost->post_title,
2549
- 'ProductStatus' => $oldpost->post_status,
2550
- $editor_link['name'] => $editor_link['value'],
2551
- ) );
 
 
2552
  $result = 1;
2553
  }
2554
 
2555
  // Name change.
2556
  if ( $old_name && $new_name && $old_name !== $new_name ) {
2557
- $this->plugin->alerts->Trigger( 9049, array(
2558
- 'AttributeName' => $new_attr['name'],
2559
- 'OldValue' => $old_name,
2560
- 'NewValue' => $new_name,
2561
- 'ProductID' => $oldpost->ID,
2562
- 'ProductTitle' => $oldpost->post_title,
2563
- 'ProductStatus' => $oldpost->post_status,
2564
- 'ProductUrl' => get_permalink( $oldpost->ID ),
2565
- $editor_link['name'] => $editor_link['value'],
2566
- ) );
 
 
2567
  $result = 1;
2568
  }
2569
 
2570
  // Visibility change.
2571
  if ( ! empty( $new_attr['name'] ) && $old_visible !== $new_visible ) {
2572
- $this->plugin->alerts->Trigger( 9051, array(
2573
- 'AttributeName' => $new_attr['name'],
2574
- 'AttributeVisiblilty' => 1 === $new_visible ? __( 'Visible', 'wp-security-audit-log' ) : __( 'Non-Visible', 'wp-security-audit-log' ),
2575
- 'ProductID' => $oldpost->ID,
2576
- 'ProductTitle' => $oldpost->post_title,
2577
- 'ProductStatus' => $oldpost->post_status,
2578
- $editor_link['name'] => $editor_link['value'],
2579
- ) );
 
 
2580
  $result = 1;
2581
  }
2582
  }
@@ -2586,6 +2746,119 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2586
  return 0;
2587
  }
2588
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2589
  /**
2590
  * Returns the attribute key using attribute name.
2591
  *
@@ -2687,34 +2960,40 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2687
 
2688
  // Update if both slugs are not same.
2689
  if ( $old_slug !== $new_slug ) {
2690
- $this->plugin->alerts->Trigger( 9053, array(
2691
- 'CategoryID' => $term_id,
2692
- 'CategoryName' => $new_name,
2693
- 'OldSlug' => $old_slug,
2694
- 'NewSlug' => $new_slug,
2695
- ) );
 
 
2696
  }
2697
 
2698
  // Update if both parent categories are not same.
2699
  if ( $term->parent !== $new_parent_id ) {
2700
- $this->plugin->alerts->Trigger( 9054, array(
2701
- 'CategoryID' => $term_id,
2702
- 'CategoryName' => $new_name,
2703
- 'OldParentID' => isset( $old_parent_cat->term_id ) ? $old_parent_cat->term_id : false,
2704
- 'OldParentCat' => isset( $old_parent_cat->name ) ? $old_parent_cat->name : false,
2705
- 'NewParentID' => isset( $new_parent_cat->term_id ) ? $new_parent_cat->term_id : false,
2706
- 'NewParentCat' => isset( $new_parent_cat->name ) ? $new_parent_cat->name : false,
2707
- ) );
 
 
2708
  }
2709
 
2710
  // Update if both names are not same.
2711
  if ( $old_name !== $new_name ) {
2712
- $this->plugin->alerts->Trigger( 9056, array(
2713
- 'CategoryID' => $term_id,
2714
- 'CategoryName' => $new_name,
2715
- 'OldName' => $old_name,
2716
- 'NewName' => $new_name,
2717
- ) );
 
 
2718
  }
2719
  }
2720
  return $data;
@@ -2744,12 +3023,14 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2744
 
2745
  // Check if display type changed.
2746
  if ( $meta_value !== $old_display ) {
2747
- $this->plugin->alerts->Trigger( 9055, array(
2748
- 'CategoryID' => $object_id,
2749
- 'CategoryName' => $term->name,
2750
- 'OldDisplayType' => $old_display,
2751
- 'NewDisplayType' => $meta_value,
2752
- ) );
 
 
2753
  }
2754
  }
2755
 
@@ -2765,11 +3046,13 @@ class WSAL_Sensors_WooCommerce extends WSAL_AbstractSensor {
2765
  */
2766
  public function event_product_cat_deleted( $term_id, $tt_id, $deleted_term, $object_ids ) {
2767
  if ( 'product_cat' === $deleted_term->taxonomy ) {
2768
- $this->plugin->alerts->Trigger( 9052, array(
2769
- 'CategoryID' => $deleted_term->term_id,
2770
- 'CategoryName' => $deleted_term->name,
2771
- 'CategorySlug' => $deleted_term->slug,
2772
- ) );
 
 
2773
  }
2774
  }
2775
 
272
  // Global variable which returns current page.
273
  global $pagenow;
274
 
275
+ // @codingStandardsIgnoreStart
276
+ $wpnonce = isset( $_POST['_wpnonce'] ) ? sanitize_text_field( wp_unslash( $_POST['_wpnonce'] ) ) : false;
277
+ $post_id = isset( $_POST['post_ID'] ) ? sanitize_text_field( wp_unslash( $_POST['post_ID'] ) ) : false;
278
+ // @codingStandardsIgnoreEnd
279
+
280
+ if (
281
+ 'post.php' === $pagenow // Check post edit page.
282
+ && $this->CheckWooCommerce( $oldpost ) // Check WooCommerce CPT.
283
+ && is_admin() // Check if admin.
284
+ && $wpnonce && $post_id // Check post id and nonce exists.
285
+ && wp_verify_nonce( $wpnonce, 'update-post_' . $post_id ) // Verify nonce.
286
+ ) {
287
  $changes = 0 + $this->EventCreation( $oldpost, $newpost );
288
  if ( ! $changes ) {
289
  // Change Categories.
346
  * @param object $new_post - New Post.
347
  */
348
  private function EventCreation( $old_post, $new_post ) {
349
+ // Original post status.
350
+ $original = isset( $_POST['original_post_status'] ) ? sanitize_text_field( wp_unslash( $_POST['original_post_status'] ) ) : ''; // @codingStandardsIgnoreLine
 
 
 
 
 
 
 
 
 
351
 
352
+ // Ignore if original or new post type is draft.
353
+ if ( 'draft' === $original && 'draft' === $new_post->post_status ) {
354
+ return 0;
355
+ }
356
 
357
+ if ( 'draft' === $old_post->post_status || 'auto-draft' === $original ) {
358
+ if ( 'product' === $old_post->post_type ) {
359
+ $editor_link = $this->GetEditorLink( $new_post );
360
+ if ( 'draft' === $new_post->post_status ) {
361
+ $this->plugin->alerts->Trigger(
362
+ 9000, array(
363
  'ProductTitle' => $new_post->post_title,
364
  $editor_link['name'] => $editor_link['value'],
365
+ )
366
+ );
367
+ return 1;
368
+ } elseif ( 'publish' === $new_post->post_status ) {
369
+ $this->plugin->alerts->Trigger(
370
+ 9001, array(
371
  'ProductTitle' => $new_post->post_title,
372
  'ProductUrl' => get_post_permalink( $new_post->ID ),
373
  $editor_link['name'] => $editor_link['value'],
374
+ )
375
+ );
 
 
 
 
376
  return 1;
377
  }
378
+ } elseif ( 'shop_coupon' === $old_post->post_type && 'publish' === $new_post->post_status ) {
379
+ $coupon_data = $this->get_coupon_event_data( $new_post );
380
+ $this->plugin->alerts->Trigger( 9063, $coupon_data );
381
+ return 1;
382
  }
383
  }
384
  return 0;
502
  * @return int
503
  */
504
  protected function CheckPermalinkChange( $old_link, $new_link, $post ) {
505
+ if ( $old_link && $new_link && ( $old_link != $new_link ) ) {
506
  $editor_link = $this->GetEditorLink( $post );
507
  $this->plugin->alerts->Trigger(
508
  9006, array(
527
  * @return int
528
  */
529
  protected function CheckProductDataChange( $old_data, $post ) {
530
+ if ( isset( $_POST['product-type'] ) ) { // @codingStandardsIgnoreLine
531
+ $old_data = is_array( $old_data ) ? implode( ', ', $old_data ) : $old_data;
532
+ $new_data = sanitize_text_field( wp_unslash( $_POST['product-type'] ) ); // @codingStandardsIgnoreLine
 
 
 
 
 
 
533
 
534
+ if ( $old_data !== $new_data ) {
535
+ $editor_link = $this->GetEditorLink( $post );
536
+ $this->plugin->alerts->Trigger(
537
+ 9007, array(
538
+ 'ProductTitle' => $post->post_title,
539
+ 'ProductStatus' => $post->post_status,
540
+ 'OldType' => $old_data,
541
+ 'NewType' => $new_data,
542
+ $editor_link['name'] => $editor_link['value'],
543
+ )
544
+ );
545
+ return 1;
 
546
  }
 
547
  }
548
+ return 0;
549
  }
550
 
551
  /**
586
  * @return int
587
  */
588
  protected function CheckVisibilityChange( $oldpost ) {
589
+ // Get visibility data.
590
+ // @codingStandardsIgnoreStart
591
+ $old_visibility = isset( $_POST['hidden_post_visibility'] ) ? sanitize_text_field( wp_unslash( $_POST['hidden_post_visibility'] ) ) : null;
592
+ $new_visibility = isset( $_POST['visibility'] ) ? sanitize_text_field( wp_unslash( $_POST['visibility'] ) ) : null;
593
+ // @codingStandardsIgnoreEnd
 
 
 
 
594
 
595
+ if ( 'password' === $old_visibility ) {
596
+ $old_visibility = __( 'Password Protected', 'wp-security-audit-log' );
597
+ } else {
598
+ $old_visibility = ucfirst( $old_visibility );
599
+ }
600
 
601
+ if ( 'password' === $new_visibility ) {
602
+ $new_visibility = __( 'Password Protected', 'wp-security-audit-log' );
603
+ } else {
604
+ $new_visibility = ucfirst( $new_visibility );
605
+ }
606
 
607
+ if ( ( $old_visibility && $new_visibility ) && ( $old_visibility != $new_visibility ) ) {
608
+ $editor_link = $this->GetEditorLink( $oldpost );
609
+ $this->plugin->alerts->Trigger(
610
+ 9009, array(
611
+ 'ProductTitle' => $oldpost->post_title,
612
+ 'ProductStatus' => $oldpost->post_status,
613
+ 'OldVisibility' => $old_visibility,
614
+ 'NewVisibility' => $new_visibility,
615
+ $editor_link['name'] => $editor_link['value'],
616
+ )
617
+ );
618
+ return 1;
 
 
619
  }
620
+ return 0;
621
  }
622
 
623
  /**
678
  * @return int
679
  */
680
  protected function check_catalog_visibility_change( $oldpost ) {
681
+ // Get product data.
682
+ $product_object = new WC_Product( $oldpost->ID );
683
+ $old_visibility = $product_object->get_catalog_visibility();
684
+ $new_visibility = isset( $_POST['_visibility'] ) ? sanitize_text_field( wp_unslash( $_POST['_visibility'] ) ) : false; // @codingStandardsIgnoreLine
 
 
 
 
685
 
686
+ // Get WooCommerce visibility options.
687
+ $visibility_options = wc_get_product_visibility_options();
688
 
689
+ if ( ( $old_visibility && $new_visibility ) && ( $old_visibility !== $new_visibility ) ) {
690
+ $editor_link = $this->GetEditorLink( $oldpost );
691
+ $this->plugin->alerts->Trigger(
692
+ 9042, array(
693
+ 'ProductTitle' => $oldpost->post_title,
694
+ 'ProductStatus' => $oldpost->post_status,
695
+ 'OldVisibility' => isset( $visibility_options[ $old_visibility ] ) ? $visibility_options[ $old_visibility ] : false,
696
+ 'NewVisibility' => isset( $visibility_options[ $new_visibility ] ) ? $visibility_options[ $new_visibility ] : false,
697
+ $editor_link['name'] => $editor_link['value'],
698
+ )
699
+ );
700
+ return 1;
 
 
701
  }
702
+ return 0;
703
  }
704
 
705
  /**
711
  * @return int
712
  */
713
  protected function check_featured_product( $oldpost ) {
714
+ // Get product data.
715
+ $product_object = new WC_Product( $oldpost->ID );
716
+ $old_featured = $product_object->get_featured();
717
+ $new_featured = isset( $_POST['_featured'] ); // @codingStandardsIgnoreLine
 
 
 
 
718
 
719
+ if ( $old_featured !== $new_featured ) {
720
+ $editor_link = $this->GetEditorLink( $oldpost );
721
+ $this->plugin->alerts->Trigger(
722
+ 9043, array(
723
+ 'ProductTitle' => $oldpost->post_title,
724
+ 'ProductStatus' => $oldpost->post_status,
725
+ 'Status' => ( $new_featured ) ? 'Enabled' : 'Disabled',
726
+ $editor_link['name'] => $editor_link['value'],
727
+ )
728
+ );
729
+ return 1;
 
 
730
  }
731
+ return 0;
732
  }
733
 
734
  /**
736
  *
737
  * @since 3.3.1
738
  *
739
+ * @param object $oldpost - Old product object.
740
+ * @param string $old_backorder - Old backorder value.
741
+ * @param string $new_backorder - New backorder value.
742
  * @return int
743
  */
744
+ protected function check_backorders_setting( $oldpost, $old_backorder = '', $new_backorder = '' ) {
745
+ // Get product data.
746
+ if ( '' === $old_backorder ) {
 
 
 
747
  $old_backorder = get_post_meta( $oldpost->ID, '_backorders', true );
748
+ }
749
+ if ( '' === $new_backorder ) {
750
+ $new_backorder = isset( $_POST['_backorders'] ) ? sanitize_text_field( wp_unslash( $_POST['_backorders'] ) ) : false; // @codingStandardsIgnoreLine
751
+ }
752
 
753
+ if ( $old_backorder !== $new_backorder ) {
754
+ $editor_link = $this->GetEditorLink( $oldpost );
755
+ $this->plugin->alerts->Trigger(
756
+ 9044, array(
757
+ 'ProductTitle' => $oldpost->post_title,
758
+ 'ProductStatus' => $oldpost->post_status,
759
+ 'OldStatus' => $old_backorder,
760
+ 'NewStatus' => $new_backorder,
761
+ $editor_link['name'] => $editor_link['value'],
762
+ )
763
+ );
764
+ return 1;
 
 
765
  }
766
+ return 0;
767
  }
768
 
769
  /**
775
  * @return int
776
  */
777
  protected function check_upsells_change( $oldpost ) {
778
+ // Get product data.
779
+ $old_upsell_ids = get_post_meta( $oldpost->ID, '_upsell_ids', true );
780
+ $new_upsell_ids = isset( $_POST['upsell_ids'] ) ? array_map( 'sanitize_text_field', wp_unslash( $_POST['upsell_ids'] ) ) : false; // @codingStandardsIgnoreLine
 
 
 
 
 
 
 
 
 
 
 
 
781
 
782
+ // Compute the difference.
783
+ $added_upsells = array();
784
+ $removed_upsells = array();
785
+ if ( is_array( $new_upsell_ids ) && is_array( $old_upsell_ids ) ) {
786
+ $added_upsells = array_diff( $new_upsell_ids, $old_upsell_ids );
787
+ $removed_upsells = array_diff( $old_upsell_ids, $new_upsell_ids );
788
+ }
789
 
790
+ // Get editor link.
791
+ $editor_link = $this->GetEditorLink( $oldpost );
792
 
793
+ // Return.
794
+ $return = 0;
795
+
796
+ // Added upsell products.
797
+ if ( ! empty( $added_upsells ) && is_array( $added_upsells ) ) {
798
+ foreach ( $added_upsells as $added_upsell ) {
799
+ $upsell_title = get_the_title( $added_upsell );
800
+ $this->plugin->alerts->Trigger(
801
+ 9045, array(
802
+ 'Status' => 'Added',
803
+ 'ProductTitle' => $oldpost->post_title,
804
+ 'ProductStatus' => $oldpost->post_status,
805
+ 'UpsellTitle' => $upsell_title,
806
+ 'UpsellID' => $added_upsell,
807
+ $editor_link['name'] => $editor_link['value'],
808
+ )
809
+ );
810
  }
811
+ $return = 1;
812
+ }
813
 
814
+ // Removed upsell products.
815
+ if ( ! empty( $removed_upsells ) && is_array( $removed_upsells ) ) {
816
+ foreach ( $removed_upsells as $removed_upsell ) {
817
+ $upsell_title = get_the_title( $removed_upsell );
818
+ $this->plugin->alerts->Trigger(
819
+ 9045, array(
820
+ 'Status' => 'Removed',
821
+ 'ProductTitle' => $oldpost->post_title,
822
+ 'ProductStatus' => $oldpost->post_status,
823
+ 'UpsellTitle' => $upsell_title,
824
+ 'UpsellID' => $removed_upsell,
825
+ $editor_link['name'] => $editor_link['value'],
826
+ )
827
+ );
 
 
828
  }
829
+ $return = 1;
830
  }
831
+ return $return;
832
  }
833
 
834
  /**
840
  * @return int
841
  */
842
  protected function check_cross_sell_change( $oldpost ) {
843
+ // Get product data.
844
+ $old_cross_sell_ids = get_post_meta( $oldpost->ID, '_crosssell_ids', true );
845
+ $new_cross_sell_ids = isset( $_POST['crosssell_ids'] ) ? array_map( 'sanitize_text_field', wp_unslash( $_POST['crosssell_ids'] ) ) : false; // @codingStandardsIgnoreLine
 
 
 
 
 
 
 
 
 
 
 
 
846
 
847
+ // Compute the difference.
848
+ $added_cross_sells = array();
849
+ $removed_cross_sells = array();
850
+ if ( is_array( $new_cross_sell_ids ) && is_array( $old_cross_sell_ids ) ) {
851
+ $added_cross_sells = array_diff( $new_cross_sell_ids, $old_cross_sell_ids );
852
+ $removed_cross_sells = array_diff( $old_cross_sell_ids, $new_cross_sell_ids );
853
+ }
854
 
855
+ // Get editor link.
856
+ $editor_link = $this->GetEditorLink( $oldpost );
857
 
858
+ // Return.
859
+ $return = 0;
860
+
861
+ // Added cross-sell products.
862
+ if ( ! empty( $added_cross_sells ) && is_array( $added_cross_sells ) ) {
863
+ foreach ( $added_cross_sells as $added_cross_sell ) {
864
+ $cross_sell_title = get_the_title( $added_cross_sell );
865
+ $this->plugin->alerts->Trigger(
866
+ 9046, array(
867
+ 'Status' => 'Added',
868
+ 'ProductTitle' => $oldpost->post_title,
869
+ 'ProductStatus' => $oldpost->post_status,
870
+ 'CrossSellTitle' => $cross_sell_title,
871
+ 'CrossSellID' => $added_cross_sell,
872
+ $editor_link['name'] => $editor_link['value'],
873
+ )
874
+ );
875
  }
876
+ $return = 1;
877
+ }
878
 
879
+ // Removed cross-sell products.
880
+ if ( ! empty( $removed_cross_sells ) && is_array( $removed_cross_sells ) ) {
881
+ foreach ( $removed_cross_sells as $removed_cross_sell ) {
882
+ $cross_sell_title = get_the_title( $removed_cross_sell );
883
+ $this->plugin->alerts->Trigger(
884
+ 9046, array(
885
+ 'Status' => 'Removed',
886
+ 'ProductTitle' => $oldpost->post_title,
887
+ 'ProductStatus' => $oldpost->post_status,
888
+ 'CrossSellTitle' => $cross_sell_title,
889
+ 'CrossSellID' => $removed_cross_sell,
890
+ $editor_link['name'] => $editor_link['value'],
891
+ )
892
+ );
 
 
893
  }
894
+ $return = 1;
895
  }
896
+ return $return;
897
  }
898
 
899
  /**
941
  }
942
 
943
  if ( 'product' === $post->post_type ) {
944
+ $this->plugin->alerts->Trigger(
945
+ 9012, array(
946
+ 'ProductTitle' => $post->post_title,
947
+ 'ProductStatus' => $post->post_status,
948
+ 'ProductUrl' => get_post_permalink( $post->ID ),
949
+ )
950
+ );
951
  } elseif ( 'shop_order' === $post->post_type ) {
952
+ $this->plugin->alerts->Trigger(
953
+ 9037, array(
954
+ 'OrderID' => $post->ID,
955
+ 'OrderTitle' => $this->get_order_title( $post->ID ),
956
+ 'OrderStatus' => $post->post_status,
957
+ )
958
+ );
959
  }
960
  }
961
 
990
 
991
  if ( 'product' === $post->post_type ) {
992
  $editor_link = $this->GetEditorLink( $post );
993
+ $this->plugin->alerts->Trigger(
994
+ 9014, array(
995
+ 'ProductTitle' => $post->post_title,
996
+ $editor_link['name'] => $editor_link['value'],
997
+ )
998
+ );
999
  } elseif ( 'shop_order' === $post->post_type ) {
1000
  $editor_link = $this->GetEditorLink( $post );
1001
+ $this->plugin->alerts->Trigger(
1002
+ 9038, array(
1003
+ 'OrderID' => $post->ID,
1004
+ 'OrderTitle' => $this->get_order_title( $post_id ),
1005
+ 'OrderStatus' => $post->post_status,
1006
+ $editor_link['name'] => $editor_link['value'],
1007
+ )
1008
+ );
1009
  }
1010
  }
1011
 
1098
  * @return int
1099
  */
1100
  protected function CheckPriceChange( $oldpost ) {
1101
+ $result = 0;
1102
+ $old_price = get_post_meta( $oldpost->ID, '_regular_price', true );
1103
+ $old_sale_price = get_post_meta( $oldpost->ID, '_sale_price', true );
1104
 
1105
+ // @codingStandardsIgnoreStart
1106
+ $new_price = isset( $_POST['_regular_price'] ) ? sanitize_text_field( wp_unslash( $_POST['_regular_price'] ) ) : null;
1107
+ $new_sale_price = isset( $_POST['_sale_price'] ) ? sanitize_text_field( wp_unslash( $_POST['_sale_price'] ) ) : null;
1108
+ // @codingStandardsIgnoreEnd
1109
+
1110
+ if ( ( $new_price ) && ( $old_price !== $new_price ) ) {
1111
+ $result = $this->EventPrice( $oldpost, 'Regular price', $old_price, $new_price );
 
 
 
 
 
 
 
 
 
 
1112
  }
1113
+ if ( ( $new_sale_price ) && ( $old_sale_price !== $new_sale_price ) ) {
1114
+ $result = $this->EventPrice( $oldpost, 'Sale price', $old_sale_price, $new_sale_price );
1115
+ }
1116
+ return $result;
1117
  }
1118
 
1119
  /**
1145
  * Trigger events 9017
1146
  *
1147
  * @param object $oldpost - Old product object.
1148
+ * @param string $old_sku - Old SKU.
1149
+ * @param string $new_sku - New SKU.
1150
  * @return int
1151
  */
1152
+ protected function CheckSKUChange( $oldpost, $old_sku = '', $new_sku = '' ) {
1153
+ if ( '' === $old_sku && '' === $new_sku ) {
 
 
 
 
 
 
1154
  $old_sku = get_post_meta( $oldpost->ID, '_sku', true );
1155
+ $new_sku = isset( $_POST['_sku'] ) ? sanitize_text_field( wp_unslash( $_POST['_sku'] ) ) : null; // @codingStandardsIgnoreLine
1156
+ }
1157
 
1158
+ if ( $new_sku && ( $old_sku !== $new_sku ) ) {
1159
+ $editor_link = $this->GetEditorLink( $oldpost );
1160
+ $this->plugin->alerts->Trigger(
1161
+ 9017, array(
1162
+ 'ProductTitle' => $oldpost->post_title,
1163
+ 'ProductStatus' => $oldpost->post_status,
1164
+ 'OldSku' => ( ! empty( $old_sku ) ? $old_sku : 0 ),
1165
+ 'NewSku' => $new_sku,
1166
+ $editor_link['name'] => $editor_link['value'],
1167
+ )
1168
+ );
1169
+ return 1;
 
 
1170
  }
1171
+ return 0;
1172
  }
1173
 
1174
  /**
1175
  * Trigger events 9018
1176
  *
1177
+ * @param object $oldpost - Old product object.
1178
+ * @param string $old_status - Old status.
1179
+ * @param string $new_status - New status.
1180
  * @return int
1181
  */
1182
+ protected function CheckStockStatusChange( $oldpost, $old_status = '', $new_status = '' ) {
1183
+ if ( '' === $old_status && '' === $new_status ) {
 
 
 
 
 
 
1184
  $old_status = $this->_old_stock_status;
1185
+ $new_status = isset( $_POST['_stock_status'] ) ? sanitize_text_field( wp_unslash( $_POST['_stock_status'] ) ) : null; // @codingStandardsIgnoreLine
1186
+ }
1187
 
1188
+ if ( ( $old_status && $new_status ) && ( $old_status !== $new_status ) ) {
1189
+ $editor_link = $this->GetEditorLink( $oldpost );
1190
+ $this->plugin->alerts->Trigger(
1191
+ 9018, array(
1192
+ 'ProductTitle' => $oldpost->post_title,
1193
+ 'ProductStatus' => $oldpost->post_status,
1194
+ 'OldStatus' => $this->GetStockStatusName( $old_status ),
1195
+ 'NewStatus' => $this->GetStockStatusName( $new_status ),
1196
+ $editor_link['name'] => $editor_link['value'],
1197
+ )
1198
+ );
1199
+ return 1;
 
 
1200
  }
1201
+ return 0;
1202
  }
1203
 
1204
  /**
1205
  * Trigger events 9019
1206
  *
1207
+ * @param object $oldpost - Old product object.
1208
+ * @param mixed $old_value - Old stock quantity.
1209
+ * @param mixed $new_value - New stock quantity.
1210
  * @return int
1211
  */
1212
+ protected function CheckStockQuantityChange( $oldpost, $old_value = false, $new_value = false ) {
1213
+ if ( false === $old_value && false === $new_value ) {
 
 
 
 
 
 
 
1214
  $old_value = (int) get_post_meta( $oldpost->ID, '_stock', true );
1215
+ $new_value = isset( $_POST['_stock'] ) ? (int) sanitize_text_field( wp_unslash( $_POST['_stock'] ) ) : null; // @codingStandardsIgnoreLine
1216
+ }
1217
 
1218
+ if ( $new_value && ( $old_value !== $new_value ) ) {
1219
+ $editor_link = $this->GetEditorLink( $oldpost );
1220
+ $this->plugin->alerts->Trigger(
1221
+ 9019, array(
1222
+ 'ProductTitle' => $oldpost->post_title,
1223
+ 'ProductStatus' => $oldpost->post_status,
1224
+ 'OldValue' => ! empty( $old_value ) ? $old_value : 0,
1225
+ 'NewValue' => $new_value,
1226
+ $editor_link['name'] => $editor_link['value'],
1227
+ )
1228
+ );
1229
+ return 1;
 
1230
  }
1231
  return 0;
1232
  }
1234
  /**
1235
  * Trigger events 9020
1236
  *
1237
+ * @param object $oldpost - Old product object.
1238
+ * @param object $newpost - New product object.
1239
+ * @param mixed $virtual - Product virtual data.
1240
+ * @param mixed $download - Product downloadable data.
1241
  * @return int
1242
  */
1243
+ protected function CheckTypeChange( $oldpost, $newpost = null, $virtual = false, $download = false ) {
1244
+ if ( 'trash' === $oldpost->post_status ) {
1245
+ return 0;
1246
+ }
 
 
 
 
 
1247
 
1248
+ if ( $newpost && $newpost instanceof WP_Post && 'trash' === $newpost->post_status ) {
1249
+ return 0;
1250
+ }
1251
 
1252
+ // Set initial variables.
1253
+ $old_virtual = false;
1254
+ $new_virtual = false;
1255
+ $old_download = false;
1256
+ $new_download = false;
1257
 
1258
+ // Get simple product virtual data.
1259
+ if ( false === $virtual ) {
1260
+ $old_virtual = get_post_meta( $oldpost->ID, '_virtual', true );
1261
+ $new_virtual = isset( $_POST['_virtual'] ) ? 'yes' : 'no'; // @codingStandardsIgnoreLine
1262
+ } elseif ( is_array( $virtual ) ) {
1263
+ $old_virtual = ( isset( $virtual['old'] ) && $virtual['old'] ) ? 'yes' : 'no';
1264
+ $new_virtual = ( isset( $virtual['new'] ) && $virtual['new'] ) ? 'yes' : 'no';
1265
+ }
 
 
 
 
 
1266
 
1267
+ // Get simple product downloadable data.
1268
+ if ( false === $download ) {
1269
+ $old_download = get_post_meta( $oldpost->ID, '_downloadable', true );
1270
+ $new_download = isset( $_POST['_downloadable'] ) ? 'yes' : 'no'; // @codingStandardsIgnoreLine
1271
+ } elseif ( is_array( $download ) ) {
1272
+ $old_download = ( isset( $download['old'] ) && $download['old'] ) ? 'yes' : 'no';
1273
+ $new_download = ( isset( $download['new'] ) && $download['new'] ) ? 'yes' : 'no';
 
 
 
 
 
 
 
 
 
1274
  }
1275
+
1276
+ // Return variable.
1277
+ $result = 0;
1278
+
1279
+ if ( $old_virtual && $new_virtual && $old_virtual !== $new_virtual ) {
1280
+ $editor_link = $this->GetEditorLink( $oldpost );
1281
+ $this->plugin->alerts->Trigger(
1282
+ 9020, array(
1283
+ 'ProductTitle' => $oldpost->post_title,
1284
+ 'ProductStatus' => $oldpost->post_status,
1285
+ 'OldType' => ( 'yes' === $old_virtual ) ? 'Virtual' : 'Non-Virtual',
1286
+ 'NewType' => ( 'yes' === $new_virtual ) ? 'Virtual' : 'Non-Virtual',
1287
+ $editor_link['name'] => $editor_link['value'],
1288
+ )
1289
+ );
1290
+ $result = 1;
1291
+ }
1292
+
1293
+ if ( $old_download && $new_download && $old_download !== $new_download ) {
1294
+ $editor_link = $this->GetEditorLink( $oldpost );
1295
+ $this->plugin->alerts->Trigger(
1296
+ 9020, array(
1297
+ 'ProductTitle' => $oldpost->post_title,
1298
+ 'ProductStatus' => $oldpost->post_status,
1299
+ 'OldType' => ( 'yes' === $old_download ) ? 'Downloadable' : 'Non-Downloadable',
1300
+ 'NewType' => ( 'yes' === $new_download ) ? 'Downloadable' : 'Non-Downloadable',
1301
+ $editor_link['name'] => $editor_link['value'],
1302
+ )
1303
+ );
1304
+ $result = 1;
1305
+ }
1306
+ return $result;
1307
  }
1308
 
1309
  /**
1330
  /**
1331
  * Trigger events 9021
1332
  *
1333
+ * @param object $oldpost - Old product object.
1334
+ * @param string $old_weight - (Optional) Old weight.
1335
+ * @param string $new_weight - (Optional) New weight.
1336
  * @return int
1337
  */
1338
+ protected function CheckWeightChange( $oldpost, $old_weight = '', $new_weight = '' ) {
1339
+ if ( '' === $old_weight && '' === $new_weight ) {
 
 
 
 
 
 
1340
  $old_weight = get_post_meta( $oldpost->ID, '_weight', true );
1341
+ $new_weight = isset( $_POST['_weight'] ) ? sanitize_text_field( wp_unslash( $_POST['_weight'] ) ) : null; // @codingStandardsIgnoreLine
1342
+ }
1343
 
1344
+ if ( $new_weight && ( $old_weight !== $new_weight ) ) {
1345
+ $weight_unit = $this->GetConfig( 'weight_unit' );
1346
+ $editor_link = $this->GetEditorLink( $oldpost );
1347
+ $this->plugin->alerts->Trigger(
1348
+ 9021, array(
1349
+ 'ProductTitle' => $oldpost->post_title,
1350
+ 'ProductStatus' => $oldpost->post_status,
1351
+ 'OldWeight' => ! empty( $old_weight ) ? $old_weight . ' ' . $weight_unit : 0,
1352
+ 'NewWeight' => $new_weight . ' ' . $weight_unit,
1353
+ $editor_link['name'] => $editor_link['value'],
1354
+ )
1355
+ );
1356
+ return 1;
 
1357
  }
1358
+ return 0;
1359
  }
1360
 
1361
  /**
1362
  * Trigger events 9022
1363
  *
1364
  * @param object $oldpost - Old product object.
1365
+ * @param mixed $length - (Optional) Product lenght.
1366
+ * @param mixed $width - (Optional) Product width.
1367
+ * @param mixed $height - (Optional) Product height.
1368
  * @return int
1369
  */
1370
+ protected function CheckDimensionsChange( $oldpost, $length = false, $width = false, $height = false ) {
1371
+ // Get product dimensions data.
1372
+ $result = 0;
1373
 
1374
+ $old_length = false;
1375
+ $new_length = false;
1376
+ $old_width = false;
1377
+ $new_width = false;
1378
+ $old_height = false;
1379
+ $new_height = false;
1380
+
1381
+ // Length.
1382
+ if ( false === $length ) {
1383
  $old_length = get_post_meta( $oldpost->ID, '_length', true );
1384
+ $new_length = isset( $_POST['_length'] ) ? sanitize_text_field( wp_unslash( $_POST['_length'] ) ) : null; // @codingStandardsIgnoreLine
1385
+ } elseif ( is_array( $length ) ) {
1386
+ $old_length = isset( $length['old'] ) ? $length['old'] : false;
1387
+ $new_length = isset( $length['new'] ) ? $length['new'] : false;
1388
+ }
1389
+
1390
+ // Width.
1391
+ if ( false === $width ) {
1392
+ $old_width = get_post_meta( $oldpost->ID, '_width', true );
1393
+ $new_width = isset( $_POST['_width'] ) ? sanitize_text_field( wp_unslash( $_POST['_width'] ) ) : null; // @codingStandardsIgnoreLine
1394
+ } elseif ( is_array( $width ) ) {
1395
+ $old_width = isset( $width['old'] ) ? $width['old'] : false;
1396
+ $new_width = isset( $width['new'] ) ? $width['new'] : false;
1397
+ }
1398
+
1399
+ // Height.
1400
+ if ( false === $height ) {
1401
  $old_height = get_post_meta( $oldpost->ID, '_height', true );
1402
+ $new_height = isset( $_POST['_height'] ) ? sanitize_text_field( wp_unslash( $_POST['_height'] ) ) : null; // @codingStandardsIgnoreLine
1403
+ } elseif ( is_array( $height ) ) {
1404
+ $old_height = isset( $height['old'] ) ? $height['old'] : false;
1405
+ $new_height = isset( $height['new'] ) ? $height['new'] : false;
1406
+ }
1407
 
1408
+ if ( $new_length && ( $old_length !== $new_length ) ) {
1409
+ $result = $this->EventDimension( $oldpost, 'Length', $old_length, $new_length );
 
 
 
 
 
 
 
 
1410
  }
1411
+ if ( $new_width && ( $old_width !== $new_width ) ) {
1412
+ $result = $this->EventDimension( $oldpost, 'Width', $old_width, $new_width );
1413
+ }
1414
+ if ( $new_height && ( $old_height !== $new_height ) ) {
1415
+ $result = $this->EventDimension( $oldpost, 'Height', $old_height, $new_height );
1416
+ }
1417
+ return $result;
1418
  }
1419
 
1420
  /**
1421
  * Group the Dimension changes in one function.
1422
  *
1423
+ * @param object $oldpost - Old Product object.
1424
+ * @param string $type - Dimension type.
1425
  * @param string $old_dimension - Old dimension.
1426
  * @param string $new_dimension - New dimension.
1427
  * @return int
1434
  'ProductTitle' => $oldpost->post_title,
1435
  'ProductStatus' => $oldpost->post_status,
1436
  'DimensionType' => $type,
1437
+ 'OldDimension' => ! empty( $old_dimension ) ? $old_dimension . ' ' . $dimension_unit : 0,
1438
+ 'NewDimension' => $new_dimension . ' ' . $dimension_unit,
1439
  $editor_link['name'] => $editor_link['value'],
1440
  )
1441
  );
1445
  /**
1446
  * Trigger events 9023, 9024, 9025, 9026
1447
  *
1448
+ * @param object $oldpost - Old product object.
1449
+ * @param mixed $file_names - (Optional) New product file names.
1450
+ * @param mixed $file_urls - (Optional) New product file urls.
1451
  * @return int
1452
  */
1453
+ protected function CheckDownloadableFileChange( $oldpost, $file_names = false, $file_urls = false ) {
1454
+ // Get product data.
1455
+ $result = 0;
1456
+ $is_url_changed = false;
1457
+ $is_name_changed = false;
1458
+ $editor_link = $this->GetEditorLink( $oldpost );
1459
 
1460
+ if ( false === $file_names ) {
1461
+ $new_file_names = ! empty( $_POST['_wc_file_names'] ) ? array_map( 'sanitize_text_field', wp_unslash( $_POST['_wc_file_names'] ) ) : array(); // @codingStandardsIgnoreLine
1462
+ } else {
1463
+ $new_file_names = $file_names;
1464
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1465
 
1466
+ if ( false === $file_urls ) {
1467
+ $new_file_urls = ! empty( $_POST['_wc_file_urls'] ) ? array_map( 'esc_url_raw', wp_unslash( $_POST['_wc_file_urls'] ) ) : array(); // @codingStandardsIgnoreLine
1468
+ } else {
1469
+ $new_file_urls = $file_urls;
1470
+ }
1471
+
1472
+ $added_urls = array_diff( $new_file_urls, $this->_old_file_urls );
1473
+ $removed_urls = array_diff( $this->_old_file_urls, $new_file_urls );
1474
+ $added_names = array_diff( $new_file_names, $this->_old_file_names );
1475
+
1476
+ // Added files to the product.
1477
+ if ( count( $added_urls ) > 0 ) {
1478
+ // If the file has only changed URL.
1479
+ if ( count( $new_file_urls ) === count( $this->_old_file_urls ) ) {
1480
+ $is_url_changed = true;
1481
+ } else {
1482
+ foreach ( $added_urls as $key => $url ) {
1483
+ $this->plugin->alerts->Trigger(
1484
+ 9023, array(
1485
+ 'ProductTitle' => $oldpost->post_title,
1486
+ 'ProductStatus' => $oldpost->post_status,
1487
+ 'FileName' => $new_file_names[ $key ],
1488
+ 'FileUrl' => $url,
1489
+ $editor_link['name'] => $editor_link['value'],
1490
+ )
1491
+ );
1492
  }
1493
+ $result = 1;
1494
  }
1495
+ }
1496
 
1497
+ // Removed files from the product.
1498
+ if ( count( $removed_urls ) > 0 ) {
1499
+ // If the file has only changed URL.
1500
+ if ( count( $new_file_urls ) === count( $this->_old_file_urls ) ) {
1501
+ $is_url_changed = true;
1502
+ } else {
1503
+ foreach ( $removed_urls as $key => $url ) {
1504
+ $this->plugin->alerts->Trigger(
1505
+ 9024, array(
1506
+ 'ProductTitle' => $oldpost->post_title,
1507
+ 'ProductStatus' => $oldpost->post_status,
1508
+ 'FileName' => $this->_old_file_names[ $key ],
1509
+ 'FileUrl' => $url,
1510
+ $editor_link['name'] => $editor_link['value'],
1511
+ )
1512
+ );
1513
  }
1514
+ $result = 1;
1515
  }
1516
+ }
1517
 
1518
+ if ( count( $added_names ) > 0 ) {
1519
+ // If the file has only changed Name.
1520
+ if ( count( $new_file_names ) === count( $this->_old_file_names ) ) {
1521
+ foreach ( $added_names as $key => $name ) {
1522
  $this->plugin->alerts->Trigger(
1523
+ 9025, array(
1524
  'ProductTitle' => $oldpost->post_title,
1525
  'ProductStatus' => $oldpost->post_status,
1526
+ 'OldName' => $this->_old_file_names[ $key ],
1527
+ 'NewName' => $name,
 
1528
  $editor_link['name'] => $editor_link['value'],
1529
  )
1530
  );
1531
  }
1532
  $result = 1;
1533
  }
 
1534
  }
1535
+
1536
+ if ( $is_url_changed ) {
1537
+ foreach ( $added_urls as $key => $url ) {
1538
+ $this->plugin->alerts->Trigger(
1539
+ 9026, array(
1540
+ 'ProductTitle' => $oldpost->post_title,
1541
+ 'ProductStatus' => $oldpost->post_status,
1542
+ 'FileName' => $new_file_names[ $key ],
1543
+ 'OldUrl' => $removed_urls[ $key ],
1544
+ 'NewUrl' => $url,
1545
+ $editor_link['name'] => $editor_link['value'],
1546
+ )
1547
+ );
1548
+ }
1549
+ $result = 1;
1550
+ }
1551
+ return $result;
1552
  }
1553
 
1554
  /**
1565
  $old_unit = $this->GetConfig( 'weight_unit' );
1566
  $new_unit = sanitize_text_field( wp_unslash( $_POST['woocommerce_weight_unit'] ) );
1567
  if ( $old_unit !== $new_unit ) {
1568
+ $this->plugin->alerts->Trigger(
1569
+ 9027, array(
1570
+ 'OldUnit' => $old_unit,
1571
+ 'NewUnit' => $new_unit,
1572
+ )
1573
+ );
1574
  }
1575
  }
1576
 
1579
  $old_unit = $this->GetConfig( 'dimension_unit' );
1580
  $new_unit = sanitize_text_field( wp_unslash( $_POST['woocommerce_dimension_unit'] ) );
1581
  if ( $old_unit !== $new_unit ) {
1582
+ $this->plugin->alerts->Trigger(
1583
+ 9028, array(
1584
+ 'OldUnit' => $old_unit,
1585
+ 'NewUnit' => $new_unit,
1586
+ )
1587
+ );
1588
  }
1589
  }
1590
  } elseif ( isset( $_GET['tab'] ) && 'account' === sanitize_text_field( wp_unslash( $_GET['tab'] ) ) ) {
1625
  if ( $old_gateway_status !== $new_gateway_status ) {
1626
  if ( 'yes' === $new_gateway_status ) {
1627
  // Gateway enabled.
1628
+ $this->plugin->alerts->Trigger(
1629
+ 9074, array(
1630
+ 'GatewayID' => $gateway,
1631
+ 'GatewayName' => isset( $gateway_settings['title'] ) ? $gateway_settings['title'] : false,
1632
+ )
1633
+ );
1634
  } else {
1635
  // Gateway disabled.
1636
+ $this->plugin->alerts->Trigger(
1637
+ 9075, array(
1638
+ 'GatewayID' => $gateway,
1639
+ 'GatewayName' => isset( $gateway_settings['title'] ) ? $gateway_settings['title'] : false,
1640
+ )
1641
+ );
1642
  }
1643
  $status_change = true;
1644
  }
1646
 
1647
  if ( $gateway && ! $status_change ) {
1648
  $gateway_settings = $this->GetConfig( $gateway . '_settings' );
1649
+ $this->plugin->alerts->Trigger(
1650
+ 9076, array(
1651
+ 'GatewayID' => $gateway,
1652
+ 'GatewayName' => isset( $gateway_settings['title'] ) ? $gateway_settings['title'] : false,
1653
+ )
1654
+ );
1655
+ }
1656
+ } elseif ( isset( $_GET['tab'] ) && 'tax' === sanitize_text_field( wp_unslash( $_GET['tab'] ) ) ) {
1657
+ // Check prices entered with tax setting.
1658
+ if ( isset( $_POST['woocommerce_prices_include_tax'] ) ) {
1659
+ $old_price_tax = $this->GetConfig( 'prices_include_tax' );
1660
+ $new_price_tax = sanitize_text_field( wp_unslash( $_POST['woocommerce_prices_include_tax'] ) );
1661
+ if ( $old_price_tax !== $new_price_tax ) {
1662
+ $this->plugin->alerts->Trigger( 9078, array( 'TaxStatus' => 'yes' === $new_price_tax ? 'including' : 'excluding' ) );
1663
+ }
1664
+ }
1665
+
1666
+ // Check calculate tax based on setting.
1667
+ if ( isset( $_POST['woocommerce_tax_based_on'] ) ) {
1668
+ $old_tax_base = $this->GetConfig( 'tax_based_on' );
1669
+ $new_tax_base = sanitize_text_field( wp_unslash( $_POST['woocommerce_tax_based_on'] ) );
1670
+ if ( $old_tax_base !== $new_tax_base ) {
1671
+ $setting = '';
1672
+ if ( 'shipping' === $new_tax_base ) {
1673
+ $setting = 'Customer shipping address';
1674
+ } elseif ( 'billing' === $new_tax_base ) {
1675
+ $setting = 'Customer billing address';
1676
+ } elseif ( 'base' === $new_tax_base ) {
1677
+ $setting = 'Shop base address';
1678
+ } else {
1679
+ $setting = 'Customer shipping address';
1680
+ }
1681
+ $this->plugin->alerts->Trigger(
1682
+ 9079, array(
1683
+ 'Setting' => $setting,
1684
+ 'OldTaxBase' => $old_tax_base,
1685
+ 'NewTaxBase' => $new_tax_base,
1686
+ )
1687
+ );
1688
+ }
1689
+ }
1690
+
1691
+ // Check shipping tax class setting.
1692
+ if ( isset( $_POST['woocommerce_shipping_tax_class'] ) ) {
1693
+ $old_tax_class = $this->GetConfig( 'shipping_tax_class' );
1694
+ $new_tax_class = sanitize_text_field( wp_unslash( $_POST['woocommerce_shipping_tax_class'] ) );
1695
+ if ( $old_tax_class !== $new_tax_class ) {
1696
+ $setting = '';
1697
+ if ( 'inherit' === $new_tax_class ) {
1698
+ $setting = 'Shipping tax class based on cart items';
1699
+ } elseif ( 'reduced-rate' === $new_tax_class ) {
1700
+ $setting = 'Reduced rate';
1701
+ } elseif ( 'zero-rate' === $new_tax_class ) {
1702
+ $setting = 'Zero rate';
1703
+ } elseif ( empty( $new_tax_class ) ) {
1704
+ $setting = 'Standard';
1705
+ } else {
1706
+ $setting = 'Shipping tax class based on cart items';
1707
+ }
1708
+ $this->plugin->alerts->Trigger(
1709
+ 9080, array(
1710
+ 'Setting' => $setting,
1711
+ 'OldTaxClass' => $old_tax_class,
1712
+ 'NewTaxClass' => $new_tax_class,
1713
+ )
1714
+ );
1715
+ }
1716
+ }
1717
+
1718
+ // Check rounding of tax setting.
1719
+ $old_tax_round = $this->GetConfig( 'tax_round_at_subtotal' );
1720
+ $new_tax_round = isset( $_POST['woocommerce_tax_round_at_subtotal'] ) ? 'yes' : 'no';
1721
+ if ( $old_tax_round !== $new_tax_round ) {
1722
+ $this->plugin->alerts->Trigger( 9081, array( 'Status' => 'yes' === $new_tax_round ? 'Enabled' : 'Disabled' ) );
1723
  }
1724
  } else {
1725
  // "Enable Coupon" event.
1735
  $old_location = $this->GetConfig( 'default_country' );
1736
  $new_location = sanitize_text_field( wp_unslash( $_POST['woocommerce_default_country'] ) );
1737
  if ( $old_location !== $new_location ) {
1738
+ $this->plugin->alerts->Trigger(
1739
+ 9029, array(
1740
+ 'OldLocation' => $old_location,
1741
+ 'NewLocation' => $new_location,
1742
+ )
1743
+ );
1744
  }
1745
 
1746
  // Calculate taxes event.
1757
  $old_currency = $this->GetConfig( 'currency' );
1758
  $new_currency = sanitize_text_field( wp_unslash( $_POST['woocommerce_currency'] ) );
1759
  if ( $old_currency !== $new_currency ) {
1760
+ $this->plugin->alerts->Trigger(
1761
+ 9031, array(
1762
+ 'OldCurrency' => $old_currency,
1763
+ 'NewCurrency' => $new_currency,
1764
+ )
1765
+ );
1766
  }
1767
  }
1768
  }
1796
  } else {
1797
  if ( ! wc_string_to_bool( $enabled ) ) {
1798
  // Gateway enabled.
1799
+ $this->plugin->alerts->Trigger(
1800
+ 9074, array(
1801
+ 'GatewayID' => $gateway->id,
1802
+ 'GatewayName' => $gateway->title,
1803
+ )
1804
+ );
1805
  } else {
1806
  // Gateway disabled.
1807
+ $this->plugin->alerts->Trigger(
1808
+ 9075, array(
1809
+ 'GatewayID' => $gateway->id,
1810
+ 'GatewayName' => $gateway->title,
1811
+ )
1812
+ );
1813
  }
1814
  }
1815
  }
1816
  }
1817
  }
1818
  }
1819
+
1820
+ // Verify nonce for shipping zones events.
1821
+ if ( isset( $_POST['wc_shipping_zones_nonce'] ) && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['wc_shipping_zones_nonce'] ) ), 'wc_shipping_zones_nonce' ) ) {
1822
+ if ( isset( $_POST['zone_id'] ) ) {
1823
+ // Get zone details.
1824
+ $zone_id = sanitize_text_field( wp_unslash( $_POST['zone_id'] ) );
1825
+
1826
+ if ( ! $zone_id && isset( $_POST['changes']['zone_name'] ) ) {
1827
+ // Get zone details.
1828
+ $zone_name = sanitize_text_field( wp_unslash( $_POST['changes']['zone_name'] ) );
1829
+
1830
+ $this->plugin->alerts->Trigger(
1831
+ 9082, array(
1832
+ 'ShippingZoneStatus' => 'Added',
1833
+ 'ShippingZoneName' => $zone_name,
1834
+ )
1835
+ );
1836
+ } elseif ( ! empty( $_POST['changes'] ) ) {
1837
+ $shipping_zone = new WC_Shipping_Zone( $zone_id );
1838
+ $zone_name = isset( $_POST['changes']['zone_name'] ) ? sanitize_text_field( wp_unslash( $_POST['changes']['zone_name'] ) ) : false;
1839
+ $this->plugin->alerts->Trigger(
1840
+ 9082, array(
1841
+ 'ShippingZoneID' => $zone_id,
1842
+ 'ShippingZoneStatus' => 'Modified',
1843
+ 'ShippingZoneName' => $zone_name ? $zone_name : $shipping_zone->get_zone_name(),
1844
+ )
1845
+ );
1846
+ }
1847
+ }
1848
+
1849
+ if ( isset( $_POST['changes'] ) && ! empty( $_POST['changes'] ) ) {
1850
+ // @codingStandardsIgnoreLine
1851
+ $changes = $_POST['changes'];
1852
+ foreach ( $changes as $key => $zone ) {
1853
+ if ( ! is_integer( $key ) ) {
1854
+ continue;
1855
+ }
1856
+
1857
+ if ( isset( $zone['zone_id'], $zone['deleted'] ) && 'deleted' === $zone['deleted'] ) {
1858
+ $zone_obj = new WC_Shipping_Zone( $zone['zone_id'] );
1859
+ $this->plugin->alerts->Trigger(
1860
+ 9082, array(
1861
+ 'ShippingZoneID' => $zone['zone_id'],
1862
+ 'ShippingZoneStatus' => 'Deleted',
1863
+ 'ShippingZoneName' => $zone_obj->get_zone_name(),
1864
+ )
1865
+ );
1866
+ }
1867
+ }
1868
+ }
1869
+ }
1870
  }
1871
 
1872
  /**
1892
  * @return array
1893
  */
1894
  protected function GetProductCategories( $post ) {
1895
+ return wp_get_post_terms( $post->ID, 'product_cat', array( 'fields' => 'names' ) );
 
 
 
 
1896
  }
1897
 
1898
  /**
2238
  if ( ! $order ) {
2239
  return false;
2240
  }
2241
+ if ( is_int( $order ) ) {
2242
  $order = new WC_Order( $order );
2243
  }
2244
  if ( ! $order instanceof WC_Order ) {
2345
  $edit_link = $this->GetEditorLink( $order_post );
2346
 
2347
  // Log event.
2348
+ $this->plugin->alerts->Trigger(
2349
+ 9040, array(
2350
+ 'OrderID' => $order_id,
2351
+ 'OrderTitle' => $this->get_order_title( $order_id ),
2352
+ 'OrderStatus' => $order_post->post_status,
2353
+ $edit_link['name'] => $edit_link['value'],
2354
+ )
2355
+ );
2356
  }
2357
  }
2358
  return $order_ids;
2371
  $order_obj = get_post( $order_id );
2372
  $edit_link = $this->GetEditorLink( $order_obj );
2373
 
2374
+ $this->plugin->alerts->Trigger(
2375
+ 9041, array(
2376
+ 'OrderID' => $order_id,
2377
+ 'RefundID' => $refund_id,
2378
+ 'OrderTitle' => $this->get_order_title( $order_id ),
2379
+ 'OrderStatus' => $order_obj->post_status,
2380
+ $edit_link['name'] => $edit_link['value'],
2381
+ )
2382
+ );
2383
  }
2384
 
2385
  /**
2411
 
2412
  // Check id and attribute object.
2413
  if ( $id && ! is_null( $attribute ) ) {
2414
+ $this->plugin->alerts->Trigger(
2415
+ 9058, array(
2416
+ 'AttributeID' => $id,
2417
+ 'AttributeName' => isset( $attribute->name ) ? $attribute->name : false,
2418
+ 'AttributeSlug' => isset( $attribute->slug ) ? str_replace( 'pa_', '', $attribute->slug ) : false,
2419
+ 'AttributeType' => isset( $attribute->type ) ? $attribute->type : false,
2420
+ 'AttributeOrderby' => isset( $attribute->order_by ) ? $attribute->order_by : false,
2421
+ 'AttributePublic' => isset( $attribute->has_archives ) ? $attribute->has_archives : '0',
2422
+ 'Taxonomy' => $taxonomy,
2423
+ )
2424
+ );
2425
  }
2426
  }
2427
 
2547
  // Get the attributes data.
2548
  parse_str( $_POST['data'], $data );
2549
  $this->check_attributes_change( $post, $data );
2550
+ } elseif ( 'woocommerce_save_variations' === $action ) {
2551
+ // Check nonce.
2552
+ check_ajax_referer( 'save-variations', 'security' );
2553
+
2554
+ $product_id = isset( $_POST['product_id'] ) ? sanitize_text_field( wp_unslash( $_POST['product_id'] ) ) : false;
2555
+ if ( ! $product_id ) {
2556
+ return;
2557
+ }
2558
+
2559
+ $post = get_post( $product_id );
2560
+ if ( ! $post ) {
2561
+ return;
2562
+ }
2563
+ $this->check_variations_change( $post );
2564
  } elseif ( in_array( $action, $wc_order_actions, true ) ) {
2565
  // Check nonce.
2566
  check_ajax_referer( 'order-item', 'security' );
2578
  $edit_link = $this->GetEditorLink( $order );
2579
 
2580
  // Log event.
2581
+ $this->plugin->alerts->Trigger(
2582
+ 9040, array(
2583
+ 'OrderID' => $order_id,
2584
+ 'OrderTitle' => $this->get_order_title( $order_id ),
2585
+ 'OrderStatus' => isset( $order->post_status ) ? $order->post_status : false,
2586
+ $edit_link['name'] => $edit_link['value'],
2587
+ )
2588
+ );
2589
  }
2590
  }
2591
 
2639
  if ( ! empty( $added_attributes ) ) {
2640
  foreach ( $added_attributes as $added_attribute ) {
2641
  if ( $added_attribute && ! empty( $added_attribute['name'] ) ) {
2642
+ $this->plugin->alerts->Trigger(
2643
+ 9047, array(
2644
+ 'AttributeName' => $added_attribute['name'],
2645
+ 'AttributeValue' => $added_attribute['value'],
2646
+ 'ProductID' => $oldpost->ID,
2647
+ 'ProductTitle' => $oldpost->post_title,
2648
+ 'ProductStatus' => $oldpost->post_status,
2649
+ $editor_link['name'] => $editor_link['value'],
2650
+ )
2651
+ );
2652
  $result = 1;
2653
  }
2654
  }
2657
  // Event 9050.
2658
  if ( ! empty( $deleted_attributes ) ) {
2659
  foreach ( $deleted_attributes as $deleted_attribute ) {
2660
+ $this->plugin->alerts->Trigger(
2661
+ 9050, array(
2662
+ 'AttributeName' => $deleted_attribute['name'],
2663
+ 'AttributeValue' => $deleted_attribute['value'],
2664
+ 'ProductID' => $oldpost->ID,
2665
+ 'ProductTitle' => $oldpost->post_title,
2666
+ 'ProductStatus' => $oldpost->post_status,
2667
+ 'ProductUrl' => get_permalink( $oldpost->ID ),
2668
+ $editor_link['name'] => $editor_link['value'],
2669
+ )
2670
+ );
2671
  $result = 1;
2672
  }
2673
  }
2694
 
2695
  // Value change.
2696
  if ( $old_value && $new_value && $old_value !== $new_value ) {
2697
+ $this->plugin->alerts->Trigger(
2698
+ 9048, array(
2699
+ 'AttributeName' => $new_attr['name'],
2700
+ 'OldValue' => $old_value,
2701
+ 'NewValue' => $new_value,
2702
+ 'ProductID' => $oldpost->ID,
2703
+ 'ProductTitle' => $oldpost->post_title,
2704
+ 'ProductStatus' => $oldpost->post_status,
2705
+ $editor_link['name'] => $editor_link['value'],
2706
+ )
2707
+ );
2708
  $result = 1;
2709
  }
2710
 
2711
  // Name change.
2712
  if ( $old_name && $new_name && $old_name !== $new_name ) {
2713
+ $this->plugin->alerts->Trigger(
2714
+ 9049, array(
2715
+ 'AttributeName' => $new_attr['name'],
2716
+ 'OldValue' => $old_name,
2717
+ 'NewValue' => $new_name,
2718
+ 'ProductID' => $oldpost->ID,
2719
+ 'ProductTitle' => $oldpost->post_title,
2720
+ 'ProductStatus' => $oldpost->post_status,
2721
+ 'ProductUrl' => get_permalink( $oldpost->ID ),
2722
+ $editor_link['name'] => $editor_link['value'],
2723
+ )
2724
+ );
2725
  $result = 1;
2726
  }
2727
 
2728
  // Visibility change.
2729
  if ( ! empty( $new_attr['name'] ) && $old_visible !== $new_visible ) {
2730
+ $this->plugin->alerts->Trigger(
2731
+ 9051, array(
2732
+ 'AttributeName' => $new_attr['name'],
2733
+ 'AttributeVisiblilty' => 1 === $new_visible ? __( 'Visible', 'wp-security-audit-log' ) : __( 'Non-Visible', 'wp-security-audit-log' ),
2734
+ 'ProductID' => $oldpost->ID,
2735
+ 'ProductTitle' => $oldpost->post_title,
2736
+ 'ProductStatus' => $oldpost->post_status,
2737
+ $editor_link['name'] => $editor_link['value'],
2738
+ )
2739
+ );
2740
  $result = 1;
2741
  }
2742
  }
2746
  return 0;
2747
  }
2748
 
2749
+ /**
2750
+ * Check Product Variations Change.
2751
+ *
2752
+ * @since 3.3.1.2
2753
+ *
2754
+ * @param WP_Post $oldpost - WP Post type object.
2755
+ * @param array $data - Data array.
2756
+ * @return int
2757
+ */
2758
+ private function check_variations_change( $oldpost, $data = false ) {
2759
+ if ( ! $data ) {
2760
+ // @codingStandardsIgnoreLine
2761
+ $data = $_POST;
2762
+ }
2763
+
2764
+ if ( ! empty( $data['variable_post_id'] ) ) {
2765
+ foreach ( $data['variable_post_id'] as $key => $post_id ) {
2766
+ $post_id = absint( $post_id );
2767
+ $variation = new WC_Product_Variation( $post_id );
2768
+
2769
+ // Copy and set the product variation.
2770
+ $product = $oldpost;
2771
+ $product->post_title = $variation->get_name();
2772
+ $product->post_status = $variation->get_status();
2773
+
2774
+ // Check regular price.
2775
+ $old_price = (int) $variation->get_regular_price();
2776
+ $new_price = isset( $data['variable_regular_price'][ $key ] ) ? (int) sanitize_text_field( wp_unslash( $data['variable_regular_price'][ $key ] ) ) : false;
2777
+ if ( $old_price !== $new_price ) {
2778
+ $result = $this->EventPrice( $product, 'Regular price', $old_price, $new_price );
2779
+ }
2780
+
2781
+ // Check sale price.
2782
+ $old_sale_price = (int) $variation->get_sale_price();
2783
+ $new_sale_price = isset( $data['variable_sale_price'][ $key ] ) ? (int) sanitize_text_field( wp_unslash( $data['variable_sale_price'][ $key ] ) ) : false;
2784
+ if ( $old_sale_price !== $new_sale_price ) {
2785
+ $result = $this->EventPrice( $product, 'Sale price', $old_sale_price, $new_sale_price );
2786
+ }
2787
+
2788
+ // Check product SKU.
2789
+ $old_sku = $variation->get_sku();
2790
+ $new_sku = isset( $data['variable_sku'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_sku'][ $key ] ) ) : false;
2791
+ if ( $old_sku !== $new_sku ) {
2792
+ $result = $this->CheckSKUChange( $product, $old_sku, $new_sku );
2793
+ }
2794
+
2795
+ // Check product virtual.
2796
+ $virtual['old'] = $variation->is_virtual();
2797
+ $virtual['new'] = isset( $data['variable_is_virtual'][ $key ] ) ? true : false;
2798
+ if ( $virtual['old'] !== $virtual['new'] ) {
2799
+ $result = $this->CheckTypeChange( $product, null, $virtual );
2800
+ }
2801
+
2802
+ // Check product downloadable.
2803
+ $download['old'] = $variation->is_downloadable();
2804
+ $download['new'] = isset( $data['variable_is_downloadable'][ $key ] ) ? true : false;
2805
+ if ( $download['old'] !== $download['new'] ) {
2806
+ $result = $this->CheckTypeChange( $product, null, false, $download );
2807
+ }
2808
+
2809
+ // Check product stock status.
2810
+ $old_stock_status = $variation->get_stock_status();
2811
+ $new_stock_status = isset( $data['variable_stock_status'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_stock_status'][ $key ] ) ) : false;
2812
+ if ( $old_stock_status !== $new_stock_status ) {
2813
+ $result = $this->CheckStockStatusChange( $product, $old_stock_status, $new_stock_status );
2814
+ }
2815
+
2816
+ // Check product stock quantity.
2817
+ $old_stock = $variation->get_stock_quantity();
2818
+ $new_stock = isset( $data['variable_stock'][ $key ] ) ? (int) sanitize_text_field( wp_unslash( $data['variable_stock'][ $key ] ) ) : false;
2819
+ if ( $old_stock !== $new_stock ) {
2820
+ $result = $this->CheckStockQuantityChange( $product, $old_stock, $new_stock );
2821
+ }
2822
+
2823
+ // Check product weight.
2824
+ $old_weight = $variation->get_weight();
2825
+ $new_weight = isset( $data['variable_weight'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_weight'][ $key ] ) ) : false;
2826
+ if ( $old_weight !== $new_weight ) {
2827
+ $result = $this->CheckWeightChange( $product, $old_weight, $new_weight );
2828
+ }
2829
+
2830
+ // Check product dimensions change.
2831
+ $length['old'] = $variation->get_length();
2832
+ $length['new'] = isset( $data['variable_length'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_length'][ $key ] ) ) : false;
2833
+ $width['old'] = $variation->get_width();
2834
+ $width['new'] = isset( $data['variable_width'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_width'][ $key ] ) ) : false;
2835
+ $height['old'] = $variation->get_height();
2836
+ $height['new'] = isset( $data['variable_height'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_height'][ $key ] ) ) : false;
2837
+ $this->CheckDimensionsChange( $product, $length, $width, $height );
2838
+
2839
+ // Check product downloads change.
2840
+ $new_file_names = isset( $data['_wc_variation_file_names'][ $post_id ] ) ? array_map( 'sanitize_text_field', wp_unslash( $data['_wc_variation_file_names'][ $post_id ] ) ) : false;
2841
+ $new_file_urls = isset( $data['_wc_variation_file_urls'][ $post_id ] ) ? array_map( 'esc_url_raw', wp_unslash( $data['_wc_variation_file_urls'][ $post_id ] ) ) : false;
2842
+ $wc_downloads = $variation->get_downloads();
2843
+
2844
+ // Set product old downloads data.
2845
+ if ( empty( $this->_old_file_names ) && empty( $this->_old_file_urls ) ) {
2846
+ foreach ( $wc_downloads as $download ) {
2847
+ array_push( $this->_old_file_names, $download->get_name() );
2848
+ array_push( $this->_old_file_urls, $download->get_file() );
2849
+ }
2850
+ }
2851
+ $this->CheckDownloadableFileChange( $product, $new_file_names, $new_file_urls );
2852
+
2853
+ // Check backorders change.
2854
+ $old_backorder = $variation->get_backorders();
2855
+ $new_backorder = isset( $data['variable_backorders'][ $key ] ) ? sanitize_text_field( wp_unslash( $data['variable_backorders'][ $key ] ) ) : false;
2856
+ $this->check_backorders_setting( $product, $old_backorder, $new_backorder );
2857
+ }
2858
+ }
2859
+ return 1;
2860
+ }
2861
+
2862
  /**
2863
  * Returns the attribute key using attribute name.
2864
  *
2960
 
2961
  // Update if both slugs are not same.
2962
  if ( $old_slug !== $new_slug ) {
2963
+ $this->plugin->alerts->Trigger(
2964
+ 9053, array(
2965
+ 'CategoryID' => $term_id,
2966
+ 'CategoryName' => $new_name,
2967
+ 'OldSlug' => $old_slug,
2968
+ 'NewSlug' => $new_slug,
2969
+ )
2970
+ );
2971
  }
2972
 
2973
  // Update if both parent categories are not same.
2974
  if ( $term->parent !== $new_parent_id ) {
2975
+ $this->plugin->alerts->Trigger(
2976
+ 9054, array(
2977
+ 'CategoryID' => $term_id,
2978
+ 'CategoryName' => $new_name,
2979
+ 'OldParentID' => isset( $old_parent_cat->term_id ) ? $old_parent_cat->term_id : false,
2980
+ 'OldParentCat' => isset( $old_parent_cat->name ) ? $old_parent_cat->name : false,
2981
+ 'NewParentID' => isset( $new_parent_cat->term_id ) ? $new_parent_cat->term_id : false,
2982
+ 'NewParentCat' => isset( $new_parent_cat->name ) ? $new_parent_cat->name : false,
2983
+ )
2984
+ );
2985
  }
2986
 
2987
  // Update if both names are not same.
2988
  if ( $old_name !== $new_name ) {
2989
+ $this->plugin->alerts->Trigger(
2990
+ 9056, array(
2991
+ 'CategoryID' => $term_id,
2992
+ 'CategoryName' => $new_name,
2993
+ 'OldName' => $old_name,
2994
+ 'NewName' => $new_name,
2995
+ )
2996
+ );
2997
  }
2998
  }
2999
  return $data;
3023
 
3024
  // Check if display type changed.
3025
  if ( $meta_value !== $old_display ) {
3026
+ $this->plugin->alerts->Trigger(
3027
+ 9055, array(
3028
+ 'CategoryID' => $object_id,
3029
+ 'CategoryName' => $term->name,
3030
+ 'OldDisplayType' => $old_display,
3031
+ 'NewDisplayType' => $meta_value,
3032
+ )
3033
+ );
3034
  }
3035
  }
3036
 
3046
  */
3047
  public function event_product_cat_deleted( $term_id, $tt_id, $deleted_term, $object_ids ) {
3048
  if ( 'product_cat' === $deleted_term->taxonomy ) {
3049
+ $this->plugin->alerts->Trigger(
3050
+ 9052, array(
3051
+ 'CategoryID' => $deleted_term->term_id,
3052
+ 'CategoryName' => $deleted_term->name,
3053
+ 'CategorySlug' => $deleted_term->slug,
3054
+ )
3055
+ );
3056
  }
3057
  }
3058
 
classes/Settings.php CHANGED
@@ -203,7 +203,7 @@ class WSAL_Settings {
203
  // Make sure options have been loaded.
204
  $this->IsDevOptionEnabled( '' );
205
  // Remove option if it exists.
206
- while ( ($p = array_search( $option, $this->_devoption )) !== false ) {
207
  unset( $this->_devoption[ $p ] );
208
  }
209
  // Add option if callee wants it enabled.
@@ -539,7 +539,7 @@ class WSAL_Settings {
539
  }
540
 
541
  public function SetIncognito( $enabled ) {
542
- return $this->_plugin->SetGlobalOption( 'hide-plugin', $enabled );
543
  }
544
 
545
  /**
@@ -550,7 +550,7 @@ class WSAL_Settings {
550
  }
551
 
552
  public function SetDeleteData( $enabled ) {
553
- return $this->_plugin->SetGlobalOption( 'delete-data', $enabled );
554
  }
555
 
556
  /**
@@ -738,7 +738,7 @@ class WSAL_Settings {
738
  $user = get_userdata( $user );
739
  }
740
  $allowed = $this->GetAccessTokens( $action );
741
- $check = array_merge( $user->roles, array( $user->user_login ) );
742
  foreach ( $check as $item ) {
743
  if ( in_array( $item, $allowed ) ) {
744
  return true;
@@ -759,11 +759,7 @@ class WSAL_Settings {
759
 
760
  public function IsLoginSuperAdmin( $username ) {
761
  $user_id = username_exists( $username );
762
- if ( function_exists( 'is_super_admin' ) && is_super_admin( $user_id ) ) {
763
- return true;
764
- } else {
765
- return false;
766
- }
767
  }
768
 
769
  public function GetLicenses() {
@@ -831,7 +827,7 @@ class WSAL_Settings {
831
  }
832
 
833
  public function SetMainIPFromProxy( $enabled ) {
834
- return $this->_plugin->SetGlobalOption( 'use-proxy-ip', $enabled );
835
  }
836
 
837
  public function IsInternalIPsFiltered() {
@@ -839,7 +835,7 @@ class WSAL_Settings {
839
  }
840
 
841
  public function SetInternalIPsFiltering( $enabled ) {
842
- return $this->_plugin->SetGlobalOption( 'filter-internal-ip', $enabled );
843
  }
844
 
845
  public function GetMainClientIP() {
@@ -952,8 +948,8 @@ class WSAL_Settings {
952
  * @since 3.2.2
953
  */
954
  public function set_excluded_urls( $urls ) {
955
- $urls = array_map( 'untrailingslashit', $urls );
956
- $urls = array_unique( $urls );
957
  $this->excluded_urls = $urls;
958
  $this->_plugin->SetGlobalOption( 'excluded-urls', esc_html( implode( ',', $this->excluded_urls ) ) );
959
  }
@@ -1023,6 +1019,8 @@ class WSAL_Settings {
1023
 
1024
  /**
1025
  * Datetime used in the Alerts.
 
 
1026
  */
1027
  public function GetDatetimeFormat( $line_break = true ) {
1028
  if ( $line_break ) {
@@ -1031,11 +1029,26 @@ class WSAL_Settings {
1031
  $date_time_format = $this->GetDateFormat() . ' ' . $this->GetTimeFormat();
1032
  }
1033
 
1034
- $wp_time_format = get_option( 'time_format' );
1035
- if ( stripos( $wp_time_format, 'A' ) !== false ) {
1036
- $date_time_format .= '.$$$&\n\b\s\p;A';
 
 
 
 
 
 
1037
  } else {
1038
- $date_time_format .= '.$$$';
 
 
 
 
 
 
 
 
 
1039
  }
1040
  return $date_time_format;
1041
  }
@@ -1056,9 +1069,9 @@ class WSAL_Settings {
1056
  */
1057
  public function GetTimeFormat() {
1058
  $wp_time_format = get_option( 'time_format' );
1059
- $search = array( 'a', 'A', 'T', ' ' );
1060
- $replace = array( '', '', '', '' );
1061
- $time_format = str_replace( $search, $replace, $wp_time_format );
1062
  return $time_format;
1063
  }
1064
 
@@ -1072,7 +1085,7 @@ class WSAL_Settings {
1072
  }
1073
 
1074
  public function SetTimezone( $newvalue ) {
1075
- return $this->_plugin->SetGlobalOption( 'timezone', $newvalue );
1076
  }
1077
 
1078
  /**
@@ -1089,7 +1102,7 @@ class WSAL_Settings {
1089
  * @since 2.6.5
1090
  */
1091
  public function set_type_username( $newvalue ) {
1092
- return $this->_plugin->SetGlobalOption( 'type_username', $newvalue );
1093
  }
1094
 
1095
  public function GetAdapterConfig( $name_field, $default_value = false ) {
@@ -1097,7 +1110,7 @@ class WSAL_Settings {
1097
  }
1098
 
1099
  public function SetAdapterConfig( $name_field, $newvalue ) {
1100
- return $this->_plugin->SetGlobalOption( $name_field, trim( $newvalue ) );
1101
  }
1102
 
1103
  public function GetColumns() {
@@ -1130,7 +1143,7 @@ class WSAL_Settings {
1130
  ) + array_slice( $columns, 5, null, true );
1131
  }
1132
  $selected = (array) json_decode( $selected );
1133
- $columns = array_merge( $columns, $selected );
1134
  return $columns;
1135
  } else {
1136
  return $columns;
@@ -1142,7 +1155,7 @@ class WSAL_Settings {
1142
  }
1143
 
1144
  public function SetColumns( $columns ) {
1145
- return $this->_plugin->SetGlobalOption( 'columns', json_encode( $columns ) );
1146
  }
1147
 
1148
  public function IsWPBackend() {
@@ -1150,7 +1163,7 @@ class WSAL_Settings {
1150
  }
1151
 
1152
  public function SetWPBackend( $enabled ) {
1153
- return $this->_plugin->SetGlobalOption( 'wp-backend', $enabled );
1154
  }
1155
 
1156
  /**
@@ -1159,7 +1172,7 @@ class WSAL_Settings {
1159
  * @param string $use – Setting value.
1160
  */
1161
  public function set_use_email( $use ) {
1162
- return $this->_plugin->SetGlobalOption( 'use-email', $use );
1163
  }
1164
 
1165
  /**
@@ -1172,7 +1185,7 @@ class WSAL_Settings {
1172
  }
1173
 
1174
  public function SetFromEmail( $email_address ) {
1175
- return $this->_plugin->SetGlobalOption( 'from-email', trim( $email_address ) );
1176
  }
1177
 
1178
  public function GetFromEmail() {
@@ -1180,7 +1193,7 @@ class WSAL_Settings {
1180
  }
1181
 
1182
  public function SetDisplayName( $display_name ) {
1183
- return $this->_plugin->SetGlobalOption( 'display-name', trim( $display_name ) );
1184
  }
1185
 
1186
  public function GetDisplayName() {
@@ -1188,7 +1201,7 @@ class WSAL_Settings {
1188
  }
1189
 
1190
  public function Set404LogLimit( $value ) {
1191
- return $this->_plugin->SetGlobalOption( 'log-404-limit', abs( $value ) );
1192
  }
1193
 
1194
  public function Get404LogLimit() {
@@ -1202,7 +1215,7 @@ class WSAL_Settings {
1202
  * @since 2.6.3
1203
  */
1204
  public function SetVisitor404LogLimit( $value ) {
1205
- return $this->_plugin->SetGlobalOption( 'log-visitor-404-limit', abs( $value ) );
1206
  }
1207
 
1208
  /**
@@ -1222,9 +1235,9 @@ class WSAL_Settings {
1222
  */
1223
  public function set_failed_login_limit( $value ) {
1224
  if ( ! empty( $value ) ) {
1225
- return $this->_plugin->SetGlobalOption( 'log-failed-login-limit', abs( $value ) );
1226
  } else {
1227
- return $this->_plugin->SetGlobalOption( 'log-failed-login-limit', -1 );
1228
  }
1229
  }
1230
 
@@ -1245,9 +1258,9 @@ class WSAL_Settings {
1245
  */
1246
  public function set_visitor_failed_login_limit( $value ) {
1247
  if ( ! empty( $value ) ) {
1248
- return $this->_plugin->SetGlobalOption( 'log-visitor-failed-login-limit', abs( $value ) );
1249
  } else {
1250
- return $this->_plugin->SetGlobalOption( 'log-visitor-failed-login-limit', -1 );
1251
  }
1252
  }
1253
 
@@ -1345,11 +1358,11 @@ class WSAL_Settings {
1345
  final public function create_index_file( $dir_path ) {
1346
  // Check if index.php file exists.
1347
  $dir_path = trailingslashit( $dir_path );
1348
- $result = 0;
1349
  if ( ! is_file( $dir_path . 'index.php' ) ) {
1350
  $result = @file_put_contents( $dir_path . 'index.php', '<?php // Silence is golden' );
1351
  }
1352
- return ($result > 0);
1353
  }
1354
 
1355
  /**
@@ -1363,11 +1376,11 @@ class WSAL_Settings {
1363
  final public function create_htaccess_file( $dir_path ) {
1364
  // Check if .htaccess file exists.
1365
  $dir_path = trailingslashit( $dir_path );
1366
- $result = 0;
1367
  if ( ! is_file( $dir_path . '.htaccess' ) ) {
1368
  $result = @file_put_contents( $dir_path . '.htaccess', 'Deny from all' );
1369
  }
1370
- return ($result > 0);
1371
  }
1372
 
1373
  /**
@@ -1503,10 +1516,7 @@ class WSAL_Settings {
1503
  */
1504
  public function is_stealth_mode() {
1505
  $stealth_mode = $this->_plugin->GetGlobalOption( 'mwp-child-stealth-mode', 'no' );
1506
- if ( 'yes' === $stealth_mode ) {
1507
- return true;
1508
- }
1509
- return false;
1510
  }
1511
 
1512
  /**
203
  // Make sure options have been loaded.
204
  $this->IsDevOptionEnabled( '' );
205
  // Remove option if it exists.
206
+ while ( ( $p = array_search( $option, $this->_devoption ) ) !== false ) {
207
  unset( $this->_devoption[ $p ] );
208
  }
209
  // Add option if callee wants it enabled.
539
  }
540
 
541
  public function SetIncognito( $enabled ) {
542
+ $this->_plugin->SetGlobalOption( 'hide-plugin', $enabled );
543
  }
544
 
545
  /**
550
  }
551
 
552
  public function SetDeleteData( $enabled ) {
553
+ $this->_plugin->SetGlobalOption( 'delete-data', $enabled );
554
  }
555
 
556
  /**
738
  $user = get_userdata( $user );
739
  }
740
  $allowed = $this->GetAccessTokens( $action );
741
+ $check = array_merge( $user->roles, array( $user->user_login ) );
742
  foreach ( $check as $item ) {
743
  if ( in_array( $item, $allowed ) ) {
744
  return true;
759
 
760
  public function IsLoginSuperAdmin( $username ) {
761
  $user_id = username_exists( $username );
762
+ return function_exists( 'is_super_admin' ) && is_super_admin( $user_id );
 
 
 
 
763
  }
764
 
765
  public function GetLicenses() {
827
  }
828
 
829
  public function SetMainIPFromProxy( $enabled ) {
830
+ $this->_plugin->SetGlobalOption( 'use-proxy-ip', $enabled );
831
  }
832
 
833
  public function IsInternalIPsFiltered() {
835
  }
836
 
837
  public function SetInternalIPsFiltering( $enabled ) {
838
+ $this->_plugin->SetGlobalOption( 'filter-internal-ip', $enabled );
839
  }
840
 
841
  public function GetMainClientIP() {
948
  * @since 3.2.2
949
  */
950
  public function set_excluded_urls( $urls ) {
951
+ $urls = array_map( 'untrailingslashit', $urls );
952
+ $urls = array_unique( $urls );
953
  $this->excluded_urls = $urls;
954
  $this->_plugin->SetGlobalOption( 'excluded-urls', esc_html( implode( ',', $this->excluded_urls ) ) );
955
  }
1019
 
1020
  /**
1021
  * Datetime used in the Alerts.
1022
+ *
1023
+ * @param boolean $line_break - True if line break otherwise false.
1024
  */
1025
  public function GetDatetimeFormat( $line_break = true ) {
1026
  if ( $line_break ) {
1029
  $date_time_format = $this->GetDateFormat() . ' ' . $this->GetTimeFormat();
1030
  }
1031
 
1032
+ $wp_time_format = get_option( 'time_format' ); // WP time format.
1033
+
1034
+ // Check if the time format does not have seconds.
1035
+ if ( stripos( $wp_time_format, 's' ) === false ) {
1036
+ if ( stripos( $wp_time_format, '.v' ) !== false ) {
1037
+ $date_time_format = str_replace( '.v', '', $date_time_format );
1038
+ }
1039
+ $date_time_format .= ':s'; // Add seconds to time format.
1040
+ $date_time_format .= '.$$$'; // Add milliseconds to time format.
1041
  } else {
1042
+ // Check if the time format does have milliseconds.
1043
+ if ( stripos( $wp_time_format, '.v' ) !== false ) {
1044
+ $date_time_format = str_replace( '.v', '.$$$', $date_time_format );
1045
+ } else {
1046
+ $date_time_format .= '.$$$';
1047
+ }
1048
+ }
1049
+
1050
+ if ( stripos( $wp_time_format, 'A' ) !== false ) {
1051
+ $date_time_format .= '&\n\b\s\p;A';
1052
  }
1053
  return $date_time_format;
1054
  }
1069
  */
1070
  public function GetTimeFormat() {
1071
  $wp_time_format = get_option( 'time_format' );
1072
+ $search = array( 'a', 'A', 'T', ' ' );
1073
+ $replace = array( '', '', '', '' );
1074
+ $time_format = str_replace( $search, $replace, $wp_time_format );
1075
  return $time_format;
1076
  }
1077
 
1085
  }
1086
 
1087
  public function SetTimezone( $newvalue ) {
1088
+ $this->_plugin->SetGlobalOption( 'timezone', $newvalue );
1089
  }
1090
 
1091
  /**
1102
  * @since 2.6.5
1103
  */
1104
  public function set_type_username( $newvalue ) {
1105
+ $this->_plugin->SetGlobalOption( 'type_username', $newvalue );
1106
  }
1107
 
1108
  public function GetAdapterConfig( $name_field, $default_value = false ) {
1110
  }
1111
 
1112
  public function SetAdapterConfig( $name_field, $newvalue ) {
1113
+ $this->_plugin->SetGlobalOption( $name_field, trim( $newvalue ) );
1114
  }
1115
 
1116
  public function GetColumns() {
1143
  ) + array_slice( $columns, 5, null, true );
1144
  }
1145
  $selected = (array) json_decode( $selected );
1146
+ $columns = array_merge( $columns, $selected );
1147
  return $columns;
1148
  } else {
1149
  return $columns;
1155
  }
1156
 
1157
  public function SetColumns( $columns ) {
1158
+ $this->_plugin->SetGlobalOption( 'columns', json_encode( $columns ) );
1159
  }
1160
 
1161
  public function IsWPBackend() {
1163
  }
1164
 
1165
  public function SetWPBackend( $enabled ) {
1166
+ $this->_plugin->SetGlobalOption( 'wp-backend', $enabled );
1167
  }
1168
 
1169
  /**
1172
  * @param string $use – Setting value.
1173
  */
1174
  public function set_use_email( $use ) {
1175
+ $this->_plugin->SetGlobalOption( 'use-email', $use );
1176
  }
1177
 
1178
  /**
1185
  }
1186
 
1187
  public function SetFromEmail( $email_address ) {
1188
+ $this->_plugin->SetGlobalOption( 'from-email', trim( $email_address ) );
1189
  }
1190
 
1191
  public function GetFromEmail() {
1193
  }
1194
 
1195
  public function SetDisplayName( $display_name ) {
1196
+ $this->_plugin->SetGlobalOption( 'display-name', trim( $display_name ) );
1197
  }
1198
 
1199
  public function GetDisplayName() {
1201
  }
1202
 
1203
  public function Set404LogLimit( $value ) {
1204
+ $this->_plugin->SetGlobalOption( 'log-404-limit', abs( $value ) );
1205
  }
1206
 
1207
  public function Get404LogLimit() {
1215
  * @since 2.6.3
1216
  */
1217
  public function SetVisitor404LogLimit( $value ) {
1218
+ $this->_plugin->SetGlobalOption( 'log-visitor-404-limit', abs( $value ) );
1219
  }
1220
 
1221
  /**
1235
  */
1236
  public function set_failed_login_limit( $value ) {
1237
  if ( ! empty( $value ) ) {
1238
+ $this->_plugin->SetGlobalOption( 'log-failed-login-limit', abs( $value ) );
1239
  } else {
1240
+ $this->_plugin->SetGlobalOption( 'log-failed-login-limit', -1 );
1241
  }
1242
  }
1243
 
1258
  */
1259
  public function set_visitor_failed_login_limit( $value ) {
1260
  if ( ! empty( $value ) ) {
1261
+ $this->_plugin->SetGlobalOption( 'log-visitor-failed-login-limit', abs( $value ) );
1262
  } else {
1263
+ $this->_plugin->SetGlobalOption( 'log-visitor-failed-login-limit', -1 );
1264
  }
1265
  }
1266
 
1358
  final public function create_index_file( $dir_path ) {
1359
  // Check if index.php file exists.
1360
  $dir_path = trailingslashit( $dir_path );
1361
+ $result = 0;
1362
  if ( ! is_file( $dir_path . 'index.php' ) ) {
1363
  $result = @file_put_contents( $dir_path . 'index.php', '<?php // Silence is golden' );
1364
  }
1365
+ return ( $result > 0 );
1366
  }
1367
 
1368
  /**
1376
  final public function create_htaccess_file( $dir_path ) {
1377
  // Check if .htaccess file exists.
1378
  $dir_path = trailingslashit( $dir_path );
1379
+ $result = 0;
1380
  if ( ! is_file( $dir_path . '.htaccess' ) ) {
1381
  $result = @file_put_contents( $dir_path . '.htaccess', 'Deny from all' );
1382
  }
1383
+ return ( $result > 0 );
1384
  }
1385
 
1386
  /**
1516
  */
1517
  public function is_stealth_mode() {
1518
  $stealth_mode = $this->_plugin->GetGlobalOption( 'mwp-child-stealth-mode', 'no' );
1519
+ return 'yes' === $stealth_mode;
 
 
 
1520
  }
1521
 
1522
  /**
classes/Views/AuditLog.php CHANGED
@@ -103,10 +103,12 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
103
  }
104
 
105
  /**
106
- * Method: Add premium extensions notice.
107
  *
108
- * @author Ashar Irfan
109
- * @since 1.0.0
 
 
110
  */
111
  public function AdminNoticesPremium() {
112
  $is_current_view = $this->_plugin->views->GetActiveView() == $this;
@@ -121,7 +123,6 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
121
  ) {
122
  $get_transient_fn = $this->_plugin->IsMultisite() ? 'get_site_transient' : 'get_transient'; // Check for multisite.
123
  $wsal_is_advert_dismissed = $get_transient_fn( 'wsal-is-advert-dismissed' ); // Check if advert has been dismissed.
124
- $wsal_is_advert_dismissed = false !== $wsal_is_advert_dismissed ? $wsal_is_advert_dismissed : false; // Set the default.
125
  $wsal_premium_advert = $this->_plugin->GetGlobalOption( 'premium-advert', false ); // Get the advert to display.
126
  $wsal_premium_advert = false !== $wsal_premium_advert ? (int) $wsal_premium_advert : 0; // Set the default.
127
 
@@ -200,6 +201,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
200
  if (
201
  wsal_freemius()->is_anonymous() // Anonymous mode option.
202
  && wsal_freemius()->is_not_paying() // Not paying customer.
 
203
  && $is_current_view
204
  && $this->_plugin->settings->CurrentUserCan( 'edit' ) // Have permission to edit plugin settings.
205
  ) {
@@ -318,7 +320,7 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
318
  global $pagenow;
319
 
320
  // Only run the function on audit log custom page.
321
- $page = isset( $_GET['page'] ) ? sanitize_text_field( wp_unslash( $_GET['page'] ) ) : false; // Current page.
322
  if ( 'admin.php' !== $pagenow ) {
323
  return;
324
  } elseif ( 'wsal-auditlog' !== $page ) { // Page is admin.php, now check auditlog page.
@@ -492,7 +494,8 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
492
  ?>
493
  );
494
  } );
495
- </script><?php
 
496
  endif;
497
  }
498
 
@@ -1135,12 +1138,11 @@ class WSAL_Views_AuditLog extends WSAL_AbstractView {
1135
  // Verify nonce.
1136
  if ( isset( $_POST['wsal_viewer_security'] ) && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['wsal_viewer_security'] ) ), 'wsal_auditlog_viewer_nonce' ) ) {
1137
  // Get $_POST arguments.
1138
- $paged = isset( $_POST['page_number'] ) ? sanitize_text_field( wp_unslash( $_POST['page_number'] ) ) : 0;
1139
- $per_page = 25;
1140
 
1141
  // Query events.
1142
  $events_query = $this->GetListView()->query_events( $paged );
1143
- if ( isset( $events_query['items'] ) ) {
1144
  foreach ( $events_query['items'] as $event ) {
1145
  $this->GetListView()->single_row( $event );
1146
  }
103
  }
104
 
105
  /**
106
+ * Add premium extensions notice.
107
  *
108
+ * Notices:
109
+ * 1. Plugin advert.
110
+ * 2. DB disconnection notice.
111
+ * 3. Freemius opt-in/out notice.
112
  */
113
  public function AdminNoticesPremium() {
114
  $is_current_view = $this->_plugin->views->GetActiveView() == $this;
123
  ) {
124
  $get_transient_fn = $this->_plugin->IsMultisite() ? 'get_site_transient' : 'get_transient'; // Check for multisite.
125
  $wsal_is_advert_dismissed = $get_transient_fn( 'wsal-is-advert-dismissed' ); // Check if advert has been dismissed.
 
126
  $wsal_premium_advert = $this->_plugin->GetGlobalOption( 'premium-advert', false ); // Get the advert to display.
127
  $wsal_premium_advert = false !== $wsal_premium_advert ? (int) $wsal_premium_advert : 0; // Set the default.
128
 
201
  if (
202
  wsal_freemius()->is_anonymous() // Anonymous mode option.
203
  && wsal_freemius()->is_not_paying() // Not paying customer.
204
+ && wsal_freemius()->has_api_connectivity() // Check API connectivity.
205
  && $is_current_view
206
  && $this->_plugin->settings->CurrentUserCan( 'edit' ) // Have permission to edit plugin settings.
207
  ) {
320
  global $pagenow;
321
 
322
  // Only run the function on audit log custom page.
323
+ $page = isset( $_GET['page'] ) ? sanitize_text_field( wp_unslash( $_GET['page'] ) ) : false; // @codingStandardsIgnoreLine
324
  if ( 'admin.php' !== $pagenow ) {
325
  return;
326
  } elseif ( 'wsal-auditlog' !== $page ) { // Page is admin.php, now check auditlog page.
494
  ?>
495
  );
496
  } );
497
+ </script>
498
+ <?php
499
  endif;
500
  }
501
 
1138
  // Verify nonce.
1139
  if ( isset( $_POST['wsal_viewer_security'] ) && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['wsal_viewer_security'] ) ), 'wsal_auditlog_viewer_nonce' ) ) {
1140
  // Get $_POST arguments.
1141
+ $paged = isset( $_POST['page_number'] ) ? sanitize_text_field( wp_unslash( $_POST['page_number'] ) ) : 0;
 
1142
 
1143
  // Query events.
1144
  $events_query = $this->GetListView()->query_events( $paged );
1145
+ if ( ! empty( $events_query['items'] ) ) {
1146
  foreach ( $events_query['items'] as $event ) {
1147
  $this->GetListView()->single_row( $event );
1148
  }
classes/Views/SetupWizard.php CHANGED
@@ -47,7 +47,7 @@ final class WSAL_Views_SetupWizard {
47
  *
48
  * @param WpSecurityAuditLog $wsal – Instance of main plugin.
49
  */
50
- public function __construct( WpSecurityAuditLog &$wsal ) {
51
  $this->wsal = $wsal;
52
 
53
  add_action( 'admin_menu', array( $this, 'admin_menus' ), 10 );
@@ -446,7 +446,6 @@ final class WSAL_Views_SetupWizard {
446
  <?php
447
  // Step help text.
448
  $step_help = __( 'The plugin stores the data in the WordPress database in a very efficient way, though the more data you keep the more hard disk space it will consume. If you need need to retain a lot of data we would recommend you to <a href="https://www.wpsecurityauditlog.com/premium-features/" target="_blank">upgrade to Premium</a> and use the Database tools to store the WordPress activity log in an external database.', 'wp-security-audit-log' );
449
-
450
  echo wp_kses( $step_help, $this->wsal->allowed_html_tags );
451
  ?>
452
  </em>
@@ -775,4 +774,3 @@ final class WSAL_Views_SetupWizard {
775
  exit();
776
  }
777
  }
778
-
47
  *
48
  * @param WpSecurityAuditLog $wsal – Instance of main plugin.
49
  */
50
+ public function __construct( WpSecurityAuditLog $wsal ) {
51
  $this->wsal = $wsal;
52
 
53
  add_action( 'admin_menu', array( $this, 'admin_menus' ), 10 );
446
  <?php
447
  // Step help text.
448
  $step_help = __( 'The plugin stores the data in the WordPress database in a very efficient way, though the more data you keep the more hard disk space it will consume. If you need need to retain a lot of data we would recommend you to <a href="https://www.wpsecurityauditlog.com/premium-features/" target="_blank">upgrade to Premium</a> and use the Database tools to store the WordPress activity log in an external database.', 'wp-security-audit-log' );
 
449
  echo wp_kses( $step_help, $this->wsal->allowed_html_tags );
450
  ?>
451
  </em>
774
  exit();
775
  }
776
  }
 
classes/Views/ToggleAlerts.php CHANGED
@@ -174,7 +174,7 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
174
  $is_custom = ! empty( $events_diff ) ? true : false; // If difference is not empty then mode is custom.
175
  $log_details = $this->_plugin->GetGlobalOption( 'details-level', false ); // Get log level option.
176
 
177
- $subcat_alerts = array( 1004, 2010, 6007, 2111, 2119, 2016, 2053, 7000, 8009, 8014, 9007, 9047, 9027, 9002, 9057, 9063, 9035, 8809, 8813, 6000, 6001, 6019, 6028 );
178
  $public_events = $this->_plugin->alerts->get_public_events(); // Get public events.
179
  ?>
180
  <p>
@@ -454,8 +454,6 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
454
  esc_html_e( 'System', 'wp-security-audit-log' );
455
  } elseif ( 6001 === $alert->type ) {
456
  esc_html_e( 'Settings', 'wp-security-audit-log' );
457
- } elseif ( 6019 === $alert->type ) {
458
- esc_html_e( 'Cron Jobs', 'wp-security-audit-log' );
459
  } elseif ( 6028 === $alert->type ) {
460
  esc_html_e( 'File Changes Scanning', 'wp-security-audit-log' );
461
  }
@@ -689,7 +687,8 @@ class WSAL_Views_ToggleAlerts extends WSAL_AbstractView {
689
  var wsal_log_level_modal = jQuery( '[data-remodal-id="wsal-log-level-updated"]' );
690
  wsal_log_level_modal.remodal().open();
691
  } );
692
- </script><?php
 
693
  endif;
694
  ?>
695
 
174
  $is_custom = ! empty( $events_diff ) ? true : false; // If difference is not empty then mode is custom.
175
  $log_details = $this->_plugin->GetGlobalOption( 'details-level', false ); // Get log level option.
176
 
177
+ $subcat_alerts = array( 1004, 2010, 6007, 2111, 2119, 2016, 2053, 7000, 8009, 8014, 9007, 9047, 9027, 9002, 9057, 9063, 9035, 8809, 8813, 6000, 6001, 6028 );
178
  $public_events = $this->_plugin->alerts->get_public_events(); // Get public events.
179
  ?>
180
  <p>
454
  esc_html_e( 'System', 'wp-security-audit-log' );
455
  } elseif ( 6001 === $alert->type ) {
456
  esc_html_e( 'Settings', 'wp-security-audit-log' );
 
 
457
  } elseif ( 6028 === $alert->type ) {
458
  esc_html_e( 'File Changes Scanning', 'wp-security-audit-log' );
459
  }
687
  var wsal_log_level_modal = jQuery( '[data-remodal-id="wsal-log-level-updated"]' );
688
  wsal_log_level_modal.remodal().open();
689
  } );
690
+ </script>
691
+ <?php
692
  endif;
693
  ?>
694
 
css/auditlog.css CHANGED
@@ -338,9 +338,13 @@ div.wsal_notice__wrapper p {
338
  align-items: center;
339
  }
340
 
341
- #wsal-event-loader {
 
342
  text-align: center;
343
  }
 
 
 
344
 
345
  .wsal-lds-ellipsis {
346
  display: inline-block;
338
  align-items: center;
339
  }
340
 
341
+ #wsal-event-loader,
342
+ #wsal-auditlog-end {
343
  text-align: center;
344
  }
345
+ #wsal-auditlog-end {
346
+ display: none;
347
+ }
348
 
349
  .wsal-lds-ellipsis {
350
  display: inline-block;
defaults.php CHANGED
@@ -453,10 +453,6 @@ function wsaldefaults_wsal_init() {
453
  array( 6018, E_CRITICAL, __( 'Modified the list of keywords for comments blacklisting', 'wp-security-audit-log' ), __( 'Modified the list of keywords for comments blacklisting.', 'wp-security-audit-log' ) ),
454
  array( 6024, E_CRITICAL, __( 'Option WordPress Address (URL) in WordPress settings changed', 'wp-security-audit-log' ), __( 'Changed the WordPress address (URL) from %old_url% to %new_url%.', 'wp-security-audit-log' ) ),
455
  array( 6025, E_CRITICAL, __( 'Option Site Address (URL) in WordPress settings changed', 'wp-security-audit-log' ), __( 'Changed the site address (URL) from %old_url% to %new_url%.', 'wp-security-audit-log' ) ),
456
- array( 6019, E_CRITICAL, __( 'Created a New cron job', 'wp-security-audit-log' ), __( 'A new cron job called %name% was created and is scheduled to run %schedule%.', 'wp-security-audit-log' ) ),
457
- array( 6020, E_CRITICAL, __( 'Changed status of the cron job', 'wp-security-audit-log' ), __( 'The cron job %name% was %status%.', 'wp-security-audit-log' ) ),
458
- array( 6021, E_CRITICAL, __( 'Deleted the cron job', 'wp-security-audit-log' ), __( 'The cron job %name% was deleted.', 'wp-security-audit-log' ) ),
459
- array( 6022, E_NOTICE, __( 'Started the cron job', 'wp-security-audit-log' ), __( 'The cron job %name% has just started.', 'wp-security-audit-log' ) ),
460
  ),
461
  ),
462
 
@@ -576,6 +572,11 @@ function wsaldefaults_wsal_init() {
576
  array( 9074, E_CRITICAL, __( 'User enabled a payment gateway', 'wp-security-audit-log' ), __( 'Enabled the payment gateway %GatewayName%.', 'wp-security-audit-log' ) ),
577
  array( 9075, E_CRITICAL, __( 'User disabled a payment gateway', 'wp-security-audit-log' ), __( 'Disabled the payment gateway %GatewayName%.', 'wp-security-audit-log' ) ),
578
  array( 9076, E_CRITICAL, __( 'User modified a payment gateway', 'wp-security-audit-log' ), __( 'Modified the payment gateway %GatewayName%.', 'wp-security-audit-log' ) ),
 
 
 
 
 
579
  array( 9002, E_NOTICE, __( 'User created a new product category', 'wp-security-audit-log' ), __( 'Created a new product category called %CategoryName% in WooCommerce. Product category slug is %Slug%.', 'wp-security-audit-log' ) ),
580
  array( 9052, E_WARNING, __( 'User deleted a product category', 'wp-security-audit-log' ), __( 'Deleted the product category called %CategoryName% in WooCommerce. Product category slug was %CategorySlug%.', 'wp-security-audit-log' ) ),
581
  array( 9053, E_WARNING, __( 'User changed the slug of a product category', 'wp-security-audit-log' ), __( 'Changed the Slug of the product category %CategoryName% in WooCommerce from %OldSlug% to %NewSlug%.', 'wp-security-audit-log' ) ),
453
  array( 6018, E_CRITICAL, __( 'Modified the list of keywords for comments blacklisting', 'wp-security-audit-log' ), __( 'Modified the list of keywords for comments blacklisting.', 'wp-security-audit-log' ) ),
454
  array( 6024, E_CRITICAL, __( 'Option WordPress Address (URL) in WordPress settings changed', 'wp-security-audit-log' ), __( 'Changed the WordPress address (URL) from %old_url% to %new_url%.', 'wp-security-audit-log' ) ),
455
  array( 6025, E_CRITICAL, __( 'Option Site Address (URL) in WordPress settings changed', 'wp-security-audit-log' ), __( 'Changed the site address (URL) from %old_url% to %new_url%.', 'wp-security-audit-log' ) ),
 
 
 
 
456
  ),
457
  ),
458
 
572
  array( 9074, E_CRITICAL, __( 'User enabled a payment gateway', 'wp-security-audit-log' ), __( 'Enabled the payment gateway %GatewayName%.', 'wp-security-audit-log' ) ),
573
  array( 9075, E_CRITICAL, __( 'User disabled a payment gateway', 'wp-security-audit-log' ), __( 'Disabled the payment gateway %GatewayName%.', 'wp-security-audit-log' ) ),
574
  array( 9076, E_CRITICAL, __( 'User modified a payment gateway', 'wp-security-audit-log' ), __( 'Modified the payment gateway %GatewayName%.', 'wp-security-audit-log' ) ),
575
+ array( 9078, E_NOTICE, __( 'User modified prices with tax option', 'wp-security-audit-log' ), __( 'Set the option that prices are %TaxStatus% of tax.', 'wp-security-audit-log' ) ),
576
+ array( 9079, E_CRITICAL, __( 'User modified tax calculation base', 'wp-security-audit-log' ), __( 'Set the setting Calculate tax based on to %Setting%.', 'wp-security-audit-log' ) ),
577
+ array( 9080, E_CRITICAL, __( 'User modified shipping tax class', 'wp-security-audit-log' ), __( 'Set the Shipping tax class to %Setting%.', 'wp-security-audit-log' ) ),
578
+ array( 9081, E_CRITICAL, __( 'User enabled/disabled rounding of tax', 'wp-security-audit-log' ), __( '%Status% rounding of tax at subtotal level.', 'wp-security-audit-log' ) ),
579
+ array( 9082, E_CRITICAL, __( 'User modified a shipping zone', 'wp-security-audit-log' ), __( '%ShippingZoneStatus% the shipping zone %ShippingZoneName%.', 'wp-security-audit-log' ) ),
580
  array( 9002, E_NOTICE, __( 'User created a new product category', 'wp-security-audit-log' ), __( 'Created a new product category called %CategoryName% in WooCommerce. Product category slug is %Slug%.', 'wp-security-audit-log' ) ),
581
  array( 9052, E_WARNING, __( 'User deleted a product category', 'wp-security-audit-log' ), __( 'Deleted the product category called %CategoryName% in WooCommerce. Product category slug was %CategorySlug%.', 'wp-security-audit-log' ) ),
582
  array( 9053, E_WARNING, __( 'User changed the slug of a product category', 'wp-security-audit-log' ), __( 'Changed the Slug of the product category %CategoryName% in WooCommerce from %OldSlug% to %NewSlug%.', 'wp-security-audit-log' ) ),
js/auditlog.js CHANGED
@@ -442,7 +442,13 @@ function wsalLoadEvents( pageNumber ) {
442
  },
443
  success: function( html ) {
444
  jQuery( '#wsal-event-loader' ).hide( '1000' );
445
- jQuery( '#audit-log-viewer #the-list' ).append( html ); // This will be the div where our content will be loaded.
 
 
 
 
 
 
446
  },
447
  error: function( xhr, textStatus, error ) {
448
  console.log( xhr.statusText );
@@ -450,8 +456,12 @@ function wsalLoadEvents( pageNumber ) {
450
  console.log( error );
451
  }
452
  });
453
- return false;
 
 
 
454
  }
 
455
 
456
  jQuery( document ).ready( function() {
457
 
@@ -487,8 +497,9 @@ jQuery( document ).ready( function() {
487
  var count = 2;
488
  jQuery( window ).scroll( function() {
489
  if ( jQuery( window ).scrollTop() === jQuery( document ).height() - jQuery( window ).height() ) {
490
- wsalLoadEvents( count );
491
- count++;
 
492
  }
493
  });
494
  }
442
  },
443
  success: function( html ) {
444
  jQuery( '#wsal-event-loader' ).hide( '1000' );
445
+ if ( html ) {
446
+ wsalLoadEventsResponse = true;
447
+ jQuery( '#audit-log-viewer #the-list' ).append( html ); // This will be the div where our content will be loaded.
448
+ } else {
449
+ wsalLoadEventsResponse = false;
450
+ jQuery( '#wsal-auditlog-end' ).show( 'fast' );
451
+ }
452
  },
453
  error: function( xhr, textStatus, error ) {
454
  console.log( xhr.statusText );
456
  console.log( error );
457
  }
458
  });
459
+ if ( wsalLoadEventsResponse ) {
460
+ return pageNumber + 1;
461
+ }
462
+ return 0;
463
  }
464
+ var wsalLoadEventsResponse = true; // Global variable to check events loading response.
465
 
466
  jQuery( document ).ready( function() {
467
 
497
  var count = 2;
498
  jQuery( window ).scroll( function() {
499
  if ( jQuery( window ).scrollTop() === jQuery( document ).height() - jQuery( window ).height() ) {
500
+ if ( 0 !== count ) {
501
+ count = wsalLoadEvents( count );
502
+ }
503
  }
504
  });
505
  }
languages/wp-security-audit-log.pot CHANGED
@@ -3,14 +3,14 @@ msgid ""
3
  msgstr ""
4
  "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
5
  "Project-Id-Version: WP Security Audit Log\n"
6
- "POT-Creation-Date: 2018-05-02 11:30+0100\n"
7
- "PO-Revision-Date: 2018-05-02 11:30+0100\n"
8
  "Last-Translator: \n"
9
  "Language-Team: \n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
- "X-Generator: Poedit 2.0.7\n"
14
  "X-Poedit-Basepath: ..\n"
15
  "X-Poedit-Flags-xgettext: --add-comments=translators:\n"
16
  "X-Poedit-WPHeader: wp-security-audit-log.php\n"
@@ -21,226 +21,490 @@ msgstr ""
21
  "X-Poedit-SearchPath-0: .\n"
22
  "X-Poedit-SearchPathExcluded-0: *.js\n"
23
 
24
- #: classes/AuditLogListView.php:80
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
25
  msgid "No events so far."
26
  msgstr ""
27
 
28
- #: classes/AuditLogListView.php:98
29
  msgid "Show "
30
  msgstr ""
31
 
32
- #: classes/AuditLogListView.php:108
33
  msgid " Items"
34
  msgstr ""
35
 
36
- #: classes/AuditLogListView.php:123 classes/Views/AuditLog.php:221
37
- #: classes/Views/AuditLog.php:244
 
 
 
 
38
  msgid "All Sites"
39
  msgstr ""
40
 
41
- #: classes/AuditLogListView.php:147
42
  msgid "Live Database"
43
  msgstr ""
44
 
45
- #: classes/AuditLogListView.php:150
46
  msgid "Archive Database"
47
  msgstr ""
48
 
49
- #: classes/AuditLogListView.php:203 classes/WidgetManager.php:67
 
50
  msgid "User"
51
  msgstr ""
52
 
53
- #: classes/AuditLogListView.php:205 classes/Views/Settings.php:650
54
  msgid "Username"
55
  msgstr ""
56
 
57
- #: classes/AuditLogListView.php:208 classes/AuditLogListView.php:225
58
- msgid "Alert ID"
 
59
  msgstr ""
60
 
61
- #: classes/AuditLogListView.php:209 classes/AuditLogListView.php:228
 
62
  msgid "Severity"
63
  msgstr ""
64
 
65
- #: classes/AuditLogListView.php:210 classes/AuditLogListView.php:231
66
  msgid "Date"
67
  msgstr ""
68
 
69
- #: classes/AuditLogListView.php:212 classes/AuditLogListView.php:237
70
  msgid "Source IP"
71
  msgstr ""
72
 
73
- #: classes/AuditLogListView.php:215 classes/AuditLogListView.php:240
74
  msgid "Site"
75
  msgstr ""
76
 
77
- #: classes/AuditLogListView.php:217 classes/AuditLogListView.php:243
78
  msgid "Message"
79
  msgstr ""
80
 
81
- #: classes/AuditLogListView.php:295
82
  msgid "Click to toggle."
83
  msgstr ""
84
 
85
- #: classes/AuditLogListView.php:314
86
- msgid "Disable this type of alerts."
87
  msgstr ""
88
 
89
- #: classes/AuditLogListView.php:322
90
  msgid "Unknown error code."
91
  msgstr ""
92
 
93
- #: classes/AuditLogListView.php:357
94
- msgid "Show me all activity by this User"
 
 
 
 
 
 
 
 
 
95
  msgstr ""
96
 
97
- #: classes/AuditLogListView.php:372
98
  msgid "Unknown"
99
  msgstr ""
100
 
101
- #: classes/AuditLogListView.php:376 classes/Views/Licensing.php:113
 
 
 
 
102
  #: classes/Views/Licensing.php:153
103
  msgid "Plugin"
104
  msgstr ""
105
 
106
- #: classes/AuditLogListView.php:380
107
  msgid "Plugins"
108
  msgstr ""
109
 
110
- #: classes/AuditLogListView.php:384
111
  msgid "Website Visitor"
112
  msgstr ""
113
 
114
- #: classes/AuditLogListView.php:388
 
115
  msgid "System"
116
  msgstr ""
117
 
118
- #: classes/AuditLogListView.php:408 classes/AuditLogListView.php:421
119
  msgid "Show me all activity originating from this IP Address"
120
  msgstr ""
121
 
122
- #: classes/AuditLogListView.php:450
123
  msgid "View all details of this change"
124
  msgstr ""
125
 
126
- #: classes/AuditLogListView.php:451 classes/AuditLogListView.php:597
 
127
  msgid "Alert Data Inspector"
128
  msgstr ""
129
 
130
- #: classes/AuditLogListView.php:552 classes/AuditLogListView.php:569
 
 
 
 
131
  msgid "Download the log file."
132
  msgstr ""
133
 
134
- #: classes/AuditLogListView.php:577
 
135
  msgid "published"
136
  msgstr ""
137
 
138
- #: classes/Loggers/Database.php:182 classes/Views/EmailNotifications.php:153
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
139
  #: classes/Views/EmailNotifications.php:185 classes/Views/ExternalDB.php:152
140
- #: classes/Views/ExternalDB.php:184 classes/Views/Help.php:144
141
- #: classes/Views/Help.php:195 classes/Views/LogInUsers.php:154
142
  #: classes/Views/LogInUsers.php:186 classes/Views/Reports.php:153
143
  #: classes/Views/Reports.php:185 classes/Views/Search.php:153
144
  #: classes/Views/Search.php:178
145
  msgid "Upgrade to Premium"
146
  msgstr ""
147
 
148
- #: classes/Loggers/Database.php:183 classes/Views/AuditLog.php:105
149
- #: classes/Views/EmailNotifications.php:154
150
  #: classes/Views/EmailNotifications.php:186 classes/Views/ExternalDB.php:153
151
- #: classes/Views/ExternalDB.php:185 classes/Views/Help.php:196
152
  #: classes/Views/LogInUsers.php:155 classes/Views/LogInUsers.php:187
153
  #: classes/Views/Reports.php:154 classes/Views/Reports.php:186
154
  #: classes/Views/Search.php:154 classes/Views/Search.php:179
155
  msgid "More Information"
156
  msgstr ""
157
 
158
- #: classes/Sensors/Content.php:941 classes/Sensors/Content.php:949
159
- #: classes/Sensors/WooCommerce.php:608 classes/Sensors/WooCommerce.php:614
160
  msgid "Password Protected"
161
  msgstr ""
162
 
163
- #: classes/Sensors/Content.php:943 classes/Sensors/Content.php:951
164
  msgid "Public"
165
  msgstr ""
166
 
167
- #: classes/Sensors/Content.php:945 classes/Sensors/Content.php:953
168
  msgid "Private"
169
  msgstr ""
170
 
171
- #: classes/Sensors/WooCommerce.php:1270
 
 
 
 
 
 
 
172
  msgid "In stock"
173
  msgstr ""
174
 
175
- #: classes/Sensors/WooCommerce.php:1272
176
  msgid "Out of stock"
177
  msgstr ""
178
 
179
- #: classes/Settings.php:363
 
 
 
 
 
 
 
 
 
 
 
 
180
  msgid "This function is deprecated"
181
  msgstr ""
182
 
183
- #: classes/Views/AuditLog.php:78
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
184
  msgid ""
185
  "See who is logged in to your WordPress, create user productivity reports, "
186
  "get alerted via email of important changes and more!"
187
  msgstr ""
188
 
189
- #: classes/Views/AuditLog.php:79
190
  msgid ""
191
  "Unlock these powerful features and much more with the premium edition of WP "
192
  "Security Audit Log."
193
  msgstr ""
194
 
195
- #: classes/Views/AuditLog.php:104
196
- msgid "Buy Now"
 
 
 
 
 
 
 
 
 
 
 
 
197
  msgstr ""
198
 
199
- #: classes/Views/AuditLog.php:123
200
  msgid ""
201
  "There are connectivity issues with the database where the WordPress activity "
202
  "log is stored. The logs will be temporary buffered in the WordPress database "
203
  "until the connection is fully restored."
204
  msgstr ""
205
 
206
- #: classes/Views/AuditLog.php:140 classes/Views/AuditLog.php:156
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
207
  msgid "Audit Log Viewer"
208
  msgstr ""
209
 
210
- #: classes/Views/AuditLog.php:183 classes/Views/Licensing.php:82
211
- #: classes/Views/Settings.php:211 classes/Views/ToggleAlerts.php:68
212
  msgid "You do not have sufficient permissions to access this page."
213
  msgstr ""
214
 
215
- #: classes/Views/AuditLog.php:191 classes/Views/AuditLog.php:422
216
- #: classes/Views/Licensing.php:90 classes/Views/Settings.php:207
217
- #: classes/Views/Settings.php:968 classes/Views/Settings.php:996
218
- #: classes/Views/Settings.php:1026
219
- msgid "Nonce verification failed."
220
  msgstr ""
221
 
222
- #: classes/Views/AuditLog.php:220 classes/Views/AuditLog.php:243
 
 
 
 
 
 
 
 
 
 
223
  msgid "Please enter the number of alerts you would like to see on one page:"
224
  msgstr ""
225
 
226
- #: classes/Views/AuditLog.php:222 classes/Views/AuditLog.php:245
227
  msgid "No Results"
228
  msgstr ""
229
 
230
- #: classes/Views/AuditLog.php:419
231
  msgid "No users found."
232
  msgstr ""
233
 
234
- #: classes/Views/AuditLog.php:441
 
 
 
 
 
 
 
 
 
 
 
 
 
235
  msgid "Log file does not exist."
236
  msgstr ""
237
 
238
- #: classes/Views/AuditLog.php:482
239
  msgid "Request to get log file failed."
240
  msgstr ""
241
 
242
- #: classes/Views/AuditLog.php:489
243
- msgid "Nonce verification failed!"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
244
  msgstr ""
245
 
246
  #: classes/Views/EmailNotifications.php:28
@@ -337,7 +601,7 @@ msgstr ""
337
 
338
  #: classes/Views/ExternalDB.php:121
339
  msgid ""
340
- "Configure archiving rules to archive old alerts in an archiving database,"
341
  msgstr ""
342
 
343
  #: classes/Views/ExternalDB.php:167 classes/Views/ExternalDB.php:168
@@ -353,14 +617,19 @@ msgid ""
353
  msgstr ""
354
 
355
  #: classes/Views/Help.php:30 classes/Views/Help.php:44
 
356
  msgid "Help"
357
  msgstr ""
358
 
359
- #: classes/Views/Help.php:75
 
 
 
 
360
  msgid "Getting Started"
361
  msgstr ""
362
 
363
- #: classes/Views/Help.php:77
364
  msgid ""
365
  "Getting started with WP Security Audit Log is really easy; once the plugin "
366
  "is installed it will automatically keep a log of everything that is "
@@ -368,126 +637,126 @@ msgid ""
368
  "video below for a quick overview of the plugin."
369
  msgstr ""
370
 
371
- #: classes/Views/Help.php:86
372
  msgid "Plugin Support"
373
  msgstr ""
374
 
375
- #: classes/Views/Help.php:88
376
  msgid ""
377
  "Have you encountered or noticed any issues while using WP Security Audit Log "
378
  "plugin?"
379
  msgstr ""
380
 
381
- #: classes/Views/Help.php:89
382
  msgid ""
383
  "Or you want to report something to us? Click any of the options below to "
384
  "post on the plugin's forum or contact our support directly."
385
  msgstr ""
386
 
387
- #: classes/Views/Help.php:91
388
  msgid "Free Support Forum"
389
  msgstr ""
390
 
391
- #: classes/Views/Help.php:93
392
  msgid "Free Support Email"
393
  msgstr ""
394
 
395
- #: classes/Views/Help.php:99
396
  msgid "Plugin Documentation"
397
  msgstr ""
398
 
399
- #: classes/Views/Help.php:101
400
  msgid ""
401
  "For more technical information about the WP Security Audit Log plugin please "
402
  "visit the plugin’s knowledge base."
403
  msgstr ""
404
 
405
- #: classes/Views/Help.php:102
406
  msgid ""
407
- "Refer to the list of WordPress security alerts for a complete list of Alerts "
408
  "and IDs that the plugin uses to keep a log of all the changes in the "
409
  "WordPress audit log."
410
  msgstr ""
411
 
412
- #: classes/Views/Help.php:104
413
  msgid "Plugin Website"
414
  msgstr ""
415
 
416
- #: classes/Views/Help.php:106
417
  msgid "Knowledge Base"
418
  msgstr ""
419
 
420
- #: classes/Views/Help.php:108
421
- msgid "List of WordPress Security Alerts"
422
  msgstr ""
423
 
424
- #: classes/Views/Help.php:114
425
  msgid "Rate WP Security Audit Log"
426
  msgstr ""
427
 
428
- #: classes/Views/Help.php:116
429
  msgid ""
430
  "We work really hard to deliver a plugin that enables you to keep a record of "
431
  "all the changes that are happening on your WordPress."
432
  msgstr ""
433
 
434
- #: classes/Views/Help.php:117
435
  msgid ""
436
  "It takes thousands of man-hours every year and endless amount of dedication "
437
  "to research, develop and maintain the free edition of WP Security Audit Log."
438
  msgstr ""
439
 
440
- #: classes/Views/Help.php:118
441
  msgid ""
442
  "Therefore if you like what you see, and find WP Security Audit Log useful we "
443
  "ask you nothing more than to please rate our plugin."
444
  msgstr ""
445
 
446
- #: classes/Views/Help.php:119
447
  msgid "We appreciate every star!"
448
  msgstr ""
449
 
450
- #: classes/Views/Help.php:129
451
  msgid "Rate Plugin"
452
  msgstr ""
453
 
454
- #: classes/Views/Help.php:148
455
  msgid "See who is logged in"
456
  msgstr ""
457
 
458
- #: classes/Views/Help.php:149
459
  msgid "And remotely terminate sessions"
460
  msgstr ""
461
 
462
- #: classes/Views/Help.php:152
463
  msgid "Generate reports"
464
  msgstr ""
465
 
466
- #: classes/Views/Help.php:153
467
  msgid "Or configure automated email reports"
468
  msgstr ""
469
 
470
- #: classes/Views/Help.php:156
471
  msgid "Configure email notifications"
472
  msgstr ""
473
 
474
- #: classes/Views/Help.php:157
475
  msgid "Get instantly notified of important changes"
476
  msgstr ""
477
 
478
- #: classes/Views/Help.php:160
479
  msgid "Add Search"
480
  msgstr ""
481
 
482
- #: classes/Views/Help.php:161
483
  msgid "Easily track down suspicious behaviour"
484
  msgstr ""
485
 
486
- #: classes/Views/Help.php:164
487
  msgid "Integrate & Centralise"
488
  msgstr ""
489
 
490
- #: classes/Views/Help.php:165
491
  msgid "Export the logs to your centralised logging system"
492
  msgstr ""
493
 
@@ -495,13 +764,13 @@ msgstr ""
495
  msgid "Licensing"
496
  msgstr ""
497
 
498
- #: classes/Views/Licensing.php:96 classes/Views/Settings.php:218
499
- #: classes/Views/ToggleAlerts.php:92
500
  msgid "Settings have been saved."
501
  msgstr ""
502
 
503
- #: classes/Views/Licensing.php:101 classes/Views/Settings.php:223
504
- #: classes/Views/ToggleAlerts.php:98
505
  msgid "Error: "
506
  msgstr ""
507
 
@@ -660,117 +929,143 @@ msgid ""
660
  "to fine tune the search results."
661
  msgstr ""
662
 
663
- #: classes/Views/Settings.php:57 classes/Views/Settings.php:71
664
- msgid "Settings"
665
  msgstr ""
666
 
667
- #: classes/Views/Settings.php:229
668
- msgid "General"
669
  msgstr ""
670
 
671
- #: classes/Views/Settings.php:230
672
- msgid "Audit Log"
673
  msgstr ""
674
 
675
- #: classes/Views/Settings.php:231
676
  msgid "Exclude Objects"
677
  msgstr ""
678
 
679
- #: classes/Views/Settings.php:247
680
- msgid "From Email & Name"
681
  msgstr ""
682
 
683
- #: classes/Views/Settings.php:250
684
- msgid "Email Address"
 
685
  msgstr ""
686
 
687
- #: classes/Views/Settings.php:253
688
- msgid "Display Name"
689
  msgstr ""
690
 
691
- #: classes/Views/Settings.php:259
692
- #, php-format
693
- msgid ""
694
- "These email address and display name will be used as From details in the "
695
- "emails sent by the %s . Please ensure the mail server can relay emails with "
696
- "the domain of the specified email address."
 
697
  msgstr ""
698
 
699
- #: classes/Views/Settings.php:260
700
- msgid "(premium add-ons)"
701
  msgstr ""
702
 
703
- #: classes/Views/Settings.php:268
704
- msgid "Alerts Dashboard Widget"
705
  msgstr ""
706
 
707
- #: classes/Views/Settings.php:274
708
- msgid "On"
 
 
 
709
  msgstr ""
710
 
711
- #: classes/Views/Settings.php:279
712
- msgid "Off"
713
  msgstr ""
714
 
715
- #: classes/Views/Settings.php:285
 
716
  #, php-format
717
- msgid "Display a dashboard widget with the latest %d security alerts."
 
 
718
  msgstr ""
719
 
720
- #: classes/Views/Settings.php:295
721
- msgid "Reverse Proxy / Firewall Options"
722
  msgstr ""
723
 
724
- #: classes/Views/Settings.php:300
725
- msgid "WordPress running behind firewall or proxy"
726
  msgstr ""
727
 
728
- #: classes/Views/Settings.php:303
729
- msgid ""
730
- "Enable this option if your WordPress is running behind a firewall or reverse "
731
- "proxy. When this option is enabled the plugin will retrieve the user's IP "
732
- "address from the proxy header."
 
733
  msgstr ""
734
 
735
- #: classes/Views/Settings.php:307
736
- msgid "Filter Internal IP Addresses"
737
  msgstr ""
738
 
739
- #: classes/Views/Settings.php:310
 
 
740
  msgid ""
741
- "Enable this option to filter internal IP addresses from the proxy headers."
 
742
  msgstr ""
743
 
744
- #: classes/Views/Settings.php:316
745
- msgid "Can Manage Plugin"
746
  msgstr ""
747
 
748
- #: classes/Views/Settings.php:323
749
- msgid "Users and Roles in this list can manage the plugin settings"
750
  msgstr ""
751
 
752
- #: classes/Views/Settings.php:341
753
- msgid "Restrict Plugin Access"
754
  msgstr ""
755
 
756
- #: classes/Views/Settings.php:351
757
- msgid ""
758
- "If this option is disabled all the administrators on this WordPress have "
759
- "access to manage this plugin."
 
 
 
 
 
 
 
 
 
 
760
  msgstr ""
761
 
762
- #: classes/Views/Settings.php:352
 
 
 
 
763
  msgid ""
764
- "By enabling this option only <strong>You</strong> and the users specified in "
765
- "the <strong>Can Manage Plugin</strong> and <strong>Can View Alerts</strong> "
766
- "can configure this plugin or view the alerts in the WordPress audit trail."
767
  msgstr ""
768
 
769
- #: classes/Views/Settings.php:359
770
  msgid "Login Page Notification"
771
  msgstr ""
772
 
773
- #: classes/Views/Settings.php:383 wp-security-audit-log.php:1122
774
  msgid ""
775
  "For security and auditing purposes, a record of all of your logged-in "
776
  "actions and changes within the WordPress dashboard will be recorded in an "
@@ -779,3297 +1074,5036 @@ msgid ""
779
  "IP address where you accessed this site from."
780
  msgstr ""
781
 
782
- #: classes/Views/Settings.php:401
783
- msgid ""
784
- "Many compliance regulations (such as the GDRP) require website "
785
- "administrators to tell the users of this website that a log is kept of all "
786
- "the changes they do when logged in."
787
- msgstr ""
788
-
789
- #: classes/Views/Settings.php:403
790
  msgid "<strong>Note: </strong>"
791
  msgstr ""
792
 
793
- #: classes/Views/Settings.php:403
794
  msgid ""
795
  "The only HTML code allowed in the login page notification is for links ( < a "
796
- "href >...< /a > )."
797
- msgstr ""
798
-
799
- #: classes/Views/Settings.php:410
800
- msgid "Developer Options"
801
  msgstr ""
802
 
803
- #: classes/Views/Settings.php:416
804
- msgid "Show Developer Options"
805
  msgstr ""
806
 
807
- #: classes/Views/Settings.php:420
 
 
808
  msgid ""
809
- "Only enable these options on testing, staging and development websites. "
810
- "Enabling any of the settings below on LIVE websites may cause unintended "
811
- "side-effects including degraded performance."
812
  msgstr ""
813
 
814
- #: classes/Views/Settings.php:434
815
- msgid "Request Log"
816
  msgstr ""
817
 
818
- #: classes/Views/Settings.php:435
819
- msgid "Enables logging request to file."
820
  msgstr ""
821
 
822
- #: classes/Views/Settings.php:459
823
  msgid ""
824
- "The request log file is saved in the /wp-content/uploads/wp-security-audit-"
825
- "log/ directory."
826
- msgstr ""
827
-
828
- #: classes/Views/Settings.php:467
829
- msgid "Hide Plugin in Plugins Page"
830
  msgstr ""
831
 
832
- #: classes/Views/Settings.php:472
833
- msgid "Hide"
834
  msgstr ""
835
 
836
- #: classes/Views/Settings.php:476
837
  msgid ""
838
- "To manually revert this setting set the value of option wsal-hide-plugin to "
839
- "0 in the wp_wsal_options table."
 
840
  msgstr ""
841
 
842
- #: classes/Views/Settings.php:483
843
- msgid "Remove Data on Uninstall"
844
  msgstr ""
845
 
846
- #: classes/Views/Settings.php:490
847
- msgid ""
848
- "Check this box if you would like remove all data when the plugin is deleted."
849
  msgstr ""
850
 
851
- #: classes/Views/Settings.php:509
852
- msgid ""
853
- "The options below are disabled because you enabled archiving of alerts to "
854
- "the archiving table from"
855
  msgstr ""
856
 
857
- #: classes/Views/Settings.php:514
858
- msgid "Audit Log Retention"
859
  msgstr ""
860
 
861
- #: classes/Views/Settings.php:517
862
- msgid "(eg: 1 month)"
863
  msgstr ""
864
 
865
- #: classes/Views/Settings.php:523
866
- msgid "None"
 
 
867
  msgstr ""
868
 
869
- #: classes/Views/Settings.php:527
870
- msgid "(Leave empty or enter 0 to disable automatic pruning.)"
871
  msgstr ""
872
 
873
- #: classes/Views/Settings.php:533
874
- msgid "Delete alerts older than"
 
 
 
875
  msgstr ""
876
 
877
- #: classes/Views/Settings.php:542
878
- msgid "months"
879
  msgstr ""
880
 
881
- #: classes/Views/Settings.php:546
882
- msgid "(eg: 80)"
 
 
883
  msgstr ""
884
 
885
- #: classes/Views/Settings.php:552
886
- msgid "Keep up to"
887
  msgstr ""
888
 
889
- #: classes/Views/Settings.php:557
890
- msgid "alerts"
 
 
 
891
  msgstr ""
892
 
893
- #: classes/Views/Settings.php:563
894
- msgid "Next Scheduled Cleanup is in "
895
  msgstr ""
896
 
897
- #: classes/Views/Settings.php:567
898
- #, php-format
899
- msgid "(or %s)"
900
  msgstr ""
901
 
902
- #: classes/Views/Settings.php:568
903
- msgid "Run Manually"
904
  msgstr ""
905
 
906
- #: classes/Views/Settings.php:576
907
- msgid "Can View Alerts"
908
  msgstr ""
909
 
910
- #: classes/Views/Settings.php:583
911
- msgid "Users and Roles in this list can view the security alerts"
912
  msgstr ""
913
 
914
- #: classes/Views/Settings.php:599
915
- msgid "Refresh Audit Log Viewer"
916
  msgstr ""
917
 
918
- #: classes/Views/Settings.php:606
919
- msgid "Automatic"
 
 
 
 
920
  msgstr ""
921
 
922
- #: classes/Views/Settings.php:608
923
- msgid "Refresh Audit Log Viewer as soon as there are new alerts."
924
  msgstr ""
925
 
926
- #: classes/Views/Settings.php:613
927
- msgid "Manual"
928
  msgstr ""
929
 
930
- #: classes/Views/Settings.php:615
931
- msgid "Refresh Audit Log Viewer only when the page is reloaded."
932
  msgstr ""
933
 
934
- #: classes/Views/Settings.php:622
935
- msgid "Alerts Timestamp"
 
 
936
  msgstr ""
937
 
938
- #: classes/Views/Settings.php:629
939
- msgid "UTC"
 
 
 
940
  msgstr ""
941
 
942
- #: classes/Views/Settings.php:635
943
- msgid "WordPress' timezone"
 
 
 
944
  msgstr ""
945
 
946
- #: classes/Views/Settings.php:638
 
 
947
  msgid ""
948
- "Select which timestamp the alerts should have in the Audit Log viewer. Note "
949
- "that the WordPress' timezone might be different from that of the server."
950
  msgstr ""
951
 
952
- #: classes/Views/Settings.php:644
953
- msgid "User Information in Audit Log"
954
  msgstr ""
955
 
956
- #: classes/Views/Settings.php:655
957
- msgid "First Name & Last Name"
958
  msgstr ""
959
 
960
- #: classes/Views/Settings.php:658
961
- msgid ""
962
- "Select the type of user information that should be displayed in the audit "
963
- "log."
964
  msgstr ""
965
 
966
- #: classes/Views/Settings.php:664
967
- msgid "Audit Log Columns Selection"
968
  msgstr ""
969
 
970
- #: classes/Views/Settings.php:680
971
- msgid ""
972
- "When you disable any of the above such details won’t be shown in the Audit "
973
- "Log viewer though the plugin will still record such information in the "
974
- "database."
975
  msgstr ""
976
 
977
- #: classes/Views/Settings.php:686
978
- msgid "Disable Alerts for WordPress Background Activity"
979
  msgstr ""
980
 
981
- #: classes/Views/Settings.php:692
982
- msgid "Hide activity"
983
  msgstr ""
984
 
985
- #: classes/Views/Settings.php:696
986
- msgid ""
987
- "For example do not raise an alert when WordPress deletes the auto drafts."
988
  msgstr ""
989
 
990
- #: classes/Views/Settings.php:707
991
- msgid "Users & Roles"
992
  msgstr ""
993
 
994
- #: classes/Views/Settings.php:710
995
  msgid ""
996
- "Any of the users and roles listed in the below options will be excluded from "
997
- "monitoring. This means that any change they do will not be logged."
 
998
  msgstr ""
999
 
1000
- #: classes/Views/Settings.php:714
1001
- msgid "Excluded Users"
1002
  msgstr ""
1003
 
1004
- #: classes/Views/Settings.php:734
1005
- msgid "Excluded Roles"
1006
  msgstr ""
1007
 
1008
- #: classes/Views/Settings.php:753
1009
- msgid "Custom Fields"
1010
  msgstr ""
1011
 
1012
- #: classes/Views/Settings.php:757
1013
  msgid ""
1014
- "All of the custom fields listed below will be excluded from monitoring. This "
1015
- "means that if they are changed or updated the plugin will not log such "
1016
- "activity."
1017
  msgstr ""
1018
 
1019
- #: classes/Views/Settings.php:758
1020
  msgid ""
1021
- "You can use the * wildcard to exclude more than one Custom Field. For "
1022
- "example, to exclude all the Custom Fields that start with wp123 specify "
1023
- "wp123*."
 
1024
  msgstr ""
1025
 
1026
- #: classes/Views/Settings.php:763
1027
- msgid "Excluded Custom Fields"
1028
  msgstr ""
1029
 
1030
- #: classes/Views/Settings.php:782
1031
- msgid "IP Addresses"
1032
  msgstr ""
1033
 
1034
- #: classes/Views/Settings.php:785
1035
- msgid ""
1036
- "Any of the IP addresses listed below will be excluded from monitoring. This "
1037
- "means that all activity from such IP address will not be recorded."
1038
  msgstr ""
1039
 
1040
- #: classes/Views/Settings.php:789
1041
- msgid "Excluded IP Addresses"
1042
  msgstr ""
1043
 
1044
- #: classes/Views/Settings.php:808 defaults.php:206
1045
- msgid "Custom Post Types"
1046
  msgstr ""
1047
 
1048
- #: classes/Views/Settings.php:811
1049
  msgid ""
1050
- "The below list of Custom Post Types are excluded from monitoring. This means "
1051
- "that all activity related to these Custom Post Types will not be recorded."
1052
- msgstr ""
1053
-
1054
- #: classes/Views/Settings.php:814
1055
- msgid "Exclude Custom Post Type from monitoring"
1056
  msgstr ""
1057
 
1058
- #: classes/Views/ToggleAlerts.php:27 classes/Views/ToggleAlerts.php:41
1059
- msgid "Enable/Disable Alerts"
1060
  msgstr ""
1061
 
1062
- #: classes/Views/ToggleAlerts.php:175
1063
- msgid "Code"
1064
  msgstr ""
1065
 
1066
- #: classes/Views/ToggleAlerts.php:176
1067
- msgid "Type"
1068
  msgstr ""
1069
 
1070
- #: classes/Views/ToggleAlerts.php:177 classes/WidgetManager.php:68
1071
- msgid "Description"
1072
  msgstr ""
1073
 
1074
- #: classes/Views/ToggleAlerts.php:186
1075
  msgid ""
1076
- "<strong>Note:</strong> Post refers to any type of content, i.e. blog post, "
1077
- "page or a post with a custom post type."
1078
  msgstr ""
1079
 
1080
- #: classes/Views/ToggleAlerts.php:201
1081
- msgid "Not Implemented"
1082
  msgstr ""
1083
 
1084
- #: classes/Views/ToggleAlerts.php:204
1085
- msgid "Not Available"
1086
  msgstr ""
1087
 
1088
- #: classes/Views/ToggleAlerts.php:230 classes/Views/ToggleAlerts.php:263
1089
- msgid ""
1090
- "Capture 404 requests to file (the log file are created in the /wp-content/"
1091
- "uploads/wp-security-audit-log/404s/ directory)"
1092
  msgstr ""
1093
 
1094
- #: classes/Views/ToggleAlerts.php:238 classes/Views/ToggleAlerts.php:271
1095
- msgid "Purge log files older than one month"
1096
  msgstr ""
1097
 
1098
- #: classes/Views/ToggleAlerts.php:243
1099
  msgid ""
1100
- "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
1101
- "to non-existing pages from the same IP address. Increase the value in this "
1102
- "setting to the desired amount to keep a log of more or less requests."
 
1103
  msgstr ""
1104
 
1105
- #: classes/Views/ToggleAlerts.php:248 classes/Views/ToggleAlerts.php:281
1106
- msgid "Record the referrer that generated the 404 error."
1107
  msgstr ""
1108
 
1109
- #: classes/Views/ToggleAlerts.php:276
1110
  msgid ""
1111
- "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
1112
- "to non-existing pages from the same IP address. Increase the value in this "
1113
- "setting to the desired amount to keep a log of more or less requests. Note "
1114
- "that by increasing this value to a high number, should your website be "
1115
- "scanned the plugin will consume more resources to log all the requests."
1116
  msgstr ""
1117
 
1118
- #: classes/Views/ToggleAlerts.php:293 classes/Views/ToggleAlerts.php:306
1119
  msgid ""
1120
- "Number of login attempts to log. Enter 0 to log all failed login attempts. "
1121
- "(By default the plugin only logs up to 10 failed login because the process "
1122
- "can be very resource intensive in case of a brute force attack)"
1123
  msgstr ""
1124
 
1125
- #: classes/Views/ToggleAlerts.php:321
1126
- msgid "Save Changes"
1127
  msgstr ""
1128
 
1129
- #: classes/WidgetManager.php:36
1130
- msgid "Latest Alerts"
1131
  msgstr ""
1132
 
1133
- #: classes/WidgetManager.php:60
1134
- msgid "No alerts found."
 
1135
  msgstr ""
1136
 
1137
- #: defaults.php:60
1138
- msgid "Fatal run-time error."
 
 
 
 
1139
  msgstr ""
1140
 
1141
- #: defaults.php:64
1142
- msgid "Run-time warning (non-fatal error)."
1143
  msgstr ""
1144
 
1145
- #: defaults.php:68
1146
- msgid "Compile-time parse error."
1147
  msgstr ""
1148
 
1149
- #: defaults.php:72
1150
- msgid "Run-time notice."
1151
  msgstr ""
1152
 
1153
- #: defaults.php:76
1154
- msgid "Fatal error that occurred during startup."
 
 
 
 
 
 
1155
  msgstr ""
1156
 
1157
- #: defaults.php:80
1158
- msgid "Warnings that occurred during startup."
1159
  msgstr ""
1160
 
1161
- #: defaults.php:84
1162
- msgid "Fatal compile-time error."
1163
  msgstr ""
1164
 
1165
- #: defaults.php:88
1166
- msgid "Compile-time warning."
1167
  msgstr ""
1168
 
1169
- #: defaults.php:92
1170
- msgid "User-generated error message."
1171
  msgstr ""
1172
 
1173
- #: defaults.php:96
1174
- msgid "User-generated warning message."
1175
  msgstr ""
1176
 
1177
- #: defaults.php:100
1178
- msgid "User-generated notice message."
1179
  msgstr ""
1180
 
1181
- #: defaults.php:104
1182
- msgid "Non-standard/optimal code warning."
1183
  msgstr ""
1184
 
1185
- #: defaults.php:108
1186
- msgid "Catchable fatal error."
1187
  msgstr ""
1188
 
1189
- #: defaults.php:112
1190
- msgid "Run-time deprecation notices."
1191
  msgstr ""
1192
 
1193
- #: defaults.php:116
1194
- msgid "Run-time user deprecation notices."
1195
  msgstr ""
1196
 
1197
- #: defaults.php:121
1198
- msgid "Critical, high-impact messages."
1199
  msgstr ""
1200
 
1201
- #: defaults.php:125
1202
- msgid "Debug informational messages."
1203
  msgstr ""
1204
 
1205
- #: defaults.php:135
1206
- msgid "Content & Comments"
1207
  msgstr ""
1208
 
1209
- #: defaults.php:139
1210
- msgid "Content"
1211
  msgstr ""
1212
 
1213
- #: defaults.php:140
1214
- msgid "User created a new post and saved it as draft"
1215
  msgstr ""
1216
 
1217
- #: defaults.php:140
1218
- msgid ""
1219
- "Created a new %PostType% titled %PostTitle% and saved it as draft. "
1220
- "%EditorLinkPost%."
1221
  msgstr ""
1222
 
1223
- #: defaults.php:141
1224
- msgid "User published a post"
1225
  msgstr ""
1226
 
1227
- #: defaults.php:141
1228
- msgid ""
1229
- "Published a %PostType% titled %PostTitle%. URL is %PostUrl%. %EditorLinkPost"
1230
- "%."
1231
  msgstr ""
1232
 
1233
- #: defaults.php:142
1234
- msgid "User modified a post"
1235
  msgstr ""
1236
 
1237
- #: defaults.php:142
1238
- msgid ""
1239
- "Modified the %PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
1240
- "%EditorLinkPost%."
1241
  msgstr ""
1242
 
1243
- #: defaults.php:143
1244
- msgid "User permanently deleted a post from the trash"
1245
  msgstr ""
1246
 
1247
- #: defaults.php:143
1248
- msgid ""
1249
- "Permanently deleted the %PostType% titled %PostTitle%. URL was %PostUrl%."
1250
  msgstr ""
1251
 
1252
- #: defaults.php:144
1253
- msgid "User moved a post to the trash"
1254
  msgstr ""
1255
 
1256
- #: defaults.php:144
1257
- msgid ""
1258
- "Moved the %PostStatus% %PostType% titled %PostTitle% to trash. URL is "
1259
- "%PostUrl%."
1260
  msgstr ""
1261
 
1262
- #: defaults.php:145
1263
- msgid "User restored a post from trash"
1264
  msgstr ""
1265
 
1266
- #: defaults.php:145
1267
- msgid ""
1268
- "The %PostStatus% %PostType% titled %PostTitle% has been restored from trash. "
1269
- "URL is: %PostUrl%. %EditorLinkPost%."
1270
  msgstr ""
1271
 
1272
- #: defaults.php:146
1273
- msgid "User changed post category"
1274
  msgstr ""
1275
 
1276
- #: defaults.php:146
1277
- msgid ""
1278
- "Changed the category of the %PostStatus% %PostType% titled %PostTitle% from "
1279
- "%OldCategories% to %NewCategories%. URL is: %PostUrl%. %EditorLinkPost%."
1280
  msgstr ""
1281
 
1282
- #: defaults.php:147
1283
- msgid "User changed post URL"
1284
  msgstr ""
1285
 
1286
- #: defaults.php:147
1287
- msgid ""
1288
- "Changed the URL of the %PostStatus% %PostType% titled %PostTitle%%ReportText"
1289
- "%.%ChangeText% %EditorLinkPost%."
1290
  msgstr ""
1291
 
1292
- #: defaults.php:148
1293
- msgid "User changed post author"
1294
  msgstr ""
1295
 
1296
- #: defaults.php:148
1297
- msgid ""
1298
- "Changed the author of the %PostStatus% %PostType% titled %PostTitle% from "
1299
- "%OldAuthor% to %NewAuthor%. URL is: %PostUrl%. %EditorLinkPost%."
1300
  msgstr ""
1301
 
1302
- #: defaults.php:149
1303
- msgid "User changed post status"
1304
  msgstr ""
1305
 
1306
- #: defaults.php:149
1307
- msgid ""
1308
- "Changed the status of the %PostType% titled %PostTitle% from %OldStatus% to "
1309
- "%NewStatus%. URL is: %PostUrl%. %EditorLinkPost%."
1310
  msgstr ""
1311
 
1312
- #: defaults.php:150
1313
- msgid "User created new category"
1314
  msgstr ""
1315
 
1316
- #: defaults.php:150
1317
- msgid ""
1318
- "Created a new category called %CategoryName%. Category slug is %Slug%. "
1319
- "%CategoryLink%."
1320
  msgstr ""
1321
 
1322
- #: defaults.php:151
1323
- msgid "User deleted category"
1324
  msgstr ""
1325
 
1326
- #: defaults.php:151
1327
- msgid ""
1328
- "Deleted the %CategoryName% category. Category slug was %Slug%. %CategoryLink"
1329
- "%."
1330
  msgstr ""
1331
 
1332
- #: defaults.php:152
1333
- msgid "User changed the visibility of a post"
1334
  msgstr ""
1335
 
1336
- #: defaults.php:152
1337
- msgid ""
1338
- "Changed the visibility of the %PostStatus% %PostType% titled %PostTitle% "
1339
- "from %OldVisibility% to %NewVisibility%. URL is: %PostUrl%. %EditorLinkPost%."
1340
  msgstr ""
1341
 
1342
- #: defaults.php:153
1343
- msgid "User changed the date of a post"
1344
  msgstr ""
1345
 
1346
- #: defaults.php:153
1347
- msgid ""
1348
- "Changed the date of the %PostStatus% %PostType% titled %PostTitle% from "
1349
- "%OldDate% to %NewDate%. URL is: %PostUrl%. %EditorLinkPost%."
1350
  msgstr ""
1351
 
1352
- #: defaults.php:154
1353
- msgid "User changed the parent of a page"
1354
  msgstr ""
1355
 
1356
- #: defaults.php:154
1357
- msgid ""
1358
- "Changed the parent of the %PostStatus% %PostType% titled %PostTitle% from "
1359
- "%OldParentName% to %NewParentName%. %EditorLinkPost%."
1360
  msgstr ""
1361
 
1362
- #: defaults.php:155
1363
- msgid "User changed the template of a page"
1364
  msgstr ""
1365
 
1366
- #: defaults.php:155
1367
- msgid ""
1368
- "Changed the template of the %PostStatus% %PostType% titled %PostTitle% from "
1369
- "%OldTemplate% to %NewTemplate%. %EditorLinkPost%."
1370
  msgstr ""
1371
 
1372
- #: defaults.php:156
1373
- msgid "User set a post as sticky"
1374
  msgstr ""
1375
 
1376
- #: defaults.php:156
1377
- msgid ""
1378
- "Set the post %PostTitle% as Sticky. Post URL is %PostUrl%. %EditorLinkPost%."
1379
  msgstr ""
1380
 
1381
- #: defaults.php:157
1382
- msgid "User removed post from sticky"
1383
  msgstr ""
1384
 
1385
- #: defaults.php:157
1386
- msgid "Removed the post %PostTitle% from Sticky. %EditorLinkPost%."
1387
  msgstr ""
1388
 
1389
- #: defaults.php:158
1390
- msgid "Changed the parent of a category."
1391
  msgstr ""
1392
 
1393
- #: defaults.php:158
1394
- msgid ""
1395
- "Changed the parent of the category %CategoryName% from %OldParent% to "
1396
- "%NewParent%. %CategoryLink%."
1397
  msgstr ""
1398
 
1399
- #: defaults.php:159
1400
- msgid "User created a custom field for a post"
1401
  msgstr ""
1402
 
1403
- #: defaults.php:159
1404
- msgid ""
1405
- "Created a new custom field called %MetaKey% with value %MetaValue% in the "
1406
- "%PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
1407
- "%EditorLinkPost%.<br>%MetaLink%."
1408
  msgstr ""
1409
 
1410
- #: defaults.php:160
1411
- msgid "User updated a custom field value for a post"
1412
  msgstr ""
1413
 
1414
- #: defaults.php:160
1415
- msgid ""
1416
- "Modified the value of the custom field %MetaKey%%ReportText% in the "
1417
- "%PostStatus% %PostType% titled %PostTitle%.%ChangeText% URL is: %PostUrl%. "
1418
- "%EditorLinkPost%.<br>%MetaLink%."
1419
  msgstr ""
1420
 
1421
- #: defaults.php:161
1422
- msgid "User deleted a custom field from a post"
1423
  msgstr ""
1424
 
1425
- #: defaults.php:161
1426
- msgid ""
1427
- "Deleted the custom field %MetaKey% with value %MetaValue% from %PostStatus% "
1428
- "%PostType% titled %PostTitle%. URL is: %PostUrl%. %EditorLinkPost%."
1429
  msgstr ""
1430
 
1431
- #: defaults.php:162
1432
- msgid "User updated a custom field name for a post"
1433
  msgstr ""
1434
 
1435
- #: defaults.php:162
1436
- msgid ""
1437
- "Changed the custom field's name from %MetaKeyOld% to %MetaKeyNew% in the "
1438
- "%PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
1439
- "%EditorLinkPost%.<br>%MetaLink%."
1440
  msgstr ""
1441
 
1442
- #: defaults.php:163
1443
- msgid "User modified the content of a post."
1444
  msgstr ""
1445
 
1446
- #: defaults.php:163
1447
- msgid ""
1448
- "Modified the content of the %PostStatus% %PostType% titled %PostTitle%. Post "
1449
- "URL is %PostUrl%. %RevisionLink% %EditorLinkPost%."
1450
  msgstr ""
1451
 
1452
- #: defaults.php:164
1453
- msgid "User submitted a post for review"
1454
  msgstr ""
1455
 
1456
- #: defaults.php:164
1457
- msgid ""
1458
- "Submitted the %PostType% titled %PostTitle% for review. URL is: %PostUrl%. "
1459
- "%EditorLinkPost%."
1460
  msgstr ""
1461
 
1462
- #: defaults.php:165
1463
- msgid "User scheduled a post"
1464
  msgstr ""
1465
 
1466
- #: defaults.php:165
1467
- msgid ""
1468
- "Scheduled the %PostType% titled %PostTitle% to be published on "
1469
- "%PublishingDate%. URL is: %PostUrl%. %EditorLinkPost%."
1470
  msgstr ""
1471
 
1472
- #: defaults.php:166
1473
- msgid "User changed title of a post"
1474
  msgstr ""
1475
 
1476
- #: defaults.php:166
1477
- msgid ""
1478
- "Changed the title of the %PostStatus% %PostType% from %OldTitle% to %NewTitle"
1479
- "%. URL is: %PostUrl%. %EditorLinkPost%."
1480
  msgstr ""
1481
 
1482
- #: defaults.php:167
1483
- msgid "User opened a post in the editor"
1484
  msgstr ""
1485
 
1486
- #: defaults.php:167
1487
  msgid ""
1488
- "Opened the %PostStatus% %PostType% titled %PostTitle% in the editor. URL is: "
1489
- "%PostUrl%. %EditorLinkPost%."
1490
- msgstr ""
1491
-
1492
- #: defaults.php:168
1493
- msgid "User viewed a post"
1494
  msgstr ""
1495
 
1496
- #: defaults.php:168
1497
- msgid ""
1498
- "Viewed the %PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
1499
- "%EditorLinkPost%."
1500
  msgstr ""
1501
 
1502
- #: defaults.php:169
1503
- msgid "A plugin modified a post"
1504
  msgstr ""
1505
 
1506
- #: defaults.php:169
1507
- msgid ""
1508
- "Plugin modified the %PostStatus% %PostType% titled %PostTitle% of type "
1509
- "%PostType%. URL is: %PostUrl%. %EditorLinkPost%."
1510
  msgstr ""
1511
 
1512
- #: defaults.php:170
1513
- msgid "User disabled Comments/Trackbacks and Pingbacks in a post."
1514
  msgstr ""
1515
 
1516
- #: defaults.php:170
1517
  msgid ""
1518
- "Disabled %Type% on the %PostStatus% %PostType% titled %PostTitle%. URL is: "
1519
- "%PostUrl%. %EditorLinkPost%."
1520
  msgstr ""
1521
 
1522
- #: defaults.php:171
1523
- msgid "User enabled Comments/Trackbacks and Pingbacks in a post."
1524
  msgstr ""
1525
 
1526
- #: defaults.php:171
1527
- msgid ""
1528
- "Enabled %Type% on the %PostStatus% %PostType% titled %PostTitle%. URL is: "
1529
- "%PostUrl%. %EditorLinkPost%."
1530
  msgstr ""
1531
 
1532
- #: defaults.php:172
1533
- msgid "User added post tag"
1534
  msgstr ""
1535
 
1536
- #: defaults.php:172
1537
  msgid ""
1538
- "Added the tag %tag% to the %PostStatus% post titled %PostTitle%. URL is: "
1539
- "%PostUrl%. %EditorLinkPost%."
1540
  msgstr ""
1541
 
1542
- #: defaults.php:173
1543
- msgid "User removed post tag"
1544
  msgstr ""
1545
 
1546
- #: defaults.php:173
1547
  msgid ""
1548
- "Removed the tag %tag% from the %PostStatus% post titled %PostTitle%. URL is: "
1549
- "%PostUrl%. %EditorLinkPost%."
 
 
1550
  msgstr ""
1551
 
1552
- #: defaults.php:174
1553
- msgid "User created new tag"
1554
  msgstr ""
1555
 
1556
- #: defaults.php:174
1557
- msgid "Added a new tag called %TagName%. View the tag: %TagLink%."
1558
  msgstr ""
1559
 
1560
- #: defaults.php:175
1561
- msgid "User deleted tag"
 
 
1562
  msgstr ""
1563
 
1564
- #: defaults.php:175
1565
- msgid "Deleted the tag %TagName%."
 
 
 
 
 
1566
  msgstr ""
1567
 
1568
- #: defaults.php:176
1569
- msgid "User renamed tag"
1570
  msgstr ""
1571
 
1572
- #: defaults.php:176
1573
- msgid "Renamed a tag from %old_name% to %new_name%. View the tag: %TagLink%."
 
1574
  msgstr ""
1575
 
1576
- #: defaults.php:177
1577
- msgid "User changed tag slug"
 
 
 
1578
  msgstr ""
1579
 
1580
- #: defaults.php:177
1581
  msgid ""
1582
- "Changed the slug of tag %tag% from %old_slug% to %new_slug%. View the tag: "
1583
- "%TagLink%."
 
1584
  msgstr ""
1585
 
1586
- #: defaults.php:178
1587
- msgid "User changed tag description"
1588
  msgstr ""
1589
 
1590
- #: defaults.php:178
1591
  msgid ""
1592
- "Changed the description of the tag %tag%%ReportText%.%ChangeText% View the "
1593
- "tag: %TagLink%."
1594
- msgstr ""
1595
-
1596
- #: defaults.php:184
1597
- msgid "Comments"
1598
  msgstr ""
1599
 
1600
- #: defaults.php:185
1601
- msgid "User approved a comment"
1602
  msgstr ""
1603
 
1604
- #: defaults.php:185
1605
  msgid ""
1606
- "Approved the comment posted in response to the post %PostTitle% by %Author% "
1607
- "on %CommentLink%."
1608
  msgstr ""
1609
 
1610
- #: defaults.php:186
1611
- msgid "User unapproved a comment"
1612
  msgstr ""
1613
 
1614
- #: defaults.php:186
1615
  msgid ""
1616
- "Unapproved the comment posted in response to the post %PostTitle% by %Author"
1617
- "% on %CommentLink%."
 
 
1618
  msgstr ""
1619
 
1620
- #: defaults.php:187
1621
- msgid "User replied to a comment"
1622
  msgstr ""
1623
 
1624
- #: defaults.php:187
1625
- msgid ""
1626
- "Replied to the comment posted in response to the post %PostTitle% by %Author"
1627
- "% on %CommentLink%."
1628
  msgstr ""
1629
 
1630
- #: defaults.php:188
1631
- msgid "User edited a comment"
 
1632
  msgstr ""
1633
 
1634
- #: defaults.php:188
1635
- msgid ""
1636
- "Edited a comment posted in response to the post %PostTitle% by %Author% on "
1637
- "%CommentLink%."
1638
  msgstr ""
1639
 
1640
- #: defaults.php:189
1641
- msgid "User marked a comment as Spam"
 
 
 
 
1642
  msgstr ""
1643
 
1644
- #: defaults.php:189
1645
- msgid ""
1646
- "Marked the comment posted in response to the post %PostTitle% by %Author% on "
1647
- "%CommentLink% as Spam."
1648
  msgstr ""
1649
 
1650
- #: defaults.php:190
1651
- msgid "User marked a comment as Not Spam"
1652
  msgstr ""
1653
 
1654
- #: defaults.php:190
1655
- msgid ""
1656
- "Marked the comment posted in response to the post %PostTitle% by %Author% on "
1657
- "%CommentLink% as Not Spam."
1658
  msgstr ""
1659
 
1660
- #: defaults.php:191
1661
- msgid "User moved a comment to trash"
1662
  msgstr ""
1663
 
1664
- #: defaults.php:191
1665
  msgid ""
1666
- "Moved the comment posted in response to the post %PostTitle% by %Author% on "
1667
- "%Date% to trash."
 
1668
  msgstr ""
1669
 
1670
- #: defaults.php:192
1671
- msgid "User restored a comment from the trash"
1672
  msgstr ""
1673
 
1674
- #: defaults.php:192
1675
  msgid ""
1676
- "Restored the comment posted in response to the post %PostTitle% by %Author% "
1677
- "on %CommentLink% from the trash."
1678
  msgstr ""
1679
 
1680
- #: defaults.php:193
1681
- msgid "User permanently deleted a comment"
1682
  msgstr ""
1683
 
1684
- #: defaults.php:193
1685
  msgid ""
1686
- "Permanently deleted the comment posted in response to the post %PostTitle% "
1687
- "by %Author% on %Date%."
 
1688
  msgstr ""
1689
 
1690
- #: defaults.php:194
1691
- msgid "User posted a comment"
1692
  msgstr ""
1693
 
1694
- #: defaults.php:194 defaults.php:195
1695
- msgid "%CommentMsg% on %CommentLink%."
1696
  msgstr ""
1697
 
1698
- #: defaults.php:195
1699
- msgid "Visitor posted a comment"
1700
  msgstr ""
1701
 
1702
- #: defaults.php:207
1703
- msgid "User modified a draft blog post"
1704
- msgstr ""
1705
-
1706
- #: defaults.php:207
1707
- msgid "Modified the draft post with the %PostTitle%. %EditorLinkPost%."
1708
  msgstr ""
1709
 
1710
- #: defaults.php:208
1711
- msgid "User created a new post with custom post type and saved it as draft"
 
 
1712
  msgstr ""
1713
 
1714
- #: defaults.php:208
1715
  msgid ""
1716
- "Created a new custom post called %PostTitle% of type %PostType%. "
1717
- "%EditorLinkPost%."
 
1718
  msgstr ""
1719
 
1720
- #: defaults.php:209
1721
- msgid "User published a post with custom post type"
1722
  msgstr ""
1723
 
1724
- #: defaults.php:209
1725
  msgid ""
1726
- "Published a custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
1727
- "%. %EditorLinkPost%."
1728
  msgstr ""
1729
 
1730
- #: defaults.php:210
1731
- msgid "User modified a post with custom post type"
1732
  msgstr ""
1733
 
1734
- #: defaults.php:210
1735
  msgid ""
1736
- "Modified the custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
1737
- "%. %EditorLinkPost%."
 
1738
  msgstr ""
1739
 
1740
- #: defaults.php:211
1741
- msgid "User modified a draft post with custom post type"
1742
  msgstr ""
1743
 
1744
- #: defaults.php:211
1745
- msgid ""
1746
- "Modified the draft custom post %PostTitle% of type is %PostType%. "
1747
- "%EditorLinkPost%."
1748
  msgstr ""
1749
 
1750
- #: defaults.php:212
1751
- msgid "User permanently deleted post with custom post type"
1752
  msgstr ""
1753
 
1754
- #: defaults.php:212
1755
- msgid "Permanently Deleted the custom post %PostTitle% of type %PostType%."
 
 
1756
  msgstr ""
1757
 
1758
- #: defaults.php:213
1759
- msgid "User moved post with custom post type to trash"
1760
  msgstr ""
1761
 
1762
- #: defaults.php:213
1763
- msgid ""
1764
- "Moved the custom post %PostTitle% of type %PostType% to trash. Post URL was "
1765
- "%PostUrl%."
1766
  msgstr ""
1767
 
1768
- #: defaults.php:214
1769
- msgid "User restored post with custom post type from trash"
1770
  msgstr ""
1771
 
1772
- #: defaults.php:214
1773
  msgid ""
1774
- "The custom post %PostTitle% of type %PostType% has been restored from trash. "
1775
- "%EditorLinkPost%."
 
 
 
1776
  msgstr ""
1777
 
1778
- #: defaults.php:215
1779
- msgid "User changed the category of a post with custom post type"
1780
  msgstr ""
1781
 
1782
- #: defaults.php:215
 
 
 
 
1783
  msgid ""
1784
- "Changed the category(ies) of the custom post %PostTitle% of type %PostType% "
1785
- "from %OldCategories% to %NewCategories%. %EditorLinkPost%."
 
 
 
1786
  msgstr ""
1787
 
1788
- #: defaults.php:216
1789
- msgid "User changed the URL of a post with custom post type"
1790
  msgstr ""
1791
 
1792
- #: defaults.php:216
1793
- msgid ""
1794
- "Changed the URL of the custom post %PostTitle% of type %PostType% from "
1795
- "%OldUrl% to %NewUrl%. %EditorLinkPost%."
1796
  msgstr ""
1797
 
1798
- #: defaults.php:217
1799
- msgid "User changed the author or post with custom post type"
1800
  msgstr ""
1801
 
1802
- #: defaults.php:217
1803
- msgid ""
1804
- "Changed the author of custom post %PostTitle% of type %PostType% from "
1805
- "%OldAuthor% to %NewAuthor%. %EditorLinkPost%."
1806
  msgstr ""
1807
 
1808
- #: defaults.php:218
1809
- msgid "User changed the status of post with custom post type"
1810
  msgstr ""
1811
 
1812
- #: defaults.php:218
1813
- msgid ""
1814
- "Changed the status of custom post %PostTitle% of type %PostType% from "
1815
- "%OldStatus% to %NewStatus%. %EditorLinkPost%."
1816
  msgstr ""
1817
 
1818
- #: defaults.php:219
1819
- msgid "User changed the visibility of a post with custom post type"
1820
  msgstr ""
1821
 
1822
- #: defaults.php:219
1823
- msgid ""
1824
- "Changed the visibility of the custom post %PostTitle% of type %PostType% "
1825
- "from %OldVisibility% to %NewVisibility%. %EditorLinkPost%."
1826
  msgstr ""
1827
 
1828
- #: defaults.php:220
1829
- msgid "User changed the date of post with custom post type"
1830
  msgstr ""
1831
 
1832
- #: defaults.php:220
1833
- msgid ""
1834
- "Changed the date of the custom post %PostTitle% of type %PostType% from "
1835
- "%OldDate% to %NewDate%. %EditorLinkPost%."
1836
  msgstr ""
1837
 
1838
- #: defaults.php:221
1839
- msgid "User created a custom field for a custom post type"
1840
  msgstr ""
1841
 
1842
- #: defaults.php:221
1843
- msgid ""
1844
- "Created a new custom field %MetaKey% with value %MetaValue% in custom post "
1845
- "%PostTitle% of type %PostType%. %EditorLinkPost%.<br>%MetaLink%."
1846
  msgstr ""
1847
 
1848
- #: defaults.php:222
1849
- msgid "User updated a custom field for a custom post type"
1850
  msgstr ""
1851
 
1852
- #: defaults.php:222
1853
- msgid ""
1854
- "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
1855
- "%MetaValueNew% in custom post %PostTitle% of type %PostType% %EditorLinkPost"
1856
- "%.<br>%MetaLink%."
1857
  msgstr ""
1858
 
1859
- #: defaults.php:223
1860
- msgid "User deleted a custom field from a custom post type"
1861
  msgstr ""
1862
 
1863
- #: defaults.php:223
1864
- msgid ""
1865
- "Deleted the custom field %MetaKey% with id %MetaID% from custom post "
1866
- "%PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
1867
  msgstr ""
1868
 
1869
- #: defaults.php:224
1870
- msgid "User updated a custom field name for a custom post type"
1871
  msgstr ""
1872
 
1873
- #: defaults.php:224
1874
- msgid ""
1875
- "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in custom "
1876
- "post %PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
1877
  msgstr ""
1878
 
1879
- #: defaults.php:225
1880
- msgid "User modified content for a published custom post type"
1881
  msgstr ""
1882
 
1883
- #: defaults.php:225
1884
- msgid ""
1885
- "Modified the content of the published custom post type %PostTitle%. Post URL "
1886
- "is %PostUrl%.%EditorLinkPost%."
1887
  msgstr ""
1888
 
1889
- #: defaults.php:226
1890
- msgid "User modified content for a draft post"
1891
  msgstr ""
1892
 
1893
- #: defaults.php:226
1894
- msgid ""
1895
- "Modified the content of the draft post %PostTitle%.%RevisionLink% "
1896
- "%EditorLinkPost%."
1897
  msgstr ""
1898
 
1899
- #: defaults.php:227
1900
- msgid "User modified content for a draft custom post type"
1901
  msgstr ""
1902
 
1903
- #: defaults.php:227
1904
- msgid ""
1905
- "Modified the content of the draft custom post type %PostTitle%."
1906
- "%EditorLinkPost%."
1907
  msgstr ""
1908
 
1909
- #: defaults.php:228
1910
- msgid "User modified content of a post"
1911
  msgstr ""
1912
 
1913
- #: defaults.php:228
1914
- msgid ""
1915
- "Modified the content of post %PostTitle% which is submitted for review."
1916
- "%RevisionLink% %EditorLinkPost%."
1917
  msgstr ""
1918
 
1919
- #: defaults.php:229
1920
- msgid "User scheduled a custom post type"
1921
  msgstr ""
1922
 
1923
- #: defaults.php:229
1924
- msgid ""
1925
- "Scheduled the custom post type %PostTitle% to be published %PublishingDate%. "
1926
- "%EditorLinkPost%."
1927
  msgstr ""
1928
 
1929
- #: defaults.php:230
1930
- msgid "User changed title of a custom post type"
1931
  msgstr ""
1932
 
1933
- #: defaults.php:230
1934
- msgid ""
1935
- "Changed the title of the custom post %OldTitle% to %NewTitle%. "
1936
- "%EditorLinkPost%."
1937
  msgstr ""
1938
 
1939
- #: defaults.php:231
1940
- msgid "User opened a custom post type in the editor"
 
1941
  msgstr ""
1942
 
1943
- #: defaults.php:231
1944
- msgid ""
1945
- "Opened the custom post %PostTitle% of type %PostType% in the editor. View "
1946
- "the post: %EditorLinkPost%."
1947
  msgstr ""
1948
 
1949
- #: defaults.php:232
1950
- msgid "User viewed a custom post type"
1951
  msgstr ""
1952
 
1953
- #: defaults.php:232
1954
- msgid ""
1955
- "Viewed the custom post %PostTitle% of type %PostType%. View the post: "
1956
- "%PostUrl%."
1957
  msgstr ""
1958
 
1959
- #: defaults.php:243
1960
- msgid "Pages"
1961
  msgstr ""
1962
 
1963
- #: defaults.php:244
1964
- msgid "User created a new WordPress page and saved it as draft"
1965
  msgstr ""
1966
 
1967
- #: defaults.php:244
1968
- msgid ""
1969
- "Created a new page called %PostTitle% and saved it as draft. %EditorLinkPage"
1970
- "%."
1971
  msgstr ""
1972
 
1973
- #: defaults.php:245
1974
- msgid "User published a WordPress page"
 
 
1975
  msgstr ""
1976
 
1977
- #: defaults.php:245
1978
  msgid ""
1979
- "Published a page called %PostTitle%. Page URL is %PostUrl%. %EditorLinkPage%."
 
 
1980
  msgstr ""
1981
 
1982
- #: defaults.php:246
1983
- msgid "User modified a published WordPress page"
1984
  msgstr ""
1985
 
1986
- #: defaults.php:246
1987
- msgid ""
1988
- "Modified the published page %PostTitle%. Page URL is %PostUrl%. "
1989
- "%EditorLinkPage%."
1990
  msgstr ""
1991
 
1992
- #: defaults.php:247
1993
- msgid "User modified a draft WordPress page"
1994
  msgstr ""
1995
 
1996
- #: defaults.php:247
1997
  msgid ""
1998
- "Modified the draft page %PostTitle%. Page ID is %PostID%. %EditorLinkPage%."
1999
  msgstr ""
2000
 
2001
- #: defaults.php:248
2002
- msgid "User permanently deleted a page from the trash"
2003
  msgstr ""
2004
 
2005
- #: defaults.php:248
2006
- msgid "Permanently deleted the page %PostTitle%."
 
 
2007
  msgstr ""
2008
 
2009
- #: defaults.php:249
2010
- msgid "User moved WordPress page to the trash"
 
 
 
2011
  msgstr ""
2012
 
2013
- #: defaults.php:249
2014
- msgid "Moved the page %PostTitle% to trash. Page URL was %PostUrl%."
2015
  msgstr ""
2016
 
2017
- #: defaults.php:250
2018
- msgid "User restored a WordPress page from trash"
2019
  msgstr ""
2020
 
2021
- #: defaults.php:250
2022
- msgid "Page %PostTitle% has been restored from trash. %EditorLinkPage%."
2023
  msgstr ""
2024
 
2025
- #: defaults.php:251
2026
- msgid "User changed page URL"
2027
  msgstr ""
2028
 
2029
- #: defaults.php:251
2030
  msgid ""
2031
- "Changed the URL of the page %PostTitle% from %OldUrl% to %NewUrl%. "
2032
- "%EditorLinkPage%."
2033
  msgstr ""
2034
 
2035
- #: defaults.php:252
2036
- msgid "User changed page author"
 
 
 
 
 
 
2037
  msgstr ""
2038
 
2039
- #: defaults.php:252
2040
  msgid ""
2041
- "Changed the author of the page %PostTitle% from %OldAuthor% to %NewAuthor%. "
2042
- "%EditorLinkPage%."
 
2043
  msgstr ""
2044
 
2045
- #: defaults.php:253
2046
- msgid "User changed page status"
2047
  msgstr ""
2048
 
2049
- #: defaults.php:253
2050
- msgid ""
2051
- "Changed the status of the page %PostTitle% from %OldStatus% to %NewStatus%. "
2052
- "%EditorLinkPage%."
2053
  msgstr ""
2054
 
2055
- #: defaults.php:254
2056
- msgid "User changed the visibility of a page post"
 
 
2057
  msgstr ""
2058
 
2059
- #: defaults.php:254
2060
  msgid ""
2061
- "Changed the visibility of the page %PostTitle% from %OldVisibility% to "
2062
- "%NewVisibility%. %EditorLinkPage%."
2063
  msgstr ""
2064
 
2065
- #: defaults.php:255
2066
- msgid "User changed the date of a page post"
 
 
 
 
2067
  msgstr ""
2068
 
2069
- #: defaults.php:255
2070
- msgid ""
2071
- "Changed the date of the page %PostTitle% from %OldDate% to %NewDate%. "
2072
- "%EditorLinkPage%."
2073
  msgstr ""
2074
 
2075
- #: defaults.php:256
2076
- msgid "User created a custom field for a page"
2077
  msgstr ""
2078
 
2079
- #: defaults.php:256
2080
  msgid ""
2081
- "Created a new custom field called %MetaKey% with value %MetaValue% in the "
2082
- "page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
2083
  msgstr ""
2084
 
2085
- #: defaults.php:257
2086
- msgid "User updated a custom field value for a page"
 
 
2087
  msgstr ""
2088
 
2089
- #: defaults.php:257
2090
- msgid ""
2091
- "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
2092
- "%MetaValueNew% in the page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
2093
  msgstr ""
2094
 
2095
- #: defaults.php:258
2096
- msgid "User deleted a custom field from a page"
2097
  msgstr ""
2098
 
2099
- #: defaults.php:258
2100
- msgid ""
2101
- "Deleted the custom field %MetaKey% with id %MetaID% from page %PostTitle% "
2102
- "%EditorLinkPage%.<br>%MetaLink%."
2103
  msgstr ""
2104
 
2105
- #: defaults.php:259
2106
- msgid "User updated a custom field name for a page"
2107
  msgstr ""
2108
 
2109
- #: defaults.php:259
2110
  msgid ""
2111
- "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in the page "
2112
- "%PostTitle% %EditorLinkPage%.<br>%MetaLink%."
 
 
2113
  msgstr ""
2114
 
2115
- #: defaults.php:260
2116
- msgid "User modified content for a published page"
2117
  msgstr ""
2118
 
2119
- #: defaults.php:260
2120
- msgid ""
2121
- "Modified the content of the published page %PostTitle%. Page URL is %PostUrl"
2122
- "%. %RevisionLink% %EditorLinkPage%."
2123
  msgstr ""
2124
 
2125
- #: defaults.php:261
2126
- msgid "User modified content for a draft page"
2127
  msgstr ""
2128
 
2129
- #: defaults.php:261
2130
- msgid ""
2131
- "Modified the content of draft page %PostTitle%.%RevisionLink% %EditorLinkPage"
2132
- "%."
2133
  msgstr ""
2134
 
2135
- #: defaults.php:262
2136
- msgid "User scheduled a page"
2137
  msgstr ""
2138
 
2139
- #: defaults.php:262
2140
  msgid ""
2141
- "Scheduled the page %PostTitle% to be published %PublishingDate%. "
2142
- "%EditorLinkPage%."
 
 
 
 
2143
  msgstr ""
2144
 
2145
- #: defaults.php:263
2146
- msgid "User changed title of a page"
2147
  msgstr ""
2148
 
2149
- #: defaults.php:263
2150
- msgid ""
2151
- "Changed the title of the page %OldTitle% to %NewTitle%. %EditorLinkPage%."
2152
  msgstr ""
2153
 
2154
- #: defaults.php:264
2155
- msgid "User opened a page in the editor"
 
2156
  msgstr ""
2157
 
2158
- #: defaults.php:264
2159
- msgid ""
2160
- "Opened the page %PostTitle% in the editor. View the page: %EditorLinkPage%."
2161
  msgstr ""
2162
 
2163
- #: defaults.php:265
2164
- msgid "User viewed a page"
 
2165
  msgstr ""
2166
 
2167
- #: defaults.php:265
2168
- msgid "Viewed the page %PostTitle%. View the page: %PostUrl%."
 
2169
  msgstr ""
2170
 
2171
- #: defaults.php:266
2172
- msgid "User disabled Comments/Trackbacks and Pingbacks on a draft post"
 
 
2173
  msgstr ""
2174
 
2175
- #: defaults.php:266
2176
- msgid ""
2177
- "Disabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
2178
  msgstr ""
2179
 
2180
- #: defaults.php:267
2181
- msgid "User enabled Comments/Trackbacks and Pingbacks on a draft post"
 
2182
  msgstr ""
2183
 
2184
- #: defaults.php:267
2185
- msgid "Enabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
2186
  msgstr ""
2187
 
2188
- #: defaults.php:268
2189
- msgid "User disabled Comments/Trackbacks and Pingbacks on a published page"
2190
  msgstr ""
2191
 
2192
- #: defaults.php:268
2193
- msgid ""
2194
- "Disabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
2195
  msgstr ""
2196
 
2197
- #: defaults.php:269
2198
- msgid "User enabled Comments/Trackbacks and Pingbacks on a published page"
2199
  msgstr ""
2200
 
2201
- #: defaults.php:269
2202
  msgid ""
2203
- "Enabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
2204
- msgstr ""
2205
-
2206
- #: defaults.php:270
2207
- msgid "User disabled Comments/Trackbacks and Pingbacks on a draft page"
2208
  msgstr ""
2209
 
2210
- #: defaults.php:270
2211
  msgid ""
2212
- "Disabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
 
2213
  msgstr ""
2214
 
2215
- #: defaults.php:271
2216
- msgid "User enabled Comments/Trackbacks and Pingbacks on a draft page"
2217
  msgstr ""
2218
 
2219
- #: defaults.php:271
2220
- msgid "Enabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
 
 
2221
  msgstr ""
2222
 
2223
- #: defaults.php:278
2224
- msgid "WordPress & Multisite Management"
2225
  msgstr ""
2226
 
2227
- #: defaults.php:282
2228
- msgid "Database"
 
 
2229
  msgstr ""
2230
 
2231
- #: defaults.php:283
2232
- msgid "Plugin created tables"
2233
  msgstr ""
2234
 
2235
- #: defaults.php:283
2236
  msgid ""
2237
- "Plugin %Plugin->Name% created these tables in the database: %TableNames%."
2238
  msgstr ""
2239
 
2240
- #: defaults.php:284
2241
- msgid "Plugin modified tables structure"
2242
  msgstr ""
2243
 
2244
- #: defaults.php:284
2245
- msgid ""
2246
- "Plugin %Plugin->Name% modified the structure of these database tables: "
2247
- "%TableNames%."
2248
  msgstr ""
2249
 
2250
- #: defaults.php:285
2251
- msgid "Plugin deleted tables"
2252
  msgstr ""
2253
 
2254
- #: defaults.php:285
2255
- msgid ""
2256
- "Plugin %Plugin->Name% deleted the following tables from the database: "
2257
- "%TableNames%."
2258
  msgstr ""
2259
 
2260
- #: defaults.php:286
2261
- msgid "Theme created tables"
2262
  msgstr ""
2263
 
2264
- #: defaults.php:286
2265
- msgid "Theme %Theme->Name% created these tables in the database: %TableNames%."
2266
  msgstr ""
2267
 
2268
- #: defaults.php:287
2269
- msgid "Theme modified tables structure"
2270
  msgstr ""
2271
 
2272
- #: defaults.php:287
2273
- msgid ""
2274
- "Theme %Theme->Name% modified the structure of these database tables: "
2275
- "%TableNames%."
2276
  msgstr ""
2277
 
2278
- #: defaults.php:288
2279
- msgid "Theme deleted tables"
2280
  msgstr ""
2281
 
2282
- #: defaults.php:288
2283
- msgid ""
2284
- "Theme %Theme->Name% deleted the following tables from the database: "
2285
- "%TableNames%."
2286
  msgstr ""
2287
 
2288
- #: defaults.php:289
2289
- msgid "Unknown component created tables"
2290
  msgstr ""
2291
 
2292
- #: defaults.php:289
2293
- msgid ""
2294
- "An unknown component created these tables in the database: %TableNames%."
2295
  msgstr ""
2296
 
2297
- #: defaults.php:290
2298
- msgid "Unknown component modified tables structure"
2299
  msgstr ""
2300
 
2301
- #: defaults.php:290
2302
- msgid ""
2303
- "An unknown component modified the structure of these database tables: "
2304
- "%TableNames%."
2305
  msgstr ""
2306
 
2307
- #: defaults.php:291
2308
- msgid "Unknown component deleted tables"
2309
  msgstr ""
2310
 
2311
- #: defaults.php:291
2312
- msgid ""
2313
- "An unknown component deleted the following tables from the database: "
2314
- "%TableNames%."
2315
  msgstr ""
2316
 
2317
- #: defaults.php:297
2318
- msgid "MultiSite"
2319
  msgstr ""
2320
 
2321
- #: defaults.php:298
2322
- msgid "User granted Super Admin privileges"
2323
  msgstr ""
2324
 
2325
- #: defaults.php:298
2326
- msgid "Granted Super Admin privileges to %TargetUsername%."
2327
  msgstr ""
2328
 
2329
- #: defaults.php:299
2330
- msgid "User revoked from Super Admin privileges"
2331
  msgstr ""
2332
 
2333
- #: defaults.php:299
2334
- msgid "Revoked Super Admin privileges from %TargetUsername%."
2335
  msgstr ""
2336
 
2337
- #: defaults.php:300
2338
- msgid "Existing user added to a site"
2339
  msgstr ""
2340
 
2341
- #: defaults.php:300
2342
  msgid ""
2343
- "Added the existing user %TargetUsername% with %TargetUserRole% role to site "
2344
- "%SiteName%."
2345
  msgstr ""
2346
 
2347
- #: defaults.php:301
2348
- msgid "User removed from site"
2349
  msgstr ""
2350
 
2351
- #: defaults.php:301
2352
  msgid ""
2353
- "Removed the user %TargetUsername% with role %TargetUserRole% from %SiteName% "
2354
- "site."
 
2355
  msgstr ""
2356
 
2357
- #: defaults.php:302
2358
- msgid "New network user created"
2359
  msgstr ""
2360
 
2361
- #: defaults.php:302
2362
- msgid "Created a new network user %NewUserData->Username%."
 
 
 
 
 
2363
  msgstr ""
2364
 
2365
- #: defaults.php:303
2366
- msgid "The forum role of a user was changed by another WordPress user"
 
 
 
2367
  msgstr ""
2368
 
2369
- #: defaults.php:303
2370
  msgid ""
2371
- "Change the forum role of the user %TargetUsername% from %OldRole% to %NewRole"
2372
- "% by %UserChanger%."
 
 
2373
  msgstr ""
2374
 
2375
- #: defaults.php:304
2376
- msgid "New site added on the network"
2377
  msgstr ""
2378
 
2379
- #: defaults.php:304
2380
- msgid "Added the site %SiteName% to the network."
 
 
 
2381
  msgstr ""
2382
 
2383
- #: defaults.php:305
2384
- msgid "Existing site archived"
2385
  msgstr ""
2386
 
2387
- #: defaults.php:305
2388
- msgid "Archived the site %SiteName%."
2389
  msgstr ""
2390
 
2391
- #: defaults.php:306
2392
- msgid "Archived site has been unarchived"
 
 
2393
  msgstr ""
2394
 
2395
- #: defaults.php:306
2396
- msgid "Unarchived the site %SiteName%."
2397
  msgstr ""
2398
 
2399
- #: defaults.php:307
2400
- msgid "Deactivated site has been activated"
2401
  msgstr ""
2402
 
2403
- #: defaults.php:307
2404
- msgid "Activated the site %SiteName%."
 
 
2405
  msgstr ""
2406
 
2407
- #: defaults.php:308
2408
- msgid "Site has been deactivated"
2409
  msgstr ""
2410
 
2411
- #: defaults.php:308
2412
- msgid "Deactivated the site %SiteName%."
2413
  msgstr ""
2414
 
2415
- #: defaults.php:309
2416
- msgid "Existing site deleted from network"
 
 
2417
  msgstr ""
2418
 
2419
- #: defaults.php:309
2420
- msgid "Deleted the site %SiteName%."
2421
  msgstr ""
2422
 
2423
- #: defaults.php:310
2424
- msgid "Activated theme on network"
2425
  msgstr ""
2426
 
2427
- #: defaults.php:310
2428
- msgid ""
2429
- "Network activated the theme %Theme->Name% installed in %Theme-"
2430
- ">get_template_directory%."
2431
  msgstr ""
2432
 
2433
- #: defaults.php:311
2434
- msgid "Deactivated theme from network"
2435
  msgstr ""
2436
 
2437
- #: defaults.php:311
2438
- msgid ""
2439
- "Network deactivated the theme %Theme->Name% installed in %Theme-"
2440
- ">get_template_directory%."
2441
  msgstr ""
2442
 
2443
- #: defaults.php:317
2444
- msgid "Plugins & Themes"
2445
  msgstr ""
2446
 
2447
- #: defaults.php:318
2448
- msgid "User installed a plugin"
2449
  msgstr ""
2450
 
2451
- #: defaults.php:318
2452
- msgid "Installed the plugin %Plugin->Name% in %Plugin->plugin_dir_path%."
2453
  msgstr ""
2454
 
2455
- #: defaults.php:319
2456
- msgid "User activated a WordPress plugin"
2457
  msgstr ""
2458
 
2459
- #: defaults.php:319
2460
- msgid "Activated the plugin %PluginData->Name% installed in %PluginFile%."
2461
  msgstr ""
2462
 
2463
- #: defaults.php:320
2464
- msgid "User deactivated a WordPress plugin"
2465
  msgstr ""
2466
 
2467
- #: defaults.php:320
2468
- msgid "Deactivated the plugin %PluginData->Name% installed in %PluginFile%."
2469
  msgstr ""
2470
 
2471
- #: defaults.php:321
2472
- msgid "User uninstalled a plugin"
2473
  msgstr ""
2474
 
2475
- #: defaults.php:321
2476
- msgid ""
2477
- "Uninstalled the plugin %PluginData->Name% which was installed in %PluginFile"
2478
- "%."
2479
  msgstr ""
2480
 
2481
- #: defaults.php:322
2482
- msgid "User upgraded a plugin"
2483
  msgstr ""
2484
 
2485
- #: defaults.php:322
2486
- msgid "Upgraded the plugin %PluginData->Name% installed in %PluginFile%."
2487
  msgstr ""
2488
 
2489
- #: defaults.php:323
2490
- msgid "User installed a theme"
2491
  msgstr ""
2492
 
2493
- #: defaults.php:323
2494
- msgid ""
2495
- "Installed the theme \"%Theme->Name%\" in %Theme->get_template_directory%."
2496
  msgstr ""
2497
 
2498
- #: defaults.php:324
2499
- msgid "User activated a theme"
2500
  msgstr ""
2501
 
2502
- #: defaults.php:324
2503
- msgid ""
2504
- "Activated the theme \"%Theme->Name%\", installed in %Theme-"
2505
- ">get_template_directory%."
2506
  msgstr ""
2507
 
2508
- #: defaults.php:325
2509
- msgid "User uninstalled a theme"
2510
  msgstr ""
2511
 
2512
- #: defaults.php:325
2513
- msgid ""
2514
- "Deleted the theme \"%Theme->Name%\" installed in %Theme-"
2515
- ">get_template_directory%."
2516
  msgstr ""
2517
 
2518
- #: defaults.php:326
2519
- msgid "A plugin created a post"
2520
  msgstr ""
2521
 
2522
- #: defaults.php:326
2523
- msgid ""
2524
- "A plugin automatically created the following %PostType% called %PostTitle%. "
2525
- "View the post: %EditorLinkPost%."
2526
  msgstr ""
2527
 
2528
- #: defaults.php:327
2529
- msgid "A plugin created a page"
2530
  msgstr ""
2531
 
2532
- #: defaults.php:327
2533
- msgid "A plugin automatically created the following page: %PostTitle%."
2534
  msgstr ""
2535
 
2536
- #: defaults.php:328
2537
- msgid "A plugin created a custom post"
2538
  msgstr ""
2539
 
2540
- #: defaults.php:328
2541
- msgid "A plugin automatically created the following custom post: %PostTitle%."
2542
  msgstr ""
2543
 
2544
- #: defaults.php:329
2545
- msgid "A plugin deleted a post"
2546
  msgstr ""
2547
 
2548
- #: defaults.php:329
2549
  msgid ""
2550
- "A plugin automatically deleted the following %PostType% called %PostTitle%."
2551
  msgstr ""
2552
 
2553
- #: defaults.php:330
2554
- msgid "A plugin deleted a page"
2555
  msgstr ""
2556
 
2557
- #: defaults.php:330
2558
- msgid "A plugin automatically deleted the following page: %PostTitle%."
 
 
2559
  msgstr ""
2560
 
2561
- #: defaults.php:331
2562
- msgid "A plugin deleted a custom post"
2563
  msgstr ""
2564
 
2565
- #: defaults.php:331
2566
- msgid "A plugin automatically deleted the following custom post: %PostTitle%."
 
 
2567
  msgstr ""
2568
 
2569
- #: defaults.php:332
2570
- msgid "User updated a theme"
2571
  msgstr ""
2572
 
2573
- #: defaults.php:332
2574
- msgid ""
2575
- "Updated the theme \"%Theme->Name%\" installed in %Theme-"
2576
- ">get_template_directory%."
2577
  msgstr ""
2578
 
2579
- #: defaults.php:333
2580
- msgid "User changed a file using the theme editor"
2581
  msgstr ""
2582
 
2583
- #: defaults.php:333
2584
- msgid "Modified %File% with the Theme Editor."
2585
  msgstr ""
2586
 
2587
- #: defaults.php:334
2588
- msgid "User changed a file using the plugin editor"
2589
  msgstr ""
2590
 
2591
- #: defaults.php:334
2592
- msgid "Modified %File% with the Plugin Editor."
2593
  msgstr ""
2594
 
2595
- #: defaults.php:335
2596
- msgid "A plugin modified a page"
2597
  msgstr ""
2598
 
2599
- #: defaults.php:335
2600
- msgid "Plugin modified the page %PostTitle%. View the page: %EditorLinkPage%."
2601
  msgstr ""
2602
 
2603
- #: defaults.php:336
2604
- msgid "A plugin modified a custom post"
2605
  msgstr ""
2606
 
2607
- #: defaults.php:336
2608
  msgid ""
2609
- "Plugin modified the custom post %PostTitle%. View the post: %EditorLinkPost%."
2610
- msgstr ""
2611
-
2612
- #: defaults.php:342
2613
- msgid "System Activity"
2614
  msgstr ""
2615
 
2616
- #: defaults.php:343
2617
- msgid "Unknown Error"
2618
  msgstr ""
2619
 
2620
- #: defaults.php:343
2621
- msgid "An unexpected error has occurred ."
 
 
2622
  msgstr ""
2623
 
2624
- #: defaults.php:344
2625
- msgid "PHP error"
2626
  msgstr ""
2627
 
2628
- #: defaults.php:344 defaults.php:345 defaults.php:346 defaults.php:347
2629
- #: defaults.php:348
2630
- msgid "%Message%."
 
2631
  msgstr ""
2632
 
2633
- #: defaults.php:345
2634
- msgid "PHP warning"
2635
  msgstr ""
2636
 
2637
- #: defaults.php:346
2638
- msgid "PHP notice"
 
 
2639
  msgstr ""
2640
 
2641
- #: defaults.php:347
2642
- msgid "PHP exception"
2643
  msgstr ""
2644
 
2645
- #: defaults.php:348
2646
- msgid "PHP shutdown error"
 
 
2647
  msgstr ""
2648
 
2649
- #: defaults.php:349
2650
- msgid "Events automatically pruned by system"
2651
  msgstr ""
2652
 
2653
- #: defaults.php:349
2654
- msgid "System automatically deleted %EventCount% alert(s)."
2655
  msgstr ""
2656
 
2657
- #: defaults.php:350
2658
- msgid "Option Anyone Can Register in WordPress settings changed"
2659
  msgstr ""
2660
 
2661
- #: defaults.php:350
2662
- msgid "%NewValue% the option \"Anyone can register\"."
 
 
2663
  msgstr ""
2664
 
2665
- #: defaults.php:351
2666
- msgid "New User Default Role changed"
2667
  msgstr ""
2668
 
2669
- #: defaults.php:351
2670
- msgid "Changed the New User Default Role from %OldRole% to %NewRole%."
2671
  msgstr ""
2672
 
2673
- #: defaults.php:352
2674
- msgid "WordPress Administrator Notification email changed"
2675
  msgstr ""
2676
 
2677
- #: defaults.php:352
2678
  msgid ""
2679
- "Changed the WordPress administrator notifications email address from "
2680
- "%OldEmail% to %NewEmail%."
2681
  msgstr ""
2682
 
2683
- #: defaults.php:353
2684
- msgid "WordPress was updated"
2685
  msgstr ""
2686
 
2687
- #: defaults.php:353
2688
- msgid "Updated WordPress from version %OldVersion% to %NewVersion%."
 
 
2689
  msgstr ""
2690
 
2691
- #: defaults.php:354
2692
- msgid "User changes the WordPress Permalinks"
2693
  msgstr ""
2694
 
2695
- #: defaults.php:354
2696
- msgid "Changed the WordPress permalinks from %OldPattern% to %NewPattern%."
2697
  msgstr ""
2698
 
2699
- #: defaults.php:355
2700
- msgid "User requests non-existing pages (404 Error Pages)"
2701
  msgstr ""
2702
 
2703
- #: defaults.php:355
2704
  msgid ""
2705
- "Has requested a non existing page (404 Error Pages) %Attempts% %Msg%. "
2706
- "%LinkFile%"
2707
  msgstr ""
2708
 
2709
- #: defaults.php:356
2710
- msgid "Website Visitor User requests non-existing pages (404 Error Pages)"
2711
  msgstr ""
2712
 
2713
- #: defaults.php:356
2714
  msgid ""
2715
- "Website Visitor Has requested a non existing page (404 Error Pages) %Attempts"
2716
- "% %Msg%. %LinkFile%"
2717
  msgstr ""
2718
 
2719
- #: defaults.php:357
2720
- msgid "Option WordPress Address (URL) in WordPress settings changed"
2721
  msgstr ""
2722
 
2723
- #: defaults.php:357
2724
- msgid "Changed the WordPress address (URL) from %old_url% to %new_url%."
 
 
2725
  msgstr ""
2726
 
2727
- #: defaults.php:358
2728
- msgid "Option Site Address (URL) in WordPress settings changed"
2729
  msgstr ""
2730
 
2731
- #: defaults.php:358
2732
- msgid "Changed the site address (URL) from %old_url% to %new_url%."
 
 
2733
  msgstr ""
2734
 
2735
- #: defaults.php:359
2736
- msgid "Advertising Add-ons."
2737
  msgstr ""
2738
 
2739
- #: defaults.php:359
2740
- msgid "%PromoName% %PromoMessage%"
 
 
2741
  msgstr ""
2742
 
2743
- #: defaults.php:365
2744
- msgid "Menus"
2745
  msgstr ""
2746
 
2747
- #: defaults.php:366
2748
- msgid "User created new menu"
 
 
2749
  msgstr ""
2750
 
2751
- #: defaults.php:366
2752
- msgid "Created a new menu called %MenuName%."
2753
  msgstr ""
2754
 
2755
- #: defaults.php:367
2756
- msgid "User added content to a menu"
2757
  msgstr ""
2758
 
2759
- #: defaults.php:367
2760
- msgid "Added the %ContentType% called %ContentName% to menu %MenuName%."
 
 
2761
  msgstr ""
2762
 
2763
- #: defaults.php:368
2764
- msgid "User removed content from a menu"
2765
  msgstr ""
2766
 
2767
- #: defaults.php:368
2768
  msgid ""
2769
- "Removed the %ContentType% called %ContentName% from the menu %MenuName%."
 
2770
  msgstr ""
2771
 
2772
- #: defaults.php:369
2773
- msgid "User deleted menu"
2774
  msgstr ""
2775
 
2776
- #: defaults.php:369
2777
- msgid "Deleted the menu %MenuName%."
 
 
2778
  msgstr ""
2779
 
2780
- #: defaults.php:370
2781
- msgid "User changed menu setting"
2782
  msgstr ""
2783
 
2784
- #: defaults.php:370
2785
- msgid "%Status% the menu setting %MenuSetting% in %MenuName%."
 
2786
  msgstr ""
2787
 
2788
- #: defaults.php:371
2789
- msgid "User modified content in a menu"
2790
  msgstr ""
2791
 
2792
- #: defaults.php:371
2793
- msgid "Modified the %ContentType% called %ContentName% in menu %MenuName%."
 
 
2794
  msgstr ""
2795
 
2796
- #: defaults.php:372
2797
- msgid "User changed name of a menu"
2798
  msgstr ""
2799
 
2800
- #: defaults.php:372
2801
- msgid "Changed the name of menu %OldMenuName% to %NewMenuName%."
 
 
2802
  msgstr ""
2803
 
2804
- #: defaults.php:373
2805
- msgid "User changed order of the objects in a menu"
2806
  msgstr ""
2807
 
2808
- #: defaults.php:373
2809
- msgid "Changed the order of the %ItemName% in menu %MenuName%."
 
 
2810
  msgstr ""
2811
 
2812
- #: defaults.php:374
2813
- msgid "User moved objects as a sub-item"
2814
  msgstr ""
2815
 
2816
- #: defaults.php:374
2817
- msgid "Moved %ItemName% as a sub-item of %ParentName% in menu %MenuName%."
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2818
  msgstr ""
2819
 
2820
- #: defaults.php:380
2821
- msgid "Widgets"
2822
  msgstr ""
2823
 
2824
- #: defaults.php:381
2825
- msgid "User added a new widget"
2826
  msgstr ""
2827
 
2828
- #: defaults.php:381
2829
- msgid "Added a new %WidgetName% widget in %Sidebar%."
2830
  msgstr ""
2831
 
2832
- #: defaults.php:382
2833
- msgid "User modified a widget"
2834
  msgstr ""
2835
 
2836
- #: defaults.php:382
2837
- msgid "Modified the %WidgetName% widget in %Sidebar%."
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2838
  msgstr ""
2839
 
2840
- #: defaults.php:383
2841
- msgid "User deleted widget"
2842
  msgstr ""
2843
 
2844
- #: defaults.php:383
2845
- msgid "Deleted the %WidgetName% widget from %Sidebar%."
 
2846
  msgstr ""
2847
 
2848
- #: defaults.php:384
2849
- msgid "User moved widget"
2850
  msgstr ""
2851
 
2852
- #: defaults.php:384
2853
- msgid "Moved the %WidgetName% widget from %OldSidebar% to %NewSidebar%."
 
 
2854
  msgstr ""
2855
 
2856
- #: defaults.php:385
2857
- msgid "User changed widget position"
2858
  msgstr ""
2859
 
2860
- #: defaults.php:385
2861
- msgid "Changed the position of the widget %WidgetName% in sidebar %Sidebar%."
 
 
2862
  msgstr ""
2863
 
2864
- #: defaults.php:391
2865
- msgid "Site Settings"
2866
  msgstr ""
2867
 
2868
- #: defaults.php:392
2869
  msgid ""
2870
- "Enabled/Disabled the option Discourage search engines from indexing this site"
 
2871
  msgstr ""
2872
 
2873
- #: defaults.php:392
2874
- msgid "%Status% the option Discourage search engines from indexing this site."
2875
  msgstr ""
2876
 
2877
- #: defaults.php:393
2878
- msgid "Enabled/Disabled comments on all the website"
 
 
2879
  msgstr ""
2880
 
2881
- #: defaults.php:393
2882
- msgid "%Status% comments on all the website."
2883
  msgstr ""
2884
 
2885
- #: defaults.php:394
2886
- msgid "Enabled/Disabled the option Comment author must fill out name and email"
2887
  msgstr ""
2888
 
2889
- #: defaults.php:394
2890
- msgid "%Status% the option Comment author must fill out name and email."
2891
  msgstr ""
2892
 
2893
- #: defaults.php:395
2894
- msgid ""
2895
- "Enabled/Disabled the option Users must be logged in and registered to comment"
2896
  msgstr ""
2897
 
2898
- #: defaults.php:395
2899
- msgid "%Status% the option Users must be logged in and registered to comment."
2900
  msgstr ""
2901
 
2902
- #: defaults.php:396
2903
- msgid "Enabled/Disabled the option to automatically close comments"
2904
  msgstr ""
2905
 
2906
- #: defaults.php:396
2907
- msgid "%Status% the option to automatically close comments after %Value% days."
2908
  msgstr ""
2909
 
2910
- #: defaults.php:397
2911
- msgid "Changed the value of the option Automatically close comments"
 
 
2912
  msgstr ""
2913
 
2914
- #: defaults.php:397
 
 
 
 
2915
  msgid ""
2916
- "Changed the value of the option Automatically close comments from %OldValue% "
2917
- "to %NewValue% days."
2918
  msgstr ""
2919
 
2920
- #: defaults.php:398
2921
- msgid "Enabled/Disabled the option for comments to be manually approved"
2922
  msgstr ""
2923
 
2924
- #: defaults.php:398
2925
- msgid "%Status% the option for comments to be manually approved."
2926
  msgstr ""
2927
 
2928
- #: defaults.php:399
2929
- msgid ""
2930
- "Enabled/Disabled the option for an author to have previously approved "
2931
- "comments for the comments to appear"
2932
  msgstr ""
2933
 
2934
- #: defaults.php:399
2935
- msgid ""
2936
- "%Status% the option for an author to have previously approved comments for "
2937
- "the comments to appear."
2938
  msgstr ""
2939
 
2940
- #: defaults.php:400
2941
- msgid ""
2942
- "Changed the number of links that a comment must have to be held in the queue"
2943
  msgstr ""
2944
 
2945
- #: defaults.php:400
2946
  msgid ""
2947
- "Changed the number of links from %OldValue% to %NewValue% that a comment "
2948
- "must have to be held in the queue."
2949
  msgstr ""
2950
 
2951
- #: defaults.php:401
2952
- msgid "Modified the list of keywords for comments moderation"
2953
  msgstr ""
2954
 
2955
- #: defaults.php:401
2956
- msgid "Modified the list of keywords for comments moderation."
 
 
2957
  msgstr ""
2958
 
2959
- #: defaults.php:402
2960
- msgid "Modified the list of keywords for comments blacklisting"
2961
  msgstr ""
2962
 
2963
- #: defaults.php:402
2964
- msgid "Modified the list of keywords for comments blacklisting."
2965
  msgstr ""
2966
 
2967
- #: defaults.php:403
2968
- msgid "Created a New cron job"
2969
  msgstr ""
2970
 
2971
- #: defaults.php:403
2972
  msgid ""
2973
- "A new cron job called %name% was created and is scheduled to run %schedule%."
 
2974
  msgstr ""
2975
 
2976
- #: defaults.php:404
2977
- msgid "Changed status of the cron job"
2978
  msgstr ""
2979
 
2980
- #: defaults.php:404
2981
- msgid "The cron job %name% was %status%."
 
 
2982
  msgstr ""
2983
 
2984
- #: defaults.php:405
2985
- msgid "Deleted the cron job"
2986
  msgstr ""
2987
 
2988
- #: defaults.php:405
2989
- msgid "The cron job %name% was deleted."
2990
  msgstr ""
2991
 
2992
- #: defaults.php:406
2993
- msgid "Started the cron job"
2994
  msgstr ""
2995
 
2996
- #: defaults.php:406
2997
- msgid "The cron job %name% has just started."
 
 
2998
  msgstr ""
2999
 
3000
- #: defaults.php:413
3001
- msgid "Users Profiles & Activity"
3002
  msgstr ""
3003
 
3004
- #: defaults.php:417
3005
- msgid "Other User Activity"
3006
  msgstr ""
3007
 
3008
- #: defaults.php:418
3009
- msgid "User logged in"
3010
  msgstr ""
3011
 
3012
- #: defaults.php:418
3013
- msgid "Successfully logged in."
3014
  msgstr ""
3015
 
3016
- #: defaults.php:419
3017
- msgid "User logged out"
3018
  msgstr ""
3019
 
3020
- #: defaults.php:419
3021
- msgid "Successfully logged out."
3022
  msgstr ""
3023
 
3024
- #: defaults.php:420
3025
- msgid "Login failed"
3026
  msgstr ""
3027
 
3028
- #: defaults.php:420
3029
- msgid "%Attempts% failed login(s) detected."
 
 
3030
  msgstr ""
3031
 
3032
- #: defaults.php:421
3033
- msgid "Login failed / non existing user"
3034
  msgstr ""
3035
 
3036
- #: defaults.php:421
3037
  msgid ""
3038
- "%Attempts% failed login(s) detected using non existing user. %LogFileText%"
 
3039
  msgstr ""
3040
 
3041
- #: defaults.php:422
3042
- msgid "Login blocked"
3043
  msgstr ""
3044
 
3045
- #: defaults.php:422
3046
  msgid ""
3047
- "Blocked from logging in because the same WordPress user is logged in from "
3048
- "%ClientIP%."
3049
  msgstr ""
3050
 
3051
- #: defaults.php:423
3052
- msgid "User logged in with existing session(s)"
3053
  msgstr ""
3054
 
3055
- #: defaults.php:423
3056
  msgid ""
3057
- "Successfully logged in. Another session from %IPAddress% for this user "
3058
- "already exist."
3059
  msgstr ""
3060
 
3061
- #: defaults.php:424
3062
- msgid "User logged out all other sessions with the same username"
3063
  msgstr ""
3064
 
3065
- #: defaults.php:424
3066
- msgid "Logged out all other sessions with the same username."
 
 
3067
  msgstr ""
3068
 
3069
- #: defaults.php:425
3070
- msgid "User session destroyed and logged out."
3071
  msgstr ""
3072
 
3073
- #: defaults.php:425
3074
- msgid "Logged out session %TargetSessionID% which belonged to %TargetUserName%"
 
 
3075
  msgstr ""
3076
 
3077
- #: defaults.php:426
3078
- msgid "User uploaded file from Uploads directory"
3079
  msgstr ""
3080
 
3081
- #: defaults.php:426
3082
- msgid "Uploaded the file %FileName% in %FilePath%."
 
 
3083
  msgstr ""
3084
 
3085
- #: defaults.php:427
3086
- msgid "User deleted file from Uploads directory"
3087
  msgstr ""
3088
 
3089
- #: defaults.php:427
3090
- msgid "Deleted the file %FileName% from %FilePath%."
 
 
3091
  msgstr ""
3092
 
3093
- #: defaults.php:433
3094
- msgid "User Profiles"
3095
  msgstr ""
3096
 
3097
- #: defaults.php:434
3098
- msgid "New user was created on WordPress"
 
 
 
 
 
 
3099
  msgstr ""
3100
 
3101
- #: defaults.php:434
3102
  msgid ""
3103
- "A new user %NewUserData->Username% was created with role of %NewUserData-"
3104
- ">Roles%."
3105
  msgstr ""
3106
 
3107
- #: defaults.php:435
3108
- msgid "User created another WordPress user"
3109
  msgstr ""
3110
 
3111
- #: defaults.php:435
3112
  msgid ""
3113
- "%UserChanger% created a new user %NewUserData->Username% with the role of "
3114
- "%NewUserData->Roles%."
3115
  msgstr ""
3116
 
3117
- #: defaults.php:436
3118
- msgid "The role of a user was changed by another WordPress user"
3119
  msgstr ""
3120
 
3121
- #: defaults.php:436
3122
  msgid ""
3123
- "Changed the role of the user %TargetUsername% from %OldRole% to %NewRole%"
3124
- "%multisite_text%."
3125
  msgstr ""
3126
 
3127
- #: defaults.php:437
3128
- msgid "User has changed his or her password"
3129
  msgstr ""
3130
 
3131
- #: defaults.php:437
3132
- msgid "Changed the password."
3133
  msgstr ""
3134
 
3135
- #: defaults.php:438
3136
- msgid "User changed another user's password"
3137
  msgstr ""
3138
 
3139
- #: defaults.php:438
3140
  msgid ""
3141
- "Changed the password for the user %TargetUserData->Username% with the role "
3142
- "of %TargetUserData->Roles%."
3143
  msgstr ""
3144
 
3145
- #: defaults.php:439
3146
- msgid "User changed his or her email address"
3147
  msgstr ""
3148
 
3149
- #: defaults.php:439
3150
- msgid "Changed the email address from %OldEmail% to %NewEmail%."
 
 
3151
  msgstr ""
3152
 
3153
- #: defaults.php:440
3154
- msgid "User changed another user's email address"
3155
  msgstr ""
3156
 
3157
- #: defaults.php:440
3158
  msgid ""
3159
- "Changed the email address of the user %TargetUsername% from %OldEmail% to "
3160
- "%NewEmail%."
3161
  msgstr ""
3162
 
3163
- #: defaults.php:441
3164
- msgid "User was deleted by another user"
3165
  msgstr ""
3166
 
3167
- #: defaults.php:441
3168
  msgid ""
3169
- "Deleted the user %TargetUserData->Username% with the role of %TargetUserData-"
3170
- ">Roles%."
3171
  msgstr ""
3172
 
3173
- #: defaults.php:442
3174
- msgid "User opened the profile page of another user"
3175
  msgstr ""
3176
 
3177
- #: defaults.php:442
3178
- msgid "%UserChanger% opened the profile page of the user %TargetUsername%."
 
 
3179
  msgstr ""
3180
 
3181
- #: defaults.php:443
3182
- msgid "User updated a custom field value for a user"
3183
  msgstr ""
3184
 
3185
- #: defaults.php:443
3186
  msgid ""
3187
- "Changed the value of the custom field %custom_field_name%%ReportText% for "
3188
- "the user %TargetUsername%.%ChangeText%"
3189
  msgstr ""
3190
 
3191
- #: defaults.php:444
3192
- msgid "User created a custom field value for a user"
3193
  msgstr ""
3194
 
3195
- #: defaults.php:444
3196
  msgid ""
3197
- "Created the value of the custom field %custom_field_name% with %new_value% "
3198
- "for the user %TargetUsername%."
3199
  msgstr ""
3200
 
3201
- #: defaults.php:445
3202
- msgid "User changed first name for a user"
3203
  msgstr ""
3204
 
3205
- #: defaults.php:445
3206
  msgid ""
3207
- "Changed the first name of the user %TargetUsername% from %old_firstname% to "
3208
- "%new_firstname%"
3209
  msgstr ""
3210
 
3211
- #: defaults.php:446
3212
- msgid "User changed last name for a user"
3213
  msgstr ""
3214
 
3215
- #: defaults.php:446
3216
  msgid ""
3217
- "Changed the last name of the user %TargetUsername% from %old_lastname% to "
3218
- "%new_lastname%"
3219
  msgstr ""
3220
 
3221
- #: defaults.php:447
3222
- msgid "User changed nickname for a user"
3223
  msgstr ""
3224
 
3225
- #: defaults.php:447
3226
  msgid ""
3227
- "Changed the nickname of the user %TargetUsername% from %old_nickname% to "
3228
- "%new_nickname%"
3229
  msgstr ""
3230
 
3231
- #: defaults.php:448
3232
- msgid "User changed the display name for a user"
3233
  msgstr ""
3234
 
3235
- #: defaults.php:448
3236
  msgid ""
3237
- "Changed the Display name publicly of user %TargetUsername% from "
3238
- "%old_displayname% to %new_displayname%"
3239
  msgstr ""
3240
 
3241
- #: defaults.php:455
3242
- msgid "Third Party Support"
3243
  msgstr ""
3244
 
3245
- #: defaults.php:459
3246
- msgid "BBPress Forum"
 
 
3247
  msgstr ""
3248
 
3249
- #: defaults.php:460
3250
- msgid "User created new forum"
3251
  msgstr ""
3252
 
3253
- #: defaults.php:460
3254
  msgid ""
3255
- "Created new forum %ForumName%. Forum URL is %ForumURL%. %EditorLinkForum%."
 
 
3256
  msgstr ""
3257
 
3258
- #: defaults.php:461
3259
- msgid "User changed status of a forum"
3260
  msgstr ""
3261
 
3262
- #: defaults.php:461
3263
  msgid ""
3264
- "Changed the status of the forum %ForumName% from %OldStatus% to %NewStatus%. "
3265
- "%EditorLinkForum%."
 
3266
  msgstr ""
3267
 
3268
- #: defaults.php:462
3269
- msgid "User changed visibility of a forum"
3270
  msgstr ""
3271
 
3272
- #: defaults.php:462
3273
  msgid ""
3274
- "Changed the visibility of the forum %ForumName% from %OldVisibility% to "
3275
- "%NewVisibility%. %EditorLinkForum%."
 
3276
  msgstr ""
3277
 
3278
- #: defaults.php:463
3279
- msgid "User changed the URL of a forum"
3280
  msgstr ""
3281
 
3282
- #: defaults.php:463
3283
  msgid ""
3284
- "Changed the URL of the forum %ForumName% from %OldUrl% to %NewUrl%. "
3285
- "%EditorLinkForum%."
 
3286
  msgstr ""
3287
 
3288
- #: defaults.php:464
3289
- msgid "User changed order of a forum"
3290
  msgstr ""
3291
 
3292
- #: defaults.php:464
3293
  msgid ""
3294
- "Changed the order of the forum %ForumName% from %OldOrder% to %NewOrder%. "
3295
- "%EditorLinkForum%."
 
3296
  msgstr ""
3297
 
3298
- #: defaults.php:465
3299
- msgid "User moved forum to trash"
3300
  msgstr ""
3301
 
3302
- #: defaults.php:465
3303
- msgid "Moved the forum %ForumName% to trash."
 
 
 
3304
  msgstr ""
3305
 
3306
- #: defaults.php:466
3307
- msgid "User permanently deleted forum"
3308
  msgstr ""
3309
 
3310
- #: defaults.php:466
3311
- msgid "Permanently deleted the forum %ForumName%."
 
 
3312
  msgstr ""
3313
 
3314
- #: defaults.php:467
3315
- msgid "User restored forum from trash"
3316
  msgstr ""
3317
 
3318
- #: defaults.php:467
3319
- msgid "Restored the forum %ForumName% from trash. %EditorLinkForum%."
 
 
 
3320
  msgstr ""
3321
 
3322
- #: defaults.php:468
3323
- msgid "User changed the parent of a forum"
3324
  msgstr ""
3325
 
3326
- #: defaults.php:468
3327
  msgid ""
3328
- "Changed the parent of the forum %ForumName% from %OldParent% to %NewParent%. "
3329
- "%EditorLinkForum%."
3330
  msgstr ""
3331
 
3332
- #: defaults.php:469
3333
- msgid "User changed forum's role"
3334
  msgstr ""
3335
 
3336
- #: defaults.php:469
3337
- msgid "Changed the forum's auto role from %OldRole% to %NewRole%."
 
 
3338
  msgstr ""
3339
 
3340
- #: defaults.php:470
3341
- msgid "User changed option of a forum"
3342
  msgstr ""
3343
 
3344
- #: defaults.php:470
3345
- msgid "%Status% the option for anonymous posting on forum."
 
 
 
3346
  msgstr ""
3347
 
3348
- #: defaults.php:471
3349
- msgid "User changed type of a forum"
3350
  msgstr ""
3351
 
3352
- #: defaults.php:471
3353
  msgid ""
3354
- "Changed the type of the forum %ForumName% from %OldType% to %NewType%. "
3355
- "%EditorLinkForum%."
 
3356
  msgstr ""
3357
 
3358
- #: defaults.php:472
3359
- msgid "User changed time to disallow post editing"
3360
  msgstr ""
3361
 
3362
- #: defaults.php:472
3363
  msgid ""
3364
- "Changed the time to disallow post editing from %OldTime% to %NewTime% "
3365
- "minutes in the forums."
 
3366
  msgstr ""
3367
 
3368
- #: defaults.php:473
3369
- msgid "User changed the forum setting posting throttle time"
3370
  msgstr ""
3371
 
3372
- #: defaults.php:473
3373
  msgid ""
3374
- "Changed the posting throttle time from %OldTime% to %NewTime% seconds in the "
3375
- "forums."
 
3376
  msgstr ""
3377
 
3378
- #: defaults.php:474
3379
- msgid "User created new topic"
3380
  msgstr ""
3381
 
3382
- #: defaults.php:474
3383
- msgid "Created a new topic %TopicName%. %EditorLinkTopic%."
 
 
 
3384
  msgstr ""
3385
 
3386
- #: defaults.php:475
3387
- msgid "User changed status of a topic"
3388
  msgstr ""
3389
 
3390
- #: defaults.php:475
3391
- msgid ""
3392
- "Changed the status of the topic %TopicName% from %OldStatus% to %NewStatus%. "
3393
- "%EditorLinkTopic%."
3394
  msgstr ""
3395
 
3396
- #: defaults.php:476
3397
- msgid "User changed type of a topic"
3398
  msgstr ""
3399
 
3400
- #: defaults.php:476
3401
- msgid ""
3402
- "Changed the type of the topic %TopicName% from %OldType% to %NewType%. "
3403
- "%EditorLinkTopic%."
3404
  msgstr ""
3405
 
3406
- #: defaults.php:477
3407
- msgid "User changed URL of a topic"
3408
  msgstr ""
3409
 
3410
- #: defaults.php:477
3411
- msgid "Changed the URL of the topic %TopicName% from %OldUrl% to %NewUrl%."
 
3412
  msgstr ""
3413
 
3414
- #: defaults.php:478
3415
- msgid "User changed the forum of a topic"
3416
  msgstr ""
3417
 
3418
- #: defaults.php:478
3419
- msgid ""
3420
- "Changed the forum of the topic %TopicName% from %OldForum% to %NewForum%. "
3421
- "%EditorLinkTopic%."
3422
  msgstr ""
3423
 
3424
- #: defaults.php:479
3425
- msgid "User moved topic to trash"
 
 
 
 
 
3426
  msgstr ""
3427
 
3428
- #: defaults.php:479
3429
- msgid "Moved the topic %TopicName% to trash."
3430
  msgstr ""
3431
 
3432
- #: defaults.php:480
3433
- msgid "User permanently deleted topic"
3434
  msgstr ""
3435
 
3436
- #: defaults.php:480
3437
- msgid "Permanently deleted the topic %TopicName%."
3438
  msgstr ""
3439
 
3440
- #: defaults.php:481
3441
- msgid "User restored topic from trash"
3442
  msgstr ""
3443
 
3444
- #: defaults.php:481
3445
- msgid "Restored the topic %TopicName% from trash. %EditorLinkTopic%."
3446
  msgstr ""
3447
 
3448
- #: defaults.php:482
3449
- msgid "User changed visibility of a topic"
3450
  msgstr ""
3451
 
3452
- #: defaults.php:482
3453
- msgid ""
3454
- "Changed the visibility of the topic %TopicName% from %OldVisibility% to "
3455
- "%NewVisibility%. %EditorLinkTopic%."
3456
  msgstr ""
3457
 
3458
- #: defaults.php:488
3459
- msgid "WooCommerce"
3460
  msgstr ""
3461
 
3462
- #: defaults.php:489
3463
- msgid "User created a new product"
3464
  msgstr ""
3465
 
3466
- #: defaults.php:489
3467
- msgid ""
3468
- "Created a new product called %ProductTitle% and saved it as draft. View the "
3469
- "product: %EditorLinkProduct%."
3470
  msgstr ""
3471
 
3472
- #: defaults.php:490
3473
- msgid "User published a product"
3474
  msgstr ""
3475
 
3476
- #: defaults.php:490
3477
- msgid ""
3478
- "Published a product called %ProductTitle%. Product URL is %ProductUrl%. View "
3479
- "the product: %EditorLinkProduct%."
3480
  msgstr ""
3481
 
3482
- #: defaults.php:491
3483
- msgid "User created a new product category"
3484
  msgstr ""
3485
 
3486
- #: defaults.php:491
3487
- msgid ""
3488
- "Created a new product category called %CategoryName% in WooCommerce. Product "
3489
- "category slug is %Slug%."
3490
  msgstr ""
3491
 
3492
- #: defaults.php:492
3493
- msgid "User changed the category of a product"
3494
  msgstr ""
3495
 
3496
- #: defaults.php:492
3497
- msgid ""
3498
- "Changed the category of the product %ProductTitle% from %OldCategories% to "
3499
- "%NewCategories%. View the product: %EditorLinkProduct%."
3500
  msgstr ""
3501
 
3502
- #: defaults.php:493
3503
- msgid "User modified the short description of a product"
3504
  msgstr ""
3505
 
3506
- #: defaults.php:493
3507
- msgid ""
3508
- "Modified the short description of the product %ProductTitle%.%ChangeText% "
3509
- "View the product: %EditorLinkProduct%."
3510
  msgstr ""
3511
 
3512
- #: defaults.php:494
3513
- msgid "User modified the text of a product"
3514
  msgstr ""
3515
 
3516
- #: defaults.php:494
3517
- msgid ""
3518
- "Modified the text of the product %ProductTitle%. View the product: "
3519
- "%EditorLinkProduct%."
3520
  msgstr ""
3521
 
3522
- #: defaults.php:495
3523
- msgid "User changed the URL of a product"
3524
  msgstr ""
3525
 
3526
- #: defaults.php:495
3527
- msgid ""
3528
- "Changed the URL of the product %ProductTitle%%ReportText%.%ChangeText% View "
3529
- "the product: %EditorLinkProduct%."
3530
  msgstr ""
3531
 
3532
- #: defaults.php:496
3533
- msgid "User changed the Product Data of a product"
3534
  msgstr ""
3535
 
3536
- #: defaults.php:496
3537
  msgid ""
3538
- "Changed the Product Data of the product %ProductTitle%. View the product: "
3539
- "%EditorLinkProduct%."
3540
  msgstr ""
3541
 
3542
- #: defaults.php:497
3543
- msgid "User changed the date of a product"
3544
  msgstr ""
3545
 
3546
- #: defaults.php:497
3547
  msgid ""
3548
- "Changed the date of the product %ProductTitle% from %OldDate% to %NewDate%. "
3549
- "View the product: %EditorLinkProduct%."
3550
  msgstr ""
3551
 
3552
- #: defaults.php:498
3553
- msgid "User changed the visibility of a product"
3554
  msgstr ""
3555
 
3556
- #: defaults.php:498
3557
  msgid ""
3558
- "Changed the visibility of the product %ProductTitle% from %OldVisibility% to "
3559
- "%NewVisibility%. View the product: %EditorLinkProduct%."
3560
  msgstr ""
3561
 
3562
- #: defaults.php:499
3563
- msgid "User modified the published product"
3564
  msgstr ""
3565
 
3566
- #: defaults.php:499
3567
  msgid ""
3568
- "Modified the published product %ProductTitle%. Product URL is %ProductUrl%. "
3569
- "View the product: %EditorLinkProduct%."
3570
  msgstr ""
3571
 
3572
- #: defaults.php:500
3573
- msgid "User modified the draft product"
3574
  msgstr ""
3575
 
3576
- #: defaults.php:500
3577
  msgid ""
3578
- "Modified the draft product %ProductTitle%. View the product: "
3579
- "%EditorLinkProduct%."
3580
  msgstr ""
3581
 
3582
- #: defaults.php:501
3583
- msgid "User moved a product to trash"
3584
  msgstr ""
3585
 
3586
- #: defaults.php:501
3587
  msgid ""
3588
- "Moved the product %ProductTitle% to trash. Product URL was %ProductUrl%."
 
3589
  msgstr ""
3590
 
3591
- #: defaults.php:502
3592
- msgid "User permanently deleted a product"
3593
  msgstr ""
3594
 
3595
- #: defaults.php:502
3596
- msgid "Permanently deleted the product %ProductTitle%."
 
 
3597
  msgstr ""
3598
 
3599
- #: defaults.php:503
3600
- msgid "User restored a product from the trash"
3601
  msgstr ""
3602
 
3603
- #: defaults.php:503
3604
  msgid ""
3605
- "Product %ProductTitle% has been restored from trash. View product: "
3606
- "%EditorLinkProduct%."
3607
  msgstr ""
3608
 
3609
- #: defaults.php:504
3610
- msgid "User changed status of a product"
3611
  msgstr ""
3612
 
3613
- #: defaults.php:504
3614
  msgid ""
3615
- "Changed the status of the product %ProductTitle% from %OldStatus% to "
3616
- "%NewStatus%. View the product: %EditorLinkProduct%."
3617
  msgstr ""
3618
 
3619
- #: defaults.php:505
3620
- msgid "User changed type of a price"
3621
  msgstr ""
3622
 
3623
- #: defaults.php:505
3624
  msgid ""
3625
- "Changed the %PriceType% of the product %ProductTitle% from %OldPrice% to "
3626
- "%NewPrice%. View the product: %EditorLinkProduct%."
3627
  msgstr ""
3628
 
3629
- #: defaults.php:506
3630
- msgid "User changed the SKU of a product"
3631
  msgstr ""
3632
 
3633
- #: defaults.php:506
3634
  msgid ""
3635
- "Changed the SKU of the product %ProductTitle% from %OldSku% to %NewSku%. "
3636
- "View the product: %EditorLinkProduct%."
3637
  msgstr ""
3638
 
3639
- #: defaults.php:507
3640
- msgid "User changed the stock status of a product"
3641
  msgstr ""
3642
 
3643
- #: defaults.php:507
3644
  msgid ""
3645
- "Changed the stock status of the product %ProductTitle% from %OldStatus% to "
3646
- "%NewStatus%. View the product: %EditorLinkProduct%."
3647
  msgstr ""
3648
 
3649
- #: defaults.php:508
3650
- msgid "User changed the stock quantity"
3651
  msgstr ""
3652
 
3653
- #: defaults.php:508
3654
- msgid ""
3655
- "Changed the stock quantity of the product %ProductTitle% from %OldValue% to "
3656
- "%NewValue%. View the product: %EditorLinkProduct%"
3657
  msgstr ""
3658
 
3659
- #: defaults.php:509
3660
- msgid "User set a product type"
3661
  msgstr ""
3662
 
3663
- #: defaults.php:509
3664
  msgid ""
3665
- "Set the product %ProductTitle% as %Type%. View the product: "
3666
- "%EditorLinkProduct%."
3667
  msgstr ""
3668
 
3669
- #: defaults.php:510
3670
- msgid "User changed the weight of a product"
3671
  msgstr ""
3672
 
3673
- #: defaults.php:510
3674
  msgid ""
3675
- "Changed the weight of the product %ProductTitle% from %OldWeight% to "
3676
- "%NewWeight%. View the product: %EditorLinkProduct%."
3677
  msgstr ""
3678
 
3679
- #: defaults.php:511
3680
- msgid "User changed the dimensions of a product"
3681
  msgstr ""
3682
 
3683
- #: defaults.php:511
3684
  msgid ""
3685
- "Changed the %DimensionType% dimensions of the product %ProductTitle% from "
3686
- "%OldDimension% to %NewDimension%. View the product: %EditorLinkProduct%."
3687
  msgstr ""
3688
 
3689
- #: defaults.php:512
3690
- msgid "User added the Downloadable File to a product"
3691
  msgstr ""
3692
 
3693
- #: defaults.php:512
3694
  msgid ""
3695
- "Added the Downloadable File %FileName% with File URL %FileUrl% to the "
3696
- "product %ProductTitle%. View the product: %EditorLinkProduct%."
3697
  msgstr ""
3698
 
3699
- #: defaults.php:513
3700
- msgid "User Removed the Downloadable File from a product"
3701
  msgstr ""
3702
 
3703
- #: defaults.php:513
3704
  msgid ""
3705
- "Removed the Downloadable File %FileName% with File URL %FileUrl% from the "
3706
- "product %ProductTitle%. View the product: %EditorLinkProduct%."
3707
  msgstr ""
3708
 
3709
- #: defaults.php:514
3710
- msgid "User changed the name of a Downloadable File in a product"
3711
  msgstr ""
3712
 
3713
- #: defaults.php:514
3714
  msgid ""
3715
- "Changed the name of a Downloadable File from %OldName% to %NewName% in "
3716
- "product %ProductTitle%. View the product: %EditorLinkProduct%."
3717
  msgstr ""
3718
 
3719
- #: defaults.php:515
3720
- msgid "User changed the URL of the Downloadable File in a product"
3721
  msgstr ""
3722
 
3723
- #: defaults.php:515
3724
  msgid ""
3725
- "Changed the URL of the Downloadable File %FileName% from %OldUrl% to %NewUrl"
3726
- "% in product %ProductTitle%. View the product: %EditorLinkProduct%."
3727
  msgstr ""
3728
 
3729
- #: defaults.php:516
3730
- msgid "User changed the Weight Unit"
3731
  msgstr ""
3732
 
3733
- #: defaults.php:516
3734
- msgid "Changed the Weight Unit from %OldUnit% to %NewUnit% in WooCommerce."
3735
  msgstr ""
3736
 
3737
- #: defaults.php:517
3738
- msgid "User changed the Dimensions Unit"
3739
  msgstr ""
3740
 
3741
- #: defaults.php:517
3742
- msgid "Changed the Dimensions Unit from %OldUnit% to %NewUnit% in WooCommerce."
 
3743
  msgstr ""
3744
 
3745
- #: defaults.php:518
3746
- msgid "User changed the Base Location"
3747
  msgstr ""
3748
 
3749
- #: defaults.php:518
3750
  msgid ""
3751
- "Changed the Base Location from %OldLocation% to %NewLocation% in WooCommerce."
 
3752
  msgstr ""
3753
 
3754
- #: defaults.php:519
3755
- msgid "User Enabled/Disabled taxes"
3756
  msgstr ""
3757
 
3758
- #: defaults.php:519
3759
- msgid "%Status% taxes in the WooCommerce store."
3760
  msgstr ""
3761
 
3762
- #: defaults.php:520
3763
- msgid "User changed the currency"
3764
  msgstr ""
3765
 
3766
- #: defaults.php:520
3767
  msgid ""
3768
- "Changed the currency from %OldCurrency% to %NewCurrency% in WooCommerce."
3769
- msgstr ""
3770
-
3771
- #: defaults.php:521
3772
- msgid "User Enabled/Disabled the use of coupons during checkout"
3773
  msgstr ""
3774
 
3775
- #: defaults.php:521
3776
- msgid "%Status% the use of coupons during checkout in WooCommerce."
3777
  msgstr ""
3778
 
3779
- #: defaults.php:522
3780
- msgid "User Enabled/Disabled guest checkout"
3781
  msgstr ""
3782
 
3783
- #: defaults.php:522
3784
- msgid "%Status% guest checkout in WooCommerce."
3785
  msgstr ""
3786
 
3787
- #: defaults.php:523
3788
- msgid "User Enabled/Disabled cash on delivery"
3789
  msgstr ""
3790
 
3791
- #: defaults.php:523
3792
- msgid "%Status% the option Enable cash on delivery in WooCommerce."
3793
  msgstr ""
3794
 
3795
- #: defaults.php:525
3796
- msgid "Yoast SEO"
3797
  msgstr ""
3798
 
3799
- #: defaults.php:526
3800
  msgid "User changed title of a SEO post"
3801
  msgstr ""
3802
 
3803
- #: defaults.php:526
3804
  msgid ""
3805
  "Changed the SEO title of the %PostStatus% %PostType%%ReportText%.%ChangeText"
3806
  "% %EditorLinkPost%."
3807
  msgstr ""
3808
 
3809
- #: defaults.php:527
3810
  msgid "User changed the meta description of a SEO post"
3811
  msgstr ""
3812
 
3813
- #: defaults.php:527
3814
  msgid ""
3815
  "Changed the Meta description of the %PostStatus% %PostType% titled %PostTitle"
3816
  "%%ReportText%.%ChangeText% %EditorLinkPost%."
3817
  msgstr ""
3818
 
3819
- #: defaults.php:528
3820
  msgid ""
3821
  "User changed setting to allow search engines to show post in search results "
3822
  "of a SEO post"
3823
  msgstr ""
3824
 
3825
- #: defaults.php:528
3826
  msgid ""
3827
  "Changed the setting to allow search engines to show post in search results "
3828
  "from %OldStatus% to %NewStatus% in the %PostStatus% %PostType% titled "
3829
  "%PostTitle%. %EditorLinkPost%."
3830
  msgstr ""
3831
 
3832
- #: defaults.php:529
3833
  msgid ""
3834
  "User Enabled/Disabled the option for search engine to follow links of a SEO "
3835
  "post"
3836
  msgstr ""
3837
 
3838
- #: defaults.php:529
3839
  msgid ""
3840
  "%NewStatus% the option for search engine to follow links in the %PostType% "
3841
  "titled %PostTitle%. %EditorLinkPost%."
3842
  msgstr ""
3843
 
3844
- #: defaults.php:530
3845
  msgid "User set the meta robots advanced setting of a SEO post"
3846
  msgstr ""
3847
 
3848
- #: defaults.php:530
3849
  msgid ""
3850
  "Set the Meta Robots Advanced setting to %NewStatus% in the %PostStatus% "
3851
  "%PostType% titled %PostTitle%. %EditorLinkPost%."
3852
  msgstr ""
3853
 
3854
- #: defaults.php:531
3855
  msgid "User changed the canonical URL of a SEO post"
3856
  msgstr ""
3857
 
3858
- #: defaults.php:531
3859
  msgid ""
3860
  "Changed the Canonical URL of the %PostStatus% %PostType% titled %PostTitle%"
3861
  "%ReportText%.%ChangeText% %EditorLinkPost%."
3862
  msgstr ""
3863
 
3864
- #: defaults.php:532
3865
  msgid "User changed the focus keyword of a SEO post"
3866
  msgstr ""
3867
 
3868
- #: defaults.php:532
3869
  msgid ""
3870
  "Changed the focus keyword of the %PostStatus% %PostType% titled %PostTitle% "
3871
  "from %old_keywords% to %new_keywords%. %EditorLinkPost%."
3872
  msgstr ""
3873
 
3874
- #: defaults.php:533
3875
  msgid "User Enabled/Disabled the option Cornerston Content of a SEO post"
3876
  msgstr ""
3877
 
3878
- #: defaults.php:533
3879
  msgid ""
3880
  "%Status% the option Cornerston Content on the %PostStatus% %PostType% titled "
3881
  "%PostTitle%. %EditorLinkPost%."
3882
  msgstr ""
3883
 
3884
- #: defaults.php:534
3885
  msgid "User changed the Title Separator setting"
3886
  msgstr ""
3887
 
3888
- #: defaults.php:534
3889
  msgid ""
3890
  "Changed the Title Separator from %old% to %new% in the Yoast SEO plugin "
3891
  "settings."
3892
  msgstr ""
3893
 
3894
- #: defaults.php:535
3895
  msgid "User changed the Homepage Title setting"
3896
  msgstr ""
3897
 
3898
- #: defaults.php:535
3899
  msgid ""
3900
  "Changed the Homepage Title%ReportText% in the Yoast SEO plugin settings."
3901
  "%ChangeText%"
3902
  msgstr ""
3903
 
3904
- #: defaults.php:536
3905
  msgid "User changed the Homepage Meta description setting"
3906
  msgstr ""
3907
 
3908
- #: defaults.php:536
3909
  msgid ""
3910
  "Changed the Homepage Meta description%ReportText% in the Yoast SEO plugin "
3911
  "settings.%ChangeText%"
3912
  msgstr ""
3913
 
3914
- #: defaults.php:537
3915
  msgid "User changed the Company or Person setting"
3916
  msgstr ""
3917
 
3918
- #: defaults.php:537
3919
  msgid ""
3920
  "Changed the Company or Person setting from %old% to %new% in the YOAST SEO "
3921
  "plugin settings."
3922
  msgstr ""
3923
 
3924
- #: defaults.php:538
3925
  msgid ""
3926
  "User Enabled/Disabled the option Show Posts/Pages in Search Results in the "
3927
  "Yoast SEO plugin settings"
3928
  msgstr ""
3929
 
3930
- #: defaults.php:538
3931
  msgid ""
3932
  "%Status% the option Show %SEOPostType% in Search Results in the Yoast SEO "
3933
  "plugin settings."
3934
  msgstr ""
3935
 
3936
- #: defaults.php:539
3937
  msgid ""
3938
  "User changed the Posts/Pages title template in the Yoast SEO plugin settings"
3939
  msgstr ""
3940
 
3941
- #: defaults.php:539
3942
  msgid ""
3943
  "Changed the %SEOPostType% title template from %old% to %new% in the Yoast "
3944
  "SEO plugin settings."
3945
  msgstr ""
3946
 
3947
- #: defaults.php:540
3948
  msgid "User Enabled/Disabled SEO analysis in the Yoast SEO plugin settings"
3949
  msgstr ""
3950
 
3951
- #: defaults.php:540
3952
  msgid "%Status% SEO analysis in the Yoast SEO plugin settings."
3953
  msgstr ""
3954
 
3955
- #: defaults.php:541
3956
  msgid ""
3957
  "User Enabled/Disabled readability analysis in the Yoast SEO plugin settings"
3958
  msgstr ""
3959
 
3960
- #: defaults.php:541
3961
  msgid "%Status% Readability analysis in the Yoast SEO plugin settings."
3962
  msgstr ""
3963
 
3964
- #: defaults.php:542
3965
  msgid ""
3966
  "User Enabled/Disabled cornerstone content in the Yoast SEO plugin settings"
3967
  msgstr ""
3968
 
3969
- #: defaults.php:542
3970
  msgid "%Status% Cornerstone content in the Yoast SEO plugin settings."
3971
  msgstr ""
3972
 
3973
- #: defaults.php:543
3974
  msgid ""
3975
  "User Enabled/Disabled the text link counter in the Yoast SEO plugin settings"
3976
  msgstr ""
3977
 
3978
- #: defaults.php:543
3979
  msgid "%Status% the Text link counter in the Yoast SEO plugin settings."
3980
  msgstr ""
3981
 
3982
- #: defaults.php:544
3983
  msgid "User Enabled/Disabled XML sitemaps in the Yoast SEO plugin settings"
3984
  msgstr ""
3985
 
3986
- #: defaults.php:544
3987
  msgid "%Status% XML Sitemaps in the Yoast SEO plugin settings."
3988
  msgstr ""
3989
 
3990
- #: defaults.php:545
3991
  msgid "User Enabled/Disabled ryte integration in the Yoast SEO plugin settings"
3992
  msgstr ""
3993
 
3994
- #: defaults.php:545
3995
  msgid "%Status% Ryte Integration in the Yoast SEO plugin settings."
3996
  msgstr ""
3997
 
3998
- #: defaults.php:546
3999
  msgid ""
4000
  "User Enabled/Disabled the admin bar menu in the Yoast SEO plugin settings"
4001
  msgstr ""
4002
 
4003
- #: defaults.php:546
4004
  msgid "%Status% the Admin bar menu in the Yoast SEO plugin settings."
4005
  msgstr ""
4006
 
4007
- #: defaults.php:547
4008
  msgid ""
4009
  "User changed the Posts/Pages meta description template in the Yoast SEO "
4010
  "plugin settings"
4011
  msgstr ""
4012
 
4013
- #: defaults.php:547
4014
  msgid ""
4015
  "Changed the %SEOPostType% meta description template from %old% to %new% in "
4016
  "the Yoast SEO plugin settings."
4017
  msgstr ""
4018
 
4019
- #: defaults.php:548
4020
  msgid ""
4021
  "User set the option Date in Snippet Preview for Posts/Pages in the Yoast SEO "
4022
  "plugin settings"
4023
  msgstr ""
4024
 
4025
- #: defaults.php:548
4026
  msgid ""
4027
  "%Status% the option Date in Snippet Preview for %SEOPostType% in the Yoast "
4028
  "SEO plugin settings."
4029
  msgstr ""
4030
 
4031
- #: defaults.php:549
4032
  msgid ""
4033
  "User set the option Yoast SEO Meta Box for Posts/Pages in the Yoast SEO "
4034
  "plugin settings"
4035
  msgstr ""
4036
 
4037
- #: defaults.php:549
4038
  msgid ""
4039
  "%Status% the option Yoast SEO Meta Box for %SEOPostType% in the Yoast SEO "
4040
  "plugin settings."
4041
  msgstr ""
4042
 
4043
- #: defaults.php:550
4044
  msgid ""
4045
  "User Enabled/Disabled the advanced settings for authors in the Yoast SEO "
4046
  "plugin settings"
4047
  msgstr ""
4048
 
4049
- #: defaults.php:550
4050
  msgid "%Status% the advanced settings for authors in the Yoast SEO settings."
4051
  msgstr ""
4052
 
4053
- #: wp-security-audit-log.php:304 wp-security-audit-log.php:330
 
4054
  #, php-format
4055
  msgid "Hey %1$s"
4056
  msgstr ""
4057
 
4058
- #: wp-security-audit-log.php:305
4059
  msgid ""
4060
  "Never miss an important update! Opt-in to our security and feature updates "
4061
  "notifications, and non-sensitive diagnostic tracking with freemius.com."
4062
  msgstr ""
4063
 
4064
- #: wp-security-audit-log.php:306 wp-security-audit-log.php:332
4065
  msgid "Note: "
4066
  msgstr ""
4067
 
4068
- #: wp-security-audit-log.php:307 wp-security-audit-log.php:333
4069
  msgid "NO AUDIT LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS."
4070
  msgstr ""
4071
 
4072
- #: wp-security-audit-log.php:331
 
4073
  #, php-format
4074
  msgid ""
4075
  "Please help us improve %2$s! If you opt-in, some non-sensitive data about "
@@ -4077,35 +6111,111 @@ msgid ""
4077
  "use. If you skip this, that's okay! %2$s will still work just fine."
4078
  msgstr ""
4079
 
4080
- #: wp-security-audit-log.php:382
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4081
  msgid ""
4082
  "Error: You do not have sufficient permissions to disable this custom field."
4083
  msgstr ""
4084
 
4085
- #: wp-security-audit-log.php:418
4086
  msgid "Error: You do not have sufficient permissions to disable this alert."
4087
  msgstr ""
4088
 
4089
- #: wp-security-audit-log.php:530
4090
  #, php-format
4091
  msgid ""
4092
  "You are using a version of PHP that is older than %s, which is no longer "
4093
  "supported."
4094
  msgstr ""
4095
 
4096
- #: wp-security-audit-log.php:531
4097
  msgid ""
4098
  "Contact us on <a href=\"mailto:plugins@wpwhitesecurity.com"
4099
  "\">plugins@wpwhitesecurity.com</a> to help you switch the version of PHP you "
4100
  "are using."
4101
  msgstr ""
4102
 
4103
- #. Plugin Name of the plugin/theme
4104
- msgid "WP Security Audit Log"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4105
  msgstr ""
4106
 
4107
  #. Plugin URI of the plugin/theme
4108
- #. Author URI of the plugin/theme
4109
  msgid "http://www.wpsecurityauditlog.com/"
4110
  msgstr ""
4111
 
@@ -4122,3 +6232,7 @@ msgstr ""
4122
  #. Author of the plugin/theme
4123
  msgid "WP White Security"
4124
  msgstr ""
 
 
 
 
3
  msgstr ""
4
  "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
5
  "Project-Id-Version: WP Security Audit Log\n"
6
+ "POT-Creation-Date: 2019-02-26 11:17+0100\n"
7
+ "PO-Revision-Date: 2019-02-26 11:17+0100\n"
8
  "Last-Translator: \n"
9
  "Language-Team: \n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
+ "X-Generator: Poedit 2.2.1\n"
14
  "X-Poedit-Basepath: ..\n"
15
  "X-Poedit-Flags-xgettext: --add-comments=translators:\n"
16
  "X-Poedit-WPHeader: wp-security-audit-log.php\n"
21
  "X-Poedit-SearchPath-0: .\n"
22
  "X-Poedit-SearchPathExcluded-0: *.js\n"
23
 
24
+ #. translators: Event ID
25
+ #: classes/AlertManager.php:322
26
+ #, php-format
27
+ msgid "Event with code %d has not be registered."
28
+ msgstr ""
29
+
30
+ #: classes/AlertManager.php:377
31
+ #, php-format
32
+ msgid "Event %s already registered with WP Security Audit Log."
33
+ msgstr ""
34
+
35
+ #: classes/AlertManager.php:412
36
+ msgid ""
37
+ "You have custom events that are using the same ID or IDs which are already "
38
+ "registered in the plugin, so they have been disabled."
39
+ msgstr ""
40
+
41
+ #: classes/AlertManager.php:415
42
+ #, php-format
43
+ msgid "%4$s to help you solve this issue."
44
+ msgstr ""
45
+
46
+ #: classes/AlertManager.php:417
47
+ msgid "ERROR:"
48
+ msgstr ""
49
+
50
+ #: classes/AlertManager.php:419
51
+ msgid "Contact us"
52
+ msgstr ""
53
+
54
+ #: classes/AuditLogListView.php:120
55
  msgid "No events so far."
56
  msgstr ""
57
 
58
+ #: classes/AuditLogListView.php:171
59
  msgid "Show "
60
  msgstr ""
61
 
62
+ #: classes/AuditLogListView.php:179
63
  msgid " Items"
64
  msgstr ""
65
 
66
+ #: classes/AuditLogListView.php:186
67
+ msgid "— End of Activity Log —"
68
+ msgstr ""
69
+
70
+ #: classes/AuditLogListView.php:206 classes/Views/AuditLog.php:462
71
+ #: classes/Views/AuditLog.php:485
72
  msgid "All Sites"
73
  msgstr ""
74
 
75
+ #: classes/AuditLogListView.php:234
76
  msgid "Live Database"
77
  msgstr ""
78
 
79
+ #: classes/AuditLogListView.php:237
80
  msgid "Archive Database"
81
  msgstr ""
82
 
83
+ #: classes/AuditLogListView.php:294 classes/Views/Settings.php:1080
84
+ #: classes/WidgetManager.php:82
85
  msgid "User"
86
  msgstr ""
87
 
88
+ #: classes/AuditLogListView.php:296
89
  msgid "Username"
90
  msgstr ""
91
 
92
+ #: classes/AuditLogListView.php:301 classes/AuditLogListView.php:327
93
+ #: classes/Views/Settings.php:1074
94
+ msgid "Event ID"
95
  msgstr ""
96
 
97
+ #: classes/AuditLogListView.php:302 classes/AuditLogListView.php:330
98
+ #: classes/Views/Settings.php:1076 classes/Views/ToggleAlerts.php:318
99
  msgid "Severity"
100
  msgstr ""
101
 
102
+ #: classes/AuditLogListView.php:303 classes/AuditLogListView.php:333
103
  msgid "Date"
104
  msgstr ""
105
 
106
+ #: classes/AuditLogListView.php:305 classes/AuditLogListView.php:339
107
  msgid "Source IP"
108
  msgstr ""
109
 
110
+ #: classes/AuditLogListView.php:310 classes/AuditLogListView.php:342
111
  msgid "Site"
112
  msgstr ""
113
 
114
+ #: classes/AuditLogListView.php:313 classes/AuditLogListView.php:345
115
  msgid "Message"
116
  msgstr ""
117
 
118
+ #: classes/AuditLogListView.php:396
119
  msgid "Click to toggle."
120
  msgstr ""
121
 
122
+ #: classes/AuditLogListView.php:415
123
+ msgid "Disable this type of events."
124
  msgstr ""
125
 
126
+ #: classes/AuditLogListView.php:423
127
  msgid "Unknown error code."
128
  msgstr ""
129
 
130
+ #: classes/AuditLogListView.php:427 classes/Views/ToggleAlerts.php:490
131
+ msgid "Critical"
132
+ msgstr ""
133
+
134
+ #: classes/AuditLogListView.php:429 classes/Views/ToggleAlerts.php:492
135
+ msgid "Warning"
136
+ msgstr ""
137
+
138
+ #: classes/AuditLogListView.php:431 classes/Views/ToggleAlerts.php:494
139
+ #: classes/Views/ToggleAlerts.php:496
140
+ msgid "Notification"
141
  msgstr ""
142
 
143
+ #: classes/AuditLogListView.php:441 classes/AuditLogListView.php:482
144
  msgid "Unknown"
145
  msgstr ""
146
 
147
+ #: classes/AuditLogListView.php:467
148
+ msgid "Show me all activity by this User"
149
+ msgstr ""
150
+
151
+ #: classes/AuditLogListView.php:486 classes/Views/Licensing.php:113
152
  #: classes/Views/Licensing.php:153
153
  msgid "Plugin"
154
  msgstr ""
155
 
156
+ #: classes/AuditLogListView.php:490 defaults.php:356
157
  msgid "Plugins"
158
  msgstr ""
159
 
160
+ #: classes/AuditLogListView.php:494
161
  msgid "Website Visitor"
162
  msgstr ""
163
 
164
+ #: classes/AuditLogListView.php:498 classes/Views/ToggleAlerts.php:420
165
+ #: classes/Views/ToggleAlerts.php:454 defaults.php:389
166
  msgid "System"
167
  msgstr ""
168
 
169
+ #: classes/AuditLogListView.php:530 classes/AuditLogListView.php:543
170
  msgid "Show me all activity originating from this IP Address"
171
  msgstr ""
172
 
173
+ #: classes/AuditLogListView.php:572
174
  msgid "View all details of this change"
175
  msgstr ""
176
 
177
+ #: classes/AuditLogListView.php:573 classes/AuditLogListView.php:723
178
+ #: classes/Settings.php:1659
179
  msgid "Alert Data Inspector"
180
  msgstr ""
181
 
182
+ #: classes/AuditLogListView.php:675 classes/Settings.php:1603
183
+ msgid "Download the log file"
184
+ msgstr ""
185
+
186
+ #: classes/AuditLogListView.php:695 classes/Settings.php:1623
187
  msgid "Download the log file."
188
  msgstr ""
189
 
190
+ #: classes/AuditLogListView.php:703 classes/Settings.php:1631
191
+ #: classes/Settings.php:1883
192
  msgid "published"
193
  msgstr ""
194
 
195
+ #. translators: Mailto link for support.
196
+ #: classes/AuditLogListView.php:731 classes/Settings.php:1670
197
+ #: classes/Settings.php:1909
198
+ #, php-format
199
+ msgid "Contact us on %s for assistance"
200
+ msgstr ""
201
+
202
+ #: classes/AuditLogListView.php:865
203
+ msgid "Select All"
204
+ msgstr ""
205
+
206
+ #: classes/Connector/wp-db-custom.php:202
207
+ msgid "Error establishing a database connection"
208
+ msgstr ""
209
+
210
+ #. translators: 1: wp-config.php. 2: database host
211
+ #: classes/Connector/wp-db-custom.php:206
212
+ #, php-format
213
+ msgid ""
214
+ "This either means that the username and password information in your %1$s "
215
+ "file is incorrect or we can&#8217;t contact the database server at %2$s. "
216
+ "This could mean your host&#8217;s database server is down."
217
+ msgstr ""
218
+
219
+ #: classes/Connector/wp-db-custom.php:212
220
+ msgid "Are you sure you have the correct username and password?"
221
+ msgstr ""
222
+
223
+ #: classes/Connector/wp-db-custom.php:213
224
+ msgid "Are you sure that you have typed the correct hostname?"
225
+ msgstr ""
226
+
227
+ #: classes/Connector/wp-db-custom.php:214
228
+ msgid "Are you sure that the database server is running?"
229
+ msgstr ""
230
+
231
+ #. translators: %s: support forums URL
232
+ #: classes/Connector/wp-db-custom.php:219
233
+ #, php-format
234
+ msgid ""
235
+ "If you&#8217;re unsure what these terms mean you should probably contact "
236
+ "your host. If you still need help you can always visit the <a href=\"%s"
237
+ "\">WordPress Support Forums</a>."
238
+ msgstr ""
239
+
240
+ #: classes/Connector/wp-db-custom.php:220
241
+ msgid "https://wordpress.org/support/"
242
+ msgstr ""
243
+
244
+ #: classes/Loggers/Database.php:243 classes/Views/EmailNotifications.php:153
245
  #: classes/Views/EmailNotifications.php:185 classes/Views/ExternalDB.php:152
246
+ #: classes/Views/ExternalDB.php:184 classes/Views/Help.php:188
247
+ #: classes/Views/Help.php:239 classes/Views/LogInUsers.php:154
248
  #: classes/Views/LogInUsers.php:186 classes/Views/Reports.php:153
249
  #: classes/Views/Reports.php:185 classes/Views/Search.php:153
250
  #: classes/Views/Search.php:178
251
  msgid "Upgrade to Premium"
252
  msgstr ""
253
 
254
+ #: classes/Loggers/Database.php:244 classes/Views/EmailNotifications.php:154
 
255
  #: classes/Views/EmailNotifications.php:186 classes/Views/ExternalDB.php:153
256
+ #: classes/Views/ExternalDB.php:185 classes/Views/Help.php:240
257
  #: classes/Views/LogInUsers.php:155 classes/Views/LogInUsers.php:187
258
  #: classes/Views/Reports.php:154 classes/Views/Reports.php:186
259
  #: classes/Views/Search.php:154 classes/Views/Search.php:179
260
  msgid "More Information"
261
  msgstr ""
262
 
263
+ #: classes/Sensors/Content.php:1326 classes/Sensors/Content.php:1334
264
+ #: classes/Sensors/WooCommerce.php:596 classes/Sensors/WooCommerce.php:602
265
  msgid "Password Protected"
266
  msgstr ""
267
 
268
+ #: classes/Sensors/Content.php:1328 classes/Sensors/Content.php:1336
269
  msgid "Public"
270
  msgstr ""
271
 
272
+ #: classes/Sensors/Content.php:1330 classes/Sensors/Content.php:1338
273
  msgid "Private"
274
  msgstr ""
275
 
276
+ #: classes/Sensors/Public.php:124
277
+ #, php-format
278
+ msgid ""
279
+ "A comment was posted in response to the post %1$s. The comment was posted by "
280
+ "%2$s"
281
+ msgstr ""
282
+
283
+ #: classes/Sensors/Public.php:653 classes/Sensors/WooCommerce.php:1880
284
  msgid "In stock"
285
  msgstr ""
286
 
287
+ #: classes/Sensors/Public.php:655 classes/Sensors/WooCommerce.php:1882
288
  msgid "Out of stock"
289
  msgstr ""
290
 
291
+ #: classes/Sensors/Public.php:657 classes/Sensors/WooCommerce.php:1884
292
+ msgid "On backorder"
293
+ msgstr ""
294
+
295
+ #: classes/Sensors/WooCommerce.php:2733
296
+ msgid "Visible"
297
+ msgstr ""
298
+
299
+ #: classes/Sensors/WooCommerce.php:2733
300
+ msgid "Non-Visible"
301
+ msgstr ""
302
+
303
+ #: classes/Settings.php:464
304
  msgid "This function is deprecated"
305
  msgstr ""
306
 
307
+ #: classes/Settings.php:1571
308
+ msgid "View Order"
309
+ msgstr ""
310
+
311
+ #: classes/Settings.php:1682 classes/Settings.php:1921
312
+ msgid "plugin settings"
313
+ msgstr ""
314
+
315
+ #: classes/Settings.php:1685 classes/Settings.php:1924
316
+ msgid "contact our support"
317
+ msgstr ""
318
+
319
+ #: classes/Utilities/Emailer.php:53
320
+ #, php-format
321
+ msgid "WP Security Audit Log plugin disabled on %s"
322
+ msgstr ""
323
+
324
+ #: classes/Utilities/Emailer.php:56
325
+ msgid "Hello admin,"
326
+ msgstr ""
327
+
328
+ #: classes/Utilities/Emailer.php:61
329
+ #, php-format
330
+ msgid ""
331
+ "This is a notification to let you know that the user %1$s has deactivated "
332
+ "the plugin WP Security Audit Log on the website %2$s on %3$s."
333
+ msgstr ""
334
+
335
+ #: classes/Views/AuditLog.php:91
336
+ msgid ""
337
+ "Get instantly alerted of important changes via email, do text based searches "
338
+ "and filter results, generate reports, see who is logged in and more!"
339
+ msgstr ""
340
+
341
+ #: classes/Views/AuditLog.php:92
342
+ msgid "Upgrade to premium to unlock these powerful activity log features."
343
+ msgstr ""
344
+
345
+ #: classes/Views/AuditLog.php:95
346
+ msgid ""
347
+ "Instant email notifications, search & filters, reports, users sessions "
348
+ "management, integration tools and more!"
349
+ msgstr ""
350
+
351
+ #: classes/Views/AuditLog.php:96
352
+ msgid ""
353
+ "Upgrade to unlock these powerful features and gain more from your activity "
354
+ "logs."
355
+ msgstr ""
356
+
357
+ #: classes/Views/AuditLog.php:99
358
  msgid ""
359
  "See who is logged in to your WordPress, create user productivity reports, "
360
  "get alerted via email of important changes and more!"
361
  msgstr ""
362
 
363
+ #: classes/Views/AuditLog.php:100
364
  msgid ""
365
  "Unlock these powerful features and much more with the premium edition of WP "
366
  "Security Audit Log."
367
  msgstr ""
368
 
369
+ #: classes/Views/AuditLog.php:164
370
+ msgid "UPGRADE"
371
+ msgstr ""
372
+
373
+ #: classes/Views/AuditLog.php:166
374
+ msgid "Tell me more"
375
+ msgstr ""
376
+
377
+ #: classes/Views/AuditLog.php:167
378
+ msgid "Dismiss the banner"
379
+ msgstr ""
380
+
381
+ #: classes/Views/AuditLog.php:167
382
+ msgid "Close"
383
  msgstr ""
384
 
385
+ #: classes/Views/AuditLog.php:193
386
  msgid ""
387
  "There are connectivity issues with the database where the WordPress activity "
388
  "log is stored. The logs will be temporary buffered in the WordPress database "
389
  "until the connection is fully restored."
390
  msgstr ""
391
 
392
+ #: classes/Views/AuditLog.php:211
393
+ msgid ""
394
+ "Help us improve WP Security Audit Log! Opt-in to sending us diagnostic non-"
395
+ "sensitive data about your plugin usage (<strong>no activity log data is "
396
+ "sent</strong>) and subscribe to our newsletter."
397
+ msgstr ""
398
+
399
+ #: classes/Views/AuditLog.php:214
400
+ msgid "Opt-In"
401
+ msgstr ""
402
+
403
+ #: classes/Views/AuditLog.php:216
404
+ msgid "Learn More"
405
+ msgstr ""
406
+
407
+ #: classes/Views/AuditLog.php:218 classes/Views/AuditLog.php:426
408
+ #: classes/Views/Settings.php:503 classes/Views/Settings.php:530
409
+ #: classes/Views/Settings.php:621 classes/Views/Settings.php:659
410
+ #: classes/Views/Settings.php:1142 classes/Views/Settings.php:1210
411
+ #: classes/Views/Settings.php:1865 classes/Views/Settings.php:1928
412
+ #: classes/Views/Settings.php:1956 classes/Views/Settings.php:1971
413
+ #: classes/Views/Settings.php:1981 classes/Views/SetupWizard.php:519
414
+ msgid "No"
415
+ msgstr ""
416
+
417
+ #: classes/Views/AuditLog.php:258 classes/Views/AuditLog.php:274
418
  msgid "Audit Log Viewer"
419
  msgstr ""
420
 
421
+ #: classes/Views/AuditLog.php:374 classes/Views/Licensing.php:82
422
+ #: classes/Views/Settings.php:334 classes/Views/ToggleAlerts.php:127
423
  msgid "You do not have sufficient permissions to access this page."
424
  msgstr ""
425
 
426
+ #: classes/Views/AuditLog.php:422
427
+ msgid ""
428
+ "Thank you very much for using the WP Security Audit Log plugin. We have "
429
+ "created a wizard to ease the process of configuring the plugin so you can "
430
+ "get the best out of it. Would you like to run the wizard?"
431
  msgstr ""
432
 
433
+ #: classes/Views/AuditLog.php:425 classes/Views/Settings.php:498
434
+ #: classes/Views/Settings.php:525 classes/Views/Settings.php:591
435
+ #: classes/Views/Settings.php:649 classes/Views/Settings.php:1137
436
+ #: classes/Views/Settings.php:1203 classes/Views/Settings.php:1860
437
+ #: classes/Views/Settings.php:1921 classes/Views/Settings.php:1949
438
+ #: classes/Views/Settings.php:1970 classes/Views/Settings.php:1980
439
+ #: classes/Views/SetupWizard.php:524
440
+ msgid "Yes"
441
+ msgstr ""
442
+
443
+ #: classes/Views/AuditLog.php:461 classes/Views/AuditLog.php:484
444
  msgid "Please enter the number of alerts you would like to see on one page:"
445
  msgstr ""
446
 
447
+ #: classes/Views/AuditLog.php:463 classes/Views/AuditLog.php:486
448
  msgid "No Results"
449
  msgstr ""
450
 
451
+ #: classes/Views/AuditLog.php:671
452
  msgid "No users found."
453
  msgstr ""
454
 
455
+ #: classes/Views/AuditLog.php:674 classes/Views/AuditLog.php:751
456
+ #: classes/Views/AuditLog.php:777 classes/Views/AuditLog.php:1082
457
+ #: classes/Views/AuditLog.php:1152 classes/Views/Licensing.php:90
458
+ #: classes/Views/Settings.php:241 classes/Views/Settings.php:330
459
+ #: classes/Views/Settings.php:2127 classes/Views/Settings.php:2155
460
+ #: classes/Views/Settings.php:2185 classes/Views/Settings.php:2224
461
+ #: classes/Views/Settings.php:2226 classes/Views/Settings.php:2228
462
+ #: classes/Views/Settings.php:2335 classes/Views/Settings.php:2337
463
+ #: classes/Views/Settings.php:2339 classes/Views/Settings.php:2429
464
+ #: classes/Views/Settings.php:2509 classes/Views/SetupWizard.php:81
465
+ msgid "Nonce verification failed."
466
+ msgstr ""
467
+
468
+ #: classes/Views/AuditLog.php:693
469
  msgid "Log file does not exist."
470
  msgstr ""
471
 
472
+ #: classes/Views/AuditLog.php:742
473
  msgid "Request to get log file failed."
474
  msgstr ""
475
 
476
+ #: classes/Views/AuditLog.php:817
477
+ msgid "Freemius opt choice selected."
478
+ msgstr ""
479
+
480
+ #: classes/Views/AuditLog.php:824
481
+ msgid "Freemius opt choice not found."
482
+ msgstr ""
483
+
484
+ #: classes/Views/AuditLog.php:996
485
+ msgid "WordPress Activity Log"
486
+ msgstr ""
487
+
488
+ #: classes/Views/AuditLog.php:997
489
+ msgid ""
490
+ "When a user makes a change on your website the plugin will keep a record of "
491
+ "that event here. Right now there is nothing because this is a new install."
492
+ msgstr ""
493
+
494
+ #: classes/Views/AuditLog.php:998
495
+ msgid "Thank you for using WP Security Audit Log"
496
+ msgstr ""
497
+
498
+ #: classes/Views/AuditLog.php:1019
499
+ msgid "Error: You do not have sufficient permissions to exclude this URL."
500
+ msgstr ""
501
+
502
+ #: classes/Views/AuditLog.php:1065
503
+ msgid "You do not have sufficient permissions to dismiss this notice."
504
+ msgstr ""
505
+
506
+ #: classes/Views/AuditLog.php:1135
507
+ msgid "Access Denied"
508
  msgstr ""
509
 
510
  #: classes/Views/EmailNotifications.php:28
601
 
602
  #: classes/Views/ExternalDB.php:121
603
  msgid ""
604
+ "Configure archiving rules to archive old events in an archiving database,"
605
  msgstr ""
606
 
607
  #: classes/Views/ExternalDB.php:167 classes/Views/ExternalDB.php:168
617
  msgstr ""
618
 
619
  #: classes/Views/Help.php:30 classes/Views/Help.php:44
620
+ #: classes/Views/Help.php:86
621
  msgid "Help"
622
  msgstr ""
623
 
624
+ #: classes/Views/Help.php:88 classes/Views/Help.php:165
625
+ msgid "System Info"
626
+ msgstr ""
627
+
628
+ #: classes/Views/Help.php:97
629
  msgid "Getting Started"
630
  msgstr ""
631
 
632
+ #: classes/Views/Help.php:99
633
  msgid ""
634
  "Getting started with WP Security Audit Log is really easy; once the plugin "
635
  "is installed it will automatically keep a log of everything that is "
637
  "video below for a quick overview of the plugin."
638
  msgstr ""
639
 
640
+ #: classes/Views/Help.php:108
641
  msgid "Plugin Support"
642
  msgstr ""
643
 
644
+ #: classes/Views/Help.php:110
645
  msgid ""
646
  "Have you encountered or noticed any issues while using WP Security Audit Log "
647
  "plugin?"
648
  msgstr ""
649
 
650
+ #: classes/Views/Help.php:111
651
  msgid ""
652
  "Or you want to report something to us? Click any of the options below to "
653
  "post on the plugin's forum or contact our support directly."
654
  msgstr ""
655
 
656
+ #: classes/Views/Help.php:113
657
  msgid "Free Support Forum"
658
  msgstr ""
659
 
660
+ #: classes/Views/Help.php:115
661
  msgid "Free Support Email"
662
  msgstr ""
663
 
664
+ #: classes/Views/Help.php:121
665
  msgid "Plugin Documentation"
666
  msgstr ""
667
 
668
+ #: classes/Views/Help.php:123
669
  msgid ""
670
  "For more technical information about the WP Security Audit Log plugin please "
671
  "visit the plugin’s knowledge base."
672
  msgstr ""
673
 
674
+ #: classes/Views/Help.php:124
675
  msgid ""
676
+ "Refer to the list of WordPress security events for a complete list of Events "
677
  "and IDs that the plugin uses to keep a log of all the changes in the "
678
  "WordPress audit log."
679
  msgstr ""
680
 
681
+ #: classes/Views/Help.php:126
682
  msgid "Plugin Website"
683
  msgstr ""
684
 
685
+ #: classes/Views/Help.php:128
686
  msgid "Knowledge Base"
687
  msgstr ""
688
 
689
+ #: classes/Views/Help.php:130
690
+ msgid "List of WordPress Security Events"
691
  msgstr ""
692
 
693
+ #: classes/Views/Help.php:136
694
  msgid "Rate WP Security Audit Log"
695
  msgstr ""
696
 
697
+ #: classes/Views/Help.php:138
698
  msgid ""
699
  "We work really hard to deliver a plugin that enables you to keep a record of "
700
  "all the changes that are happening on your WordPress."
701
  msgstr ""
702
 
703
+ #: classes/Views/Help.php:139
704
  msgid ""
705
  "It takes thousands of man-hours every year and endless amount of dedication "
706
  "to research, develop and maintain the free edition of WP Security Audit Log."
707
  msgstr ""
708
 
709
+ #: classes/Views/Help.php:140
710
  msgid ""
711
  "Therefore if you like what you see, and find WP Security Audit Log useful we "
712
  "ask you nothing more than to please rate our plugin."
713
  msgstr ""
714
 
715
+ #: classes/Views/Help.php:141
716
  msgid "We appreciate every star!"
717
  msgstr ""
718
 
719
+ #: classes/Views/Help.php:151
720
  msgid "Rate Plugin"
721
  msgstr ""
722
 
723
+ #: classes/Views/Help.php:192
724
  msgid "See who is logged in"
725
  msgstr ""
726
 
727
+ #: classes/Views/Help.php:193
728
  msgid "And remotely terminate sessions"
729
  msgstr ""
730
 
731
+ #: classes/Views/Help.php:196
732
  msgid "Generate reports"
733
  msgstr ""
734
 
735
+ #: classes/Views/Help.php:197
736
  msgid "Or configure automated email reports"
737
  msgstr ""
738
 
739
+ #: classes/Views/Help.php:200
740
  msgid "Configure email notifications"
741
  msgstr ""
742
 
743
+ #: classes/Views/Help.php:201
744
  msgid "Get instantly notified of important changes"
745
  msgstr ""
746
 
747
+ #: classes/Views/Help.php:204
748
  msgid "Add Search"
749
  msgstr ""
750
 
751
+ #: classes/Views/Help.php:205
752
  msgid "Easily track down suspicious behaviour"
753
  msgstr ""
754
 
755
+ #: classes/Views/Help.php:208
756
  msgid "Integrate & Centralise"
757
  msgstr ""
758
 
759
+ #: classes/Views/Help.php:209
760
  msgid "Export the logs to your centralised logging system"
761
  msgstr ""
762
 
764
  msgid "Licensing"
765
  msgstr ""
766
 
767
+ #: classes/Views/Licensing.php:96 classes/Views/Settings.php:341
768
+ #: classes/Views/ToggleAlerts.php:144
769
  msgid "Settings have been saved."
770
  msgstr ""
771
 
772
+ #: classes/Views/Licensing.php:101 classes/Views/Settings.php:346
773
+ #: classes/Views/ToggleAlerts.php:150
774
  msgid "Error: "
775
  msgstr ""
776
 
929
  "to fine tune the search results."
930
  msgstr ""
931
 
932
+ #: classes/Views/Settings.php:79
933
+ msgid "General"
934
  msgstr ""
935
 
936
+ #: classes/Views/Settings.php:85
937
+ msgid "Activity Log"
938
  msgstr ""
939
 
940
+ #: classes/Views/Settings.php:91
941
+ msgid "File Integrity Scan"
942
  msgstr ""
943
 
944
+ #: classes/Views/Settings.php:97 classes/Views/SetupWizard.php:148
945
  msgid "Exclude Objects"
946
  msgstr ""
947
 
948
+ #: classes/Views/Settings.php:103
949
+ msgid "Advanced Settings"
950
  msgstr ""
951
 
952
+ #: classes/Views/Settings.php:144 classes/Views/Settings.php:158
953
+ #: classes/Views/ToggleAlerts.php:432 classes/Views/ToggleAlerts.php:456
954
+ msgid "Settings"
955
  msgstr ""
956
 
957
+ #: classes/Views/Settings.php:214
958
+ msgid "Unknown settings tab."
959
  msgstr ""
960
 
961
+ #: classes/Views/Settings.php:226 classes/Views/Settings.php:2530
962
+ #: classes/Views/Settings.php:2559 classes/Views/SetupWizard.php:66
963
+ msgid "Access Denied."
964
+ msgstr ""
965
+
966
+ #: classes/Views/Settings.php:251 classes/Views/SetupWizard.php:91
967
+ msgid "Invalid input."
968
  msgstr ""
969
 
970
+ #: classes/Views/Settings.php:354
971
+ msgid "Old data successfully purged."
972
  msgstr ""
973
 
974
+ #: classes/Views/Settings.php:360
975
+ msgid "No data is old enough to be purged."
976
  msgstr ""
977
 
978
+ #: classes/Views/Settings.php:443
979
+ msgid ""
980
+ "Need help with setting up the plugin to meet your requirements? <a href="
981
+ "\"https://www.wpsecurityauditlog.com/contact/\" target=\"_blank\">Schedule a "
982
+ "20 minutes consultation and setup call</a> with our experts for just $50."
983
  msgstr ""
984
 
985
+ #: classes/Views/Settings.php:445
986
+ msgid "Use infinite scroll or pagination for the event viewer?"
987
  msgstr ""
988
 
989
+ #. translators: Learn more link.
990
+ #: classes/Views/Settings.php:450
991
  #, php-format
992
+ msgid ""
993
+ "When using infinite scroll the event viewer and search results %s load up "
994
+ "much faster and require less resources."
995
  msgstr ""
996
 
997
+ #: classes/Views/Settings.php:451
998
+ msgid "(Premium feature)"
999
  msgstr ""
1000
 
1001
+ #: classes/Views/Settings.php:458
1002
+ msgid "Select event viewer view type:"
1003
  msgstr ""
1004
 
1005
+ #: classes/Views/Settings.php:463
1006
+ msgid "Infinite Scroll (Recommended)"
1007
+ msgstr ""
1008
+
1009
+ #: classes/Views/Settings.php:468
1010
+ msgid "Pagination"
1011
  msgstr ""
1012
 
1013
+ #: classes/Views/Settings.php:479
1014
+ msgid "Display latest events widget in Dashboard & Admin bar"
1015
  msgstr ""
1016
 
1017
+ #. translators: Max number of dashboard widget alerts.
1018
+ #: classes/Views/Settings.php:484
1019
+ #, php-format
1020
  msgid ""
1021
+ "The events widget displays the latest %d security events in the dashboard "
1022
+ "and the admin bar notification displays the latest event."
1023
  msgstr ""
1024
 
1025
+ #: classes/Views/Settings.php:492
1026
+ msgid "Dashboard Widget"
1027
  msgstr ""
1028
 
1029
+ #: classes/Views/Settings.php:513
1030
+ msgid "Admin Bar Notification"
1031
  msgstr ""
1032
 
1033
+ #: classes/Views/Settings.php:516
1034
+ msgid "Admin Bar Notification (Premium)"
1035
  msgstr ""
1036
 
1037
+ #: classes/Views/Settings.php:540
1038
+ msgid "Admin Bar Notification Updates"
1039
+ msgstr ""
1040
+
1041
+ #: classes/Views/Settings.php:543
1042
+ msgid "Admin Bar Notification Updates (Premium)"
1043
+ msgstr ""
1044
+
1045
+ #: classes/Views/Settings.php:552
1046
+ msgid "Update in near real time"
1047
+ msgstr ""
1048
+
1049
+ #: classes/Views/Settings.php:557
1050
+ msgid "Update only on page refreshes"
1051
  msgstr ""
1052
 
1053
+ #: classes/Views/Settings.php:567
1054
+ msgid "Add user notification on the WordPress login page"
1055
+ msgstr ""
1056
+
1057
+ #: classes/Views/Settings.php:568
1058
  msgid ""
1059
+ "Many compliance regulations (such as the GDRP) require website "
1060
+ "administrators to tell the users of their website that all the changes they "
1061
+ "do when logged in are being logged."
1062
  msgstr ""
1063
 
1064
+ #: classes/Views/Settings.php:572
1065
  msgid "Login Page Notification"
1066
  msgstr ""
1067
 
1068
+ #: classes/Views/Settings.php:597 wp-security-audit-log.php:1545
1069
  msgid ""
1070
  "For security and auditing purposes, a record of all of your logged-in "
1071
  "actions and changes within the WordPress dashboard will be recorded in an "
1074
  "IP address where you accessed this site from."
1075
  msgstr ""
1076
 
1077
+ #: classes/Views/Settings.php:615
 
 
 
 
 
 
 
1078
  msgid "<strong>Note: </strong>"
1079
  msgstr ""
1080
 
1081
+ #: classes/Views/Settings.php:615
1082
  msgid ""
1083
  "The only HTML code allowed in the login page notification is for links ( < a "
1084
+ "href >< /a > )."
 
 
 
 
1085
  msgstr ""
1086
 
1087
+ #: classes/Views/Settings.php:631
1088
+ msgid "Is your website running behind a firewall or reverse proxy?"
1089
  msgstr ""
1090
 
1091
+ #. translators: Learn more link.
1092
+ #: classes/Views/Settings.php:636
1093
+ #, php-format
1094
  msgid ""
1095
+ "If your website is running behind a firewall set this option to yes so the "
1096
+ "plugin retrieves the end user’s IP address from the proxy header - %s."
 
1097
  msgstr ""
1098
 
1099
+ #: classes/Views/Settings.php:637
1100
+ msgid "learn more"
1101
  msgstr ""
1102
 
1103
+ #: classes/Views/Settings.php:644
1104
+ msgid "Reverse Proxy / Firewall Options"
1105
  msgstr ""
1106
 
1107
+ #: classes/Views/Settings.php:654
1108
  msgid ""
1109
+ "Filter internal IP addresses from the proxy headers. Enable this option only "
1110
+ "if you are\tare still seeing the internal IP addresses of the firewall or "
1111
+ "proxy."
 
 
 
1112
  msgstr ""
1113
 
1114
+ #: classes/Views/Settings.php:670
1115
+ msgid "Who can change the plugin settings?"
1116
  msgstr ""
1117
 
1118
+ #: classes/Views/Settings.php:671
1119
  msgid ""
1120
+ "By default only users with administrator or super administrator (multisite) "
1121
+ "roles can change the settings of the plugin. Though you can change these "
1122
+ "privileges from this section."
1123
  msgstr ""
1124
 
1125
+ #: classes/Views/Settings.php:675
1126
+ msgid "Restrict Plugin Access"
1127
  msgstr ""
1128
 
1129
+ #: classes/Views/Settings.php:681
1130
+ msgid "Only me"
 
1131
  msgstr ""
1132
 
1133
+ #: classes/Views/Settings.php:686
1134
+ msgid "Only administrators"
 
 
1135
  msgstr ""
1136
 
1137
+ #: classes/Views/Settings.php:692
1138
+ msgid "Only superadmins"
1139
  msgstr ""
1140
 
1141
+ #: classes/Views/Settings.php:698
1142
+ msgid "All these users or users with these roles"
1143
  msgstr ""
1144
 
1145
+ #: classes/Views/Settings.php:700
1146
+ msgid ""
1147
+ "Specify the username or the users which can change the plugin settings. You "
1148
+ "can also specify roles."
1149
  msgstr ""
1150
 
1151
+ #: classes/Views/Settings.php:729
1152
+ msgid "Allow other users to view the activity log"
1153
  msgstr ""
1154
 
1155
+ #: classes/Views/Settings.php:730
1156
+ msgid ""
1157
+ "By default only users with administrator and super administrator (multisite) "
1158
+ "role can view the WordPress activity log. Though you can allow other users "
1159
+ "with no admin role to view the events."
1160
  msgstr ""
1161
 
1162
+ #: classes/Views/Settings.php:734
1163
+ msgid "Can View Events"
1164
  msgstr ""
1165
 
1166
+ #: classes/Views/Settings.php:742
1167
+ msgid ""
1168
+ "Specify the username or the users which do not have an admin role but can "
1169
+ "also see the WordPress activity role. You can also specify roles."
1170
  msgstr ""
1171
 
1172
+ #: classes/Views/Settings.php:768
1173
+ msgid "Which email address should the plugin use as a from address?"
1174
  msgstr ""
1175
 
1176
+ #: classes/Views/Settings.php:769
1177
+ msgid ""
1178
+ "By default when the plugin sends an email notification it uses the email "
1179
+ "address specified in this website’s general settings. Though you can change "
1180
+ "the email address and display name from this section."
1181
  msgstr ""
1182
 
1183
+ #: classes/Views/Settings.php:773
1184
+ msgid "From Email & Name"
1185
  msgstr ""
1186
 
1187
+ #: classes/Views/Settings.php:779
1188
+ msgid "Use the email address from the WordPress general settings"
 
1189
  msgstr ""
1190
 
1191
+ #: classes/Views/Settings.php:784
1192
+ msgid "Use another email address"
1193
  msgstr ""
1194
 
1195
+ #: classes/Views/Settings.php:788
1196
+ msgid "Email Address"
1197
  msgstr ""
1198
 
1199
+ #: classes/Views/Settings.php:793
1200
+ msgid "Display Name"
1201
  msgstr ""
1202
 
1203
+ #: classes/Views/Settings.php:804
1204
+ msgid "Do you want to hide the plugin from the list of installed plugins?"
1205
  msgstr ""
1206
 
1207
+ #: classes/Views/Settings.php:805
1208
+ msgid ""
1209
+ "By default all installed plugins are listed in the plugins page. If you do "
1210
+ "not want other administrators to see that you installed this plugin set this "
1211
+ "option to Yes so the WP Security Audit Log is not listed as an installed "
1212
+ "plugin on this website."
1213
  msgstr ""
1214
 
1215
+ #: classes/Views/Settings.php:809
1216
+ msgid "Hide Plugin in Plugins Page"
1217
  msgstr ""
1218
 
1219
+ #: classes/Views/Settings.php:814
1220
+ msgid "Yes, hide the plugin from the list of installed plugins"
1221
  msgstr ""
1222
 
1223
+ #: classes/Views/Settings.php:819
1224
+ msgid "No, do not hide the plugin"
1225
  msgstr ""
1226
 
1227
+ #: classes/Views/Settings.php:888
1228
+ msgid ""
1229
+ "For how long do you want to keep the activity log events (Retention "
1230
+ "settings) ?"
1231
  msgstr ""
1232
 
1233
+ #: classes/Views/Settings.php:891
1234
+ msgid ""
1235
+ "The plugin uses an efficient way to store the activity log data in the "
1236
+ "WordPress database, though the more data you keep the more disk space will "
1237
+ "be required. "
1238
  msgstr ""
1239
 
1240
+ #: classes/Views/Settings.php:892
1241
+ msgid ""
1242
+ "<a href=\"https://www.wpsecurityauditlog.com/pricing/\" target=\"_blank"
1243
+ "\">Upgrade to Premium</a> to store the activity log data in an external "
1244
+ "database."
1245
  msgstr ""
1246
 
1247
+ #. translators: 1: Archive page link tag. 2: Link closing tag.
1248
+ #: classes/Views/Settings.php:910
1249
+ #, php-format
1250
  msgid ""
1251
+ "Retention settings moved to %1$s archiving settings %2$s because archiving "
1252
+ "is enabled"
1253
  msgstr ""
1254
 
1255
+ #: classes/Views/Settings.php:917
1256
+ msgid "Audit Log Retention"
1257
  msgstr ""
1258
 
1259
+ #: classes/Views/Settings.php:923
1260
+ msgid "Keep all data"
1261
  msgstr ""
1262
 
1263
+ #: classes/Views/Settings.php:950
1264
+ msgid "Delete events older than"
 
 
1265
  msgstr ""
1266
 
1267
+ #: classes/Views/Settings.php:957
1268
+ msgid "Months"
1269
  msgstr ""
1270
 
1271
+ #: classes/Views/Settings.php:958
1272
+ msgid "Years"
 
 
 
1273
  msgstr ""
1274
 
1275
+ #: classes/Views/Settings.php:966
1276
+ msgid "The next scheduled purging of activity log data that is older than "
1277
  msgstr ""
1278
 
1279
+ #: classes/Views/Settings.php:973
1280
+ msgid "You can run the purging process now by clicking the button below."
1281
  msgstr ""
1282
 
1283
+ #: classes/Views/Settings.php:977
1284
+ msgid "Purge Old Data"
 
1285
  msgstr ""
1286
 
1287
+ #: classes/Views/Settings.php:988
1288
+ msgid "What timestamp you would like to see in the WordPress activity log?"
1289
  msgstr ""
1290
 
1291
+ #: classes/Views/Settings.php:989
1292
  msgid ""
1293
+ "Note that the WordPress' timezone might be different from that configured on "
1294
+ "the server so when you switch from UTC to WordPress timezone or vice versa "
1295
+ "you might notice a big difference."
1296
  msgstr ""
1297
 
1298
+ #: classes/Views/Settings.php:993
1299
+ msgid "Events Timestamp"
1300
  msgstr ""
1301
 
1302
+ #: classes/Views/Settings.php:1013
1303
+ msgid "UTC"
1304
  msgstr ""
1305
 
1306
+ #: classes/Views/Settings.php:1019
1307
+ msgid "Timezone configured on this WordPress website"
1308
  msgstr ""
1309
 
1310
+ #: classes/Views/Settings.php:1029
1311
  msgid ""
1312
+ "What user information should be displayed in the WordPress activity log?"
 
 
1313
  msgstr ""
1314
 
1315
+ #: classes/Views/Settings.php:1030
1316
  msgid ""
1317
+ "Usernames might not be the same as a user's first and last name so it can be "
1318
+ "difficult to recognize whose user was that did a change. When there is no "
1319
+ "first & last name or public display name configured the plugin will revert "
1320
+ "back to the WordPress username."
1321
  msgstr ""
1322
 
1323
+ #: classes/Views/Settings.php:1034
1324
+ msgid "User Information in Audit Log"
1325
  msgstr ""
1326
 
1327
+ #: classes/Views/Settings.php:1040
1328
+ msgid "WordPress Username"
1329
  msgstr ""
1330
 
1331
+ #: classes/Views/Settings.php:1045
1332
+ msgid "First Name & Last Name"
 
 
1333
  msgstr ""
1334
 
1335
+ #: classes/Views/Settings.php:1050
1336
+ msgid "Configured Public Display Name"
1337
  msgstr ""
1338
 
1339
+ #: classes/Views/Settings.php:1060
1340
+ msgid "Select the columns to be displayed in the WordPress activity log"
1341
  msgstr ""
1342
 
1343
+ #: classes/Views/Settings.php:1061
1344
  msgid ""
1345
+ "When you deselect a column it won’t be shown in the activity log viewer but "
1346
+ "the data will still be recorded by the plugin, so when you select it again "
1347
+ "all the data will be displayed."
 
 
 
1348
  msgstr ""
1349
 
1350
+ #: classes/Views/Settings.php:1065
1351
+ msgid "Audit Log Columns Selection"
1352
  msgstr ""
1353
 
1354
+ #: classes/Views/Settings.php:1078
1355
+ msgid "Date & Time"
1356
  msgstr ""
1357
 
1358
+ #: classes/Views/Settings.php:1082
1359
+ msgid "Source IP Address"
1360
  msgstr ""
1361
 
1362
+ #: classes/Views/Settings.php:1097
1363
+ msgid "Do you want the activity log viewer to auto refresh?"
1364
  msgstr ""
1365
 
1366
+ #: classes/Views/Settings.php:1098
1367
  msgid ""
1368
+ "The activity log viewer auto refreshes every 30 seconds when opened so you "
1369
+ "can see the latest events as they happen almost in real time."
1370
  msgstr ""
1371
 
1372
+ #: classes/Views/Settings.php:1102
1373
+ msgid "Refresh Audit Log Viewer"
1374
  msgstr ""
1375
 
1376
+ #: classes/Views/Settings.php:1109
1377
+ msgid "Auto refresh"
1378
  msgstr ""
1379
 
1380
+ #: classes/Views/Settings.php:1115
1381
+ msgid "Do not auto refresh"
 
 
1382
  msgstr ""
1383
 
1384
+ #: classes/Views/Settings.php:1125
1385
+ msgid "Do you want to keep a log of WordPress background activity?"
1386
  msgstr ""
1387
 
1388
+ #: classes/Views/Settings.php:1127
1389
  msgid ""
1390
+ "WordPress does a lot of things in the background that you do not necessarily "
1391
+ "need to know about, such as; deletion of post revisions, deletion of auto "
1392
+ "saved drafts etc. By default the plugin does not report them since there "
1393
+ "might be a lot and are irrelevant to the user."
1394
  msgstr ""
1395
 
1396
+ #: classes/Views/Settings.php:1132
1397
+ msgid "Enable Events for WordPress Background Activity"
1398
  msgstr ""
1399
 
1400
+ #: classes/Views/Settings.php:1186
1401
  msgid ""
1402
+ "The plugin runs file integrity scans on your website so it keeps a log when "
1403
+ "a file is added, modified or deleted. All the settings for the file "
1404
+ "integrity scans can be found in this page."
 
 
1405
  msgstr ""
1406
 
1407
+ #: classes/Views/Settings.php:1187
1408
  msgid ""
1409
+ "<a href=\"https://www.wpsecurityauditlog.com/support-documentation/wordpress-"
1410
+ "files-changes-warning-activity-logs/\" target=\"_blank\">Refer to the "
1411
+ "WordPress file integrity scans feature page</a> for more information."
1412
  msgstr ""
1413
 
1414
+ #: classes/Views/Settings.php:1190
1415
+ msgid "Do you want the plugin to scan your website for file changes?"
1416
  msgstr ""
1417
 
1418
+ #: classes/Views/Settings.php:1195
1419
+ msgid "Keep a Log of File Changes"
1420
  msgstr ""
1421
 
1422
+ #: classes/Views/Settings.php:1219
1423
+ msgid ""
1424
+ "Which file changes events do you want to keep a log of in the activity log?"
1425
  msgstr ""
1426
 
1427
+ #: classes/Views/Settings.php:1221
1428
+ msgid ""
1429
+ "By default the plugin will keep a log whenever a file has been added, "
1430
+ "modified or deleted. It will also log an event in the activity log when a "
1431
+ "file is too big to scan or there are too many files to scan. Click on the "
1432
+ "link to specify which of these events the plugin should keep a log of."
1433
  msgstr ""
1434
 
1435
+ #: classes/Views/Settings.php:1227
1436
+ msgid "Alert me when"
1437
  msgstr ""
1438
 
1439
+ #: classes/Views/Settings.php:1240
1440
+ msgid "Configure Events"
1441
  msgstr ""
1442
 
1443
+ #: classes/Views/Settings.php:1249
1444
+ msgid "When should the plugin scan your website for file changes?"
1445
  msgstr ""
1446
 
1447
+ #: classes/Views/Settings.php:1251
1448
+ msgid ""
1449
+ "By default the plugin will run file integrity scans once a week. If you can, "
1450
+ "ideally you should run file integrity scans on a daily basis. The file "
1451
+ "integrity scanner is very efficient and requires very little resources. "
1452
+ "Though if you have a fairly large website we recommend you to scan it when "
1453
+ "it is the least busy. The scan process should only take a few seconds to "
1454
+ "complete."
1455
  msgstr ""
1456
 
1457
+ #: classes/Views/Settings.php:1257
1458
+ msgid "Scan Frequency"
1459
  msgstr ""
1460
 
1461
+ #: classes/Views/Settings.php:1262
1462
+ msgid "Daily"
1463
  msgstr ""
1464
 
1465
+ #: classes/Views/Settings.php:1263
1466
+ msgid "Weekly"
1467
  msgstr ""
1468
 
1469
+ #: classes/Views/Settings.php:1264
1470
+ msgid "Monthly"
1471
  msgstr ""
1472
 
1473
+ #: classes/Views/Settings.php:1282
1474
+ msgid "Scan Time"
1475
  msgstr ""
1476
 
1477
+ #: classes/Views/Settings.php:1288
1478
+ msgid "00:00"
1479
  msgstr ""
1480
 
1481
+ #: classes/Views/Settings.php:1289
1482
+ msgid "01:00"
1483
  msgstr ""
1484
 
1485
+ #: classes/Views/Settings.php:1290
1486
+ msgid "02:00"
1487
  msgstr ""
1488
 
1489
+ #: classes/Views/Settings.php:1291
1490
+ msgid "03:00"
1491
  msgstr ""
1492
 
1493
+ #: classes/Views/Settings.php:1292
1494
+ msgid "04:00"
1495
  msgstr ""
1496
 
1497
+ #: classes/Views/Settings.php:1293
1498
+ msgid "05:00"
1499
  msgstr ""
1500
 
1501
+ #: classes/Views/Settings.php:1294
1502
+ msgid "06:00"
1503
  msgstr ""
1504
 
1505
+ #: classes/Views/Settings.php:1295
1506
+ msgid "07:00"
1507
  msgstr ""
1508
 
1509
+ #: classes/Views/Settings.php:1296
1510
+ msgid "08:00"
1511
  msgstr ""
1512
 
1513
+ #: classes/Views/Settings.php:1297
1514
+ msgid "09:00"
1515
  msgstr ""
1516
 
1517
+ #: classes/Views/Settings.php:1298
1518
+ msgid "10:00"
 
 
1519
  msgstr ""
1520
 
1521
+ #: classes/Views/Settings.php:1299
1522
+ msgid "11:00"
1523
  msgstr ""
1524
 
1525
+ #: classes/Views/Settings.php:1300
1526
+ msgid "12:00"
 
 
1527
  msgstr ""
1528
 
1529
+ #: classes/Views/Settings.php:1301
1530
+ msgid "13:00"
1531
  msgstr ""
1532
 
1533
+ #: classes/Views/Settings.php:1302
1534
+ msgid "14:00"
 
 
1535
  msgstr ""
1536
 
1537
+ #: classes/Views/Settings.php:1303
1538
+ msgid "15:00"
1539
  msgstr ""
1540
 
1541
+ #: classes/Views/Settings.php:1304
1542
+ msgid "16:00"
 
1543
  msgstr ""
1544
 
1545
+ #: classes/Views/Settings.php:1305
1546
+ msgid "17:00"
1547
  msgstr ""
1548
 
1549
+ #: classes/Views/Settings.php:1306
1550
+ msgid "18:00"
 
 
1551
  msgstr ""
1552
 
1553
+ #: classes/Views/Settings.php:1307
1554
+ msgid "19:00"
1555
  msgstr ""
1556
 
1557
+ #: classes/Views/Settings.php:1308
1558
+ msgid "20:00"
 
 
1559
  msgstr ""
1560
 
1561
+ #: classes/Views/Settings.php:1309
1562
+ msgid "21:00"
1563
  msgstr ""
1564
 
1565
+ #: classes/Views/Settings.php:1310
1566
+ msgid "22:00"
 
 
1567
  msgstr ""
1568
 
1569
+ #: classes/Views/Settings.php:1311
1570
+ msgid "23:00"
1571
  msgstr ""
1572
 
1573
+ #: classes/Views/Settings.php:1316
1574
+ msgid "Monday"
 
 
1575
  msgstr ""
1576
 
1577
+ #: classes/Views/Settings.php:1317
1578
+ msgid "Tuesday"
1579
  msgstr ""
1580
 
1581
+ #: classes/Views/Settings.php:1318
1582
+ msgid "Wednesday"
 
 
1583
  msgstr ""
1584
 
1585
+ #: classes/Views/Settings.php:1319
1586
+ msgid "Thursday"
1587
  msgstr ""
1588
 
1589
+ #: classes/Views/Settings.php:1320
1590
+ msgid "Friday"
 
 
1591
  msgstr ""
1592
 
1593
+ #: classes/Views/Settings.php:1321
1594
+ msgid "Saturday"
1595
  msgstr ""
1596
 
1597
+ #: classes/Views/Settings.php:1322
1598
+ msgid "Sunday"
 
 
1599
  msgstr ""
1600
 
1601
+ #: classes/Views/Settings.php:1327
1602
+ msgid "01"
1603
  msgstr ""
1604
 
1605
+ #: classes/Views/Settings.php:1328
1606
+ msgid "02"
 
 
1607
  msgstr ""
1608
 
1609
+ #: classes/Views/Settings.php:1329
1610
+ msgid "03"
1611
  msgstr ""
1612
 
1613
+ #: classes/Views/Settings.php:1330
1614
+ msgid "04"
 
 
1615
  msgstr ""
1616
 
1617
+ #: classes/Views/Settings.php:1331
1618
+ msgid "05"
1619
  msgstr ""
1620
 
1621
+ #: classes/Views/Settings.php:1332
1622
+ msgid "06"
 
 
1623
  msgstr ""
1624
 
1625
+ #: classes/Views/Settings.php:1333
1626
+ msgid "07"
1627
  msgstr ""
1628
 
1629
+ #: classes/Views/Settings.php:1334
1630
+ msgid "08"
 
 
1631
  msgstr ""
1632
 
1633
+ #: classes/Views/Settings.php:1335
1634
+ msgid "09"
1635
  msgstr ""
1636
 
1637
+ #: classes/Views/Settings.php:1336
1638
+ msgid "10"
 
 
1639
  msgstr ""
1640
 
1641
+ #: classes/Views/Settings.php:1337
1642
+ msgid "11"
1643
  msgstr ""
1644
 
1645
+ #: classes/Views/Settings.php:1338
1646
+ msgid "12"
 
1647
  msgstr ""
1648
 
1649
+ #: classes/Views/Settings.php:1339
1650
+ msgid "13"
1651
  msgstr ""
1652
 
1653
+ #: classes/Views/Settings.php:1340
1654
+ msgid "14"
1655
  msgstr ""
1656
 
1657
+ #: classes/Views/Settings.php:1341
1658
+ msgid "15"
1659
  msgstr ""
1660
 
1661
+ #: classes/Views/Settings.php:1342
1662
+ msgid "16"
 
 
1663
  msgstr ""
1664
 
1665
+ #: classes/Views/Settings.php:1343
1666
+ msgid "17"
1667
  msgstr ""
1668
 
1669
+ #: classes/Views/Settings.php:1344
1670
+ msgid "18"
 
 
 
1671
  msgstr ""
1672
 
1673
+ #: classes/Views/Settings.php:1345
1674
+ msgid "19"
1675
  msgstr ""
1676
 
1677
+ #: classes/Views/Settings.php:1346
1678
+ msgid "20"
 
 
 
1679
  msgstr ""
1680
 
1681
+ #: classes/Views/Settings.php:1347
1682
+ msgid "21"
1683
  msgstr ""
1684
 
1685
+ #: classes/Views/Settings.php:1348
1686
+ msgid "22"
 
 
1687
  msgstr ""
1688
 
1689
+ #: classes/Views/Settings.php:1349
1690
+ msgid "23"
1691
  msgstr ""
1692
 
1693
+ #: classes/Views/Settings.php:1350
1694
+ msgid "24"
 
 
 
1695
  msgstr ""
1696
 
1697
+ #: classes/Views/Settings.php:1351
1698
+ msgid "25"
1699
  msgstr ""
1700
 
1701
+ #: classes/Views/Settings.php:1352
1702
+ msgid "26"
 
 
1703
  msgstr ""
1704
 
1705
+ #: classes/Views/Settings.php:1353
1706
+ msgid "27"
1707
  msgstr ""
1708
 
1709
+ #: classes/Views/Settings.php:1354
1710
+ msgid "28"
 
 
1711
  msgstr ""
1712
 
1713
+ #: classes/Views/Settings.php:1355
1714
+ msgid "29"
1715
  msgstr ""
1716
 
1717
+ #: classes/Views/Settings.php:1356
1718
+ msgid "30"
 
 
1719
  msgstr ""
1720
 
1721
+ #: classes/Views/Settings.php:1372
1722
+ msgid "Hour"
1723
  msgstr ""
1724
 
1725
+ #: classes/Views/Settings.php:1388 classes/Views/Settings.php:1404
1726
+ msgid "Day"
 
 
1727
  msgstr ""
1728
 
1729
+ #: classes/Views/Settings.php:1414
1730
+ msgid "Which directories should be scanned for file changes?"
1731
  msgstr ""
1732
 
1733
+ #: classes/Views/Settings.php:1416
1734
  msgid ""
1735
+ "The plugin will scan all the directories in your WordPress website by "
1736
+ "default because that is the most secure option. Though if for some reason "
1737
+ "you do not want the plugin to scan any of these directories you can uncheck "
1738
+ "them from the below list."
 
 
1739
  msgstr ""
1740
 
1741
+ #: classes/Views/Settings.php:1422
1742
+ msgid "Directories to scan"
 
 
1743
  msgstr ""
1744
 
1745
+ #: classes/Views/Settings.php:1428
1746
+ msgid "Root directory of WordPress (excluding sub directories)"
1747
  msgstr ""
1748
 
1749
+ #: classes/Views/Settings.php:1429
1750
+ msgid "WP Admin directory (/wp-admin/)"
 
 
1751
  msgstr ""
1752
 
1753
+ #: classes/Views/Settings.php:1430
1754
+ msgid "WP Includes directory (/wp-includes/)"
1755
  msgstr ""
1756
 
1757
+ #: classes/Views/Settings.php:1431
1758
  msgid ""
1759
+ "/wp-content/ directory (excluding plugins, themes & uploads directories)"
 
1760
  msgstr ""
1761
 
1762
+ #: classes/Views/Settings.php:1432
1763
+ msgid "Themes directory (/wp-content/themes/)"
1764
  msgstr ""
1765
 
1766
+ #: classes/Views/Settings.php:1433
1767
+ msgid "Plugins directory (/wp-content/plugins/)"
 
 
1768
  msgstr ""
1769
 
1770
+ #: classes/Views/Settings.php:1434
1771
+ msgid "Uploads directory (/wp-content/uploads/)"
1772
  msgstr ""
1773
 
1774
+ #: classes/Views/Settings.php:1440
1775
  msgid ""
1776
+ "Uploads directory of all sub sites on this network (/wp-content/sites/*)"
 
1777
  msgstr ""
1778
 
1779
+ #: classes/Views/Settings.php:1463
1780
+ msgid "What is the biggest file size the plugin should scan?"
1781
  msgstr ""
1782
 
1783
+ #: classes/Views/Settings.php:1464
1784
  msgid ""
1785
+ "By default the plugin does not scan files that are bigger than 5MB. Such "
1786
+ "files are not common, hence typically not a target. Though if you are "
1787
+ "getting a lot of 6032 Events, it is recommended to increase the file size "
1788
+ "limit from the below option."
1789
  msgstr ""
1790
 
1791
+ #: classes/Views/Settings.php:1467
1792
+ msgid "File Size Limit"
1793
  msgstr ""
1794
 
1795
+ #: classes/Views/Settings.php:1470
1796
+ msgid "MB"
1797
  msgstr ""
1798
 
1799
+ #: classes/Views/Settings.php:1476
1800
+ msgid ""
1801
+ "Do you want to exclude specific files or files with a particular extension "
1802
+ "from the scan?"
1803
  msgstr ""
1804
 
1805
+ #: classes/Views/Settings.php:1477
1806
+ msgid ""
1807
+ "The plugin will scan everything that is in the WordPress root directory or "
1808
+ "below, even if the files and directories are not part of WordPress. It is "
1809
+ "recommended to scan all source code files and only exclude files that cannot "
1810
+ "be tampered, such as text files, media files etc, most of which are already "
1811
+ "excluded by default."
1812
  msgstr ""
1813
 
1814
+ #: classes/Views/Settings.php:1482
1815
+ msgid "Exclude All Files in These Directories"
1816
  msgstr ""
1817
 
1818
+ #: classes/Views/Settings.php:1495 classes/Views/Settings.php:1531
1819
+ #: classes/Views/Settings.php:1561
1820
+ msgid "REMOVE"
1821
  msgstr ""
1822
 
1823
+ #: classes/Views/Settings.php:1500 classes/Views/Settings.php:1536
1824
+ #: classes/Views/Settings.php:1566 classes/Views/SetupWizard.php:533
1825
+ #: classes/Views/SetupWizard.php:541 classes/Views/SetupWizard.php:626
1826
+ #: classes/Views/SetupWizard.php:645 classes/Views/SetupWizard.php:664
1827
+ msgid "ADD"
1828
  msgstr ""
1829
 
1830
+ #: classes/Views/Settings.php:1503
1831
  msgid ""
1832
+ "Specify the name of the directory and the path to it in relation to the "
1833
+ "website's root. For example, if you want to want to exclude all files in the "
1834
+ "sub directory dir1/dir2 specify the following:"
1835
  msgstr ""
1836
 
1837
+ #: classes/Views/Settings.php:1514
1838
+ msgid "Exclude These Files"
1839
  msgstr ""
1840
 
1841
+ #: classes/Views/Settings.php:1539
1842
  msgid ""
1843
+ "Specify the name and extension of the file(s) you want to exclude. Wildcard "
1844
+ "not supported. There is no need to specify the path of the file."
 
 
 
 
1845
  msgstr ""
1846
 
1847
+ #: classes/Views/Settings.php:1548
1848
+ msgid "Exclude these File Types"
1849
  msgstr ""
1850
 
1851
+ #: classes/Views/Settings.php:1569
1852
  msgid ""
1853
+ "Specify the extension of the file types you want to exclude. You should "
1854
+ "exclude any type of logs and backup files that tend to be very big."
1855
  msgstr ""
1856
 
1857
+ #: classes/Views/Settings.php:1578
1858
+ msgid "Launch an instant file integrity scan"
1859
  msgstr ""
1860
 
1861
+ #: classes/Views/Settings.php:1580
1862
  msgid ""
1863
+ "Click the Scan Now button to launch an instant file integrity scan using the "
1864
+ "configured settings. You can navigate away from this page during the scan. "
1865
+ "Note that the instant scan can be more resource intensive than scheduled "
1866
+ "scans."
1867
  msgstr ""
1868
 
1869
+ #: classes/Views/Settings.php:1586
1870
+ msgid "Launch Instant Scan"
1871
  msgstr ""
1872
 
1873
+ #: classes/Views/Settings.php:1592 classes/Views/Settings.php:1599
1874
+ #: classes/Views/Settings.php:2091
1875
+ msgid "Scan Now"
 
1876
  msgstr ""
1877
 
1878
+ #: classes/Views/Settings.php:1593 classes/Views/Settings.php:1596
1879
+ #: classes/Views/Settings.php:1600
1880
+ msgid "Stop Scan"
1881
  msgstr ""
1882
 
1883
+ #: classes/Views/Settings.php:1595 classes/Views/Settings.php:2093
1884
+ msgid "Scan in Progress"
 
 
1885
  msgstr ""
1886
 
1887
+ #: classes/Views/Settings.php:1679
1888
+ msgid ""
1889
+ "By default the plugin keeps a log of all user changes done on your WordPress "
1890
+ "website. Use the setting below to exclude any objects from the activity log. "
1891
+ "When an object is excluded from the activity log, any event in which that "
1892
+ "object is referred will not be logged in the activity log."
1893
  msgstr ""
1894
 
1895
+ #: classes/Views/Settings.php:1683
1896
+ msgid "Exclude Users:"
 
 
1897
  msgstr ""
1898
 
1899
+ #: classes/Views/Settings.php:1704
1900
+ msgid "Exclude Roles:"
1901
  msgstr ""
1902
 
1903
+ #: classes/Views/Settings.php:1725
1904
+ msgid "Exclude IP Addresses:"
 
 
1905
  msgstr ""
1906
 
1907
+ #: classes/Views/Settings.php:1746
1908
+ msgid "Exclude Post Type:"
1909
  msgstr ""
1910
 
1911
+ #: classes/Views/Settings.php:1761
1912
  msgid ""
1913
+ "WordPress has the post and page post types by default though your website "
1914
+ "might use more post types (custom post types). You can exclude all post "
1915
+ "types, including the default WordPress ones."
1916
  msgstr ""
1917
 
1918
+ #: classes/Views/Settings.php:1768
1919
+ msgid "Exclude Custom Fields:"
1920
  msgstr ""
1921
 
1922
+ #: classes/Views/Settings.php:1783
1923
  msgid ""
1924
+ "You can use the * wildcard to exclude multiple matching custom fields. For "
1925
+ "example to exclude all custom fields starting with wp123 enter wp123*"
1926
  msgstr ""
1927
 
1928
+ #: classes/Views/Settings.php:1790
1929
+ msgid "Exclude Non-Existing URLs:"
1930
  msgstr ""
1931
 
1932
+ #: classes/Views/Settings.php:1806
1933
  msgid ""
1934
+ "Add the non existing URLs for which you do not want to be alerted of HTTP "
1935
+ "404 errors in the activity log by specifying the complete URL.\tExamples "
1936
+ "below:"
1937
  msgstr ""
1938
 
1939
+ #: classes/Views/Settings.php:1808
1940
+ msgid "File: "
1941
  msgstr ""
1942
 
1943
+ #: classes/Views/Settings.php:1810
1944
+ msgid "Directory: "
1945
  msgstr ""
1946
 
1947
+ #: classes/Views/Settings.php:1843
1948
+ msgid "These settings are for advanced users."
1949
  msgstr ""
1950
 
1951
+ #: classes/Views/Settings.php:1844
1952
+ msgid ""
1953
+ "If you have any questions <a href=\"https://www.wpsecurityauditlog.com/"
1954
+ "contact/\" target=\"_blank\">contact us</a>."
 
 
1955
  msgstr ""
1956
 
1957
+ #: classes/Views/Settings.php:1847
1958
+ msgid ""
1959
+ "Troubleshooting setting: Keep a debug log of all the requests this website "
1960
+ "receives"
1961
  msgstr ""
1962
 
1963
+ #: classes/Views/Settings.php:1848
1964
  msgid ""
1965
+ "Only enable the request log on testing, staging and development website. "
1966
+ "Never enable logging on a live website unless instructed to do so. Enabling "
1967
+ "request logging on a live website may degrade the performance of the website."
1968
  msgstr ""
1969
 
1970
+ #: classes/Views/Settings.php:1852
1971
+ msgid "Request Log"
1972
  msgstr ""
1973
 
1974
+ #: classes/Views/Settings.php:1870
1975
  msgid ""
1976
+ "<strong>Note:</strong> The requests debug log file is saved as request.log."
1977
+ "php in the /wp-content/uploads/wp-security-audit-log/ directory."
1978
  msgstr ""
1979
 
1980
+ #: classes/Views/Settings.php:1882
1981
+ msgid "Reset plugin settings to default"
1982
  msgstr ""
1983
 
1984
+ #: classes/Views/Settings.php:1883
1985
  msgid ""
1986
+ "Click the RESET button to reset ALL plugin settings to default. Note that "
1987
+ "the activity log data will be retained and only the plugin settings will be "
1988
+ "reset. To purge the data of the activity log use the setting below."
1989
  msgstr ""
1990
 
1991
+ #: classes/Views/Settings.php:1887
1992
+ msgid "Reset Settings"
1993
  msgstr ""
1994
 
1995
+ #: classes/Views/Settings.php:1889
1996
+ msgid "RESET"
 
 
1997
  msgstr ""
1998
 
1999
+ #: classes/Views/Settings.php:1895
2000
+ msgid "Purge the WordPress activity log"
2001
  msgstr ""
2002
 
2003
+ #: classes/Views/Settings.php:1896
2004
+ msgid ""
2005
+ "Click the Purge button below to delete all the data from the WordPress "
2006
+ "activity log and start afresh."
2007
  msgstr ""
2008
 
2009
+ #: classes/Views/Settings.php:1900
2010
+ msgid "Purge Activity Log"
2011
  msgstr ""
2012
 
2013
+ #: classes/Views/Settings.php:1902
2014
+ msgid "PURGE"
 
 
2015
  msgstr ""
2016
 
2017
+ #: classes/Views/Settings.php:1908
2018
+ msgid "MainWP Child Site Stealth Mode"
2019
  msgstr ""
2020
 
2021
+ #: classes/Views/Settings.php:1909
2022
  msgid ""
2023
+ "This option is enabled automatically when the plugin detects the MainWP "
2024
+ "Child plugin on the site. When this setting is enabled plugin access is "
2025
+ "restricted to the administrator who installs the plugin, the plugin is not "
2026
+ "shown in the list of installed plugins and no admin notifications are shown. "
2027
+ "Disable this option to change the plugin to the default setup."
2028
  msgstr ""
2029
 
2030
+ #: classes/Views/Settings.php:1913
2031
+ msgid "Enable MainWP Child Site Stealth Mode"
2032
  msgstr ""
2033
 
2034
+ #: classes/Views/Settings.php:1937
2035
+ msgid "Do you want to delete the plugin data from the database upon uninstall?"
2036
+ msgstr ""
2037
+
2038
+ #: classes/Views/Settings.php:1938
2039
  msgid ""
2040
+ "The plugin saves the activity log data and settings in the WordPress "
2041
+ "database. By default upon uninstalling the plugin the data is kept in the "
2042
+ "database so if it is installed again, you can still access the data. If the "
2043
+ "data is deleted it is not possible to recover it so you won't be able to "
2044
+ "access it again even when you reinstall the plugin."
2045
  msgstr ""
2046
 
2047
+ #: classes/Views/Settings.php:1942
2048
+ msgid "Remove Data on Uninstall"
2049
  msgstr ""
2050
 
2051
+ #: classes/Views/Settings.php:1967
2052
+ msgid "Are you sure you want to reset all the plugin settings to default?"
 
 
2053
  msgstr ""
2054
 
2055
+ #: classes/Views/Settings.php:1977
2056
+ msgid "Are you sure you want to purge all the activity log data?"
2057
  msgstr ""
2058
 
2059
+ #: classes/Views/Settings.php:2009
2060
+ msgid "MainWP Child plugin is not active on this website."
 
 
2061
  msgstr ""
2062
 
2063
+ #: classes/Views/Settings.php:2084
2064
+ msgid "The specified value is not a valid URL!"
2065
  msgstr ""
2066
 
2067
+ #: classes/Views/Settings.php:2085
2068
+ msgid "The specified value is not a valid post type!"
 
 
2069
  msgstr ""
2070
 
2071
+ #: classes/Views/Settings.php:2086
2072
+ msgid "The specified value is not a valid IP address!"
2073
  msgstr ""
2074
 
2075
+ #: classes/Views/Settings.php:2087
2076
+ msgid "The specified value is not a user nor a role!"
 
 
2077
  msgstr ""
2078
 
2079
+ #: classes/Views/Settings.php:2088
2080
+ msgid "Filename cannot be added because it contains invalid characters."
2081
  msgstr ""
2082
 
2083
+ #: classes/Views/Settings.php:2089
2084
+ msgid "File extension cannot be added because it contains invalid characters."
 
 
2085
  msgstr ""
2086
 
2087
+ #: classes/Views/Settings.php:2090
2088
+ msgid "Directory cannot be added because it contains invalid characters."
2089
  msgstr ""
2090
 
2091
+ #: classes/Views/Settings.php:2092
2092
+ msgid "Scan Failed"
 
 
2093
  msgstr ""
2094
 
2095
+ #: classes/Views/Settings.php:2217 classes/Views/Settings.php:2328
2096
+ msgid "Invalid setting type."
2097
  msgstr ""
2098
 
2099
+ #: classes/Views/Settings.php:2271
2100
+ msgid "You can exclude this directory using the check boxes above."
 
 
 
2101
  msgstr ""
2102
 
2103
+ #: classes/Views/Settings.php:2290
2104
+ msgid "Option added to excluded types."
2105
  msgstr ""
2106
 
2107
+ #: classes/Views/Settings.php:2294
2108
+ msgid "This file is already excluded from the scan."
 
 
2109
  msgstr ""
2110
 
2111
+ #: classes/Views/Settings.php:2296
2112
+ msgid "This file extension is already excluded from the scan."
2113
  msgstr ""
2114
 
2115
+ #: classes/Views/Settings.php:2298
2116
+ msgid "This directory is already excluded from the scan."
 
 
2117
  msgstr ""
2118
 
2119
+ #: classes/Views/Settings.php:2308
2120
+ msgid "Option name is empty."
2121
  msgstr ""
2122
 
2123
+ #: classes/Views/Settings.php:2404
2124
+ msgid "Option removed from excluded scan types."
 
 
2125
  msgstr ""
2126
 
2127
+ #: classes/Views/Settings.php:2409 classes/Views/Settings.php:2487
2128
+ msgid "Something went wrong."
2129
  msgstr ""
2130
 
2131
+ #: classes/Views/Settings.php:2436
2132
+ msgid "A cron job is in progress."
 
 
2133
  msgstr ""
2134
 
2135
+ #: classes/Views/Settings.php:2482 classes/Views/Settings.php:2519
2136
+ msgid "Scan started successfully."
2137
  msgstr ""
2138
 
2139
+ #: classes/Views/Settings.php:2544 classes/Views/Settings.php:2571
2140
+ msgid "Tables has been reset."
 
 
2141
  msgstr ""
2142
 
2143
+ #: classes/Views/Settings.php:2546 classes/Views/Settings.php:2573
2144
+ msgid "Reset query failed."
2145
  msgstr ""
2146
 
2147
+ #: classes/Views/Settings.php:2549 classes/Views/Settings.php:2576
2148
+ msgid "Nonce Verification Failed."
 
 
2149
  msgstr ""
2150
 
2151
+ #: classes/Views/SetupWizard.php:129
2152
+ msgid "Welcome"
2153
  msgstr ""
2154
 
2155
+ #: classes/Views/SetupWizard.php:133
2156
+ msgid "Log Details"
 
 
2157
  msgstr ""
2158
 
2159
+ #: classes/Views/SetupWizard.php:138
2160
+ msgid "Log Retention"
2161
  msgstr ""
2162
 
2163
+ #: classes/Views/SetupWizard.php:143
2164
+ msgid "Access"
 
 
2165
  msgstr ""
2166
 
2167
+ #: classes/Views/SetupWizard.php:153 classes/Views/SetupWizard.php:755
2168
+ #: classes/Views/SetupWizard.php:756
2169
+ msgid "Finish"
2170
  msgstr ""
2171
 
2172
+ #: classes/Views/SetupWizard.php:197
2173
+ msgid "Specified value in not a user."
 
 
2174
  msgstr ""
2175
 
2176
+ #: classes/Views/SetupWizard.php:198
2177
+ msgid "Specified value in not a role."
2178
  msgstr ""
2179
 
2180
+ #: classes/Views/SetupWizard.php:199
2181
+ msgid "Specified value in not an IP address."
 
 
2182
  msgstr ""
2183
 
2184
+ #: classes/Views/SetupWizard.php:229
2185
+ msgid "WP Security Audit Log &rsaquo; Setup Wizard"
2186
  msgstr ""
2187
 
2188
+ #: classes/Views/SetupWizard.php:246
2189
+ msgid "Close Wizard"
2190
  msgstr ""
2191
 
2192
+ #: classes/Views/SetupWizard.php:326
2193
+ msgid "Thank you for installing the WP Security Audit Log plugin."
 
 
2194
  msgstr ""
2195
 
2196
+ #: classes/Views/SetupWizard.php:327
2197
+ msgid ""
2198
+ "This wizard will help you configure your WordPress activity log plugin and "
2199
+ "get you started quickly."
2200
  msgstr ""
2201
 
2202
+ #: classes/Views/SetupWizard.php:328
2203
  msgid ""
2204
+ "Anything that can be configured in this wizard can be changed at a later "
2205
+ "stage from the plugin settings. If you are an experienced user of this "
2206
+ "plugin you can exit this wizard and configure all the settings manually."
2207
  msgstr ""
2208
 
2209
+ #: classes/Views/SetupWizard.php:333
2210
+ msgid "Start Configuring the Plugin"
2211
  msgstr ""
2212
 
2213
+ #: classes/Views/SetupWizard.php:337
2214
+ msgid "Exit Wizard"
 
 
2215
  msgstr ""
2216
 
2217
+ #: classes/Views/SetupWizard.php:351
2218
+ msgid "Please select the level of detail for your WordPress activity logs:"
2219
  msgstr ""
2220
 
2221
+ #: classes/Views/SetupWizard.php:356
2222
  msgid ""
2223
+ "Basic (I want a high level overview and I am not interested in the detail)"
2224
  msgstr ""
2225
 
2226
+ #: classes/Views/SetupWizard.php:361
2227
+ msgid "Geek (I want to know everything that is happening on my WordPress)"
2228
  msgstr ""
2229
 
2230
+ #: classes/Views/SetupWizard.php:364
2231
+ msgid ""
2232
+ "Note: You can change the WordPress logging level from the plugin’s settings "
2233
+ "anytime."
2234
  msgstr ""
2235
 
2236
+ #: classes/Views/SetupWizard.php:372 classes/Views/SetupWizard.php:373
2237
+ #: classes/Views/SetupWizard.php:438 classes/Views/SetupWizard.php:439
2238
+ #: classes/Views/SetupWizard.php:566 classes/Views/SetupWizard.php:567
2239
+ #: classes/Views/SetupWizard.php:686 classes/Views/SetupWizard.php:687
2240
+ msgid "Next"
2241
  msgstr ""
2242
 
2243
+ #: classes/Views/SetupWizard.php:412
2244
+ msgid "How long do you want to keep the data in the WordPress activity Log?"
2245
  msgstr ""
2246
 
2247
+ #: classes/Views/SetupWizard.php:417
2248
+ msgid "6 months (data older than 6 months will be deleted)"
2249
  msgstr ""
2250
 
2251
+ #: classes/Views/SetupWizard.php:422
2252
+ msgid "12 months (data older than 12 months will be deleted)"
2253
  msgstr ""
2254
 
2255
+ #: classes/Views/SetupWizard.php:427
2256
+ msgid "Keep all data."
2257
  msgstr ""
2258
 
2259
+ #: classes/Views/SetupWizard.php:430
2260
  msgid ""
2261
+ "Note: You can change the WordPress activity log retention settings at any "
2262
+ "time from the plugin settings later on."
2263
  msgstr ""
2264
 
2265
+ #: classes/Views/SetupWizard.php:448
2266
+ msgid ""
2267
+ "The plugin stores the data in the WordPress database in a very efficient "
2268
+ "way, though the more data you keep the more hard disk space it will consume. "
2269
+ "If you need need to retain a lot of data we would recommend you to <a href="
2270
+ "\"https://www.wpsecurityauditlog.com/premium-features/\" target=\"_blank"
2271
+ "\">upgrade to Premium</a> and use the Database tools to store the WordPress "
2272
+ "activity log in an external database."
2273
  msgstr ""
2274
 
2275
+ #: classes/Views/SetupWizard.php:514
2276
  msgid ""
2277
+ "By default only the users with administrator role can access the WordPress "
2278
+ "activity log. Would you like to allow any other user or users with a role to "
2279
+ "access the WordPress activity log?"
2280
  msgstr ""
2281
 
2282
+ #: classes/Views/SetupWizard.php:530 classes/Views/SetupWizard.php:623
2283
+ msgid "Usernames: "
2284
  msgstr ""
2285
 
2286
+ #: classes/Views/SetupWizard.php:538 classes/Views/SetupWizard.php:642
2287
+ msgid "Roles: "
 
 
2288
  msgstr ""
2289
 
2290
+ #: classes/Views/SetupWizard.php:559
2291
+ msgid ""
2292
+ "Note: you can change the WordPress activity log privileges settings at any "
2293
+ "time from the plugin settings."
2294
  msgstr ""
2295
 
2296
+ #: classes/Views/SetupWizard.php:573
2297
  msgid ""
2298
+ "The WordPress activity log contains sensitive data such as who logged in, "
2299
+ "from where, when, and what they did."
2300
  msgstr ""
2301
 
2302
+ #: classes/Views/SetupWizard.php:618
2303
+ msgid ""
2304
+ "The plugin will keep a log of everything that happens on your WordPress "
2305
+ "website. If you would like to exclude a particular user, users with a role "
2306
+ "or an IP address from the log specify them below. If not just click the Next "
2307
+ "button."
2308
  msgstr ""
2309
 
2310
+ #: classes/Views/SetupWizard.php:661
2311
+ msgid "IP Address: "
 
 
2312
  msgstr ""
2313
 
2314
+ #: classes/Views/SetupWizard.php:679
2315
+ msgid "Note: You can change these exclusions anytime from the plugin settings."
2316
  msgstr ""
2317
 
2318
+ #: classes/Views/SetupWizard.php:693
2319
  msgid ""
2320
+ "The WordPress activity log contains sensitive data such as who logged in, "
2321
+ "from where, when and what they did."
2322
  msgstr ""
2323
 
2324
+ #: classes/Views/SetupWizard.php:726
2325
+ msgid ""
2326
+ "Your plugin is all set and it is ready to start keeping a record of "
2327
+ "everything that is happening on your WordPress in a WordPress activity log."
2328
  msgstr ""
2329
 
2330
+ #: classes/Views/SetupWizard.php:727
2331
+ msgid "Below are a few useful links you might need to refer to:"
 
 
2332
  msgstr ""
2333
 
2334
+ #: classes/Views/SetupWizard.php:732
2335
+ msgid "Getting started with the WP Security Audit Log plugin"
2336
  msgstr ""
2337
 
2338
+ #: classes/Views/SetupWizard.php:737
2339
+ msgid "Knowledge Base & Support Documents"
 
 
2340
  msgstr ""
2341
 
2342
+ #: classes/Views/SetupWizard.php:742
2343
+ msgid "Benefits of keeping a WordPress activity log"
2344
  msgstr ""
2345
 
2346
+ #: classes/Views/SetupWizard.php:747
2347
  msgid ""
2348
+ "We trust this plugin meets all your activity log requirements. Should you "
2349
+ "encounter any problems, have feature requests or would like to share some "
2350
+ "feedback, <a href=\"https://www.wpsecurityauditlog.com/contact/\" target="
2351
+ "\"_blank\">please get in touch!</a>"
2352
  msgstr ""
2353
 
2354
+ #: classes/Views/ToggleAlerts.php:27 classes/Views/ToggleAlerts.php:41
2355
+ msgid "Enable/Disable Events"
2356
  msgstr ""
2357
 
2358
+ #: classes/Views/ToggleAlerts.php:184
2359
+ msgid "Log Level: "
 
 
2360
  msgstr ""
2361
 
2362
+ #: classes/Views/ToggleAlerts.php:189
2363
+ msgid "Basic"
2364
  msgstr ""
2365
 
2366
+ #: classes/Views/ToggleAlerts.php:194
2367
+ msgid "Geek"
 
 
2368
  msgstr ""
2369
 
2370
+ #: classes/Views/ToggleAlerts.php:197
2371
+ msgid "Custom"
2372
  msgstr ""
2373
 
2374
+ #: classes/Views/ToggleAlerts.php:201
2375
  msgid ""
2376
+ "Use the Log level drop down menu above to use one of our preset log levels. "
2377
+ "Alternatively you can enable or disable any of the individual events from "
2378
+ "the below tabs. Refer to <a href=\"https://www.wpsecurityauditlog.com/"
2379
+ "support-documentation/list-wordpress-audit-trail-alerts/\" target=\"_blank"
2380
+ "\">the complete list of WordPress activity log event IDs</a> for reference "
2381
+ "on all the events the plugin can keep a log of."
2382
  msgstr ""
2383
 
2384
+ #: classes/Views/ToggleAlerts.php:209 defaults.php:485
2385
+ msgid "Third Party Plugins"
2386
  msgstr ""
2387
 
2388
+ #: classes/Views/ToggleAlerts.php:212
2389
+ msgid "Visitor Events"
 
2390
  msgstr ""
2391
 
2392
+ #: classes/Views/ToggleAlerts.php:229 classes/Views/ToggleAlerts.php:261
2393
+ #: defaults.php:265
2394
+ msgid "Custom Post Types"
2395
  msgstr ""
2396
 
2397
+ #: classes/Views/ToggleAlerts.php:229 classes/Views/ToggleAlerts.php:261
2398
+ #: defaults.php:305
2399
+ msgid "Pages"
2400
  msgstr ""
2401
 
2402
+ #: classes/Views/ToggleAlerts.php:264 classes/Views/ToggleAlerts.php:271
2403
+ #: classes/Views/ToggleAlerts.php:329 defaults.php:489
2404
+ msgid "BBPress Forum"
2405
  msgstr ""
2406
 
2407
+ #: classes/Views/ToggleAlerts.php:265 classes/Views/ToggleAlerts.php:278
2408
+ #: classes/Views/ToggleAlerts.php:342 defaults.php:563
2409
+ msgid "WooCommerce"
2410
  msgstr ""
2411
 
2412
+ #: classes/Views/ToggleAlerts.php:266 classes/Views/ToggleAlerts.php:285
2413
+ #: classes/Views/ToggleAlerts.php:342 classes/Views/ToggleAlerts.php:350
2414
+ #: defaults.php:518
2415
+ msgid "WooCommerce Products"
2416
  msgstr ""
2417
 
2418
+ #: classes/Views/ToggleAlerts.php:267 classes/Views/ToggleAlerts.php:292
2419
+ #: classes/Views/ToggleAlerts.php:357 defaults.php:613
2420
+ msgid "Yoast SEO"
2421
  msgstr ""
2422
 
2423
+ #: classes/Views/ToggleAlerts.php:268 classes/Views/ToggleAlerts.php:301
2424
+ #: classes/Views/ToggleAlerts.php:370 defaults.php:466
2425
+ msgid "MultiSite"
2426
  msgstr ""
2427
 
2428
+ #: classes/Views/ToggleAlerts.php:317
2429
+ msgid "Code"
2430
  msgstr ""
2431
 
2432
+ #: classes/Views/ToggleAlerts.php:319 classes/WidgetManager.php:83
2433
+ msgid "Description"
2434
  msgstr ""
2435
 
2436
+ #: classes/Views/ToggleAlerts.php:322 classes/Views/ToggleAlerts.php:482
2437
+ #: classes/Views/ToggleAlerts.php:610
2438
+ msgid "File Changes"
2439
  msgstr ""
2440
 
2441
+ #: classes/Views/ToggleAlerts.php:323 defaults.php:196
2442
+ msgid "Content"
2443
  msgstr ""
2444
 
2445
+ #: classes/Views/ToggleAlerts.php:326
2446
  msgid ""
2447
+ "<strong>Note:</strong> Post refers to any type of content, i.e. blog post, "
2448
+ "page or a post with a custom post type."
 
 
 
2449
  msgstr ""
2450
 
2451
+ #: classes/Views/ToggleAlerts.php:333
2452
  msgid ""
2453
+ "The plugin BBPress is not installed on your website so these events have "
2454
+ "been disabled."
2455
  msgstr ""
2456
 
2457
+ #: classes/Views/ToggleAlerts.php:339
2458
+ msgid "Forums"
2459
  msgstr ""
2460
 
2461
+ #: classes/Views/ToggleAlerts.php:346
2462
+ msgid ""
2463
+ "The plugin WooCommerce is not installed on your website so these events have "
2464
+ "been disabled."
2465
  msgstr ""
2466
 
2467
+ #: classes/Views/ToggleAlerts.php:353
2468
+ msgid "Products"
2469
  msgstr ""
2470
 
2471
+ #: classes/Views/ToggleAlerts.php:361
2472
+ msgid ""
2473
+ "The plugin Yoast SEO is not installed on your website so these events have "
2474
+ "been disabled."
2475
  msgstr ""
2476
 
2477
+ #: classes/Views/ToggleAlerts.php:367
2478
+ msgid "Post Changes"
2479
  msgstr ""
2480
 
2481
+ #: classes/Views/ToggleAlerts.php:374
2482
  msgid ""
2483
+ "Your website is a single site so the multisite events have been disabled."
2484
  msgstr ""
2485
 
2486
+ #: classes/Views/ToggleAlerts.php:380 defaults.php:170
2487
+ msgid "User Profiles"
2488
  msgstr ""
2489
 
2490
+ #: classes/Views/ToggleAlerts.php:383 defaults.php:152
2491
+ msgid "Other User Activity"
 
 
2492
  msgstr ""
2493
 
2494
+ #: classes/Views/ToggleAlerts.php:386
2495
+ msgid "Logins & Logouts"
2496
  msgstr ""
2497
 
2498
+ #: classes/Views/ToggleAlerts.php:403
2499
+ msgid "Not Implemented"
 
 
2500
  msgstr ""
2501
 
2502
+ #: classes/Views/ToggleAlerts.php:406
2503
+ msgid "Not Available"
2504
  msgstr ""
2505
 
2506
+ #: classes/Views/ToggleAlerts.php:416
2507
+ msgid "User Sessions"
2508
  msgstr ""
2509
 
2510
+ #: classes/Views/ToggleAlerts.php:418
2511
+ msgid "Files"
2512
  msgstr ""
2513
 
2514
+ #: classes/Views/ToggleAlerts.php:422
2515
+ msgid "Post Settings"
 
 
2516
  msgstr ""
2517
 
2518
+ #: classes/Views/ToggleAlerts.php:424
2519
+ msgid "Tags"
2520
  msgstr ""
2521
 
2522
+ #: classes/Views/ToggleAlerts.php:426 classes/Views/ToggleAlerts.php:442
2523
+ msgid "Categories"
 
 
2524
  msgstr ""
2525
 
2526
+ #: classes/Views/ToggleAlerts.php:428
2527
+ msgid "Custom Fields"
2528
  msgstr ""
2529
 
2530
+ #: classes/Views/ToggleAlerts.php:430
2531
+ msgid "Sites"
 
2532
  msgstr ""
2533
 
2534
+ #: classes/Views/ToggleAlerts.php:434
2535
+ msgid "Topics"
2536
  msgstr ""
2537
 
2538
+ #: classes/Views/ToggleAlerts.php:436
2539
+ msgid "Product Admin"
 
 
2540
  msgstr ""
2541
 
2542
+ #: classes/Views/ToggleAlerts.php:438
2543
+ msgid "Product Attribute"
2544
  msgstr ""
2545
 
2546
+ #: classes/Views/ToggleAlerts.php:440
2547
+ msgid "Store Admin"
 
 
2548
  msgstr ""
2549
 
2550
+ #: classes/Views/ToggleAlerts.php:444
2551
+ msgid "Attributes"
2552
  msgstr ""
2553
 
2554
+ #: classes/Views/ToggleAlerts.php:446
2555
+ msgid "Coupons"
2556
  msgstr ""
2557
 
2558
+ #: classes/Views/ToggleAlerts.php:448
2559
+ msgid "Orders"
2560
  msgstr ""
2561
 
2562
+ #: classes/Views/ToggleAlerts.php:450
2563
+ msgid "Website Changes"
2564
  msgstr ""
2565
 
2566
+ #: classes/Views/ToggleAlerts.php:452
2567
+ msgid "Plugin Settings"
2568
  msgstr ""
2569
 
2570
+ #: classes/Views/ToggleAlerts.php:458
2571
+ msgid "File Changes Scanning"
2572
  msgstr ""
2573
 
2574
+ #: classes/Views/ToggleAlerts.php:514 classes/Views/ToggleAlerts.php:547
2575
  msgid ""
2576
+ "Capture 404 requests to file (the log file are created in the /wp-content/"
2577
+ "uploads/wp-security-audit-log/404s/ directory)"
2578
  msgstr ""
2579
 
2580
+ #: classes/Views/ToggleAlerts.php:522 classes/Views/ToggleAlerts.php:555
2581
+ msgid "Purge log files older than one month"
2582
  msgstr ""
2583
 
2584
+ #: classes/Views/ToggleAlerts.php:527
2585
  msgid ""
2586
+ "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
2587
+ "to non-existing pages from the same IP address. Increase the value in this "
2588
+ "setting to the desired amount to keep a log of more or less requests."
2589
  msgstr ""
2590
 
2591
+ #: classes/Views/ToggleAlerts.php:532 classes/Views/ToggleAlerts.php:565
2592
+ msgid "Record the referrer that generated the 404 error."
2593
  msgstr ""
2594
 
2595
+ #: classes/Views/ToggleAlerts.php:560
2596
+ msgid ""
2597
+ "Number of 404 Requests to Log. By default the plugin keeps up to 99 requests "
2598
+ "to non-existing pages from the same IP address. Increase the value in this "
2599
+ "setting to the desired amount to keep a log of more or less requests. Note "
2600
+ "that by increasing this value to a high number, should your website be "
2601
+ "scanned the plugin will consume more resources to log all the requests."
2602
  msgstr ""
2603
 
2604
+ #: classes/Views/ToggleAlerts.php:577 classes/Views/ToggleAlerts.php:590
2605
+ msgid ""
2606
+ "Number of login attempts to log. Enter 0 to log all failed login attempts. "
2607
+ "(By default the plugin only logs up to 10 failed login because the process "
2608
+ "can be very resource intensive in case of a brute force attack)"
2609
  msgstr ""
2610
 
2611
+ #: classes/Views/ToggleAlerts.php:603
2612
  msgid ""
2613
+ "Log all stock changes. Disable this setting to only keep a log of stock "
2614
+ "changes done manually via the WooCommerce dashboard. Therefore automated "
2615
+ "stock changes typically done via customers placing orders or via other "
2616
+ "plugins will not be logged."
2617
  msgstr ""
2618
 
2619
+ #: classes/Views/ToggleAlerts.php:625
2620
+ msgid "Configure the file integrity scan settings."
2621
  msgstr ""
2622
 
2623
+ #: classes/Views/ToggleAlerts.php:640
2624
+ msgid ""
2625
+ "The plugin also keeps a log of some events that website visitors (non-logged "
2626
+ "in users) do because it is typically required by site admins. You can "
2627
+ "disable these events from here:"
2628
  msgstr ""
2629
 
2630
+ #: classes/Views/ToggleAlerts.php:642
2631
+ msgid "Enable website visitors events"
2632
  msgstr ""
2633
 
2634
+ #: classes/Views/ToggleAlerts.php:648
2635
+ msgid "Enable"
2636
  msgstr ""
2637
 
2638
+ #: classes/Views/ToggleAlerts.php:653
2639
+ msgid ""
2640
+ "Below is the list of the events which are disabled when the above option is "
2641
+ "disabled:"
2642
  msgstr ""
2643
 
2644
+ #: classes/Views/ToggleAlerts.php:668
2645
+ msgid "Save Changes"
2646
  msgstr ""
2647
 
2648
+ #: classes/Views/ToggleAlerts.php:675
2649
+ msgid "Log Level Updated"
2650
  msgstr ""
2651
 
2652
+ #. translators: Alerts log level.
2653
+ #: classes/Views/ToggleAlerts.php:679
2654
+ #, php-format
2655
+ msgid "The %s log level has been successfully loaded and applied."
2656
  msgstr ""
2657
 
2658
+ #: classes/Views/ToggleAlerts.php:683
2659
+ msgid "OK"
2660
  msgstr ""
2661
 
2662
+ #: classes/Views/ToggleAlerts.php:698
2663
+ msgid "Enable File Integrity Scanner"
2664
  msgstr ""
2665
 
2666
+ #: classes/Views/ToggleAlerts.php:700
2667
+ msgid ""
2668
+ "The file integrity scanner is switched off. To enable this event it has to "
2669
+ "be switched on."
2670
  msgstr ""
2671
 
2672
+ #: classes/Views/ToggleAlerts.php:704
2673
+ msgid "SWITCH ON"
2674
  msgstr ""
2675
 
2676
+ #: classes/Views/ToggleAlerts.php:705
2677
+ msgid "DISABLE EVENT"
2678
  msgstr ""
2679
 
2680
+ #: classes/WidgetManager.php:55
2681
+ msgid "Latest Events"
 
 
2682
  msgstr ""
2683
 
2684
+ #: classes/WidgetManager.php:77
2685
+ msgid "No alerts found."
2686
  msgstr ""
2687
 
2688
+ #: defaults.php:73
2689
+ msgid "Fatal run-time error."
 
 
2690
  msgstr ""
2691
 
2692
+ #: defaults.php:77
2693
+ msgid "Run-time warning (non-fatal error)."
2694
  msgstr ""
2695
 
2696
+ #: defaults.php:81
2697
+ msgid "Compile-time parse error."
2698
  msgstr ""
2699
 
2700
+ #: defaults.php:85
2701
+ msgid "Run-time notice."
2702
  msgstr ""
2703
 
2704
+ #: defaults.php:89
2705
+ msgid "Fatal error that occurred during startup."
2706
  msgstr ""
2707
 
2708
+ #: defaults.php:93
2709
+ msgid "Warnings that occurred during startup."
2710
  msgstr ""
2711
 
2712
+ #: defaults.php:97
2713
+ msgid "Fatal compile-time error."
2714
  msgstr ""
2715
 
2716
+ #: defaults.php:101
2717
+ msgid "Compile-time warning."
2718
  msgstr ""
2719
 
2720
+ #: defaults.php:105
2721
+ msgid "User-generated error message."
2722
  msgstr ""
2723
 
2724
+ #: defaults.php:109
2725
+ msgid "User-generated warning message."
 
 
2726
  msgstr ""
2727
 
2728
+ #: defaults.php:113
2729
+ msgid "User-generated notice message."
2730
  msgstr ""
2731
 
2732
+ #: defaults.php:117
2733
+ msgid "Non-standard/optimal code warning."
2734
  msgstr ""
2735
 
2736
+ #: defaults.php:121
2737
+ msgid "Catchable fatal error."
2738
  msgstr ""
2739
 
2740
+ #: defaults.php:125
2741
+ msgid "Run-time deprecation notices."
 
2742
  msgstr ""
2743
 
2744
+ #: defaults.php:129
2745
+ msgid "Run-time user deprecation notices."
2746
  msgstr ""
2747
 
2748
+ #: defaults.php:134
2749
+ msgid "Critical, high-impact messages."
 
 
2750
  msgstr ""
2751
 
2752
+ #: defaults.php:138
2753
+ msgid "Debug informational messages."
2754
  msgstr ""
2755
 
2756
+ #: defaults.php:148
2757
+ msgid "Users Profiles & Activity"
 
 
2758
  msgstr ""
2759
 
2760
+ #: defaults.php:153
2761
+ msgid "User logged in"
2762
  msgstr ""
2763
 
2764
+ #: defaults.php:153
2765
+ msgid "Successfully logged in."
 
 
2766
  msgstr ""
2767
 
2768
+ #: defaults.php:154
2769
+ msgid "User logged out"
2770
  msgstr ""
2771
 
2772
+ #: defaults.php:154
2773
+ msgid "Successfully logged out."
2774
  msgstr ""
2775
 
2776
+ #: defaults.php:155
2777
+ msgid "Login failed"
2778
  msgstr ""
2779
 
2780
+ #: defaults.php:155
2781
+ msgid "%Attempts% failed login(s) detected."
2782
  msgstr ""
2783
 
2784
+ #: defaults.php:156
2785
+ msgid "Login failed / non existing user"
2786
  msgstr ""
2787
 
2788
+ #: defaults.php:156
2789
  msgid ""
2790
+ "%Attempts% failed login(s) detected using non existing user. %LogFileText%"
2791
  msgstr ""
2792
 
2793
+ #: defaults.php:157
2794
+ msgid "Login blocked"
2795
  msgstr ""
2796
 
2797
+ #: defaults.php:157
2798
+ msgid ""
2799
+ "Blocked from logging in because the same WordPress user is logged in from "
2800
+ "%ClientIP%."
2801
  msgstr ""
2802
 
2803
+ #: defaults.php:158
2804
+ msgid "User logged in with existing session(s)"
2805
  msgstr ""
2806
 
2807
+ #: defaults.php:158
2808
+ msgid ""
2809
+ "Successfully logged in. Another session from %IPAddress% for this user "
2810
+ "already exist."
2811
  msgstr ""
2812
 
2813
+ #: defaults.php:159
2814
+ msgid "User logged out all other sessions with the same username"
2815
  msgstr ""
2816
 
2817
+ #: defaults.php:159
2818
+ msgid "Logged out all other sessions with the same username."
 
 
2819
  msgstr ""
2820
 
2821
+ #: defaults.php:160
2822
+ msgid "User session destroyed and logged out"
2823
  msgstr ""
2824
 
2825
+ #: defaults.php:160
2826
+ msgid "Logged out session %TargetSessionID% which belonged to %TargetUserName%"
2827
  msgstr ""
2828
 
2829
+ #: defaults.php:161
2830
+ msgid "User uploaded file from Uploads directory"
2831
  msgstr ""
2832
 
2833
+ #: defaults.php:161
2834
+ msgid "Uploaded the file %FileName% in %FilePath%."
2835
  msgstr ""
2836
 
2837
+ #: defaults.php:162
2838
+ msgid "User deleted file from Uploads directory"
2839
  msgstr ""
2840
 
2841
+ #: defaults.php:162
2842
+ msgid "Deleted the file %FileName% from %FilePath%."
2843
  msgstr ""
2844
 
2845
+ #: defaults.php:163
2846
+ msgid "User requests non-existing pages (404 Error Pages)"
2847
  msgstr ""
2848
 
2849
+ #: defaults.php:163
2850
  msgid ""
2851
+ "Has requested a non existing page (404 Error Pages) %Attempts% %Msg%. "
2852
+ "%LinkFile%%URL%"
 
 
 
2853
  msgstr ""
2854
 
2855
+ #: defaults.php:164
2856
+ msgid "Website Visitor User requests non-existing pages (404 Error Pages)"
2857
  msgstr ""
2858
 
2859
+ #: defaults.php:164
2860
+ msgid ""
2861
+ "Website Visitor Has requested a non existing page (404 Error Pages) %Attempts"
2862
+ "% %Msg%. %LinkFile%%URL%"
2863
  msgstr ""
2864
 
2865
+ #: defaults.php:171
2866
+ msgid "New user was created on WordPress"
2867
  msgstr ""
2868
 
2869
+ #: defaults.php:171
2870
+ msgid ""
2871
+ "A new user %NewUserData->Username% was created with role of %NewUserData-"
2872
+ ">Roles%."
2873
  msgstr ""
2874
 
2875
+ #: defaults.php:172
2876
+ msgid "User created another WordPress user"
2877
  msgstr ""
2878
 
2879
+ #: defaults.php:172
2880
+ msgid ""
2881
+ "%UserChanger% created a new user %NewUserData->Username% with the role of "
2882
+ "%NewUserData->Roles%."
2883
  msgstr ""
2884
 
2885
+ #: defaults.php:173
2886
+ msgid "The role of a user was changed by another WordPress user"
2887
  msgstr ""
2888
 
2889
+ #: defaults.php:173
2890
+ msgid ""
2891
+ "Changed the role of the user %TargetUsername% from %OldRole% to %NewRole%"
2892
+ "%multisite_text%."
2893
  msgstr ""
2894
 
2895
+ #: defaults.php:174
2896
+ msgid "User has changed his or her password"
2897
  msgstr ""
2898
 
2899
+ #: defaults.php:174
2900
+ msgid "Changed the password."
2901
  msgstr ""
2902
 
2903
+ #: defaults.php:175
2904
+ msgid "User changed another user's password"
2905
  msgstr ""
2906
 
2907
+ #: defaults.php:175
2908
+ msgid ""
2909
+ "Changed the password for the user %TargetUserData->Username% with the role "
2910
+ "of %TargetUserData->Roles%."
2911
  msgstr ""
2912
 
2913
+ #: defaults.php:176
2914
+ msgid "User changed his or her email address"
2915
  msgstr ""
2916
 
2917
+ #: defaults.php:176
2918
+ msgid "Changed the email address from %OldEmail% to %NewEmail%."
2919
  msgstr ""
2920
 
2921
+ #: defaults.php:177
2922
+ msgid "User changed another user's email address"
2923
  msgstr ""
2924
 
2925
+ #: defaults.php:177
2926
  msgid ""
2927
+ "Changed the email address of the user %TargetUsername% from %OldEmail% to "
2928
+ "%NewEmail%."
2929
  msgstr ""
2930
 
2931
+ #: defaults.php:178
2932
+ msgid "User was deleted by another user"
2933
  msgstr ""
2934
 
2935
+ #: defaults.php:178
2936
+ msgid ""
2937
+ "Deleted the user %TargetUserData->Username% with the role of %TargetUserData-"
2938
+ ">Roles%."
2939
  msgstr ""
2940
 
2941
+ #: defaults.php:179
2942
+ msgid "User opened the profile page of another user"
2943
  msgstr ""
2944
 
2945
+ #: defaults.php:179
2946
+ msgid "%UserChanger% opened the profile page of the user %TargetUsername%."
2947
  msgstr ""
2948
 
2949
+ #: defaults.php:180
2950
+ msgid "User updated a custom field value for a user"
2951
  msgstr ""
2952
 
2953
+ #: defaults.php:180
2954
  msgid ""
2955
+ "Changed the value of the custom field %custom_field_name%%ReportText% for "
2956
+ "the user %TargetUsername%.%ChangeText%"
2957
  msgstr ""
2958
 
2959
+ #: defaults.php:181
2960
+ msgid "User created a custom field value for a user"
2961
  msgstr ""
2962
 
2963
+ #: defaults.php:181
2964
  msgid ""
2965
+ "Created the value of the custom field %custom_field_name% with %new_value% "
2966
+ "for the user %TargetUsername%."
2967
  msgstr ""
2968
 
2969
+ #: defaults.php:182
2970
+ msgid "User changed first name for a user"
2971
  msgstr ""
2972
 
2973
+ #: defaults.php:182
2974
+ msgid ""
2975
+ "Changed the first name of the user %TargetUsername% from %old_firstname% to "
2976
+ "%new_firstname%"
2977
  msgstr ""
2978
 
2979
+ #: defaults.php:183
2980
+ msgid "User changed last name for a user"
2981
  msgstr ""
2982
 
2983
+ #: defaults.php:183
2984
+ msgid ""
2985
+ "Changed the last name of the user %TargetUsername% from %old_lastname% to "
2986
+ "%new_lastname%"
2987
  msgstr ""
2988
 
2989
+ #: defaults.php:184
2990
+ msgid "User changed nickname for a user"
2991
  msgstr ""
2992
 
2993
+ #: defaults.php:184
2994
+ msgid ""
2995
+ "Changed the nickname of the user %TargetUsername% from %old_nickname% to "
2996
+ "%new_nickname%"
2997
  msgstr ""
2998
 
2999
+ #: defaults.php:185
3000
+ msgid "User changed the display name for a user"
3001
  msgstr ""
3002
 
3003
+ #: defaults.php:185
3004
+ msgid ""
3005
+ "Changed the Display name publicly of user %TargetUsername% from "
3006
+ "%old_displayname% to %new_displayname%"
3007
  msgstr ""
3008
 
3009
+ #: defaults.php:192
3010
+ msgid "Content & Comments"
3011
  msgstr ""
3012
 
3013
+ #: defaults.php:197
3014
+ msgid "User created a new post and saved it as draft"
3015
  msgstr ""
3016
 
3017
+ #: defaults.php:197
3018
+ msgid ""
3019
+ "Created a new %PostType% titled %PostTitle% and saved it as draft. "
3020
+ "%EditorLinkPost%."
3021
  msgstr ""
3022
 
3023
+ #: defaults.php:198
3024
+ msgid "User published a post"
3025
  msgstr ""
3026
 
3027
+ #: defaults.php:198
3028
  msgid ""
3029
+ "Published a %PostType% titled %PostTitle%. URL is %PostUrl%. %EditorLinkPost"
3030
+ "%."
3031
  msgstr ""
3032
 
3033
+ #: defaults.php:199
3034
+ msgid "User modified a post"
3035
  msgstr ""
3036
 
3037
+ #: defaults.php:199
3038
+ msgid ""
3039
+ "Modified the %PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
3040
+ "%EditorLinkPost%."
3041
  msgstr ""
3042
 
3043
+ #: defaults.php:200
3044
+ msgid "User permanently deleted a post from the trash"
3045
  msgstr ""
3046
 
3047
+ #: defaults.php:200
3048
+ msgid ""
3049
+ "Permanently deleted the %PostType% titled %PostTitle%. URL was %PostUrl%."
3050
  msgstr ""
3051
 
3052
+ #: defaults.php:201
3053
+ msgid "User moved a post to the trash"
3054
  msgstr ""
3055
 
3056
+ #: defaults.php:201
3057
+ msgid ""
3058
+ "Moved the %PostStatus% %PostType% titled %PostTitle% to trash. URL is "
3059
+ "%PostUrl%."
3060
  msgstr ""
3061
 
3062
+ #: defaults.php:202
3063
+ msgid "User restored a post from trash"
3064
  msgstr ""
3065
 
3066
+ #: defaults.php:202
3067
+ msgid ""
3068
+ "The %PostStatus% %PostType% titled %PostTitle% has been restored from trash. "
3069
+ "URL is: %PostUrl%. %EditorLinkPost%."
3070
  msgstr ""
3071
 
3072
+ #: defaults.php:203
3073
+ msgid "User changed post URL"
3074
  msgstr ""
3075
 
3076
+ #: defaults.php:203
3077
+ msgid ""
3078
+ "Changed the URL of the %PostStatus% %PostType% titled %PostTitle%%ReportText"
3079
+ "%.%ChangeText% %EditorLinkPost%."
3080
  msgstr ""
3081
 
3082
+ #: defaults.php:204
3083
+ msgid "User changed post author"
3084
  msgstr ""
3085
 
3086
+ #: defaults.php:204
3087
+ msgid ""
3088
+ "Changed the author of the %PostStatus% %PostType% titled %PostTitle% from "
3089
+ "%OldAuthor% to %NewAuthor%. URL is: %PostUrl%. %EditorLinkPost%."
3090
+ msgstr ""
3091
+
3092
+ #: defaults.php:205
3093
+ msgid "User changed post status"
3094
+ msgstr ""
3095
+
3096
+ #: defaults.php:205
3097
+ msgid ""
3098
+ "Changed the status of the %PostType% titled %PostTitle% from %OldStatus% to "
3099
+ "%NewStatus%. URL is: %PostUrl%. %EditorLinkPost%."
3100
+ msgstr ""
3101
+
3102
+ #: defaults.php:206
3103
+ msgid "User changed the visibility of a post"
3104
+ msgstr ""
3105
+
3106
+ #: defaults.php:206
3107
+ msgid ""
3108
+ "Changed the visibility of the %PostStatus% %PostType% titled %PostTitle% "
3109
+ "from %OldVisibility% to %NewVisibility%. URL is: %PostUrl%. %EditorLinkPost%."
3110
+ msgstr ""
3111
+
3112
+ #: defaults.php:207
3113
+ msgid "User changed the date of a post"
3114
+ msgstr ""
3115
+
3116
+ #: defaults.php:207
3117
+ msgid ""
3118
+ "Changed the date of the %PostStatus% %PostType% titled %PostTitle% from "
3119
+ "%OldDate% to %NewDate%. URL is: %PostUrl%. %EditorLinkPost%."
3120
+ msgstr ""
3121
+
3122
+ #: defaults.php:208
3123
+ msgid "User changed the parent of a page"
3124
+ msgstr ""
3125
+
3126
+ #: defaults.php:208
3127
+ msgid ""
3128
+ "Changed the parent of the %PostStatus% %PostType% titled %PostTitle% from "
3129
+ "%OldParentName% to %NewParentName%. %EditorLinkPost%."
3130
+ msgstr ""
3131
+
3132
+ #: defaults.php:209
3133
+ msgid "User changed the template of a page"
3134
+ msgstr ""
3135
+
3136
+ #: defaults.php:209
3137
+ msgid ""
3138
+ "Changed the template of the %PostStatus% %PostType% titled %PostTitle% from "
3139
+ "%OldTemplate% to %NewTemplate%. %EditorLinkPost%."
3140
+ msgstr ""
3141
+
3142
+ #: defaults.php:210
3143
+ msgid "User set a post as sticky"
3144
+ msgstr ""
3145
+
3146
+ #: defaults.php:210
3147
+ msgid ""
3148
+ "Set the post %PostTitle% as Sticky. Post URL is %PostUrl%. %EditorLinkPost%."
3149
+ msgstr ""
3150
+
3151
+ #: defaults.php:211
3152
+ msgid "User removed post from sticky"
3153
+ msgstr ""
3154
+
3155
+ #: defaults.php:211
3156
+ msgid "Removed the post %PostTitle% from Sticky. %EditorLinkPost%."
3157
+ msgstr ""
3158
+
3159
+ #: defaults.php:212
3160
+ msgid "User modified the content of a post"
3161
+ msgstr ""
3162
+
3163
+ #: defaults.php:212
3164
+ msgid ""
3165
+ "Modified the content of the %PostStatus% %PostType% titled %PostTitle%. Post "
3166
+ "URL is %PostUrl%. %RevisionLink% %EditorLinkPost%."
3167
+ msgstr ""
3168
+
3169
+ #: defaults.php:213
3170
+ msgid "User submitted a post for review"
3171
+ msgstr ""
3172
+
3173
+ #: defaults.php:213
3174
+ msgid ""
3175
+ "Submitted the %PostType% titled %PostTitle% for review. URL is: %PostUrl%. "
3176
+ "%EditorLinkPost%."
3177
+ msgstr ""
3178
+
3179
+ #: defaults.php:214
3180
+ msgid "User scheduled a post"
3181
+ msgstr ""
3182
+
3183
+ #: defaults.php:214
3184
+ msgid ""
3185
+ "Scheduled the %PostType% titled %PostTitle% to be published on "
3186
+ "%PublishingDate%. URL is: %PostUrl%. %EditorLinkPost%."
3187
+ msgstr ""
3188
+
3189
+ #: defaults.php:215
3190
+ msgid "User changed title of a post"
3191
+ msgstr ""
3192
+
3193
+ #: defaults.php:215
3194
+ msgid ""
3195
+ "Changed the title of the %PostStatus% %PostType% from %OldTitle% to %NewTitle"
3196
+ "%. URL is: %PostUrl%. %EditorLinkPost%."
3197
+ msgstr ""
3198
+
3199
+ #: defaults.php:216
3200
+ msgid "User opened a post in the editor"
3201
+ msgstr ""
3202
+
3203
+ #: defaults.php:216
3204
+ msgid ""
3205
+ "Opened the %PostStatus% %PostType% titled %PostTitle% in the editor. URL is: "
3206
+ "%PostUrl%. %EditorLinkPost%."
3207
+ msgstr ""
3208
+
3209
+ #: defaults.php:217
3210
+ msgid "User viewed a post"
3211
+ msgstr ""
3212
+
3213
+ #: defaults.php:217
3214
+ msgid ""
3215
+ "Viewed the %PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
3216
+ "%EditorLinkPost%."
3217
+ msgstr ""
3218
+
3219
+ #: defaults.php:218
3220
+ msgid "A plugin modified a post"
3221
+ msgstr ""
3222
+
3223
+ #: defaults.php:218
3224
+ msgid ""
3225
+ "Plugin modified the %PostStatus% %PostType% titled %PostTitle% of type "
3226
+ "%PostType%. URL is: %PostUrl%. %EditorLinkPost%."
3227
+ msgstr ""
3228
+
3229
+ #: defaults.php:219
3230
+ msgid "User disabled Comments/Trackbacks and Pingbacks in a post"
3231
+ msgstr ""
3232
+
3233
+ #: defaults.php:219
3234
+ msgid ""
3235
+ "Disabled %Type% on the %PostStatus% %PostType% titled %PostTitle%. URL is: "
3236
+ "%PostUrl%. %EditorLinkPost%."
3237
+ msgstr ""
3238
+
3239
+ #: defaults.php:220
3240
+ msgid "User enabled Comments/Trackbacks and Pingbacks in a post"
3241
+ msgstr ""
3242
+
3243
+ #: defaults.php:220
3244
+ msgid ""
3245
+ "Enabled %Type% on the %PostStatus% %PostType% titled %PostTitle%. URL is: "
3246
+ "%PostUrl%. %EditorLinkPost%."
3247
+ msgstr ""
3248
+
3249
+ #: defaults.php:221
3250
+ msgid "User added post tag"
3251
+ msgstr ""
3252
+
3253
+ #: defaults.php:221
3254
+ msgid ""
3255
+ "Added the tag %tag% to the %PostStatus% post titled %PostTitle%. URL is: "
3256
+ "%PostUrl%. %EditorLinkPost%."
3257
+ msgstr ""
3258
+
3259
+ #: defaults.php:222
3260
+ msgid "User removed post tag"
3261
+ msgstr ""
3262
+
3263
+ #: defaults.php:222
3264
+ msgid ""
3265
+ "Removed the tag %tag% from the %PostStatus% post titled %PostTitle%. URL is: "
3266
+ "%PostUrl%. %EditorLinkPost%."
3267
+ msgstr ""
3268
+
3269
+ #: defaults.php:223
3270
+ msgid "User created new tag"
3271
+ msgstr ""
3272
+
3273
+ #: defaults.php:223
3274
+ msgid "Added a new tag called %TagName%. View the tag: %TagLink%."
3275
+ msgstr ""
3276
+
3277
+ #: defaults.php:224
3278
+ msgid "User deleted tag"
3279
+ msgstr ""
3280
+
3281
+ #: defaults.php:224
3282
+ msgid "Deleted the tag %TagName%."
3283
+ msgstr ""
3284
+
3285
+ #: defaults.php:225
3286
+ msgid "User renamed tag"
3287
+ msgstr ""
3288
+
3289
+ #: defaults.php:225
3290
+ msgid "Renamed a tag from %old_name% to %new_name%. View the tag: %TagLink%."
3291
+ msgstr ""
3292
+
3293
+ #: defaults.php:226
3294
+ msgid "User changed tag slug"
3295
+ msgstr ""
3296
+
3297
+ #: defaults.php:226
3298
+ msgid ""
3299
+ "Changed the slug of tag %tag% from %old_slug% to %new_slug%. View the tag: "
3300
+ "%TagLink%."
3301
+ msgstr ""
3302
+
3303
+ #: defaults.php:227
3304
+ msgid "User changed tag description"
3305
+ msgstr ""
3306
+
3307
+ #: defaults.php:227
3308
+ msgid ""
3309
+ "Changed the description of the tag %tag%%ReportText%.%ChangeText% View the "
3310
+ "tag: %TagLink%."
3311
+ msgstr ""
3312
+
3313
+ #: defaults.php:228
3314
+ msgid "User changed post category"
3315
+ msgstr ""
3316
+
3317
+ #: defaults.php:228
3318
+ msgid ""
3319
+ "Changed the category of the %PostStatus% %PostType% titled %PostTitle% from "
3320
+ "%OldCategories% to %NewCategories%. URL is: %PostUrl%. %EditorLinkPost%."
3321
+ msgstr ""
3322
+
3323
+ #: defaults.php:229
3324
+ msgid "User created new category"
3325
+ msgstr ""
3326
+
3327
+ #: defaults.php:229
3328
+ msgid ""
3329
+ "Created a new category called %CategoryName%. Category slug is %Slug%. "
3330
+ "%CategoryLink%."
3331
+ msgstr ""
3332
+
3333
+ #: defaults.php:230
3334
+ msgid "User deleted category"
3335
+ msgstr ""
3336
+
3337
+ #: defaults.php:230
3338
+ msgid ""
3339
+ "Deleted the %CategoryName% category. Category slug was %Slug%. %CategoryLink"
3340
+ "%."
3341
+ msgstr ""
3342
+
3343
+ #: defaults.php:231
3344
+ msgid "Changed the parent of a category"
3345
+ msgstr ""
3346
+
3347
+ #: defaults.php:231
3348
+ msgid ""
3349
+ "Changed the parent of the category %CategoryName% from %OldParent% to "
3350
+ "%NewParent%. %CategoryLink%."
3351
+ msgstr ""
3352
+
3353
+ #: defaults.php:232
3354
+ msgid "User changed category name"
3355
+ msgstr ""
3356
+
3357
+ #: defaults.php:232
3358
+ msgid "Changed the name of the category %old_name% to %new_name%."
3359
+ msgstr ""
3360
+
3361
+ #: defaults.php:233
3362
+ msgid "User changed category slug"
3363
+ msgstr ""
3364
+
3365
+ #: defaults.php:233
3366
+ msgid ""
3367
+ "Changed the slug of the category %CategoryName% from %old_slug% to %new_slug"
3368
+ "%."
3369
+ msgstr ""
3370
+
3371
+ #: defaults.php:234
3372
+ msgid "User created a custom field for a post"
3373
+ msgstr ""
3374
+
3375
+ #: defaults.php:234
3376
+ msgid ""
3377
+ "Created a new custom field called %MetaKey% with value %MetaValue% in the "
3378
+ "%PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
3379
+ "%EditorLinkPost%.<br>%MetaLink%."
3380
+ msgstr ""
3381
+
3382
+ #: defaults.php:235
3383
+ msgid "User updated a custom field value for a post"
3384
+ msgstr ""
3385
+
3386
+ #: defaults.php:235
3387
+ msgid ""
3388
+ "Modified the value of the custom field %MetaKey%%ReportText% in the "
3389
+ "%PostStatus% %PostType% titled %PostTitle%.%ChangeText% URL is: %PostUrl%. "
3390
+ "%EditorLinkPost%.<br>%MetaLink%."
3391
+ msgstr ""
3392
+
3393
+ #: defaults.php:236
3394
+ msgid "User deleted a custom field from a post"
3395
+ msgstr ""
3396
+
3397
+ #: defaults.php:236
3398
+ msgid ""
3399
+ "Deleted the custom field %MetaKey% with value %MetaValue% from %PostStatus% "
3400
+ "%PostType% titled %PostTitle%. URL is: %PostUrl%. %EditorLinkPost%."
3401
+ msgstr ""
3402
+
3403
+ #: defaults.php:237
3404
+ msgid "User updated a custom field name for a post"
3405
+ msgstr ""
3406
+
3407
+ #: defaults.php:237
3408
+ msgid ""
3409
+ "Changed the custom field's name from %MetaKeyOld% to %MetaKeyNew% in the "
3410
+ "%PostStatus% %PostType% titled %PostTitle%. URL is: %PostUrl%. "
3411
+ "%EditorLinkPost%.<br>%MetaLink%."
3412
+ msgstr ""
3413
+
3414
+ #: defaults.php:243
3415
+ msgid "Comments"
3416
+ msgstr ""
3417
+
3418
+ #: defaults.php:244
3419
+ msgid "User approved a comment"
3420
+ msgstr ""
3421
+
3422
+ #: defaults.php:244
3423
+ msgid ""
3424
+ "Approved the comment posted in response to the post %PostTitle% by %Author% "
3425
+ "on %CommentLink%."
3426
+ msgstr ""
3427
+
3428
+ #: defaults.php:245
3429
+ msgid "User unapproved a comment"
3430
+ msgstr ""
3431
+
3432
+ #: defaults.php:245
3433
+ msgid ""
3434
+ "Unapproved the comment posted in response to the post %PostTitle% by %Author"
3435
+ "% on %CommentLink%."
3436
+ msgstr ""
3437
+
3438
+ #: defaults.php:246
3439
+ msgid "User replied to a comment"
3440
+ msgstr ""
3441
+
3442
+ #: defaults.php:246
3443
+ msgid ""
3444
+ "Replied to the comment posted in response to the post %PostTitle% by %Author"
3445
+ "% on %CommentLink%."
3446
+ msgstr ""
3447
+
3448
+ #: defaults.php:247
3449
+ msgid "User edited a comment"
3450
+ msgstr ""
3451
+
3452
+ #: defaults.php:247
3453
+ msgid ""
3454
+ "Edited a comment posted in response to the post %PostTitle% by %Author% on "
3455
+ "%CommentLink%."
3456
+ msgstr ""
3457
+
3458
+ #: defaults.php:248
3459
+ msgid "User marked a comment as Spam"
3460
+ msgstr ""
3461
+
3462
+ #: defaults.php:248
3463
+ msgid ""
3464
+ "Marked the comment posted in response to the post %PostTitle% by %Author% on "
3465
+ "%CommentLink% as Spam."
3466
+ msgstr ""
3467
+
3468
+ #: defaults.php:249
3469
+ msgid "User marked a comment as Not Spam"
3470
+ msgstr ""
3471
+
3472
+ #: defaults.php:249
3473
+ msgid ""
3474
+ "Marked the comment posted in response to the post %PostTitle% by %Author% on "
3475
+ "%CommentLink% as Not Spam."
3476
+ msgstr ""
3477
+
3478
+ #: defaults.php:250
3479
+ msgid "User moved a comment to trash"
3480
+ msgstr ""
3481
+
3482
+ #: defaults.php:250
3483
+ msgid ""
3484
+ "Moved the comment posted in response to the post %PostTitle% by %Author% on "
3485
+ "%Date% to trash."
3486
+ msgstr ""
3487
+
3488
+ #: defaults.php:251
3489
+ msgid "User restored a comment from the trash"
3490
+ msgstr ""
3491
+
3492
+ #: defaults.php:251
3493
+ msgid ""
3494
+ "Restored the comment posted in response to the post %PostTitle% by %Author% "
3495
+ "on %CommentLink% from the trash."
3496
+ msgstr ""
3497
+
3498
+ #: defaults.php:252
3499
+ msgid "User permanently deleted a comment"
3500
+ msgstr ""
3501
+
3502
+ #: defaults.php:252
3503
+ msgid ""
3504
+ "Permanently deleted the comment posted in response to the post %PostTitle% "
3505
+ "by %Author% on %Date%."
3506
+ msgstr ""
3507
+
3508
+ #: defaults.php:253
3509
+ msgid "User posted a comment"
3510
+ msgstr ""
3511
+
3512
+ #: defaults.php:253 defaults.php:254
3513
+ msgid "%CommentMsg% on %CommentLink%."
3514
+ msgstr ""
3515
+
3516
+ #: defaults.php:254
3517
+ msgid "Visitor posted a comment"
3518
+ msgstr ""
3519
+
3520
+ #: defaults.php:266
3521
+ msgid "User modified a draft blog post"
3522
+ msgstr ""
3523
+
3524
+ #: defaults.php:266
3525
+ msgid "Modified the draft post with the %PostTitle%. %EditorLinkPost%."
3526
+ msgstr ""
3527
+
3528
+ #: defaults.php:267
3529
+ msgid "User created a new post with custom post type and saved it as draft"
3530
+ msgstr ""
3531
+
3532
+ #: defaults.php:267
3533
+ msgid ""
3534
+ "Created a new custom post called %PostTitle% of type %PostType%. "
3535
+ "%EditorLinkPost%."
3536
+ msgstr ""
3537
+
3538
+ #: defaults.php:268
3539
+ msgid "User published a post with custom post type"
3540
+ msgstr ""
3541
+
3542
+ #: defaults.php:268
3543
+ msgid ""
3544
+ "Published a custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
3545
+ "%. %EditorLinkPost%."
3546
+ msgstr ""
3547
+
3548
+ #: defaults.php:269
3549
+ msgid "User modified a post with custom post type"
3550
+ msgstr ""
3551
+
3552
+ #: defaults.php:269
3553
+ msgid ""
3554
+ "Modified the custom post %PostTitle% of type %PostType%. Post URL is %PostUrl"
3555
+ "%. %EditorLinkPost%."
3556
+ msgstr ""
3557
+
3558
+ #: defaults.php:270
3559
+ msgid "User modified a draft post with custom post type"
3560
+ msgstr ""
3561
+
3562
+ #: defaults.php:270
3563
+ msgid ""
3564
+ "Modified the draft custom post %PostTitle% of type is %PostType%. "
3565
+ "%EditorLinkPost%."
3566
+ msgstr ""
3567
+
3568
+ #: defaults.php:271
3569
+ msgid "User permanently deleted post with custom post type"
3570
+ msgstr ""
3571
+
3572
+ #: defaults.php:271
3573
+ msgid "Permanently Deleted the custom post %PostTitle% of type %PostType%."
3574
+ msgstr ""
3575
+
3576
+ #: defaults.php:272
3577
+ msgid "User moved post with custom post type to trash"
3578
+ msgstr ""
3579
+
3580
+ #: defaults.php:272
3581
+ msgid ""
3582
+ "Moved the custom post %PostTitle% of type %PostType% to trash. Post URL was "
3583
+ "%PostUrl%."
3584
+ msgstr ""
3585
+
3586
+ #: defaults.php:273
3587
+ msgid "User restored post with custom post type from trash"
3588
+ msgstr ""
3589
+
3590
+ #: defaults.php:273
3591
+ msgid ""
3592
+ "The custom post %PostTitle% of type %PostType% has been restored from trash. "
3593
+ "%EditorLinkPost%."
3594
+ msgstr ""
3595
+
3596
+ #: defaults.php:274
3597
+ msgid "User changed the category of a post with custom post type"
3598
+ msgstr ""
3599
+
3600
+ #: defaults.php:274
3601
+ msgid ""
3602
+ "Changed the category(ies) of the custom post %PostTitle% of type %PostType% "
3603
+ "from %OldCategories% to %NewCategories%. %EditorLinkPost%."
3604
+ msgstr ""
3605
+
3606
+ #: defaults.php:275
3607
+ msgid "User changed the URL of a post with custom post type"
3608
+ msgstr ""
3609
+
3610
+ #: defaults.php:275
3611
+ msgid ""
3612
+ "Changed the URL of the custom post %PostTitle% of type %PostType% from "
3613
+ "%OldUrl% to %NewUrl%. %EditorLinkPost%."
3614
+ msgstr ""
3615
+
3616
+ #: defaults.php:276
3617
+ msgid "User changed the author or post with custom post type"
3618
+ msgstr ""
3619
+
3620
+ #: defaults.php:276
3621
+ msgid ""
3622
+ "Changed the author of custom post %PostTitle% of type %PostType% from "
3623
+ "%OldAuthor% to %NewAuthor%. %EditorLinkPost%."
3624
+ msgstr ""
3625
+
3626
+ #: defaults.php:277
3627
+ msgid "User changed the status of post with custom post type"
3628
+ msgstr ""
3629
+
3630
+ #: defaults.php:277
3631
+ msgid ""
3632
+ "Changed the status of custom post %PostTitle% of type %PostType% from "
3633
+ "%OldStatus% to %NewStatus%. %EditorLinkPost%."
3634
+ msgstr ""
3635
+
3636
+ #: defaults.php:278
3637
+ msgid "User changed the visibility of a post with custom post type"
3638
+ msgstr ""
3639
+
3640
+ #: defaults.php:278
3641
+ msgid ""
3642
+ "Changed the visibility of the custom post %PostTitle% of type %PostType% "
3643
+ "from %OldVisibility% to %NewVisibility%. %EditorLinkPost%."
3644
+ msgstr ""
3645
+
3646
+ #: defaults.php:279
3647
+ msgid "User changed the date of post with custom post type"
3648
+ msgstr ""
3649
+
3650
+ #: defaults.php:279
3651
+ msgid ""
3652
+ "Changed the date of the custom post %PostTitle% of type %PostType% from "
3653
+ "%OldDate% to %NewDate%. %EditorLinkPost%."
3654
+ msgstr ""
3655
+
3656
+ #: defaults.php:280
3657
+ msgid "User created a custom field for a custom post type"
3658
+ msgstr ""
3659
+
3660
+ #: defaults.php:280
3661
+ msgid ""
3662
+ "Created a new custom field %MetaKey% with value %MetaValue% in custom post "
3663
+ "%PostTitle% of type %PostType%. %EditorLinkPost%.<br>%MetaLink%."
3664
+ msgstr ""
3665
+
3666
+ #: defaults.php:281
3667
+ msgid "User updated a custom field for a custom post type"
3668
+ msgstr ""
3669
+
3670
+ #: defaults.php:281
3671
+ msgid ""
3672
+ "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
3673
+ "%MetaValueNew% in custom post %PostTitle% of type %PostType% %EditorLinkPost"
3674
+ "%.<br>%MetaLink%."
3675
+ msgstr ""
3676
+
3677
+ #: defaults.php:282
3678
+ msgid "User deleted a custom field from a custom post type"
3679
+ msgstr ""
3680
+
3681
+ #: defaults.php:282
3682
+ msgid ""
3683
+ "Deleted the custom field %MetaKey% with id %MetaID% from custom post "
3684
+ "%PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
3685
+ msgstr ""
3686
+
3687
+ #: defaults.php:283
3688
+ msgid "User updated a custom field name for a custom post type"
3689
+ msgstr ""
3690
+
3691
+ #: defaults.php:283
3692
+ msgid ""
3693
+ "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in custom "
3694
+ "post %PostTitle% of type %PostType% %EditorLinkPost%.<br>%MetaLink%."
3695
+ msgstr ""
3696
+
3697
+ #: defaults.php:284
3698
+ msgid "User modified content for a published custom post type"
3699
+ msgstr ""
3700
+
3701
+ #: defaults.php:284
3702
+ msgid ""
3703
+ "Modified the content of the published custom post type %PostTitle%. Post URL "
3704
+ "is %PostUrl%.%EditorLinkPost%."
3705
+ msgstr ""
3706
+
3707
+ #: defaults.php:285
3708
+ msgid "User modified content for a draft post"
3709
+ msgstr ""
3710
+
3711
+ #: defaults.php:285
3712
+ msgid ""
3713
+ "Modified the content of the draft post %PostTitle%.%RevisionLink% "
3714
+ "%EditorLinkPost%."
3715
+ msgstr ""
3716
+
3717
+ #: defaults.php:286
3718
+ msgid "User modified content for a draft custom post type"
3719
+ msgstr ""
3720
+
3721
+ #: defaults.php:286
3722
+ msgid ""
3723
+ "Modified the content of the draft custom post type %PostTitle%."
3724
+ "%EditorLinkPost%."
3725
+ msgstr ""
3726
+
3727
+ #: defaults.php:287
3728
+ msgid "User modified content of a post"
3729
+ msgstr ""
3730
+
3731
+ #: defaults.php:287
3732
+ msgid ""
3733
+ "Modified the content of post %PostTitle% which is submitted for review."
3734
+ "%RevisionLink% %EditorLinkPost%."
3735
+ msgstr ""
3736
+
3737
+ #: defaults.php:288
3738
+ msgid "User scheduled a custom post type"
3739
+ msgstr ""
3740
+
3741
+ #: defaults.php:288
3742
+ msgid ""
3743
+ "Scheduled the custom post type %PostTitle% to be published %PublishingDate%. "
3744
+ "%EditorLinkPost%."
3745
+ msgstr ""
3746
+
3747
+ #: defaults.php:289
3748
+ msgid "User changed title of a custom post type"
3749
+ msgstr ""
3750
+
3751
+ #: defaults.php:289
3752
+ msgid ""
3753
+ "Changed the title of the custom post %OldTitle% to %NewTitle%. "
3754
+ "%EditorLinkPost%."
3755
+ msgstr ""
3756
+
3757
+ #: defaults.php:290
3758
+ msgid "User opened a custom post type in the editor"
3759
+ msgstr ""
3760
+
3761
+ #: defaults.php:290
3762
+ msgid ""
3763
+ "Opened the custom post %PostTitle% of type %PostType% in the editor. View "
3764
+ "the post: %EditorLinkPost%."
3765
+ msgstr ""
3766
+
3767
+ #: defaults.php:291
3768
+ msgid "User viewed a custom post type"
3769
+ msgstr ""
3770
+
3771
+ #: defaults.php:291
3772
+ msgid ""
3773
+ "Viewed the custom post %PostTitle% of type %PostType%. View the post: "
3774
+ "%PostUrl%."
3775
+ msgstr ""
3776
+
3777
+ #: defaults.php:292
3778
+ msgid "A plugin created a custom post"
3779
+ msgstr ""
3780
+
3781
+ #: defaults.php:292
3782
+ msgid "A plugin automatically created the following custom post: %PostTitle%."
3783
+ msgstr ""
3784
+
3785
+ #: defaults.php:293
3786
+ msgid "A plugin deleted a custom post"
3787
+ msgstr ""
3788
+
3789
+ #: defaults.php:293
3790
+ msgid "A plugin automatically deleted the following custom post: %PostTitle%."
3791
+ msgstr ""
3792
+
3793
+ #: defaults.php:294
3794
+ msgid "A plugin modified a custom post"
3795
+ msgstr ""
3796
+
3797
+ #: defaults.php:294
3798
+ msgid ""
3799
+ "Plugin modified the custom post %PostTitle%. View the post: %EditorLinkPost%."
3800
+ msgstr ""
3801
+
3802
+ #: defaults.php:306
3803
+ msgid "User created a new WordPress page and saved it as draft"
3804
+ msgstr ""
3805
+
3806
+ #: defaults.php:306
3807
+ msgid ""
3808
+ "Created a new page called %PostTitle% and saved it as draft. %EditorLinkPage"
3809
+ "%."
3810
+ msgstr ""
3811
+
3812
+ #: defaults.php:307
3813
+ msgid "User published a WordPress page"
3814
+ msgstr ""
3815
+
3816
+ #: defaults.php:307
3817
+ msgid ""
3818
+ "Published a page called %PostTitle%. Page URL is %PostUrl%. %EditorLinkPage%."
3819
+ msgstr ""
3820
+
3821
+ #: defaults.php:308
3822
+ msgid "User modified a published WordPress page"
3823
+ msgstr ""
3824
+
3825
+ #: defaults.php:308
3826
+ msgid ""
3827
+ "Modified the published page %PostTitle%. Page URL is %PostUrl%. "
3828
+ "%EditorLinkPage%."
3829
+ msgstr ""
3830
+
3831
+ #: defaults.php:309
3832
+ msgid "User modified a draft WordPress page"
3833
+ msgstr ""
3834
+
3835
+ #: defaults.php:309
3836
+ msgid ""
3837
+ "Modified the draft page %PostTitle%. Page ID is %PostID%. %EditorLinkPage%."
3838
+ msgstr ""
3839
+
3840
+ #: defaults.php:310
3841
+ msgid "User permanently deleted a page from the trash"
3842
+ msgstr ""
3843
+
3844
+ #: defaults.php:310
3845
+ msgid "Permanently deleted the page %PostTitle%."
3846
+ msgstr ""
3847
+
3848
+ #: defaults.php:311
3849
+ msgid "User moved WordPress page to the trash"
3850
+ msgstr ""
3851
+
3852
+ #: defaults.php:311
3853
+ msgid "Moved the page %PostTitle% to trash. Page URL was %PostUrl%."
3854
+ msgstr ""
3855
+
3856
+ #: defaults.php:312
3857
+ msgid "User restored a WordPress page from trash"
3858
+ msgstr ""
3859
+
3860
+ #: defaults.php:312
3861
+ msgid "Page %PostTitle% has been restored from trash. %EditorLinkPage%."
3862
+ msgstr ""
3863
+
3864
+ #: defaults.php:313
3865
+ msgid "User changed page URL"
3866
+ msgstr ""
3867
+
3868
+ #: defaults.php:313
3869
+ msgid ""
3870
+ "Changed the URL of the page %PostTitle% from %OldUrl% to %NewUrl%. "
3871
+ "%EditorLinkPage%."
3872
+ msgstr ""
3873
+
3874
+ #: defaults.php:314
3875
+ msgid "User changed page author"
3876
+ msgstr ""
3877
+
3878
+ #: defaults.php:314
3879
+ msgid ""
3880
+ "Changed the author of the page %PostTitle% from %OldAuthor% to %NewAuthor%. "
3881
+ "%EditorLinkPage%."
3882
+ msgstr ""
3883
+
3884
+ #: defaults.php:315
3885
+ msgid "User changed page status"
3886
+ msgstr ""
3887
+
3888
+ #: defaults.php:315
3889
+ msgid ""
3890
+ "Changed the status of the page %PostTitle% from %OldStatus% to %NewStatus%. "
3891
+ "%EditorLinkPage%."
3892
+ msgstr ""
3893
+
3894
+ #: defaults.php:316
3895
+ msgid "User changed the visibility of a page post"
3896
+ msgstr ""
3897
+
3898
+ #: defaults.php:316
3899
+ msgid ""
3900
+ "Changed the visibility of the page %PostTitle% from %OldVisibility% to "
3901
+ "%NewVisibility%. %EditorLinkPage%."
3902
+ msgstr ""
3903
+
3904
+ #: defaults.php:317
3905
+ msgid "User changed the date of a page post"
3906
+ msgstr ""
3907
+
3908
+ #: defaults.php:317
3909
+ msgid ""
3910
+ "Changed the date of the page %PostTitle% from %OldDate% to %NewDate%. "
3911
+ "%EditorLinkPage%."
3912
+ msgstr ""
3913
+
3914
+ #: defaults.php:318
3915
+ msgid "User created a custom field for a page"
3916
+ msgstr ""
3917
+
3918
+ #: defaults.php:318
3919
+ msgid ""
3920
+ "Created a new custom field called %MetaKey% with value %MetaValue% in the "
3921
+ "page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
3922
+ msgstr ""
3923
+
3924
+ #: defaults.php:319
3925
+ msgid "User updated a custom field value for a page"
3926
+ msgstr ""
3927
+
3928
+ #: defaults.php:319
3929
+ msgid ""
3930
+ "Modified the value of the custom field %MetaKey% from %MetaValueOld% to "
3931
+ "%MetaValueNew% in the page %PostTitle% %EditorLinkPage%.<br>%MetaLink%."
3932
+ msgstr ""
3933
+
3934
+ #: defaults.php:320
3935
+ msgid "User deleted a custom field from a page"
3936
+ msgstr ""
3937
+
3938
+ #: defaults.php:320
3939
+ msgid ""
3940
+ "Deleted the custom field %MetaKey% with id %MetaID% from page %PostTitle% "
3941
+ "%EditorLinkPage%.<br>%MetaLink%."
3942
+ msgstr ""
3943
+
3944
+ #: defaults.php:321
3945
+ msgid "User updated a custom field name for a page"
3946
+ msgstr ""
3947
+
3948
+ #: defaults.php:321
3949
+ msgid ""
3950
+ "Changed the custom field name from %MetaKeyOld% to %MetaKeyNew% in the page "
3951
+ "%PostTitle% %EditorLinkPage%.<br>%MetaLink%."
3952
+ msgstr ""
3953
+
3954
+ #: defaults.php:322
3955
+ msgid "User modified content for a published page"
3956
+ msgstr ""
3957
+
3958
+ #: defaults.php:322
3959
+ msgid ""
3960
+ "Modified the content of the published page %PostTitle%. Page URL is %PostUrl"
3961
+ "%. %RevisionLink% %EditorLinkPage%."
3962
+ msgstr ""
3963
+
3964
+ #: defaults.php:323
3965
+ msgid "User modified content for a draft page"
3966
+ msgstr ""
3967
+
3968
+ #: defaults.php:323
3969
+ msgid ""
3970
+ "Modified the content of draft page %PostTitle%.%RevisionLink% %EditorLinkPage"
3971
+ "%."
3972
+ msgstr ""
3973
+
3974
+ #: defaults.php:324
3975
+ msgid "User scheduled a page"
3976
+ msgstr ""
3977
+
3978
+ #: defaults.php:324
3979
+ msgid ""
3980
+ "Scheduled the page %PostTitle% to be published %PublishingDate%. "
3981
+ "%EditorLinkPage%."
3982
+ msgstr ""
3983
+
3984
+ #: defaults.php:325
3985
+ msgid "User changed title of a page"
3986
+ msgstr ""
3987
+
3988
+ #: defaults.php:325
3989
+ msgid ""
3990
+ "Changed the title of the page %OldTitle% to %NewTitle%. %EditorLinkPage%."
3991
+ msgstr ""
3992
+
3993
+ #: defaults.php:326
3994
+ msgid "User opened a page in the editor"
3995
+ msgstr ""
3996
+
3997
+ #: defaults.php:326
3998
+ msgid ""
3999
+ "Opened the page %PostTitle% in the editor. View the page: %EditorLinkPage%."
4000
+ msgstr ""
4001
+
4002
+ #: defaults.php:327
4003
+ msgid "User viewed a page"
4004
+ msgstr ""
4005
+
4006
+ #: defaults.php:327
4007
+ msgid "Viewed the page %PostTitle%. View the page: %PostUrl%."
4008
+ msgstr ""
4009
+
4010
+ #: defaults.php:328
4011
+ msgid "User disabled Comments/Trackbacks and Pingbacks on a draft post"
4012
+ msgstr ""
4013
+
4014
+ #: defaults.php:328
4015
+ msgid ""
4016
+ "Disabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
4017
+ msgstr ""
4018
+
4019
+ #: defaults.php:329
4020
+ msgid "User enabled Comments/Trackbacks and Pingbacks on a draft post"
4021
+ msgstr ""
4022
+
4023
+ #: defaults.php:329
4024
+ msgid "Enabled %Type% on the draft post %PostTitle%. View the post: %PostUrl%."
4025
+ msgstr ""
4026
+
4027
+ #: defaults.php:330
4028
+ msgid "User disabled Comments/Trackbacks and Pingbacks on a published page"
4029
+ msgstr ""
4030
+
4031
+ #: defaults.php:330
4032
+ msgid ""
4033
+ "Disabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
4034
+ msgstr ""
4035
+
4036
+ #: defaults.php:331
4037
+ msgid "User enabled Comments/Trackbacks and Pingbacks on a published page"
4038
+ msgstr ""
4039
+
4040
+ #: defaults.php:331
4041
+ msgid ""
4042
+ "Enabled %Type% on the published page %PostTitle%. View the page: %PostUrl%."
4043
+ msgstr ""
4044
+
4045
+ #: defaults.php:332
4046
+ msgid "User disabled Comments/Trackbacks and Pingbacks on a draft page"
4047
+ msgstr ""
4048
+
4049
+ #: defaults.php:332
4050
+ msgid ""
4051
+ "Disabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
4052
+ msgstr ""
4053
+
4054
+ #: defaults.php:333
4055
+ msgid "User enabled Comments/Trackbacks and Pingbacks on a draft page"
4056
+ msgstr ""
4057
+
4058
+ #: defaults.php:333
4059
+ msgid "Enabled %Type% on the draft page %PostTitle%. View the page: %PostUrl%."
4060
+ msgstr ""
4061
+
4062
+ #: defaults.php:334
4063
+ msgid "A plugin created a page"
4064
+ msgstr ""
4065
+
4066
+ #: defaults.php:334
4067
+ msgid "A plugin automatically created the following page: %PostTitle%."
4068
+ msgstr ""
4069
+
4070
+ #: defaults.php:335
4071
+ msgid "A plugin deleted a page"
4072
+ msgstr ""
4073
+
4074
+ #: defaults.php:335
4075
+ msgid "A plugin automatically deleted the following page: %PostTitle%."
4076
+ msgstr ""
4077
+
4078
+ #: defaults.php:336
4079
+ msgid "A plugin modified a page"
4080
+ msgstr ""
4081
+
4082
+ #: defaults.php:336
4083
+ msgid "Plugin modified the page %PostTitle%. View the page: %EditorLinkPage%."
4084
+ msgstr ""
4085
+
4086
+ #: defaults.php:343
4087
+ msgid "WordPress Install"
4088
+ msgstr ""
4089
+
4090
+ #: defaults.php:347
4091
+ msgid "Database"
4092
+ msgstr ""
4093
+
4094
+ #: defaults.php:348
4095
+ msgid "Unknown component created tables"
4096
+ msgstr ""
4097
+
4098
+ #: defaults.php:348
4099
+ msgid ""
4100
+ "An unknown component created these tables in the database: %TableNames%."
4101
+ msgstr ""
4102
+
4103
+ #: defaults.php:349
4104
+ msgid "Unknown component modified tables structure"
4105
+ msgstr ""
4106
+
4107
+ #: defaults.php:349
4108
+ msgid ""
4109
+ "An unknown component modified the structure of these database tables: "
4110
+ "%TableNames%."
4111
+ msgstr ""
4112
+
4113
+ #: defaults.php:350
4114
+ msgid "Unknown component deleted tables"
4115
+ msgstr ""
4116
+
4117
+ #: defaults.php:350
4118
+ msgid ""
4119
+ "An unknown component deleted the following tables from the database: "
4120
+ "%TableNames%."
4121
+ msgstr ""
4122
+
4123
+ #: defaults.php:357
4124
+ msgid "User installed a plugin"
4125
+ msgstr ""
4126
+
4127
+ #: defaults.php:357
4128
+ msgid "Installed the plugin %Plugin->Name% in %Plugin->plugin_dir_path%."
4129
+ msgstr ""
4130
+
4131
+ #: defaults.php:358
4132
+ msgid "User activated a WordPress plugin"
4133
+ msgstr ""
4134
+
4135
+ #: defaults.php:358
4136
+ msgid "Activated the plugin %PluginData->Name% installed in %PluginFile%."
4137
+ msgstr ""
4138
+
4139
+ #: defaults.php:359
4140
+ msgid "User deactivated a WordPress plugin"
4141
+ msgstr ""
4142
+
4143
+ #: defaults.php:359
4144
+ msgid "Deactivated the plugin %PluginData->Name% installed in %PluginFile%."
4145
+ msgstr ""
4146
+
4147
+ #: defaults.php:360
4148
+ msgid "User uninstalled a plugin"
4149
+ msgstr ""
4150
+
4151
+ #: defaults.php:360
4152
+ msgid ""
4153
+ "Uninstalled the plugin %PluginData->Name% which was installed in %PluginFile"
4154
+ "%."
4155
+ msgstr ""
4156
+
4157
+ #: defaults.php:361
4158
+ msgid "User upgraded a plugin"
4159
+ msgstr ""
4160
+
4161
+ #: defaults.php:361
4162
+ msgid "Upgraded the plugin %PluginData->Name% installed in %PluginFile%."
4163
+ msgstr ""
4164
+
4165
+ #: defaults.php:362
4166
+ msgid "Plugin created tables"
4167
+ msgstr ""
4168
+
4169
+ #: defaults.php:362
4170
+ msgid ""
4171
+ "Plugin %Plugin->Name% created these tables in the database: %TableNames%."
4172
+ msgstr ""
4173
+
4174
+ #: defaults.php:363
4175
+ msgid "Plugin modified tables structure"
4176
+ msgstr ""
4177
+
4178
+ #: defaults.php:363
4179
+ msgid ""
4180
+ "Plugin %Plugin->Name% modified the structure of these database tables: "
4181
+ "%TableNames%."
4182
+ msgstr ""
4183
+
4184
+ #: defaults.php:364
4185
+ msgid "Plugin deleted tables"
4186
+ msgstr ""
4187
+
4188
+ #: defaults.php:364
4189
+ msgid ""
4190
+ "Plugin %Plugin->Name% deleted the following tables from the database: "
4191
+ "%TableNames%."
4192
+ msgstr ""
4193
+
4194
+ #: defaults.php:365
4195
+ msgid "A plugin created a post"
4196
+ msgstr ""
4197
+
4198
+ #: defaults.php:365
4199
+ msgid ""
4200
+ "A plugin automatically created the following %PostType% called %PostTitle%. "
4201
+ "View the post: %EditorLinkPost%."
4202
+ msgstr ""
4203
+
4204
+ #: defaults.php:366
4205
+ msgid "A plugin deleted a post"
4206
+ msgstr ""
4207
+
4208
+ #: defaults.php:366
4209
+ msgid ""
4210
+ "A plugin automatically deleted the following %PostType% called %PostTitle%."
4211
+ msgstr ""
4212
+
4213
+ #: defaults.php:367
4214
+ msgid "User changed a file using the plugin editor"
4215
+ msgstr ""
4216
+
4217
+ #: defaults.php:367
4218
+ msgid "Modified %File% with the Plugin Editor."
4219
+ msgstr ""
4220
+
4221
+ #: defaults.php:373
4222
+ msgid "Themes"
4223
+ msgstr ""
4224
+
4225
+ #: defaults.php:374
4226
+ msgid "User installed a theme"
4227
+ msgstr ""
4228
+
4229
+ #: defaults.php:374
4230
+ msgid ""
4231
+ "Installed the theme \"%Theme->Name%\" in %Theme->get_template_directory%."
4232
+ msgstr ""
4233
+
4234
+ #: defaults.php:375
4235
+ msgid "User activated a theme"
4236
+ msgstr ""
4237
+
4238
+ #: defaults.php:375
4239
+ msgid ""
4240
+ "Activated the theme \"%Theme->Name%\", installed in %Theme-"
4241
+ ">get_template_directory%."
4242
+ msgstr ""
4243
+
4244
+ #: defaults.php:376
4245
+ msgid "User uninstalled a theme"
4246
+ msgstr ""
4247
+
4248
+ #: defaults.php:376
4249
+ msgid ""
4250
+ "Deleted the theme \"%Theme->Name%\" installed in %Theme-"
4251
+ ">get_template_directory%."
4252
+ msgstr ""
4253
+
4254
+ #: defaults.php:377
4255
+ msgid "Activated theme on network"
4256
+ msgstr ""
4257
+
4258
+ #: defaults.php:377
4259
+ msgid ""
4260
+ "Network activated the theme %Theme->Name% installed in %Theme-"
4261
+ ">get_template_directory%."
4262
+ msgstr ""
4263
+
4264
+ #: defaults.php:378
4265
+ msgid "Deactivated theme from network"
4266
+ msgstr ""
4267
+
4268
+ #: defaults.php:378
4269
+ msgid ""
4270
+ "Network deactivated the theme %Theme->Name% installed in %Theme-"
4271
+ ">get_template_directory%."
4272
+ msgstr ""
4273
+
4274
+ #: defaults.php:379
4275
+ msgid "Theme created tables"
4276
+ msgstr ""
4277
+
4278
+ #: defaults.php:379
4279
+ msgid "Theme %Theme->Name% created these tables in the database: %TableNames%."
4280
+ msgstr ""
4281
+
4282
+ #: defaults.php:380
4283
+ msgid "Theme modified tables structure"
4284
+ msgstr ""
4285
+
4286
+ #: defaults.php:380
4287
+ msgid ""
4288
+ "Theme %Theme->Name% modified the structure of these database tables: "
4289
+ "%TableNames%."
4290
+ msgstr ""
4291
+
4292
+ #: defaults.php:381
4293
+ msgid "Theme deleted tables"
4294
+ msgstr ""
4295
+
4296
+ #: defaults.php:381
4297
+ msgid ""
4298
+ "Theme %Theme->Name% deleted the following tables from the database: "
4299
+ "%TableNames%."
4300
+ msgstr ""
4301
+
4302
+ #: defaults.php:382
4303
+ msgid "User updated a theme"
4304
+ msgstr ""
4305
+
4306
+ #: defaults.php:382
4307
+ msgid ""
4308
+ "Updated the theme \"%Theme->Name%\" installed in %Theme-"
4309
+ ">get_template_directory%."
4310
+ msgstr ""
4311
+
4312
+ #: defaults.php:383
4313
+ msgid "User changed a file using the theme editor"
4314
+ msgstr ""
4315
+
4316
+ #: defaults.php:383
4317
+ msgid "Modified %File% with the Theme Editor."
4318
+ msgstr ""
4319
+
4320
+ #: defaults.php:390
4321
+ msgid "Unknown Error"
4322
+ msgstr ""
4323
+
4324
+ #: defaults.php:390
4325
+ msgid "An unexpected error has occurred ."
4326
+ msgstr ""
4327
+
4328
+ #: defaults.php:391
4329
+ msgid "PHP error"
4330
+ msgstr ""
4331
+
4332
+ #: defaults.php:391 defaults.php:392 defaults.php:393 defaults.php:394
4333
+ #: defaults.php:395
4334
+ msgid "%Message%."
4335
+ msgstr ""
4336
+
4337
+ #: defaults.php:392
4338
+ msgid "PHP warning"
4339
+ msgstr ""
4340
+
4341
+ #: defaults.php:393
4342
+ msgid "PHP notice"
4343
+ msgstr ""
4344
+
4345
+ #: defaults.php:394
4346
+ msgid "PHP exception"
4347
+ msgstr ""
4348
+
4349
+ #: defaults.php:395
4350
+ msgid "PHP shutdown error"
4351
+ msgstr ""
4352
+
4353
+ #: defaults.php:396
4354
+ msgid "Events automatically pruned by system"
4355
+ msgstr ""
4356
+
4357
+ #: defaults.php:396
4358
+ msgid "System automatically deleted %EventCount% event(s)."
4359
+ msgstr ""
4360
+
4361
+ #: defaults.php:397
4362
+ msgid "WordPress was updated"
4363
+ msgstr ""
4364
+
4365
+ #: defaults.php:397
4366
+ msgid "Updated WordPress from version %OldVersion% to %NewVersion%."
4367
+ msgstr ""
4368
+
4369
+ #: defaults.php:398
4370
+ msgid "Reset plugin's settings to default"
4371
+ msgstr ""
4372
+
4373
+ #: defaults.php:398
4374
+ msgid "Reset plugin's settings to default."
4375
+ msgstr ""
4376
+
4377
+ #: defaults.php:399
4378
+ msgid "Purged the activity log"
4379
+ msgstr ""
4380
+
4381
+ #: defaults.php:399
4382
+ msgid "Purged the activity log."
4383
+ msgstr ""
4384
+
4385
+ #: defaults.php:400
4386
+ msgid "File content has been modified"
4387
+ msgstr ""
4388
+
4389
+ #: defaults.php:400
4390
+ msgid "The content of the file %FileLocation% has been modified."
4391
+ msgstr ""
4392
+
4393
+ #: defaults.php:401
4394
+ msgid "File added to the site"
4395
+ msgstr ""
4396
+
4397
+ #: defaults.php:401
4398
+ msgid "The file %FileLocation% has been added to your website."
4399
+ msgstr ""
4400
+
4401
+ #: defaults.php:402
4402
+ msgid "File deleted from the site"
4403
+ msgstr ""
4404
+
4405
+ #: defaults.php:402
4406
+ msgid "The file %FileLocation% has been deleted from your website."
4407
+ msgstr ""
4408
+
4409
+ #: defaults.php:403
4410
+ msgid "File not scanned because it is bigger than the maximum file size limit"
4411
+ msgstr ""
4412
+
4413
+ #: defaults.php:403
4414
+ msgid ""
4415
+ "The file %FileLocation% was not scanned because it is bigger than the "
4416
+ "maximum file size limit. If you want to include these files in the scan "
4417
+ "increase the file size limit from the %FileSettings%."
4418
+ msgstr ""
4419
+
4420
+ #: defaults.php:404
4421
+ msgid "File integrity scan stopped due to the limit of 1 million files"
4422
+ msgstr ""
4423
+
4424
+ #: defaults.php:404
4425
+ msgid ""
4426
+ "The file changes scanning engine has reached the limit of 1 million files "
4427
+ "and stopped the scan. Please %ContactSupport% for more information."
4428
+ msgstr ""
4429
+
4430
+ #: defaults.php:405
4431
+ msgid "File integrity scan started/stopped"
4432
+ msgstr ""
4433
+
4434
+ #: defaults.php:405
4435
+ msgid "The file integrity scanner has %ScanStatus%."
4436
+ msgstr ""
4437
+
4438
+ #: defaults.php:406
4439
+ msgid "Advertising Add-ons"
4440
+ msgstr ""
4441
+
4442
+ #: defaults.php:406
4443
+ msgid "%PromoName% %PromoMessage%"
4444
+ msgstr ""
4445
+
4446
+ #: defaults.php:412
4447
+ msgid "Menus"
4448
+ msgstr ""
4449
+
4450
+ #: defaults.php:413
4451
+ msgid "User created new menu"
4452
+ msgstr ""
4453
+
4454
+ #: defaults.php:413
4455
+ msgid "Created a new menu called %MenuName%."
4456
+ msgstr ""
4457
+
4458
+ #: defaults.php:414
4459
+ msgid "User added content to a menu"
4460
+ msgstr ""
4461
+
4462
+ #: defaults.php:414
4463
+ msgid "Added the %ContentType% called %ContentName% to menu %MenuName%."
4464
+ msgstr ""
4465
+
4466
+ #: defaults.php:415
4467
+ msgid "User removed content from a menu"
4468
+ msgstr ""
4469
+
4470
+ #: defaults.php:415
4471
+ msgid ""
4472
+ "Removed the %ContentType% called %ContentName% from the menu %MenuName%."
4473
+ msgstr ""
4474
+
4475
+ #: defaults.php:416
4476
+ msgid "User deleted menu"
4477
+ msgstr ""
4478
+
4479
+ #: defaults.php:416
4480
+ msgid "Deleted the menu %MenuName%."
4481
+ msgstr ""
4482
+
4483
+ #: defaults.php:417
4484
+ msgid "User changed menu setting"
4485
+ msgstr ""
4486
+
4487
+ #: defaults.php:417
4488
+ msgid "%Status% the menu setting %MenuSetting% in %MenuName%."
4489
+ msgstr ""
4490
+
4491
+ #: defaults.php:418
4492
+ msgid "User modified content in a menu"
4493
+ msgstr ""
4494
+
4495
+ #: defaults.php:418
4496
+ msgid "Modified the %ContentType% called %ContentName% in menu %MenuName%."
4497
+ msgstr ""
4498
+
4499
+ #: defaults.php:419
4500
+ msgid "User changed name of a menu"
4501
+ msgstr ""
4502
+
4503
+ #: defaults.php:419
4504
+ msgid "Changed the name of menu %OldMenuName% to %NewMenuName%."
4505
+ msgstr ""
4506
+
4507
+ #: defaults.php:420
4508
+ msgid "User changed order of the objects in a menu"
4509
+ msgstr ""
4510
+
4511
+ #: defaults.php:420
4512
+ msgid "Changed the order of the %ItemName% in menu %MenuName%."
4513
+ msgstr ""
4514
+
4515
+ #: defaults.php:421
4516
+ msgid "User moved objects as a sub-item"
4517
+ msgstr ""
4518
+
4519
+ #: defaults.php:421
4520
+ msgid "Moved %ItemName% as a sub-item of %ParentName% in menu %MenuName%."
4521
+ msgstr ""
4522
+
4523
+ #: defaults.php:427
4524
+ msgid "Widgets"
4525
+ msgstr ""
4526
+
4527
+ #: defaults.php:428
4528
+ msgid "User added a new widget"
4529
+ msgstr ""
4530
+
4531
+ #: defaults.php:428
4532
+ msgid "Added a new %WidgetName% widget in %Sidebar%."
4533
+ msgstr ""
4534
+
4535
+ #: defaults.php:429
4536
+ msgid "User modified a widget"
4537
+ msgstr ""
4538
+
4539
+ #: defaults.php:429
4540
+ msgid "Modified the %WidgetName% widget in %Sidebar%."
4541
+ msgstr ""
4542
+
4543
+ #: defaults.php:430
4544
+ msgid "User deleted widget"
4545
+ msgstr ""
4546
+
4547
+ #: defaults.php:430
4548
+ msgid "Deleted the %WidgetName% widget from %Sidebar%."
4549
+ msgstr ""
4550
+
4551
+ #: defaults.php:431
4552
+ msgid "User moved widget"
4553
  msgstr ""
4554
 
4555
+ #: defaults.php:431
4556
+ msgid "Moved the %WidgetName% widget from %OldSidebar% to %NewSidebar%."
4557
  msgstr ""
4558
 
4559
+ #: defaults.php:432
4560
+ msgid "User changed widget position"
4561
  msgstr ""
4562
 
4563
+ #: defaults.php:432
4564
+ msgid "Changed the position of the widget %WidgetName% in sidebar %Sidebar%."
4565
  msgstr ""
4566
 
4567
+ #: defaults.php:438
4568
+ msgid "WordPress Settings"
4569
  msgstr ""
4570
 
4571
+ #: defaults.php:439
4572
+ msgid "Option Anyone Can Register in WordPress settings changed"
4573
+ msgstr ""
4574
+
4575
+ #: defaults.php:439
4576
+ msgid "%NewValue% the option \"Anyone can register\"."
4577
+ msgstr ""
4578
+
4579
+ #: defaults.php:440
4580
+ msgid "New User Default Role changed"
4581
+ msgstr ""
4582
+
4583
+ #: defaults.php:440
4584
+ msgid "Changed the New User Default Role from %OldRole% to %NewRole%."
4585
+ msgstr ""
4586
+
4587
+ #: defaults.php:441
4588
+ msgid "WordPress Administrator Notification email changed"
4589
+ msgstr ""
4590
+
4591
+ #: defaults.php:441
4592
+ msgid ""
4593
+ "Changed the WordPress administrator notifications email address from "
4594
+ "%OldEmail% to %NewEmail%."
4595
+ msgstr ""
4596
+
4597
+ #: defaults.php:442
4598
+ msgid "User changes the WordPress Permalinks"
4599
+ msgstr ""
4600
+
4601
+ #: defaults.php:442
4602
+ msgid "Changed the WordPress permalinks from %OldPattern% to %NewPattern%."
4603
+ msgstr ""
4604
+
4605
+ #: defaults.php:443
4606
+ msgid ""
4607
+ "Enabled/Disabled the option Discourage search engines from indexing this site"
4608
+ msgstr ""
4609
+
4610
+ #: defaults.php:443
4611
+ msgid "%Status% the option Discourage search engines from indexing this site."
4612
+ msgstr ""
4613
+
4614
+ #: defaults.php:444
4615
+ msgid "Enabled/Disabled comments on all the website"
4616
+ msgstr ""
4617
+
4618
+ #: defaults.php:444
4619
+ msgid "%Status% comments on all the website."
4620
+ msgstr ""
4621
+
4622
+ #: defaults.php:445
4623
+ msgid "Enabled/Disabled the option Comment author must fill out name and email"
4624
+ msgstr ""
4625
+
4626
+ #: defaults.php:445
4627
+ msgid "%Status% the option Comment author must fill out name and email."
4628
+ msgstr ""
4629
+
4630
+ #: defaults.php:446
4631
+ msgid ""
4632
+ "Enabled/Disabled the option Users must be logged in and registered to comment"
4633
+ msgstr ""
4634
+
4635
+ #: defaults.php:446
4636
+ msgid "%Status% the option Users must be logged in and registered to comment."
4637
+ msgstr ""
4638
+
4639
+ #: defaults.php:447
4640
+ msgid "Enabled/Disabled the option to automatically close comments"
4641
+ msgstr ""
4642
+
4643
+ #: defaults.php:447
4644
+ msgid "%Status% the option to automatically close comments after %Value% days."
4645
+ msgstr ""
4646
+
4647
+ #: defaults.php:448
4648
+ msgid "Changed the value of the option Automatically close comments"
4649
+ msgstr ""
4650
+
4651
+ #: defaults.php:448
4652
+ msgid ""
4653
+ "Changed the value of the option Automatically close comments from %OldValue% "
4654
+ "to %NewValue% days."
4655
+ msgstr ""
4656
+
4657
+ #: defaults.php:449
4658
+ msgid "Enabled/Disabled the option for comments to be manually approved"
4659
+ msgstr ""
4660
+
4661
+ #: defaults.php:449
4662
+ msgid "%Status% the option for comments to be manually approved."
4663
+ msgstr ""
4664
+
4665
+ #: defaults.php:450
4666
+ msgid ""
4667
+ "Enabled/Disabled the option for an author to have previously approved "
4668
+ "comments for the comments to appear"
4669
+ msgstr ""
4670
+
4671
+ #: defaults.php:450
4672
+ msgid ""
4673
+ "%Status% the option for an author to have previously approved comments for "
4674
+ "the comments to appear."
4675
+ msgstr ""
4676
+
4677
+ #: defaults.php:451
4678
+ msgid ""
4679
+ "Changed the number of links that a comment must have to be held in the queue"
4680
+ msgstr ""
4681
+
4682
+ #: defaults.php:451
4683
+ msgid ""
4684
+ "Changed the number of links from %OldValue% to %NewValue% that a comment "
4685
+ "must have to be held in the queue."
4686
+ msgstr ""
4687
+
4688
+ #: defaults.php:452
4689
+ msgid "Modified the list of keywords for comments moderation"
4690
+ msgstr ""
4691
+
4692
+ #: defaults.php:452
4693
+ msgid "Modified the list of keywords for comments moderation."
4694
+ msgstr ""
4695
+
4696
+ #: defaults.php:453
4697
+ msgid "Modified the list of keywords for comments blacklisting"
4698
+ msgstr ""
4699
+
4700
+ #: defaults.php:453
4701
+ msgid "Modified the list of keywords for comments blacklisting."
4702
+ msgstr ""
4703
+
4704
+ #: defaults.php:454
4705
+ msgid "Option WordPress Address (URL) in WordPress settings changed"
4706
+ msgstr ""
4707
+
4708
+ #: defaults.php:454
4709
+ msgid "Changed the WordPress address (URL) from %old_url% to %new_url%."
4710
+ msgstr ""
4711
+
4712
+ #: defaults.php:455
4713
+ msgid "Option Site Address (URL) in WordPress settings changed"
4714
+ msgstr ""
4715
+
4716
+ #: defaults.php:455
4717
+ msgid "Changed the site address (URL) from %old_url% to %new_url%."
4718
+ msgstr ""
4719
+
4720
+ #: defaults.php:462
4721
+ msgid "Multisite Network"
4722
+ msgstr ""
4723
+
4724
+ #: defaults.php:467
4725
+ msgid "User granted Super Admin privileges"
4726
+ msgstr ""
4727
+
4728
+ #: defaults.php:467
4729
+ msgid "Granted Super Admin privileges to %TargetUsername%."
4730
+ msgstr ""
4731
+
4732
+ #: defaults.php:468
4733
+ msgid "User revoked from Super Admin privileges"
4734
+ msgstr ""
4735
+
4736
+ #: defaults.php:468
4737
+ msgid "Revoked Super Admin privileges from %TargetUsername%."
4738
+ msgstr ""
4739
+
4740
+ #: defaults.php:469
4741
+ msgid "Existing user added to a site"
4742
+ msgstr ""
4743
+
4744
+ #: defaults.php:469
4745
+ msgid ""
4746
+ "Added the existing user %TargetUsername% with %TargetUserRole% role to site "
4747
+ "%SiteName%."
4748
+ msgstr ""
4749
+
4750
+ #: defaults.php:470
4751
+ msgid "User removed from site"
4752
+ msgstr ""
4753
+
4754
+ #: defaults.php:470
4755
+ msgid ""
4756
+ "Removed the user %TargetUsername% with role %TargetUserRole% from %SiteName% "
4757
+ "site."
4758
+ msgstr ""
4759
+
4760
+ #: defaults.php:471
4761
+ msgid "New network user created"
4762
+ msgstr ""
4763
+
4764
+ #: defaults.php:471
4765
+ msgid "Created a new network user %NewUserData->Username%."
4766
+ msgstr ""
4767
+
4768
+ #: defaults.php:472
4769
+ msgid "The forum role of a user was changed by another WordPress user"
4770
+ msgstr ""
4771
+
4772
+ #: defaults.php:472
4773
+ msgid ""
4774
+ "Change the forum role of the user %TargetUsername% from %OldRole% to %NewRole"
4775
+ "% by %UserChanger%."
4776
+ msgstr ""
4777
+
4778
+ #: defaults.php:473
4779
+ msgid "New site added on the network"
4780
+ msgstr ""
4781
+
4782
+ #: defaults.php:473
4783
+ msgid "Added the site %SiteName% to the network."
4784
+ msgstr ""
4785
+
4786
+ #: defaults.php:474
4787
+ msgid "Existing site archived"
4788
+ msgstr ""
4789
+
4790
+ #: defaults.php:474
4791
+ msgid "Archived the site %SiteName%."
4792
+ msgstr ""
4793
+
4794
+ #: defaults.php:475
4795
+ msgid "Archived site has been unarchived"
4796
+ msgstr ""
4797
+
4798
+ #: defaults.php:475
4799
+ msgid "Unarchived the site %SiteName%."
4800
+ msgstr ""
4801
+
4802
+ #: defaults.php:476
4803
+ msgid "Deactivated site has been activated"
4804
+ msgstr ""
4805
+
4806
+ #: defaults.php:476
4807
+ msgid "Activated the site %SiteName%."
4808
+ msgstr ""
4809
+
4810
+ #: defaults.php:477
4811
+ msgid "Site has been deactivated"
4812
+ msgstr ""
4813
+
4814
+ #: defaults.php:477
4815
+ msgid "Deactivated the site %SiteName%."
4816
+ msgstr ""
4817
+
4818
+ #: defaults.php:478
4819
+ msgid "Existing site deleted from network"
4820
+ msgstr ""
4821
+
4822
+ #: defaults.php:478
4823
+ msgid "Deleted the site %SiteName%."
4824
  msgstr ""
4825
 
4826
+ #: defaults.php:490
4827
+ msgid "User created new forum"
4828
  msgstr ""
4829
 
4830
+ #: defaults.php:490
4831
+ msgid ""
4832
+ "Created new forum %ForumName%. Forum URL is %ForumURL%. %EditorLinkForum%."
4833
  msgstr ""
4834
 
4835
+ #: defaults.php:491
4836
+ msgid "User changed status of a forum"
4837
  msgstr ""
4838
 
4839
+ #: defaults.php:491
4840
+ msgid ""
4841
+ "Changed the status of the forum %ForumName% from %OldStatus% to %NewStatus%. "
4842
+ "%EditorLinkForum%."
4843
  msgstr ""
4844
 
4845
+ #: defaults.php:492
4846
+ msgid "User changed visibility of a forum"
4847
  msgstr ""
4848
 
4849
+ #: defaults.php:492
4850
+ msgid ""
4851
+ "Changed the visibility of the forum %ForumName% from %OldVisibility% to "
4852
+ "%NewVisibility%. %EditorLinkForum%."
4853
  msgstr ""
4854
 
4855
+ #: defaults.php:493
4856
+ msgid "User changed the URL of a forum"
4857
  msgstr ""
4858
 
4859
+ #: defaults.php:493
4860
  msgid ""
4861
+ "Changed the URL of the forum %ForumName% from %OldUrl% to %NewUrl%. "
4862
+ "%EditorLinkForum%."
4863
  msgstr ""
4864
 
4865
+ #: defaults.php:494
4866
+ msgid "User changed order of a forum"
4867
  msgstr ""
4868
 
4869
+ #: defaults.php:494
4870
+ msgid ""
4871
+ "Changed the order of the forum %ForumName% from %OldOrder% to %NewOrder%. "
4872
+ "%EditorLinkForum%."
4873
  msgstr ""
4874
 
4875
+ #: defaults.php:495
4876
+ msgid "User moved forum to trash"
4877
  msgstr ""
4878
 
4879
+ #: defaults.php:495
4880
+ msgid "Moved the forum %ForumName% to trash."
4881
  msgstr ""
4882
 
4883
+ #: defaults.php:496
4884
+ msgid "User permanently deleted forum"
4885
  msgstr ""
4886
 
4887
+ #: defaults.php:496
4888
+ msgid "Permanently deleted the forum %ForumName%."
 
4889
  msgstr ""
4890
 
4891
+ #: defaults.php:497
4892
+ msgid "User restored forum from trash"
4893
  msgstr ""
4894
 
4895
+ #: defaults.php:497
4896
+ msgid "Restored the forum %ForumName% from trash. %EditorLinkForum%."
4897
  msgstr ""
4898
 
4899
+ #: defaults.php:498
4900
+ msgid "User changed the parent of a forum"
4901
  msgstr ""
4902
 
4903
+ #: defaults.php:498
4904
+ msgid ""
4905
+ "Changed the parent of the forum %ForumName% from %OldParent% to %NewParent%. "
4906
+ "%EditorLinkForum%."
4907
  msgstr ""
4908
 
4909
+ #: defaults.php:499
4910
+ msgid "User changed type of a forum"
4911
+ msgstr ""
4912
+
4913
+ #: defaults.php:499
4914
  msgid ""
4915
+ "Changed the type of the forum %ForumName% from %OldType% to %NewType%. "
4916
+ "%EditorLinkForum%."
4917
  msgstr ""
4918
 
4919
+ #: defaults.php:500
4920
+ msgid "User changed forum's role"
4921
  msgstr ""
4922
 
4923
+ #: defaults.php:500
4924
+ msgid "Changed the forum's auto role from %OldRole% to %NewRole%."
4925
  msgstr ""
4926
 
4927
+ #: defaults.php:501
4928
+ msgid "User changed option of a forum"
 
 
4929
  msgstr ""
4930
 
4931
+ #: defaults.php:501
4932
+ msgid "%Status% the option for anonymous posting on forum."
 
 
4933
  msgstr ""
4934
 
4935
+ #: defaults.php:502
4936
+ msgid "User changed time to disallow post editing"
 
4937
  msgstr ""
4938
 
4939
+ #: defaults.php:502
4940
  msgid ""
4941
+ "Changed the time to disallow post editing from %OldTime% to %NewTime% "
4942
+ "minutes in the forums."
4943
  msgstr ""
4944
 
4945
+ #: defaults.php:503
4946
+ msgid "User changed the forum setting posting throttle time"
4947
  msgstr ""
4948
 
4949
+ #: defaults.php:503
4950
+ msgid ""
4951
+ "Changed the posting throttle time from %OldTime% to %NewTime% seconds in the "
4952
+ "forums."
4953
  msgstr ""
4954
 
4955
+ #: defaults.php:504
4956
+ msgid "User created new topic"
4957
  msgstr ""
4958
 
4959
+ #: defaults.php:504
4960
+ msgid "Created a new topic %TopicName%. %EditorLinkTopic%."
4961
  msgstr ""
4962
 
4963
+ #: defaults.php:505
4964
+ msgid "User changed status of a topic"
4965
  msgstr ""
4966
 
4967
+ #: defaults.php:505
4968
  msgid ""
4969
+ "Changed the status of the topic %TopicName% from %OldStatus% to %NewStatus%. "
4970
+ "%EditorLinkTopic%."
4971
  msgstr ""
4972
 
4973
+ #: defaults.php:506
4974
+ msgid "User changed type of a topic"
4975
  msgstr ""
4976
 
4977
+ #: defaults.php:506
4978
+ msgid ""
4979
+ "Changed the type of the topic %TopicName% from %OldType% to %NewType%. "
4980
+ "%EditorLinkTopic%."
4981
  msgstr ""
4982
 
4983
+ #: defaults.php:507
4984
+ msgid "User changed URL of a topic"
4985
  msgstr ""
4986
 
4987
+ #: defaults.php:507
4988
+ msgid "Changed the URL of the topic %TopicName% from %OldUrl% to %NewUrl%."
4989
  msgstr ""
4990
 
4991
+ #: defaults.php:508
4992
+ msgid "User changed the forum of a topic"
4993
  msgstr ""
4994
 
4995
+ #: defaults.php:508
4996
+ msgid ""
4997
+ "Changed the forum of the topic %TopicName% from %OldForum% to %NewForum%. "
4998
+ "%EditorLinkTopic%."
4999
  msgstr ""
5000
 
5001
+ #: defaults.php:509
5002
+ msgid "User moved topic to trash"
5003
  msgstr ""
5004
 
5005
+ #: defaults.php:509
5006
+ msgid "Moved the topic %TopicName% to trash."
5007
  msgstr ""
5008
 
5009
+ #: defaults.php:510
5010
+ msgid "User permanently deleted topic"
5011
  msgstr ""
5012
 
5013
+ #: defaults.php:510
5014
+ msgid "Permanently deleted the topic %TopicName%."
5015
  msgstr ""
5016
 
5017
+ #: defaults.php:511
5018
+ msgid "User restored topic from trash"
5019
  msgstr ""
5020
 
5021
+ #: defaults.php:511
5022
+ msgid "Restored the topic %TopicName% from trash. %EditorLinkTopic%."
5023
  msgstr ""
5024
 
5025
+ #: defaults.php:512
5026
+ msgid "User changed visibility of a topic"
5027
  msgstr ""
5028
 
5029
+ #: defaults.php:512
5030
+ msgid ""
5031
+ "Changed the visibility of the topic %TopicName% from %OldVisibility% to "
5032
+ "%NewVisibility%. %EditorLinkTopic%."
5033
  msgstr ""
5034
 
5035
+ #: defaults.php:519
5036
+ msgid "User created a new product"
5037
  msgstr ""
5038
 
5039
+ #: defaults.php:519
5040
  msgid ""
5041
+ "Created a new product called %ProductTitle% and saved it as draft. View the "
5042
+ "product: %EditorLinkProduct%."
5043
  msgstr ""
5044
 
5045
+ #: defaults.php:520
5046
+ msgid "User published a product"
5047
  msgstr ""
5048
 
5049
+ #: defaults.php:520
5050
  msgid ""
5051
+ "Published a product called %ProductTitle%. Product URL is %ProductUrl%. View "
5052
+ "the product: %EditorLinkProduct%."
5053
  msgstr ""
5054
 
5055
+ #: defaults.php:521
5056
+ msgid "User changed the category of a product"
5057
  msgstr ""
5058
 
5059
+ #: defaults.php:521
5060
  msgid ""
5061
+ "Changed the category of the %ProductStatus% product %ProductTitle% from "
5062
+ "%OldCategories% to %NewCategories%. View the product: %EditorLinkProduct%."
5063
  msgstr ""
5064
 
5065
+ #: defaults.php:522
5066
+ msgid "User modified the short description of a product"
5067
  msgstr ""
5068
 
5069
+ #: defaults.php:522
5070
+ msgid ""
5071
+ "Modified the short description of the %ProductStatus% product %ProductTitle%."
5072
+ "%ChangeText% View the product: %EditorLinkProduct%."
5073
  msgstr ""
5074
 
5075
+ #: defaults.php:523
5076
+ msgid "User modified the text of a product"
5077
  msgstr ""
5078
 
5079
+ #: defaults.php:523
5080
+ msgid ""
5081
+ "Modified the text of the %ProductStatus% product %ProductTitle%. View the "
5082
+ "product: %EditorLinkProduct%."
5083
  msgstr ""
5084
 
5085
+ #: defaults.php:524
5086
+ msgid "User changed the URL of a product"
5087
  msgstr ""
5088
 
5089
+ #: defaults.php:524
5090
+ msgid ""
5091
+ "Changed the URL of the %ProductStatus% product %ProductTitle%%ReportText%."
5092
+ "%ChangeText% View the product: %EditorLinkProduct%."
5093
  msgstr ""
5094
 
5095
+ #: defaults.php:525
5096
+ msgid "User changed the date of a product"
5097
  msgstr ""
5098
 
5099
+ #: defaults.php:525
5100
+ msgid ""
5101
+ "Changed the date of the %ProductStatus% product %ProductTitle% from %OldDate"
5102
+ "% to %NewDate%. View the product: %EditorLinkProduct%."
5103
  msgstr ""
5104
 
5105
+ #: defaults.php:526
5106
+ msgid "User changed the visibility of a product"
5107
  msgstr ""
5108
 
5109
+ #: defaults.php:526
5110
+ msgid ""
5111
+ "Changed the visibility of the %ProductStatus% product %ProductTitle% from "
5112
+ "%OldVisibility% to %NewVisibility%. View the product: %EditorLinkProduct%."
5113
+ msgstr ""
5114
+
5115
+ #: defaults.php:527
5116
+ msgid "User modified the product"
5117
  msgstr ""
5118
 
5119
+ #: defaults.php:527
5120
  msgid ""
5121
+ "Modified the %ProductStatus% product %ProductTitle%. Product URL is "
5122
+ "%ProductUrl%. View the product: %EditorLinkProduct%."
5123
  msgstr ""
5124
 
5125
+ #: defaults.php:528
5126
+ msgid "User modified the draft product"
5127
  msgstr ""
5128
 
5129
+ #: defaults.php:528
5130
  msgid ""
5131
+ "Modified the draft product %ProductTitle%. View the product: "
5132
+ "%EditorLinkProduct%."
5133
  msgstr ""
5134
 
5135
+ #: defaults.php:529
5136
+ msgid "User moved a product to trash"
5137
  msgstr ""
5138
 
5139
+ #: defaults.php:529
5140
  msgid ""
5141
+ "Moved the %ProductStatus% product %ProductTitle% to trash. Product URL was "
5142
+ "%ProductUrl%."
5143
  msgstr ""
5144
 
5145
+ #: defaults.php:530
5146
+ msgid "User permanently deleted a product"
5147
  msgstr ""
5148
 
5149
+ #: defaults.php:530
5150
+ msgid "Permanently deleted the product %ProductTitle%."
5151
  msgstr ""
5152
 
5153
+ #: defaults.php:531
5154
+ msgid "User restored a product from the trash"
5155
  msgstr ""
5156
 
5157
+ #: defaults.php:531
5158
  msgid ""
5159
+ "Product %ProductTitle% has been restored from trash. View product: "
5160
+ "%EditorLinkProduct%."
5161
  msgstr ""
5162
 
5163
+ #: defaults.php:532
5164
+ msgid "User changed status of a product"
5165
  msgstr ""
5166
 
5167
+ #: defaults.php:532
5168
+ msgid ""
5169
+ "Changed the status of the product %ProductTitle% from %OldStatus% to "
5170
+ "%NewStatus%. View the product: %EditorLinkProduct%."
5171
  msgstr ""
5172
 
5173
+ #: defaults.php:533
5174
+ msgid "User opened a product in the editor"
5175
  msgstr ""
5176
 
5177
+ #: defaults.php:533
5178
  msgid ""
5179
+ "Opened the %ProductStatus% product page %ProductTitle% in editor. View the "
5180
+ "product: %EditorLinkProduct%."
5181
  msgstr ""
5182
 
5183
+ #: defaults.php:534
5184
+ msgid "User viewed a product"
5185
  msgstr ""
5186
 
5187
+ #: defaults.php:534
5188
  msgid ""
5189
+ "Viewed the %ProductStatus% product page %ProductTitle%. View the product: "
5190
+ "%EditorLinkProduct%."
5191
  msgstr ""
5192
 
5193
+ #: defaults.php:535
5194
+ msgid "User renamed a product"
5195
  msgstr ""
5196
 
5197
+ #: defaults.php:535
5198
+ msgid ""
5199
+ "Renamed the %ProductStatus% product from %OldTitle% to %NewTitle%. View the "
5200
+ "product: %EditorLinkProduct%."
5201
  msgstr ""
5202
 
5203
+ #: defaults.php:536
5204
+ msgid "User changed the Product Data of a product"
5205
  msgstr ""
5206
 
5207
+ #: defaults.php:536
5208
  msgid ""
5209
+ "Changed the Product Type of the %ProductStatus% product %ProductTitle% from "
5210
+ "%OldType% to %NewType%. View the product: %EditorLinkProduct%."
5211
  msgstr ""
5212
 
5213
+ #: defaults.php:537
5214
+ msgid "User changed type of a price"
5215
  msgstr ""
5216
 
5217
+ #: defaults.php:537
5218
  msgid ""
5219
+ "Changed the %PriceType% of the %ProductStatus% product %ProductTitle% from "
5220
+ "%OldPrice% to %NewPrice%. View the product: %EditorLinkProduct%."
5221
  msgstr ""
5222
 
5223
+ #: defaults.php:538
5224
+ msgid "User changed the SKU of a product"
5225
  msgstr ""
5226
 
5227
+ #: defaults.php:538
5228
  msgid ""
5229
+ "Changed the SKU of the %ProductStatus% product %ProductTitle% from %OldSku% "
5230
+ "to %NewSku%. View the product: %EditorLinkProduct%."
5231
  msgstr ""
5232
 
5233
+ #: defaults.php:539
5234
+ msgid "User changed the stock status of a product"
5235
  msgstr ""
5236
 
5237
+ #: defaults.php:539
5238
  msgid ""
5239
+ "Changed the stock status of the %ProductStatus% product %ProductTitle% from "
5240
+ "%OldStatus% to %NewStatus%. View the product: %EditorLinkProduct%."
5241
  msgstr ""
5242
 
5243
+ #: defaults.php:540
5244
+ msgid "User changed the stock quantity"
5245
  msgstr ""
5246
 
5247
+ #: defaults.php:540
5248
  msgid ""
5249
+ "Changed the stock quantity of the %ProductStatus% product %ProductTitle% "
5250
+ "from %OldValue% to %NewValue%. View the product: %EditorLinkProduct%"
5251
  msgstr ""
5252
 
5253
+ #: defaults.php:541
5254
+ msgid "User set a product type"
5255
  msgstr ""
5256
 
5257
+ #: defaults.php:541
5258
  msgid ""
5259
+ "Changed the type of the %ProductStatus% simple product %ProductTitle% from "
5260
+ "%OldType% to %NewType%. View the product: %EditorLinkProduct%."
5261
  msgstr ""
5262
 
5263
+ #: defaults.php:542
5264
+ msgid "User changed the weight of a product"
5265
  msgstr ""
5266
 
5267
+ #: defaults.php:542
5268
+ msgid ""
5269
+ "Changed the weight of the %ProductStatus% product %ProductTitle% from "
5270
+ "%OldWeight% to %NewWeight%. View the product: %EditorLinkProduct%."
5271
  msgstr ""
5272
 
5273
+ #: defaults.php:543
5274
+ msgid "User changed the dimensions of a product"
5275
  msgstr ""
5276
 
5277
+ #: defaults.php:543
5278
  msgid ""
5279
+ "Changed the %DimensionType% dimensions of the %ProductStatus% product "
5280
+ "%ProductTitle% from %OldDimension% to %NewDimension%. View the product: "
5281
+ "%EditorLinkProduct%."
5282
  msgstr ""
5283
 
5284
+ #: defaults.php:544
5285
+ msgid "User added the Downloadable File to a product"
5286
  msgstr ""
5287
 
5288
+ #: defaults.php:544
5289
  msgid ""
5290
+ "Added the Downloadable File %FileName% with File URL %FileUrl% to the "
5291
+ "%ProductStatus% product %ProductTitle%. View the product: %EditorLinkProduct"
5292
+ "%."
5293
  msgstr ""
5294
 
5295
+ #: defaults.php:545
5296
+ msgid "User Removed the Downloadable File from a product"
5297
  msgstr ""
5298
 
5299
+ #: defaults.php:545
5300
  msgid ""
5301
+ "Removed the Downloadable File %FileName% with File URL %FileUrl% from the "
5302
+ "%ProductStatus% product %ProductTitle%. View the product: %EditorLinkProduct"
5303
+ "%."
5304
  msgstr ""
5305
 
5306
+ #: defaults.php:546
5307
+ msgid "User changed the name of a Downloadable File in a product"
5308
  msgstr ""
5309
 
5310
+ #: defaults.php:546
5311
  msgid ""
5312
+ "Changed the name of a Downloadable File from %OldName% to %NewName% in "
5313
+ "%ProductStatus% product %ProductTitle%. View the product: %EditorLinkProduct"
5314
+ "%."
5315
  msgstr ""
5316
 
5317
+ #: defaults.php:547
5318
+ msgid "User changed the URL of the Downloadable File in a product"
5319
  msgstr ""
5320
 
5321
+ #: defaults.php:547
5322
  msgid ""
5323
+ "Changed the URL of the Downloadable File %FileName% from %OldUrl% to %NewUrl"
5324
+ "% in %ProductStatus% product %ProductTitle%. View the product: "
5325
+ "%EditorLinkProduct%."
5326
  msgstr ""
5327
 
5328
+ #: defaults.php:548
5329
+ msgid "User changed the catalog visibility of a product"
5330
  msgstr ""
5331
 
5332
+ #: defaults.php:548
5333
+ msgid ""
5334
+ "Changed the catalog visibility of the %ProductStatus% product %ProductTitle% "
5335
+ "from %OldVisibility% to %NewVisibility%. View the product: %EditorLinkProduct"
5336
+ "%."
5337
  msgstr ""
5338
 
5339
+ #: defaults.php:549
5340
+ msgid "User changed the setting Featured Product of a product"
5341
  msgstr ""
5342
 
5343
+ #: defaults.php:549
5344
+ msgid ""
5345
+ "%Status% the setting Featured Product in the %ProductStatus% product "
5346
+ "%ProductTitle%. View the product: %EditorLinkProduct%."
5347
  msgstr ""
5348
 
5349
+ #: defaults.php:550
5350
+ msgid "User changed the Allow Backorders setting of a product"
5351
  msgstr ""
5352
 
5353
+ #: defaults.php:550
5354
+ msgid ""
5355
+ "Changed the Allow Backorders setting of the %ProductStatus% product "
5356
+ "%ProductTitle% from %OldStatus% to %NewStatus%. View the product: "
5357
+ "%EditorLinkProduct%."
5358
  msgstr ""
5359
 
5360
+ #: defaults.php:551
5361
+ msgid "User added/removed products to upsell of a product"
5362
  msgstr ""
5363
 
5364
+ #: defaults.php:551
5365
  msgid ""
5366
+ "%Status% the product %UpsellTitle% to Upsells in the %ProductStatus% product "
5367
+ "%ProductTitle%. View the product: %EditorLinkProduct%."
5368
  msgstr ""
5369
 
5370
+ #: defaults.php:552
5371
+ msgid "User added/removed products to cross-sells of a product"
5372
  msgstr ""
5373
 
5374
+ #: defaults.php:552
5375
+ msgid ""
5376
+ "%Status% the product %CrossSellTitle% to Cross-sells in the %ProductStatus% "
5377
+ "product %ProductTitle%. View the product: %EditorLinkProduct%."
5378
  msgstr ""
5379
 
5380
+ #: defaults.php:553
5381
+ msgid "Added a new attribute of a product"
5382
  msgstr ""
5383
 
5384
+ #: defaults.php:553
5385
+ msgid ""
5386
+ "Added a new attribute called %AttributeName% with value %AttributeValue% in "
5387
+ "the %ProductStatus% product %ProductTitle%. View the product: "
5388
+ "%EditorLinkProduct%."
5389
  msgstr ""
5390
 
5391
+ #: defaults.php:554
5392
+ msgid "Modified the value of an attribute of a product"
5393
  msgstr ""
5394
 
5395
+ #: defaults.php:554
5396
  msgid ""
5397
+ "Modified the value of the attribute %AttributeName% from %OldValue% to "
5398
+ "%NewValue% in the %ProductStatus% product %ProductTitle%. View the product: "
5399
+ "%EditorLinkProduct%."
5400
  msgstr ""
5401
 
5402
+ #: defaults.php:555
5403
+ msgid "Changed the name of an attribute of a product"
5404
  msgstr ""
5405
 
5406
+ #: defaults.php:555
5407
  msgid ""
5408
+ "Changed the attribute's name from %OldValue% to %NewValue% in the "
5409
+ "%ProductStatus% product %ProductTitle%. URL is: %ProductUrl%. View the "
5410
+ "product: %EditorLinkProduct%."
5411
  msgstr ""
5412
 
5413
+ #: defaults.php:556
5414
+ msgid "Deleted an attribute of a product"
5415
  msgstr ""
5416
 
5417
+ #: defaults.php:556
5418
  msgid ""
5419
+ "Deleted the attribute %AttributeName% with value %AttributeValue% from "
5420
+ "%ProductStatus% product %ProductTitle%. URL is: %ProductUrl%. View the "
5421
+ "product: %EditorLinkProduct%."
5422
  msgstr ""
5423
 
5424
+ #: defaults.php:557
5425
+ msgid "Set the attribute visibility of a product"
5426
  msgstr ""
5427
 
5428
+ #: defaults.php:557
5429
+ msgid ""
5430
+ "Set the attribute %AttributeName% as %AttributeVisiblilty% on product page "
5431
+ "in %ProductStatus% product %ProductTitle%. View the product: "
5432
+ "%EditorLinkProduct%."
5433
  msgstr ""
5434
 
5435
+ #: defaults.php:564
5436
+ msgid "User changed the Weight Unit"
5437
  msgstr ""
5438
 
5439
+ #: defaults.php:564
5440
+ msgid "Changed the Weight Unit from %OldUnit% to %NewUnit% in WooCommerce."
 
 
5441
  msgstr ""
5442
 
5443
+ #: defaults.php:565
5444
+ msgid "User changed the Dimensions Unit"
5445
  msgstr ""
5446
 
5447
+ #: defaults.php:565
5448
+ msgid "Changed the Dimensions Unit from %OldUnit% to %NewUnit% in WooCommerce."
 
 
5449
  msgstr ""
5450
 
5451
+ #: defaults.php:566
5452
+ msgid "User changed the Base Location"
5453
  msgstr ""
5454
 
5455
+ #: defaults.php:566
5456
+ msgid ""
5457
+ "Changed the Base Location from %OldLocation% to %NewLocation% in WooCommerce."
5458
  msgstr ""
5459
 
5460
+ #: defaults.php:567
5461
+ msgid "User Enabled/Disabled taxes"
5462
  msgstr ""
5463
 
5464
+ #: defaults.php:567
5465
+ msgid "%Status% taxes in the WooCommerce store."
 
 
5466
  msgstr ""
5467
 
5468
+ #: defaults.php:568
5469
+ msgid "User changed the currency"
5470
+ msgstr ""
5471
+
5472
+ #: defaults.php:568
5473
+ msgid ""
5474
+ "Changed the currency from %OldCurrency% to %NewCurrency% in WooCommerce."
5475
  msgstr ""
5476
 
5477
+ #: defaults.php:569
5478
+ msgid "User Enabled/Disabled the use of coupons during checkout"
5479
  msgstr ""
5480
 
5481
+ #: defaults.php:569
5482
+ msgid "%Status% the use of coupons during checkout in WooCommerce."
5483
  msgstr ""
5484
 
5485
+ #: defaults.php:570
5486
+ msgid "User Enabled/Disabled guest checkout"
5487
  msgstr ""
5488
 
5489
+ #: defaults.php:570
5490
+ msgid "%Status% guest checkout in WooCommerce."
5491
  msgstr ""
5492
 
5493
+ #: defaults.php:571
5494
+ msgid "User Enabled/Disabled cash on delivery"
5495
  msgstr ""
5496
 
5497
+ #: defaults.php:571
5498
+ msgid "%Status% the option Cash on Delivery in WooCommerce."
5499
  msgstr ""
5500
 
5501
+ #: defaults.php:572
5502
+ msgid "User enabled a payment gateway"
 
 
5503
  msgstr ""
5504
 
5505
+ #: defaults.php:572
5506
+ msgid "Enabled the payment gateway %GatewayName%."
5507
  msgstr ""
5508
 
5509
+ #: defaults.php:573
5510
+ msgid "User disabled a payment gateway"
5511
  msgstr ""
5512
 
5513
+ #: defaults.php:573
5514
+ msgid "Disabled the payment gateway %GatewayName%."
 
 
5515
  msgstr ""
5516
 
5517
+ #: defaults.php:574
5518
+ msgid "User modified a payment gateway"
5519
  msgstr ""
5520
 
5521
+ #: defaults.php:574
5522
+ msgid "Modified the payment gateway %GatewayName%."
 
 
5523
  msgstr ""
5524
 
5525
+ #: defaults.php:575
5526
+ msgid "User modified prices with tax option"
5527
  msgstr ""
5528
 
5529
+ #: defaults.php:575
5530
+ msgid "Set the option that prices are %TaxStatus% of tax."
 
 
5531
  msgstr ""
5532
 
5533
+ #: defaults.php:576
5534
+ msgid "User modified tax calculation base"
5535
  msgstr ""
5536
 
5537
+ #: defaults.php:576
5538
+ msgid "Set the setting Calculate tax based on to %Setting%."
 
 
5539
  msgstr ""
5540
 
5541
+ #: defaults.php:577
5542
+ msgid "User modified shipping tax class"
5543
  msgstr ""
5544
 
5545
+ #: defaults.php:577
5546
+ msgid "Set the Shipping tax class to %Setting%."
 
 
5547
  msgstr ""
5548
 
5549
+ #: defaults.php:578
5550
+ msgid "User enabled/disabled rounding of tax"
5551
  msgstr ""
5552
 
5553
+ #: defaults.php:578
5554
+ msgid "%Status% rounding of tax at subtotal level."
 
 
5555
  msgstr ""
5556
 
5557
+ #: defaults.php:579
5558
+ msgid "User modified a shipping zone"
5559
  msgstr ""
5560
 
5561
+ #: defaults.php:579
5562
+ msgid "%ShippingZoneStatus% the shipping zone %ShippingZoneName%."
 
 
5563
  msgstr ""
5564
 
5565
+ #: defaults.php:580
5566
+ msgid "User created a new product category"
5567
  msgstr ""
5568
 
5569
+ #: defaults.php:580
5570
  msgid ""
5571
+ "Created a new product category called %CategoryName% in WooCommerce. Product "
5572
+ "category slug is %Slug%."
5573
  msgstr ""
5574
 
5575
+ #: defaults.php:581
5576
+ msgid "User deleted a product category"
5577
  msgstr ""
5578
 
5579
+ #: defaults.php:581
5580
  msgid ""
5581
+ "Deleted the product category called %CategoryName% in WooCommerce. Product "
5582
+ "category slug was %CategorySlug%."
5583
  msgstr ""
5584
 
5585
+ #: defaults.php:582
5586
+ msgid "User changed the slug of a product category"
5587
  msgstr ""
5588
 
5589
+ #: defaults.php:582
5590
  msgid ""
5591
+ "Changed the Slug of the product category %CategoryName% in WooCommerce from "
5592
+ "%OldSlug% to %NewSlug%."
5593
  msgstr ""
5594
 
5595
+ #: defaults.php:583
5596
+ msgid "User changed the parent category of a product category"
5597
  msgstr ""
5598
 
5599
+ #: defaults.php:583
5600
  msgid ""
5601
+ "Changed the Parent Category of the product category %CategoryName% in "
5602
+ "WooCommerce from %OldParentCat% to %NewParentCat%."
5603
  msgstr ""
5604
 
5605
+ #: defaults.php:584
5606
+ msgid "User changed the display type of a product category"
5607
  msgstr ""
5608
 
5609
+ #: defaults.php:584
5610
  msgid ""
5611
+ "Changed the Display Type of the product category %CategoryName% in "
5612
+ "WooCommerce from %OldDisplayType% to %NewDisplayType%."
5613
  msgstr ""
5614
 
5615
+ #: defaults.php:585
5616
+ msgid "User changed the name of a product category"
5617
  msgstr ""
5618
 
5619
+ #: defaults.php:585
5620
  msgid ""
5621
+ "Changed the name of the product category %CategoryName% in WooCommerce from "
5622
+ "%OldName% to %NewName%."
5623
  msgstr ""
5624
 
5625
+ #: defaults.php:586
5626
+ msgid "User created a new attribute"
5627
  msgstr ""
5628
 
5629
+ #: defaults.php:586
5630
+ msgid ""
5631
+ "Created a new Attribute called %AttributeName% with slug %AttributeSlug% in "
5632
+ "WooCommerce."
5633
  msgstr ""
5634
 
5635
+ #: defaults.php:587
5636
+ msgid "User deleted an attribute"
5637
  msgstr ""
5638
 
5639
+ #: defaults.php:587
5640
  msgid ""
5641
+ "Deleted the Attribute called %AttributeName% with Slug %AttributeSlug% from "
5642
+ "WooCommerce."
5643
  msgstr ""
5644
 
5645
+ #: defaults.php:588
5646
+ msgid "User changed the slug of an attribute"
5647
  msgstr ""
5648
 
5649
+ #: defaults.php:588
5650
  msgid ""
5651
+ "Changed the Slug of the Attribute %AttributeName% in WooCommerce from "
5652
+ "%OldSlug% to %NewSlug%."
5653
  msgstr ""
5654
 
5655
+ #: defaults.php:589
5656
+ msgid "User changed the name of an attribute"
5657
  msgstr ""
5658
 
5659
+ #: defaults.php:589
5660
  msgid ""
5661
+ "Changed the Name of the Attribute %AttributeName% in WooCommerce from "
5662
+ "%OldName% to %NewName%."
5663
  msgstr ""
5664
 
5665
+ #: defaults.php:590
5666
+ msgid "User changed the default sort order of an attribute"
5667
  msgstr ""
5668
 
5669
+ #: defaults.php:590
5670
  msgid ""
5671
+ "Changed the Default Sort Order of the Attribute %AttributeName% in "
5672
+ "WooCommerce from %OldSortOrder% to %NewSortOrder%."
5673
  msgstr ""
5674
 
5675
+ #: defaults.php:591
5676
+ msgid "User enabled/disabled the option Enable Archives of an attribute"
5677
  msgstr ""
5678
 
5679
+ #: defaults.php:591
5680
  msgid ""
5681
+ "%ArchivesStatus% the option Enable Archives in the Attribute %AttributeName% "
5682
+ "in WooCommerce."
5683
  msgstr ""
5684
 
5685
+ #: defaults.php:592
5686
+ msgid "User published a new coupon"
5687
  msgstr ""
5688
 
5689
+ #: defaults.php:592
5690
+ msgid "Published a new coupon called %CouponName% in WooCommerce."
 
 
5691
  msgstr ""
5692
 
5693
+ #: defaults.php:593
5694
+ msgid "User changed the discount type of a coupon"
5695
  msgstr ""
5696
 
5697
+ #: defaults.php:593
5698
  msgid ""
5699
+ "Changed the Discount Type of the %CouponStatus% WooCommerce coupon "
5700
+ "%CouponName% from %OldDiscountType% to %NewDiscountType%."
5701
  msgstr ""
5702
 
5703
+ #: defaults.php:594
5704
+ msgid "User changed the coupon amount of a coupon"
5705
  msgstr ""
5706
 
5707
+ #: defaults.php:594
5708
  msgid ""
5709
+ "Changed the Coupon Amount of the %CouponStatus% WooCommerce coupon "
5710
+ "%CouponName% from %OldAmount% to %NewAmount%."
5711
  msgstr ""
5712
 
5713
+ #: defaults.php:595
5714
+ msgid "User changed the coupon expire date of a coupon"
5715
  msgstr ""
5716
 
5717
+ #: defaults.php:595
5718
  msgid ""
5719
+ "Changed the Coupon Expire Date of the %CouponStatus% WooCommerce coupon "
5720
+ "%CouponName% from %OldDate% to %NewDate%."
5721
  msgstr ""
5722
 
5723
+ #: defaults.php:596
5724
+ msgid "User changed the usage restriction settings of a coupon"
5725
  msgstr ""
5726
 
5727
+ #: defaults.php:596
5728
  msgid ""
5729
+ "Changed the Usage Restriction settings of the %CouponStatus% WooCommerce "
5730
+ "coupon %CouponName%."
5731
  msgstr ""
5732
 
5733
+ #: defaults.php:597
5734
+ msgid "User changed the usage limits settings of a coupon"
5735
  msgstr ""
5736
 
5737
+ #: defaults.php:597
5738
  msgid ""
5739
+ "Changed the Usage Limits settings of the %CouponStatus% WooCommerce coupon "
5740
+ "%CouponName%."
5741
  msgstr ""
5742
 
5743
+ #: defaults.php:598
5744
+ msgid "User changed the description of a coupon"
5745
  msgstr ""
5746
 
5747
+ #: defaults.php:598
5748
  msgid ""
5749
+ "Changed the Description of the %CouponStatus% WooCommerce coupon %CouponName"
5750
+ "%."
5751
  msgstr ""
5752
 
5753
+ #: defaults.php:599
5754
+ msgid "User changed the status of a coupon"
5755
  msgstr ""
5756
 
5757
+ #: defaults.php:599
5758
  msgid ""
5759
+ "Changed the Status of the WooCommerce coupon %CouponName% from %OldStatus% "
5760
+ "to %NewStatus%."
5761
  msgstr ""
5762
 
5763
+ #: defaults.php:600
5764
+ msgid "User renamed a WooCommerce coupon"
5765
  msgstr ""
5766
 
5767
+ #: defaults.php:600
5768
+ msgid "Renamed the WooCommerce coupon %OldName% to %NewName%."
5769
  msgstr ""
5770
 
5771
+ #: defaults.php:601
5772
+ msgid "A WooCommerce order has been placed"
5773
  msgstr ""
5774
 
5775
+ #: defaults.php:601
5776
+ msgid ""
5777
+ "A WooCommerce order %OrderTitle% has just been placed. %EditorLinkOrder%."
5778
  msgstr ""
5779
 
5780
+ #: defaults.php:602
5781
+ msgid "WooCommerce order status changed"
5782
  msgstr ""
5783
 
5784
+ #: defaults.php:602
5785
  msgid ""
5786
+ "Marked the WooCommerce order %OrderTitle% as %OrderStatus%. %EditorLinkOrder"
5787
+ "%."
5788
  msgstr ""
5789
 
5790
+ #: defaults.php:603
5791
+ msgid "User moved a WooCommerce order to trash"
5792
  msgstr ""
5793
 
5794
+ #: defaults.php:603
5795
+ msgid "Moved the WooCommerce order %OrderTitle% to trash."
5796
  msgstr ""
5797
 
5798
+ #: defaults.php:604
5799
+ msgid "User moved a WooCommerce order out of trash"
5800
  msgstr ""
5801
 
5802
+ #: defaults.php:604
5803
  msgid ""
5804
+ "Moved the WooCommerce order %OrderTitle% out of trash. %EditorLinkOrder%."
 
 
 
 
5805
  msgstr ""
5806
 
5807
+ #: defaults.php:605
5808
+ msgid "User permanently deleted a WooCommerce order"
5809
  msgstr ""
5810
 
5811
+ #: defaults.php:605
5812
+ msgid "Permanently deleted the WooCommerce order %OrderTitle%."
5813
  msgstr ""
5814
 
5815
+ #: defaults.php:606
5816
+ msgid "User edited a WooCommerce order"
5817
  msgstr ""
5818
 
5819
+ #: defaults.php:606
5820
+ msgid "Edited the WooCommerce order %OrderTitle%. %EditorLinkOrder%."
5821
  msgstr ""
5822
 
5823
+ #: defaults.php:607
5824
+ msgid "User refunded a WooCommerce order"
5825
  msgstr ""
5826
 
5827
+ #: defaults.php:607
5828
+ msgid "Refunded the WooCommerce order %OrderTitle%. %EditorLinkOrder%."
5829
  msgstr ""
5830
 
5831
+ #: defaults.php:614
5832
  msgid "User changed title of a SEO post"
5833
  msgstr ""
5834
 
5835
+ #: defaults.php:614
5836
  msgid ""
5837
  "Changed the SEO title of the %PostStatus% %PostType%%ReportText%.%ChangeText"
5838
  "% %EditorLinkPost%."
5839
  msgstr ""
5840
 
5841
+ #: defaults.php:615
5842
  msgid "User changed the meta description of a SEO post"
5843
  msgstr ""
5844
 
5845
+ #: defaults.php:615
5846
  msgid ""
5847
  "Changed the Meta description of the %PostStatus% %PostType% titled %PostTitle"
5848
  "%%ReportText%.%ChangeText% %EditorLinkPost%."
5849
  msgstr ""
5850
 
5851
+ #: defaults.php:616
5852
  msgid ""
5853
  "User changed setting to allow search engines to show post in search results "
5854
  "of a SEO post"
5855
  msgstr ""
5856
 
5857
+ #: defaults.php:616
5858
  msgid ""
5859
  "Changed the setting to allow search engines to show post in search results "
5860
  "from %OldStatus% to %NewStatus% in the %PostStatus% %PostType% titled "
5861
  "%PostTitle%. %EditorLinkPost%."
5862
  msgstr ""
5863
 
5864
+ #: defaults.php:617
5865
  msgid ""
5866
  "User Enabled/Disabled the option for search engine to follow links of a SEO "
5867
  "post"
5868
  msgstr ""
5869
 
5870
+ #: defaults.php:617
5871
  msgid ""
5872
  "%NewStatus% the option for search engine to follow links in the %PostType% "
5873
  "titled %PostTitle%. %EditorLinkPost%."
5874
  msgstr ""
5875
 
5876
+ #: defaults.php:618
5877
  msgid "User set the meta robots advanced setting of a SEO post"
5878
  msgstr ""
5879
 
5880
+ #: defaults.php:618
5881
  msgid ""
5882
  "Set the Meta Robots Advanced setting to %NewStatus% in the %PostStatus% "
5883
  "%PostType% titled %PostTitle%. %EditorLinkPost%."
5884
  msgstr ""
5885
 
5886
+ #: defaults.php:619
5887
  msgid "User changed the canonical URL of a SEO post"
5888
  msgstr ""
5889
 
5890
+ #: defaults.php:619
5891
  msgid ""
5892
  "Changed the Canonical URL of the %PostStatus% %PostType% titled %PostTitle%"
5893
  "%ReportText%.%ChangeText% %EditorLinkPost%."
5894
  msgstr ""
5895
 
5896
+ #: defaults.php:620
5897
  msgid "User changed the focus keyword of a SEO post"
5898
  msgstr ""
5899
 
5900
+ #: defaults.php:620
5901
  msgid ""
5902
  "Changed the focus keyword of the %PostStatus% %PostType% titled %PostTitle% "
5903
  "from %old_keywords% to %new_keywords%. %EditorLinkPost%."
5904
  msgstr ""
5905
 
5906
+ #: defaults.php:621
5907
  msgid "User Enabled/Disabled the option Cornerston Content of a SEO post"
5908
  msgstr ""
5909
 
5910
+ #: defaults.php:621
5911
  msgid ""
5912
  "%Status% the option Cornerston Content on the %PostStatus% %PostType% titled "
5913
  "%PostTitle%. %EditorLinkPost%."
5914
  msgstr ""
5915
 
5916
+ #: defaults.php:622
5917
  msgid "User changed the Title Separator setting"
5918
  msgstr ""
5919
 
5920
+ #: defaults.php:622
5921
  msgid ""
5922
  "Changed the Title Separator from %old% to %new% in the Yoast SEO plugin "
5923
  "settings."
5924
  msgstr ""
5925
 
5926
+ #: defaults.php:623
5927
  msgid "User changed the Homepage Title setting"
5928
  msgstr ""
5929
 
5930
+ #: defaults.php:623
5931
  msgid ""
5932
  "Changed the Homepage Title%ReportText% in the Yoast SEO plugin settings."
5933
  "%ChangeText%"
5934
  msgstr ""
5935
 
5936
+ #: defaults.php:624
5937
  msgid "User changed the Homepage Meta description setting"
5938
  msgstr ""
5939
 
5940
+ #: defaults.php:624
5941
  msgid ""
5942
  "Changed the Homepage Meta description%ReportText% in the Yoast SEO plugin "
5943
  "settings.%ChangeText%"
5944
  msgstr ""
5945
 
5946
+ #: defaults.php:625
5947
  msgid "User changed the Company or Person setting"
5948
  msgstr ""
5949
 
5950
+ #: defaults.php:625
5951
  msgid ""
5952
  "Changed the Company or Person setting from %old% to %new% in the YOAST SEO "
5953
  "plugin settings."
5954
  msgstr ""
5955
 
5956
+ #: defaults.php:626
5957
  msgid ""
5958
  "User Enabled/Disabled the option Show Posts/Pages in Search Results in the "
5959
  "Yoast SEO plugin settings"
5960
  msgstr ""
5961
 
5962
+ #: defaults.php:626
5963
  msgid ""
5964
  "%Status% the option Show %SEOPostType% in Search Results in the Yoast SEO "
5965
  "plugin settings."
5966
  msgstr ""
5967
 
5968
+ #: defaults.php:627
5969
  msgid ""
5970
  "User changed the Posts/Pages title template in the Yoast SEO plugin settings"
5971
  msgstr ""
5972
 
5973
+ #: defaults.php:627
5974
  msgid ""
5975
  "Changed the %SEOPostType% title template from %old% to %new% in the Yoast "
5976
  "SEO plugin settings."
5977
  msgstr ""
5978
 
5979
+ #: defaults.php:628
5980
  msgid "User Enabled/Disabled SEO analysis in the Yoast SEO plugin settings"
5981
  msgstr ""
5982
 
5983
+ #: defaults.php:628
5984
  msgid "%Status% SEO analysis in the Yoast SEO plugin settings."
5985
  msgstr ""
5986
 
5987
+ #: defaults.php:629
5988
  msgid ""
5989
  "User Enabled/Disabled readability analysis in the Yoast SEO plugin settings"
5990
  msgstr ""
5991
 
5992
+ #: defaults.php:629
5993
  msgid "%Status% Readability analysis in the Yoast SEO plugin settings."
5994
  msgstr ""
5995
 
5996
+ #: defaults.php:630
5997
  msgid ""
5998
  "User Enabled/Disabled cornerstone content in the Yoast SEO plugin settings"
5999
  msgstr ""
6000
 
6001
+ #: defaults.php:630
6002
  msgid "%Status% Cornerstone content in the Yoast SEO plugin settings."
6003
  msgstr ""
6004
 
6005
+ #: defaults.php:631
6006
  msgid ""
6007
  "User Enabled/Disabled the text link counter in the Yoast SEO plugin settings"
6008
  msgstr ""
6009
 
6010
+ #: defaults.php:631
6011
  msgid "%Status% the Text link counter in the Yoast SEO plugin settings."
6012
  msgstr ""
6013
 
6014
+ #: defaults.php:632
6015
  msgid "User Enabled/Disabled XML sitemaps in the Yoast SEO plugin settings"
6016
  msgstr ""
6017
 
6018
+ #: defaults.php:632
6019
  msgid "%Status% XML Sitemaps in the Yoast SEO plugin settings."
6020
  msgstr ""
6021
 
6022
+ #: defaults.php:633
6023
  msgid "User Enabled/Disabled ryte integration in the Yoast SEO plugin settings"
6024
  msgstr ""
6025
 
6026
+ #: defaults.php:633
6027
  msgid "%Status% Ryte Integration in the Yoast SEO plugin settings."
6028
  msgstr ""
6029
 
6030
+ #: defaults.php:634
6031
  msgid ""
6032
  "User Enabled/Disabled the admin bar menu in the Yoast SEO plugin settings"
6033
  msgstr ""
6034
 
6035
+ #: defaults.php:634
6036
  msgid "%Status% the Admin bar menu in the Yoast SEO plugin settings."
6037
  msgstr ""
6038
 
6039
+ #: defaults.php:635
6040
  msgid ""
6041
  "User changed the Posts/Pages meta description template in the Yoast SEO "
6042
  "plugin settings"
6043
  msgstr ""
6044
 
6045
+ #: defaults.php:635
6046
  msgid ""
6047
  "Changed the %SEOPostType% meta description template from %old% to %new% in "
6048
  "the Yoast SEO plugin settings."
6049
  msgstr ""
6050
 
6051
+ #: defaults.php:636
6052
  msgid ""
6053
  "User set the option Date in Snippet Preview for Posts/Pages in the Yoast SEO "
6054
  "plugin settings"
6055
  msgstr ""
6056
 
6057
+ #: defaults.php:636
6058
  msgid ""
6059
  "%Status% the option Date in Snippet Preview for %SEOPostType% in the Yoast "
6060
  "SEO plugin settings."
6061
  msgstr ""
6062
 
6063
+ #: defaults.php:637
6064
  msgid ""
6065
  "User set the option Yoast SEO Meta Box for Posts/Pages in the Yoast SEO "
6066
  "plugin settings"
6067
  msgstr ""
6068
 
6069
+ #: defaults.php:637
6070
  msgid ""
6071
  "%Status% the option Yoast SEO Meta Box for %SEOPostType% in the Yoast SEO "
6072
  "plugin settings."
6073
  msgstr ""
6074
 
6075
+ #: defaults.php:638
6076
  msgid ""
6077
  "User Enabled/Disabled the advanced settings for authors in the Yoast SEO "
6078
  "plugin settings"
6079
  msgstr ""
6080
 
6081
+ #: defaults.php:638
6082
  msgid "%Status% the advanced settings for authors in the Yoast SEO settings."
6083
  msgstr ""
6084
 
6085
+ #. translators: Username
6086
+ #: wp-security-audit-log.php:459 wp-security-audit-log.php:486
6087
  #, php-format
6088
  msgid "Hey %1$s"
6089
  msgstr ""
6090
 
6091
+ #: wp-security-audit-log.php:460
6092
  msgid ""
6093
  "Never miss an important update! Opt-in to our security and feature updates "
6094
  "notifications, and non-sensitive diagnostic tracking with freemius.com."
6095
  msgstr ""
6096
 
6097
+ #: wp-security-audit-log.php:461 wp-security-audit-log.php:489
6098
  msgid "Note: "
6099
  msgstr ""
6100
 
6101
+ #: wp-security-audit-log.php:462 wp-security-audit-log.php:490
6102
  msgid "NO AUDIT LOG ACTIVITY & DATA IS SENT BACK TO OUR SERVERS."
6103
  msgstr ""
6104
 
6105
+ #. translators: 1: Plugin name. 2: Freemius link.
6106
+ #: wp-security-audit-log.php:488
6107
  #, php-format
6108
  msgid ""
6109
  "Please help us improve %2$s! If you opt-in, some non-sensitive data about "
6111
  "use. If you skip this, that's okay! %2$s will still work just fine."
6112
  msgstr ""
6113
 
6114
+ #. translators: Plugin name
6115
+ #: wp-security-audit-log.php:510
6116
+ #, php-format
6117
+ msgid ""
6118
+ "Get a free 7-day trial of the premium edition of %s. No credit card "
6119
+ "required, no commitments!"
6120
+ msgstr ""
6121
+
6122
+ #. Plugin Name of the plugin/theme
6123
+ #: wp-security-audit-log.php:511
6124
+ msgid "WP Security Audit Log"
6125
+ msgstr ""
6126
+
6127
+ #: wp-security-audit-log.php:515
6128
+ msgid "Start free trial"
6129
+ msgstr ""
6130
+
6131
+ #: wp-security-audit-log.php:660
6132
  msgid ""
6133
  "Error: You do not have sufficient permissions to disable this custom field."
6134
  msgstr ""
6135
 
6136
+ #: wp-security-audit-log.php:696
6137
  msgid "Error: You do not have sufficient permissions to disable this alert."
6138
  msgstr ""
6139
 
6140
+ #: wp-security-audit-log.php:820
6141
  #, php-format
6142
  msgid ""
6143
  "You are using a version of PHP that is older than %s, which is no longer "
6144
  "supported."
6145
  msgstr ""
6146
 
6147
+ #: wp-security-audit-log.php:822
6148
  msgid ""
6149
  "Contact us on <a href=\"mailto:plugins@wpwhitesecurity.com"
6150
  "\">plugins@wpwhitesecurity.com</a> to help you switch the version of PHP you "
6151
  "are using."
6152
  msgstr ""
6153
 
6154
+ #: wp-security-audit-log.php:824
6155
+ msgid ""
6156
+ "The WP Security Audit Log plugin is a multisite network tool, so it has to "
6157
+ "be activated at network level."
6158
+ msgstr ""
6159
+
6160
+ #: wp-security-audit-log.php:826
6161
+ msgid "Redirect me to the network dashboard"
6162
+ msgstr ""
6163
+
6164
+ #: wp-security-audit-log.php:909
6165
+ msgid ""
6166
+ "This plugin uses 3 tables in the WordPress database to store the activity "
6167
+ "log and settings. It seems that these tables were not created."
6168
+ msgstr ""
6169
+
6170
+ #: wp-security-audit-log.php:911
6171
+ msgid ""
6172
+ "This could happen because the database user does not have the right "
6173
+ "privileges to create the tables in the database. We recommend you to update "
6174
+ "the privileges and try enabling the plugin again."
6175
+ msgstr ""
6176
+
6177
+ #: wp-security-audit-log.php:913
6178
+ #, php-format
6179
+ msgid ""
6180
+ "If after doing so you still have issues, please send us an email on %s for "
6181
+ "assistance."
6182
+ msgstr ""
6183
+
6184
+ #: wp-security-audit-log.php:913
6185
+ msgid "support@wpsecurityauditlog.com"
6186
+ msgstr ""
6187
+
6188
+ #: wp-security-audit-log.php:1564
6189
+ msgid "Every 6 hours"
6190
+ msgstr ""
6191
+
6192
+ #: wp-security-audit-log.php:1568
6193
+ msgid "Every 45 minutes"
6194
+ msgstr ""
6195
+
6196
+ #: wp-security-audit-log.php:1572
6197
+ msgid "Every 30 minutes"
6198
+ msgstr ""
6199
+
6200
+ #: wp-security-audit-log.php:1576
6201
+ msgid "Every 15 minutes"
6202
+ msgstr ""
6203
+
6204
+ #: wp-security-audit-log.php:1580
6205
+ msgid "Every 10 minutes"
6206
+ msgstr ""
6207
+
6208
+ #: wp-security-audit-log.php:1584
6209
+ msgid "Every 1 minute"
6210
+ msgstr ""
6211
+
6212
+ #. translators: 1. Deprecated method name 2. Version since deprecated
6213
+ #: wp-security-audit-log.php:1598
6214
+ #, php-format
6215
+ msgid "Method %1$s is deprecated since version %2$s!"
6216
  msgstr ""
6217
 
6218
  #. Plugin URI of the plugin/theme
 
6219
  msgid "http://www.wpsecurityauditlog.com/"
6220
  msgstr ""
6221
 
6232
  #. Author of the plugin/theme
6233
  msgid "WP White Security"
6234
  msgstr ""
6235
+
6236
+ #. Author URI of the plugin/theme
6237
+ msgid "http://www.wpwhitesecurity.com/"
6238
+ msgstr ""
readme.txt CHANGED
@@ -5,8 +5,8 @@ License: GPLv3
5
  License URI: http://www.gnu.org/licenses/gpl.html
6
  Tags: wordpress security plugin, wordpress security audit log, audit log, activity logs, event log wordpress, wordpress user tracking, wordpress activity log, wordpress audit, security event log, audit trail, wordpress security monitor, wordpress admin, wordpress admin monitoring, user activity, admin, multisite, dashboard, notification, wordpress monitoring, email notification, wordpress email alerts, tracking, user tracking, user activity report, wordpress audit trail
7
  Requires at least: 3.6
8
- Tested up to: 5.0.3
9
- Stable tag: 3.3.1.1
10
  Requires PHP: 5.4.43
11
 
12
  An easy to use & comprehensive WordPress activity log plugin to log all changes on WordPress sites & multisite networks.
@@ -195,17 +195,19 @@ Please refer to our [Support & Documentation pages](https://www.wpsecurityauditl
195
 
196
  == Changelog ==
197
 
198
- Release notes: [Infinite scroll for activity logs & performance enhancement](https://www.wpsecurityauditlog.com/releases/infinite-scroll-performance-improvements-update-3-3-1-1)
199
 
200
- = 3.3.1.1 (2019-02-06) =
201
 
202
- * **New Features**
203
- * New [infinite scroll view in audit log viewer](https://www.wpsecurityauditlog.com/support-documentation/change-audit-log-viewer-pagination-infinite-scroll/) making the browsing of the activity logs much faster.
 
 
 
 
204
 
205
  * **Plugin Improvements**
206
- * Improved the search filters - now they are much faster.
207
- * Improved user session handling to better handle >1,000 sessions.
208
- * Replaced PHP severity with event log severity in the list of Events.
209
 
210
  * **Bug Fixes**
211
- * Scan Now button for the [WordPress file integrity scanner](https://www.wpsecurityauditlog.com/support-documentation/wordpress-files-changes-warning-activity-logs/) is grayed out when auto scanning is disabled.
5
  License URI: http://www.gnu.org/licenses/gpl.html
6
  Tags: wordpress security plugin, wordpress security audit log, audit log, activity logs, event log wordpress, wordpress user tracking, wordpress activity log, wordpress audit, security event log, audit trail, wordpress security monitor, wordpress admin, wordpress admin monitoring, user activity, admin, multisite, dashboard, notification, wordpress monitoring, email notification, wordpress email alerts, tracking, user tracking, user activity report, wordpress audit trail
7
  Requires at least: 3.6
8
+ Tested up to: 5.1.0
9
+ Stable tag: 3.3.1.2
10
  Requires PHP: 5.4.43
11
 
12
  An easy to use & comprehensive WordPress activity log plugin to log all changes on WordPress sites & multisite networks.
195
 
196
  == Changelog ==
197
 
198
+ Release notes: [Activity Log Coverage of WooCommerce Variable Products](https://www.wpsecurityauditlog.com/releases/support-woocommerce-variable-products)
199
 
200
+ = 3.3.1.2 (2019-02-25) =
201
 
202
+ * **New Activity Log Events for WooCommerce**
203
+ * Event ID 9078: Changed the option to include / exclude taxes in product prices.
204
+ * Event ID 9079: Changed the option on what type of shipping to calculate tax on.
205
+ * Event ID 9080: Changed the shipping tax class.
206
+ * Event ID 9081: Enabled / Disabled the rounding of the sub total.
207
+ * Event ID 9082: Added / Deleted / Modified a shipping zone on WooCommerce.
208
 
209
  * **Plugin Improvements**
210
+ * Better handling of plugin activation on multisite - plugin can only be activated from the network dashboard.
 
 
211
 
212
  * **Bug Fixes**
213
+ * Updated Freemius SDK which includes a security fix.
sdk/class-wsal-browser.php CHANGED
@@ -591,7 +591,6 @@ class WSAL_Browser {
591
  */
592
  public $PLATFORM_ANDROID = 'Android';
593
 
594
-
595
  /**
596
  * OPERATING_SYSTEM_UNKNOWN
597
  *
@@ -604,7 +603,7 @@ class WSAL_Browser {
604
  *
605
  * @param string $useragent - User agent.
606
  */
607
- function __construct( $useragent = '' ) {
608
  $this->reset();
609
  if ( '' != $useragent ) {
610
  $this->setUserAgent( $useragent );
@@ -616,17 +615,17 @@ class WSAL_Browser {
616
  /**
617
  * Reset all properties
618
  */
619
- function reset() {
620
- $http_user_agent = filter_input( INPUT_SERVER, 'HTTP_USER_AGENT', FILTER_SANITIZE_STRING );
621
- $this->_agent = ! empty( $http_user_agent ) ? $http_user_agent : '';
622
  $this->_browser_name = $this->BROWSER_UNKNOWN;
623
- $this->_version = $this->VERSION_UNKNOWN;
624
- $this->_platform = $this->PLATFORM_UNKNOWN;
625
- $this->_os = $this->OPERATING_SYSTEM_UNKNOWN;
626
- $this->_is_aol = false;
627
- $this->_is_mobile = false;
628
- $this->_is_robot = false;
629
- $this->_aol_version = $this->VERSION_UNKNOWN;
630
  }
631
 
632
  /**
@@ -635,7 +634,7 @@ class WSAL_Browser {
635
  * @param string $browser_name - Browser name.
636
  * @return True if the browser is the specified browser
637
  */
638
- function isBrowser( $browser_name ) {
639
  return 0 == strcasecmp( $this->_browser_name, trim( $browser_name ) );
640
  }
641
 
@@ -644,17 +643,17 @@ class WSAL_Browser {
644
  *
645
  * @return string Name of the browser
646
  */
647
- function getBrowser() {
648
  return $this->_browser_name;
649
  }
650
 
651
  /**
652
  * Set the name of the browser
653
  *
654
- * @param unknown $browser - The name of the Browser.
655
  */
656
- function setBrowser( $browser ) {
657
- return $this->_browser_name = $browser;
658
  }
659
 
660
  /**
@@ -662,17 +661,17 @@ class WSAL_Browser {
662
  *
663
  * @return string Name of the browser
664
  */
665
- function getPlatform() {
666
  return $this->_platform;
667
  }
668
 
669
  /**
670
  * Set the name of the platform
671
  *
672
- * @param unknown $platform - The name of the Platform.
673
  */
674
- function setPlatform( $platform ) {
675
- return $this->_platform = $platform;
676
  }
677
 
678
  /**
@@ -680,7 +679,7 @@ class WSAL_Browser {
680
  *
681
  * @return string Version of the browser (will only contain alpha-numeric characters and a period)
682
  */
683
- function getVersion() {
684
  return $this->_version;
685
  }
686
 
@@ -688,9 +687,9 @@ class WSAL_Browser {
688
  /**
689
  * Set the version of the browser
690
  *
691
- * @param unknown $version - The version of the Browser.
692
  */
693
- function setVersion( $version ) {
694
  $this->_version = preg_replace( '/[^0-9,.,a-z,A-Z-]/', '', $version );
695
  }
696
 
@@ -699,16 +698,16 @@ class WSAL_Browser {
699
  *
700
  * @return string Version of AOL (will only contain alpha-numeric characters and a period)
701
  */
702
- function getAolVersion() {
703
  return $this->_aol_version;
704
  }
705
 
706
  /**
707
  * Set the version of AOL
708
  *
709
- * @param unknown $version - The version of AOL.
710
  */
711
- function setAolVersion( $version ) {
712
  $this->_aol_version = preg_replace( '/[^0-9,.,a-z,A-Z]/', '', $version );
713
  }
714
 
@@ -717,7 +716,7 @@ class WSAL_Browser {
717
  *
718
  * @return boolean True if the browser is from AOL otherwise false
719
  */
720
- function isAol() {
721
  return $this->_is_aol;
722
  }
723
 
@@ -726,7 +725,7 @@ class WSAL_Browser {
726
  *
727
  * @return boolean True if the browser is from a mobile device otherwise false
728
  */
729
- function isMobile() {
730
  return $this->_is_mobile;
731
  }
732
 
@@ -735,16 +734,16 @@ class WSAL_Browser {
735
  *
736
  * @return boolean True if the browser is from a robot otherwise false
737
  */
738
- function isRobot() {
739
  return $this->_is_robot;
740
  }
741
 
742
  /**
743
  * Set the browser to be from AOL
744
  *
745
- * @param unknown $isAol - True/False.
746
  */
747
- function setAol( $isAol ) {
748
  $this->_is_aol = $isAol;
749
  }
750
 
@@ -753,7 +752,7 @@ class WSAL_Browser {
753
  *
754
  * @param boolean $value - is the browser a mobile brower or not.
755
  */
756
- function setMobile( $value = true ) {
757
  $this->_is_mobile = $value;
758
  }
759
 
@@ -762,7 +761,7 @@ class WSAL_Browser {
762
  *
763
  * @param boolean $value - is the browser a robot or not.
764
  */
765
- function setRobot( $value = true ) {
766
  $this->_is_robot = $value;
767
  }
768
 
@@ -771,16 +770,16 @@ class WSAL_Browser {
771
  *
772
  * @return string The user agent from the HTTP header
773
  */
774
- function getUserAgent() {
775
  return $this->_agent;
776
  }
777
 
778
  /**
779
  * Set the user agent value (the construction will use the HTTP header value - this will overwrite it)
780
  *
781
- * @param unknown $agent_string - The value for the User Agent.
782
  */
783
- function setUserAgent( $agent_string ) {
784
  $this->reset();
785
  $this->_agent = $agent_string;
786
  $this->determine();
@@ -792,7 +791,7 @@ class WSAL_Browser {
792
  * @since 1.7
793
  * @return boolean True if the browser is using chromeframe
794
  */
795
- function isChromeFrame() {
796
  return strpos( $this->_agent, 'chromeframe' ) !== false;
797
  }
798
 
@@ -801,11 +800,11 @@ class WSAL_Browser {
801
  *
802
  * @return string formatted string with a summary of the browser
803
  */
804
- function __toString() {
805
- $text1 = $this->getUserAgent(); // Grabs the UA (user agent) string.
806
- $ua_line1 = substr( $text1, 0, 32 ); // The first line we print should only be the first 32 characters of the UA string.
807
- $text2 = $this->getUserAgent(); // Now we grab it again and save it to a string.
808
- $towrap_ua = str_replace( $ua_line1, '', $text2 ); // The rest of the printoff (other than first line) is equivolent.
809
 
810
  /**
811
  * To the whole string minus the part we printed off. IE
@@ -831,7 +830,7 @@ class WSAL_Browser {
831
  /**
832
  * Protected routine to calculate and determine what the browser is in use (including platform)
833
  */
834
- function determine() {
835
  $this->checkPlatform();
836
  $this->checkBrowsers();
837
  $this->checkForAol();
@@ -842,7 +841,7 @@ class WSAL_Browser {
842
  *
843
  * @return boolean True if the browser was detected otherwise false
844
  */
845
- function checkBrowsers() {
846
  return (
847
  /**
848
  * Well-known, well-used
@@ -904,9 +903,9 @@ class WSAL_Browser {
904
  *
905
  * @return boolean True if the browser is the BlackBerry browser otherwise false
906
  */
907
- function checkBrowserBlackBerry() {
908
  if ( stripos( $this->_agent, 'blackberry' ) !== false ) {
909
- $aresult = explode( '/', stristr( $this->_agent, 'BlackBerry' ) );
910
  $aversion = explode( ' ', $aresult[1] );
911
  $this->setVersion( $aversion[0] );
912
  $this->_browser_name = $this->BROWSER_BLACKBERRY;
@@ -921,7 +920,7 @@ class WSAL_Browser {
921
  *
922
  * @return boolean True if the browser is from AOL otherwise false
923
  */
924
- function checkForAol() {
925
  $this->setAol( false );
926
  $this->setAolVersion( $this->VERSION_UNKNOWN );
927
 
@@ -939,9 +938,9 @@ class WSAL_Browser {
939
  *
940
  * @return boolean True if the browser is the GoogletBot otherwise false
941
  */
942
- function checkBrowserGoogleBot() {
943
  if ( stripos( $this->_agent, 'googlebot' ) !== false ) {
944
- $aresult = explode( '/', stristr( $this->_agent, 'googlebot' ) );
945
  $aversion = explode( ' ', $aresult[1] );
946
  $this->setVersion( str_replace( ';', '', $aversion[0] ) );
947
  $this->_browser_name = $this->BROWSER_GOOGLEBOT;
@@ -956,9 +955,9 @@ class WSAL_Browser {
956
  *
957
  * @return boolean True if the browser is the MSNBot otherwise false
958
  */
959
- function checkBrowserMSNBot() {
960
  if ( stripos( $this->_agent, 'msnbot' ) !== false ) {
961
- $aresult = explode( '/', stristr( $this->_agent, 'msnbot' ) );
962
  $aversion = explode( ' ', $aresult[1] );
963
  $this->setVersion( str_replace( ';', '', $aversion[0] ) );
964
  $this->_browser_name = $this->BROWSER_MSNBOT;
@@ -973,17 +972,17 @@ class WSAL_Browser {
973
  *
974
  * @return boolean True if the browser is the W3C Validator otherwise false
975
  */
976
- function checkBrowserW3CValidator() {
977
  if ( stripos( $this->_agent, 'W3C-checklink' ) !== false ) {
978
- $aresult = explode( '/', stristr( $this->_agent, 'W3C-checklink' ) );
979
  $aversion = explode( ' ', $aresult[1] );
980
  $this->setVersion( $aversion[0] );
981
  $this->_browser_name = $this->BROWSER_W3CVALIDATOR;
982
  return true;
983
  } elseif ( stripos( $this->_agent, 'W3C_Validator' ) !== false ) {
984
  // Some of the Validator versions do not delineate w/ a slash - add it back in.
985
- $ua = str_replace( 'W3C_Validator ', 'W3C_Validator/', $this->_agent );
986
- $aresult = explode( '/', stristr( $ua, 'W3C_Validator' ) );
987
  $aversion = explode( ' ', $aresult[1] );
988
  $this->setVersion( $aversion[0] );
989
  $this->_browser_name = $this->BROWSER_W3CVALIDATOR;
@@ -997,9 +996,9 @@ class WSAL_Browser {
997
  *
998
  * @return boolean True if the browser is the Yahoo! Slurp Robot otherwise false
999
  */
1000
- function checkBrowserSlurp() {
1001
  if ( stripos( $this->_agent, 'slurp' ) !== false ) {
1002
- $aresult = explode( '/', stristr( $this->_agent, 'Slurp' ) );
1003
  $aversion = explode( ' ', $aresult[1] );
1004
  $this->setVersion( $aversion[0] );
1005
  $this->_browser_name = $this->BROWSER_SLURP;
@@ -1015,7 +1014,7 @@ class WSAL_Browser {
1015
  *
1016
  * @return boolean True if the browser is Internet Explorer otherwise false
1017
  */
1018
- function checkBrowserInternetExplorer() {
1019
 
1020
  // Test for v1 - v1.5 IE.
1021
  if ( stripos( $this->_agent, 'microsoft internet explorer' ) !== false ) {
@@ -1044,7 +1043,7 @@ class WSAL_Browser {
1044
  // Test for Pocket IE.
1045
  } elseif ( stripos( $this->_agent, 'mspie' ) !== false || stripos( $this->_agent, 'pocket' ) !== false ) {
1046
  $aresult = explode( ' ', stristr( $this->_agent, 'mspie' ) );
1047
- $this->setPlatform( $this->PLATFORM_WINDOWS_CE );
1048
  $this->setBrowser( $this->BROWSER_POCKET_IE );
1049
  $this->setMobile( true );
1050
 
@@ -1064,11 +1063,11 @@ class WSAL_Browser {
1064
  *
1065
  * @return boolean True if the browser is Opera otherwise false
1066
  */
1067
- function checkBrowserOpera() {
1068
  if ( stripos( $this->_agent, 'opera mini' ) !== false ) {
1069
  $resultant = stristr( $this->_agent, 'opera mini' );
1070
  if ( preg_match( '/\//', $resultant ) ) {
1071
- $aresult = explode( '/', $resultant );
1072
  $aversion = explode( ' ', $aresult[1] );
1073
  $this->setVersion( $aversion[0] );
1074
  } else {
@@ -1083,7 +1082,7 @@ class WSAL_Browser {
1083
  if ( preg_match( '/Version\/(10.*)$/', $resultant, $matches ) ) {
1084
  $this->setVersion( $matches[1] );
1085
  } elseif ( preg_match( '/\//', $resultant ) ) {
1086
- $aresult = explode( '/', str_replace( '(', ' ', $resultant ) );
1087
  $aversion = explode( ' ', $aresult[1] );
1088
  $this->setVersion( $aversion[0] );
1089
  } else {
@@ -1101,9 +1100,9 @@ class WSAL_Browser {
1101
  *
1102
  * @return boolean True if the browser is Chrome otherwise false
1103
  */
1104
- function checkBrowserChrome() {
1105
  if ( stripos( $this->_agent, 'Chrome' ) !== false ) {
1106
- $aresult = explode( '/', stristr( $this->_agent, 'Chrome' ) );
1107
  $aversion = explode( ' ', $aresult[1] );
1108
  $this->setVersion( $aversion[0] );
1109
  $this->setBrowser( $this->BROWSER_CHROME );
@@ -1118,9 +1117,9 @@ class WSAL_Browser {
1118
  *
1119
  * @return boolean True if the browser is WebTv otherwise false
1120
  */
1121
- function checkBrowserWebTv() {
1122
  if ( stripos( $this->_agent, 'webtv' ) !== false ) {
1123
- $aresult = explode( '/', stristr( $this->_agent, 'webtv' ) );
1124
  $aversion = explode( ' ', $aresult[1] );
1125
  $this->setVersion( $aversion[0] );
1126
  $this->setBrowser( $this->BROWSER_WEBTV );
@@ -1134,9 +1133,9 @@ class WSAL_Browser {
1134
  *
1135
  * @return boolean True if the browser is NetPositive otherwise false
1136
  */
1137
- function checkBrowserNetPositive() {
1138
  if ( stripos( $this->_agent, 'NetPositive' ) !== false ) {
1139
- $aresult = explode( '/', stristr( $this->_agent, 'NetPositive' ) );
1140
  $aversion = explode( ' ', $aresult[1] );
1141
  $this->setVersion( str_replace( array( '(', ')', ';' ), '', $aversion[0] ) );
1142
  $this->setBrowser( $this->BROWSER_NETPOSITIVE );
@@ -1150,9 +1149,9 @@ class WSAL_Browser {
1150
  *
1151
  * @return boolean True if the browser is Galeon otherwise false
1152
  */
1153
- function checkBrowserGaleon() {
1154
  if ( stripos( $this->_agent, 'galeon' ) !== false ) {
1155
- $aresult = explode( ' ', stristr( $this->_agent, 'galeon' ) );
1156
  $aversion = explode( '/', $aresult[0] );
1157
  $this->setVersion( $aversion[1] );
1158
  $this->setBrowser( $this->BROWSER_GALEON );
@@ -1166,9 +1165,9 @@ class WSAL_Browser {
1166
  *
1167
  * @return boolean True if the browser is Konqueror otherwise false
1168
  */
1169
- function checkBrowserKonqueror() {
1170
  if ( stripos( $this->_agent, 'Konqueror' ) !== false ) {
1171
- $aresult = explode( ' ', stristr( $this->_agent, 'Konqueror' ) );
1172
  $aversion = explode( '/', $aresult[0] );
1173
  $this->setVersion( $aversion[1] );
1174
  $this->setBrowser( $this->BROWSER_KONQUEROR );
@@ -1182,7 +1181,7 @@ class WSAL_Browser {
1182
  *
1183
  * @return boolean True if the browser is iCab otherwise false
1184
  */
1185
- function checkBrowserIcab() {
1186
  if ( stripos( $this->_agent, 'icab' ) !== false ) {
1187
  $aversion = explode( ' ', stristr( str_replace( '/', ' ', $this->_agent ), 'icab' ) );
1188
  $this->setVersion( $aversion[1] );
@@ -1197,9 +1196,9 @@ class WSAL_Browser {
1197
  *
1198
  * @return boolean True if the browser is OmniWeb otherwise false
1199
  */
1200
- function checkBrowserOmniWeb() {
1201
  if ( stripos( $this->_agent, 'omniweb' ) !== false ) {
1202
- $aresult = explode( '/', stristr( $this->_agent, 'omniweb' ) );
1203
  $aversion = explode( ' ', isset( $aresult[1] ) ? $aresult[1] : '' );
1204
  $this->setVersion( $aversion[0] );
1205
  $this->setBrowser( $this->BROWSER_OMNIWEB );
@@ -1213,7 +1212,7 @@ class WSAL_Browser {
1213
  *
1214
  * @return boolean True if the browser is Phoenix otherwise false
1215
  */
1216
- function checkBrowserPhoenix() {
1217
  if ( stripos( $this->_agent, 'Phoenix' ) !== false ) {
1218
  $aversion = explode( '/', stristr( $this->_agent, 'Phoenix' ) );
1219
  $this->setVersion( $aversion[1] );
@@ -1228,7 +1227,7 @@ class WSAL_Browser {
1228
  *
1229
  * @return boolean True if the browser is Firebird otherwise false
1230
  */
1231
- function checkBrowserFirebird() {
1232
  if ( stripos( $this->_agent, 'Firebird' ) !== false ) {
1233
  $aversion = explode( '/', stristr( $this->_agent, 'Firebird' ) );
1234
  $this->setVersion( $aversion[1] );
@@ -1244,7 +1243,7 @@ class WSAL_Browser {
1244
  *
1245
  * @return boolean True if the browser is Netscape Navigator 9+ otherwise false
1246
  */
1247
- function checkBrowserNetscapeNavigator9Plus() {
1248
  if ( stripos( $this->_agent, 'Firefox' ) !== false && preg_match( '/Navigator\/([^ ]*)/i', $this->_agent, $matches ) ) {
1249
  $this->setVersion( $matches[1] );
1250
  $this->setBrowser( $this->BROWSER_NETSCAPE_NAVIGATOR );
@@ -1262,7 +1261,7 @@ class WSAL_Browser {
1262
  *
1263
  * @return boolean True if the browser is Shiretoko otherwise false
1264
  */
1265
- function checkBrowserShiretoko() {
1266
  if ( stripos( $this->_agent, 'Mozilla' ) !== false && preg_match( '/Shiretoko\/([^ ]*)/i', $this->_agent, $matches ) ) {
1267
  $this->setVersion( $matches[1] );
1268
  $this->setBrowser( $this->BROWSER_SHIRETOKO );
@@ -1276,7 +1275,7 @@ class WSAL_Browser {
1276
  *
1277
  * @return boolean True if the browser is Ice Cat otherwise false
1278
  */
1279
- function checkBrowserIceCat() {
1280
  if ( stripos( $this->_agent, 'Mozilla' ) !== false && preg_match( '/IceCat\/([^ ]*)/i', $this->_agent, $matches ) ) {
1281
  $this->setVersion( $matches[1] );
1282
  $this->setBrowser( $this->BROWSER_ICECAT );
@@ -1290,7 +1289,7 @@ class WSAL_Browser {
1290
  *
1291
  * @return boolean True if the browser is Nokia otherwise false
1292
  */
1293
- function checkBrowserNokia() {
1294
  if ( preg_match( '/Nokia([^\/]+)\/([^ SP]+)/i', $this->_agent, $matches ) ) {
1295
  $this->setVersion( $matches[2] );
1296
  if ( stripos( $this->_agent, 'Series60' ) !== false || strpos( $this->_agent, 'S60' ) !== false ) {
@@ -1309,7 +1308,7 @@ class WSAL_Browser {
1309
  *
1310
  * @return boolean True if the browser is Firefox otherwise false
1311
  */
1312
- function checkBrowserFirefox() {
1313
  if ( stripos( $this->_agent, 'safari' ) === false ) {
1314
  if ( preg_match( '/Firefox[\/ \(]([^ ;\)]+)/i', $this->_agent, $matches ) ) {
1315
  $this->setVersion( $matches[1] );
@@ -1329,9 +1328,9 @@ class WSAL_Browser {
1329
  *
1330
  * @return boolean True if the browser is Firefox otherwise false
1331
  */
1332
- function checkBrowserIceweasel() {
1333
  if ( stripos( $this->_agent, 'Iceweasel' ) !== false ) {
1334
- $aresult = explode( '/', stristr( $this->_agent, 'Iceweasel' ) );
1335
  $aversion = explode( ' ', $aresult[1] );
1336
  $this->setVersion( $aversion[0] );
1337
  $this->setBrowser( $this->BROWSER_ICEWEASEL );
@@ -1345,7 +1344,7 @@ class WSAL_Browser {
1345
  *
1346
  * @return boolean True if the browser is Mozilla otherwise false
1347
  */
1348
- function checkBrowserMozilla() {
1349
  if ( stripos( $this->_agent, 'mozilla' ) !== false && preg_match( '/rv:[0-9].[0-9][a-b]?/i', $this->_agent ) && stripos( $this->_agent, 'netscape' ) === false ) {
1350
  $aversion = explode( ' ', stristr( $this->_agent, 'rv:' ) );
1351
  preg_match( '/rv:[0-9].[0-9][a-b]?/i', $this->_agent, $aversion );
@@ -1370,9 +1369,9 @@ class WSAL_Browser {
1370
  *
1371
  * @return boolean True if the browser is Lynx otherwise false
1372
  */
1373
- function checkBrowserLynx() {
1374
  if ( stripos( $this->_agent, 'lynx' ) !== false ) {
1375
- $aresult = explode( '/', stristr( $this->_agent, 'Lynx' ) );
1376
  $aversion = explode( ' ', ( isset( $aresult[1] ) ? $aresult[1] : '' ) );
1377
  $this->setVersion( $aversion[0] );
1378
  $this->setBrowser( $this->BROWSER_LYNX );
@@ -1386,9 +1385,9 @@ class WSAL_Browser {
1386
  *
1387
  * @return boolean True if the browser is Amaya otherwise false
1388
  */
1389
- function checkBrowserAmaya() {
1390
  if ( stripos( $this->_agent, 'amaya' ) !== false ) {
1391
- $aresult = explode( '/', stristr( $this->_agent, 'Amaya' ) );
1392
  $aversion = explode( ' ', $aresult[1] );
1393
  $this->setVersion( $aversion[0] );
1394
  $this->setBrowser( $this->BROWSER_AMAYA );
@@ -1402,7 +1401,7 @@ class WSAL_Browser {
1402
  *
1403
  * @return boolean True if the browser is Safari otherwise false
1404
  */
1405
- function checkBrowserSafari() {
1406
  if ( stripos( $this->_agent, 'Safari' ) !== false && stripos( $this->_agent, 'iPhone' ) === false && stripos( $this->_agent, 'iPod' ) === false ) {
1407
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1408
  if ( isset( $aresult[1] ) ) {
@@ -1422,7 +1421,7 @@ class WSAL_Browser {
1422
  *
1423
  * @return boolean True if the browser is iPhone otherwise false
1424
  */
1425
- function checkBrowseriPhone() {
1426
  if ( stripos( $this->_agent, 'iPhone' ) !== false ) {
1427
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1428
  if ( isset( $aresult[1] ) ) {
@@ -1443,7 +1442,7 @@ class WSAL_Browser {
1443
  *
1444
  * @return boolean True if the browser is iPod otherwise false
1445
  */
1446
- function checkBrowseriPad() {
1447
  if ( stripos( $this->_agent, 'iPad' ) !== false ) {
1448
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1449
  if ( isset( $aresult[1] ) ) {
@@ -1464,7 +1463,7 @@ class WSAL_Browser {
1464
  *
1465
  * @return boolean True if the browser is iPod otherwise false
1466
  */
1467
- function checkBrowseriPod() {
1468
  if ( stripos( $this->_agent, 'iPod' ) !== false ) {
1469
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1470
  if ( isset( $aresult[1] ) ) {
@@ -1485,7 +1484,7 @@ class WSAL_Browser {
1485
  *
1486
  * @return boolean True if the browser is Android otherwise false
1487
  */
1488
- function checkBrowserAndroid() {
1489
  if ( stripos( $this->_agent, 'Android' ) !== false ) {
1490
  $aresult = explode( ' ', stristr( $this->_agent, 'Android' ) );
1491
  if ( isset( $aresult[1] ) ) {
@@ -1504,7 +1503,7 @@ class WSAL_Browser {
1504
  /**
1505
  * Determine the user's platform (last updated 1.7)
1506
  */
1507
- function checkPlatform() {
1508
  if ( stripos( $this->_agent, 'windows' ) !== false ) {
1509
  $this->_platform = $this->PLATFORM_WINDOWS;
1510
  } elseif ( stripos( $this->_agent, 'iPad' ) !== false ) {
@@ -1540,6 +1539,5 @@ class WSAL_Browser {
1540
  } elseif ( stripos( $this->_agent, 'win' ) !== false ) {
1541
  $this->_platform = $this->PLATFORM_WINDOWS;
1542
  }
1543
-
1544
  }
1545
  }
591
  */
592
  public $PLATFORM_ANDROID = 'Android';
593
 
 
594
  /**
595
  * OPERATING_SYSTEM_UNKNOWN
596
  *
603
  *
604
  * @param string $useragent - User agent.
605
  */
606
+ public function __construct( $useragent = '' ) {
607
  $this->reset();
608
  if ( '' != $useragent ) {
609
  $this->setUserAgent( $useragent );
615
  /**
616
  * Reset all properties
617
  */
618
+ public function reset() {
619
+ $http_user_agent = filter_input( INPUT_SERVER, 'HTTP_USER_AGENT', FILTER_SANITIZE_STRING );
620
+ $this->_agent = ! empty( $http_user_agent ) ? $http_user_agent : '';
621
  $this->_browser_name = $this->BROWSER_UNKNOWN;
622
+ $this->_version = $this->VERSION_UNKNOWN;
623
+ $this->_platform = $this->PLATFORM_UNKNOWN;
624
+ $this->_os = $this->OPERATING_SYSTEM_UNKNOWN;
625
+ $this->_is_aol = false;
626
+ $this->_is_mobile = false;
627
+ $this->_is_robot = false;
628
+ $this->_aol_version = $this->VERSION_UNKNOWN;
629
  }
630
 
631
  /**
634
  * @param string $browser_name - Browser name.
635
  * @return True if the browser is the specified browser
636
  */
637
+ public function isBrowser( $browser_name ) {
638
  return 0 == strcasecmp( $this->_browser_name, trim( $browser_name ) );
639
  }
640
 
643
  *
644
  * @return string Name of the browser
645
  */
646
+ public function getBrowser() {
647
  return $this->_browser_name;
648
  }
649
 
650
  /**
651
  * Set the name of the browser
652
  *
653
+ * @param string $browser - The name of the Browser.
654
  */
655
+ public function setBrowser( $browser ) {
656
+ $this->_browser_name = $browser;
657
  }
658
 
659
  /**
661
  *
662
  * @return string Name of the browser
663
  */
664
+ public function getPlatform() {
665
  return $this->_platform;
666
  }
667
 
668
  /**
669
  * Set the name of the platform
670
  *
671
+ * @param string $platform - The name of the Platform.
672
  */
673
+ public function setPlatform( $platform ) {
674
+ $this->_platform = $platform;
675
  }
676
 
677
  /**
679
  *
680
  * @return string Version of the browser (will only contain alpha-numeric characters and a period)
681
  */
682
+ public function getVersion() {
683
  return $this->_version;
684
  }
685
 
687
  /**
688
  * Set the version of the browser
689
  *
690
+ * @param string $version - The version of the Browser.
691
  */
692
+ public function setVersion( $version ) {
693
  $this->_version = preg_replace( '/[^0-9,.,a-z,A-Z-]/', '', $version );
694
  }
695
 
698
  *
699
  * @return string Version of AOL (will only contain alpha-numeric characters and a period)
700
  */
701
+ public function getAolVersion() {
702
  return $this->_aol_version;
703
  }
704
 
705
  /**
706
  * Set the version of AOL
707
  *
708
+ * @param string $version - The version of AOL.
709
  */
710
+ public function setAolVersion( $version ) {
711
  $this->_aol_version = preg_replace( '/[^0-9,.,a-z,A-Z]/', '', $version );
712
  }
713
 
716
  *
717
  * @return boolean True if the browser is from AOL otherwise false
718
  */
719
+ public function isAol() {
720
  return $this->_is_aol;
721
  }
722
 
725
  *
726
  * @return boolean True if the browser is from a mobile device otherwise false
727
  */
728
+ public function isMobile() {
729
  return $this->_is_mobile;
730
  }
731
 
734
  *
735
  * @return boolean True if the browser is from a robot otherwise false
736
  */
737
+ public function isRobot() {
738
  return $this->_is_robot;
739
  }
740
 
741
  /**
742
  * Set the browser to be from AOL
743
  *
744
+ * @param bool $isAol - True/False.
745
  */
746
+ public function setAol( $isAol ) {
747
  $this->_is_aol = $isAol;
748
  }
749
 
752
  *
753
  * @param boolean $value - is the browser a mobile brower or not.
754
  */
755
+ public function setMobile( $value = true ) {
756
  $this->_is_mobile = $value;
757
  }
758
 
761
  *
762
  * @param boolean $value - is the browser a robot or not.
763
  */
764
+ public function setRobot( $value = true ) {
765
  $this->_is_robot = $value;
766
  }
767
 
770
  *
771
  * @return string The user agent from the HTTP header
772
  */
773
+ public function getUserAgent() {
774
  return $this->_agent;
775
  }
776
 
777
  /**
778
  * Set the user agent value (the construction will use the HTTP header value - this will overwrite it)
779
  *
780
+ * @param string $agent_string - The value for the User Agent.
781
  */
782
+ public function setUserAgent( $agent_string ) {
783
  $this->reset();
784
  $this->_agent = $agent_string;
785
  $this->determine();
791
  * @since 1.7
792
  * @return boolean True if the browser is using chromeframe
793
  */
794
+ public function isChromeFrame() {
795
  return strpos( $this->_agent, 'chromeframe' ) !== false;
796
  }
797
 
800
  *
801
  * @return string formatted string with a summary of the browser
802
  */
803
+ public function __toString() {
804
+ $text1 = $this->getUserAgent(); // Grabs the UA (user agent) string.
805
+ $ua_line1 = substr( $text1, 0, 32 ); // The first line we print should only be the first 32 characters of the UA string.
806
+ $text2 = $this->getUserAgent(); // Now we grab it again and save it to a string.
807
+ $towrap_ua = str_replace( $ua_line1, '', $text2 ); // The rest of the printoff (other than first line) is equivolent.
808
 
809
  /**
810
  * To the whole string minus the part we printed off. IE
830
  /**
831
  * Protected routine to calculate and determine what the browser is in use (including platform)
832
  */
833
+ public function determine() {
834
  $this->checkPlatform();
835
  $this->checkBrowsers();
836
  $this->checkForAol();
841
  *
842
  * @return boolean True if the browser was detected otherwise false
843
  */
844
+ public function checkBrowsers() {
845
  return (
846
  /**
847
  * Well-known, well-used
903
  *
904
  * @return boolean True if the browser is the BlackBerry browser otherwise false
905
  */
906
+ public function checkBrowserBlackBerry() {
907
  if ( stripos( $this->_agent, 'blackberry' ) !== false ) {
908
+ $aresult = explode( '/', stristr( $this->_agent, 'BlackBerry' ) );
909
  $aversion = explode( ' ', $aresult[1] );
910
  $this->setVersion( $aversion[0] );
911
  $this->_browser_name = $this->BROWSER_BLACKBERRY;
920
  *
921
  * @return boolean True if the browser is from AOL otherwise false
922
  */
923
+ public function checkForAol() {
924
  $this->setAol( false );
925
  $this->setAolVersion( $this->VERSION_UNKNOWN );
926
 
938
  *
939
  * @return boolean True if the browser is the GoogletBot otherwise false
940
  */
941
+ public function checkBrowserGoogleBot() {
942
  if ( stripos( $this->_agent, 'googlebot' ) !== false ) {
943
+ $aresult = explode( '/', stristr( $this->_agent, 'googlebot' ) );
944
  $aversion = explode( ' ', $aresult[1] );
945
  $this->setVersion( str_replace( ';', '', $aversion[0] ) );
946
  $this->_browser_name = $this->BROWSER_GOOGLEBOT;
955
  *
956
  * @return boolean True if the browser is the MSNBot otherwise false
957
  */
958
+ public function checkBrowserMSNBot() {
959
  if ( stripos( $this->_agent, 'msnbot' ) !== false ) {
960
+ $aresult = explode( '/', stristr( $this->_agent, 'msnbot' ) );
961
  $aversion = explode( ' ', $aresult[1] );
962
  $this->setVersion( str_replace( ';', '', $aversion[0] ) );
963
  $this->_browser_name = $this->BROWSER_MSNBOT;
972
  *
973
  * @return boolean True if the browser is the W3C Validator otherwise false
974
  */
975
+ public function checkBrowserW3CValidator() {
976
  if ( stripos( $this->_agent, 'W3C-checklink' ) !== false ) {
977
+ $aresult = explode( '/', stristr( $this->_agent, 'W3C-checklink' ) );
978
  $aversion = explode( ' ', $aresult[1] );
979
  $this->setVersion( $aversion[0] );
980
  $this->_browser_name = $this->BROWSER_W3CVALIDATOR;
981
  return true;
982
  } elseif ( stripos( $this->_agent, 'W3C_Validator' ) !== false ) {
983
  // Some of the Validator versions do not delineate w/ a slash - add it back in.
984
+ $ua = str_replace( 'W3C_Validator ', 'W3C_Validator/', $this->_agent );
985
+ $aresult = explode( '/', stristr( $ua, 'W3C_Validator' ) );
986
  $aversion = explode( ' ', $aresult[1] );
987
  $this->setVersion( $aversion[0] );
988
  $this->_browser_name = $this->BROWSER_W3CVALIDATOR;
996
  *
997
  * @return boolean True if the browser is the Yahoo! Slurp Robot otherwise false
998
  */
999
+ public function checkBrowserSlurp() {
1000
  if ( stripos( $this->_agent, 'slurp' ) !== false ) {
1001
+ $aresult = explode( '/', stristr( $this->_agent, 'Slurp' ) );
1002
  $aversion = explode( ' ', $aresult[1] );
1003
  $this->setVersion( $aversion[0] );
1004
  $this->_browser_name = $this->BROWSER_SLURP;
1014
  *
1015
  * @return boolean True if the browser is Internet Explorer otherwise false
1016
  */
1017
+ public function checkBrowserInternetExplorer() {
1018
 
1019
  // Test for v1 - v1.5 IE.
1020
  if ( stripos( $this->_agent, 'microsoft internet explorer' ) !== false ) {
1043
  // Test for Pocket IE.
1044
  } elseif ( stripos( $this->_agent, 'mspie' ) !== false || stripos( $this->_agent, 'pocket' ) !== false ) {
1045
  $aresult = explode( ' ', stristr( $this->_agent, 'mspie' ) );
1046
+ $this->setPlatform( $this->PLATFORM_WINDOWS_CE );
1047
  $this->setBrowser( $this->BROWSER_POCKET_IE );
1048
  $this->setMobile( true );
1049
 
1063
  *
1064
  * @return boolean True if the browser is Opera otherwise false
1065
  */
1066
+ public function checkBrowserOpera() {
1067
  if ( stripos( $this->_agent, 'opera mini' ) !== false ) {
1068
  $resultant = stristr( $this->_agent, 'opera mini' );
1069
  if ( preg_match( '/\//', $resultant ) ) {
1070
+ $aresult = explode( '/', $resultant );
1071
  $aversion = explode( ' ', $aresult[1] );
1072
  $this->setVersion( $aversion[0] );
1073
  } else {
1082
  if ( preg_match( '/Version\/(10.*)$/', $resultant, $matches ) ) {
1083
  $this->setVersion( $matches[1] );
1084
  } elseif ( preg_match( '/\//', $resultant ) ) {
1085
+ $aresult = explode( '/', str_replace( '(', ' ', $resultant ) );
1086
  $aversion = explode( ' ', $aresult[1] );
1087
  $this->setVersion( $aversion[0] );
1088
  } else {
1100
  *
1101
  * @return boolean True if the browser is Chrome otherwise false
1102
  */
1103
+ public function checkBrowserChrome() {
1104
  if ( stripos( $this->_agent, 'Chrome' ) !== false ) {
1105
+ $aresult = explode( '/', stristr( $this->_agent, 'Chrome' ) );
1106
  $aversion = explode( ' ', $aresult[1] );
1107
  $this->setVersion( $aversion[0] );
1108
  $this->setBrowser( $this->BROWSER_CHROME );
1117
  *
1118
  * @return boolean True if the browser is WebTv otherwise false
1119
  */
1120
+ public function checkBrowserWebTv() {
1121
  if ( stripos( $this->_agent, 'webtv' ) !== false ) {
1122
+ $aresult = explode( '/', stristr( $this->_agent, 'webtv' ) );
1123
  $aversion = explode( ' ', $aresult[1] );
1124
  $this->setVersion( $aversion[0] );
1125
  $this->setBrowser( $this->BROWSER_WEBTV );
1133
  *
1134
  * @return boolean True if the browser is NetPositive otherwise false
1135
  */
1136
+ public function checkBrowserNetPositive() {
1137
  if ( stripos( $this->_agent, 'NetPositive' ) !== false ) {
1138
+ $aresult = explode( '/', stristr( $this->_agent, 'NetPositive' ) );
1139
  $aversion = explode( ' ', $aresult[1] );
1140
  $this->setVersion( str_replace( array( '(', ')', ';' ), '', $aversion[0] ) );
1141
  $this->setBrowser( $this->BROWSER_NETPOSITIVE );
1149
  *
1150
  * @return boolean True if the browser is Galeon otherwise false
1151
  */
1152
+ public function checkBrowserGaleon() {
1153
  if ( stripos( $this->_agent, 'galeon' ) !== false ) {
1154
+ $aresult = explode( ' ', stristr( $this->_agent, 'galeon' ) );
1155
  $aversion = explode( '/', $aresult[0] );
1156
  $this->setVersion( $aversion[1] );
1157
  $this->setBrowser( $this->BROWSER_GALEON );
1165
  *
1166
  * @return boolean True if the browser is Konqueror otherwise false
1167
  */
1168
+ public function checkBrowserKonqueror() {
1169
  if ( stripos( $this->_agent, 'Konqueror' ) !== false ) {
1170
+ $aresult = explode( ' ', stristr( $this->_agent, 'Konqueror' ) );
1171
  $aversion = explode( '/', $aresult[0] );
1172
  $this->setVersion( $aversion[1] );
1173
  $this->setBrowser( $this->BROWSER_KONQUEROR );
1181
  *
1182
  * @return boolean True if the browser is iCab otherwise false
1183
  */
1184
+ public function checkBrowserIcab() {
1185
  if ( stripos( $this->_agent, 'icab' ) !== false ) {
1186
  $aversion = explode( ' ', stristr( str_replace( '/', ' ', $this->_agent ), 'icab' ) );
1187
  $this->setVersion( $aversion[1] );
1196
  *
1197
  * @return boolean True if the browser is OmniWeb otherwise false
1198
  */
1199
+ public function checkBrowserOmniWeb() {
1200
  if ( stripos( $this->_agent, 'omniweb' ) !== false ) {
1201
+ $aresult = explode( '/', stristr( $this->_agent, 'omniweb' ) );
1202
  $aversion = explode( ' ', isset( $aresult[1] ) ? $aresult[1] : '' );
1203
  $this->setVersion( $aversion[0] );
1204
  $this->setBrowser( $this->BROWSER_OMNIWEB );
1212
  *
1213
  * @return boolean True if the browser is Phoenix otherwise false
1214
  */
1215
+ public function checkBrowserPhoenix() {
1216
  if ( stripos( $this->_agent, 'Phoenix' ) !== false ) {
1217
  $aversion = explode( '/', stristr( $this->_agent, 'Phoenix' ) );
1218
  $this->setVersion( $aversion[1] );
1227
  *
1228
  * @return boolean True if the browser is Firebird otherwise false
1229
  */
1230
+ public function checkBrowserFirebird() {
1231
  if ( stripos( $this->_agent, 'Firebird' ) !== false ) {
1232
  $aversion = explode( '/', stristr( $this->_agent, 'Firebird' ) );
1233
  $this->setVersion( $aversion[1] );
1243
  *
1244
  * @return boolean True if the browser is Netscape Navigator 9+ otherwise false
1245
  */
1246
+ public function checkBrowserNetscapeNavigator9Plus() {
1247
  if ( stripos( $this->_agent, 'Firefox' ) !== false && preg_match( '/Navigator\/([^ ]*)/i', $this->_agent, $matches ) ) {
1248
  $this->setVersion( $matches[1] );
1249
  $this->setBrowser( $this->BROWSER_NETSCAPE_NAVIGATOR );
1261
  *
1262
  * @return boolean True if the browser is Shiretoko otherwise false
1263
  */
1264
+ public function checkBrowserShiretoko() {
1265
  if ( stripos( $this->_agent, 'Mozilla' ) !== false && preg_match( '/Shiretoko\/([^ ]*)/i', $this->_agent, $matches ) ) {
1266
  $this->setVersion( $matches[1] );
1267
  $this->setBrowser( $this->BROWSER_SHIRETOKO );
1275
  *
1276
  * @return boolean True if the browser is Ice Cat otherwise false
1277
  */
1278
+ public function checkBrowserIceCat() {
1279
  if ( stripos( $this->_agent, 'Mozilla' ) !== false && preg_match( '/IceCat\/([^ ]*)/i', $this->_agent, $matches ) ) {
1280
  $this->setVersion( $matches[1] );
1281
  $this->setBrowser( $this->BROWSER_ICECAT );
1289
  *
1290
  * @return boolean True if the browser is Nokia otherwise false
1291
  */
1292
+ public function checkBrowserNokia() {
1293
  if ( preg_match( '/Nokia([^\/]+)\/([^ SP]+)/i', $this->_agent, $matches ) ) {
1294
  $this->setVersion( $matches[2] );
1295
  if ( stripos( $this->_agent, 'Series60' ) !== false || strpos( $this->_agent, 'S60' ) !== false ) {
1308
  *
1309
  * @return boolean True if the browser is Firefox otherwise false
1310
  */
1311
+ public function checkBrowserFirefox() {
1312
  if ( stripos( $this->_agent, 'safari' ) === false ) {
1313
  if ( preg_match( '/Firefox[\/ \(]([^ ;\)]+)/i', $this->_agent, $matches ) ) {
1314
  $this->setVersion( $matches[1] );
1328
  *
1329
  * @return boolean True if the browser is Firefox otherwise false
1330
  */
1331
+ public function checkBrowserIceweasel() {
1332
  if ( stripos( $this->_agent, 'Iceweasel' ) !== false ) {
1333
+ $aresult = explode( '/', stristr( $this->_agent, 'Iceweasel' ) );
1334
  $aversion = explode( ' ', $aresult[1] );
1335
  $this->setVersion( $aversion[0] );
1336
  $this->setBrowser( $this->BROWSER_ICEWEASEL );
1344
  *
1345
  * @return boolean True if the browser is Mozilla otherwise false
1346
  */
1347
+ public function checkBrowserMozilla() {
1348
  if ( stripos( $this->_agent, 'mozilla' ) !== false && preg_match( '/rv:[0-9].[0-9][a-b]?/i', $this->_agent ) && stripos( $this->_agent, 'netscape' ) === false ) {
1349
  $aversion = explode( ' ', stristr( $this->_agent, 'rv:' ) );
1350
  preg_match( '/rv:[0-9].[0-9][a-b]?/i', $this->_agent, $aversion );
1369
  *
1370
  * @return boolean True if the browser is Lynx otherwise false
1371
  */
1372
+ public function checkBrowserLynx() {
1373
  if ( stripos( $this->_agent, 'lynx' ) !== false ) {
1374
+ $aresult = explode( '/', stristr( $this->_agent, 'Lynx' ) );
1375
  $aversion = explode( ' ', ( isset( $aresult[1] ) ? $aresult[1] : '' ) );
1376
  $this->setVersion( $aversion[0] );
1377
  $this->setBrowser( $this->BROWSER_LYNX );
1385
  *
1386
  * @return boolean True if the browser is Amaya otherwise false
1387
  */
1388
+ public function checkBrowserAmaya() {
1389
  if ( stripos( $this->_agent, 'amaya' ) !== false ) {
1390
+ $aresult = explode( '/', stristr( $this->_agent, 'Amaya' ) );
1391
  $aversion = explode( ' ', $aresult[1] );
1392
  $this->setVersion( $aversion[0] );
1393
  $this->setBrowser( $this->BROWSER_AMAYA );
1401
  *
1402
  * @return boolean True if the browser is Safari otherwise false
1403
  */
1404
+ public function checkBrowserSafari() {
1405
  if ( stripos( $this->_agent, 'Safari' ) !== false && stripos( $this->_agent, 'iPhone' ) === false && stripos( $this->_agent, 'iPod' ) === false ) {
1406
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1407
  if ( isset( $aresult[1] ) ) {
1421
  *
1422
  * @return boolean True if the browser is iPhone otherwise false
1423
  */
1424
+ public function checkBrowseriPhone() {
1425
  if ( stripos( $this->_agent, 'iPhone' ) !== false ) {
1426
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1427
  if ( isset( $aresult[1] ) ) {
1442
  *
1443
  * @return boolean True if the browser is iPod otherwise false
1444
  */
1445
+ public function checkBrowseriPad() {
1446
  if ( stripos( $this->_agent, 'iPad' ) !== false ) {
1447
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1448
  if ( isset( $aresult[1] ) ) {
1463
  *
1464
  * @return boolean True if the browser is iPod otherwise false
1465
  */
1466
+ public function checkBrowseriPod() {
1467
  if ( stripos( $this->_agent, 'iPod' ) !== false ) {
1468
  $aresult = explode( '/', stristr( $this->_agent, 'Version' ) );
1469
  if ( isset( $aresult[1] ) ) {
1484
  *
1485
  * @return boolean True if the browser is Android otherwise false
1486
  */
1487
+ public function checkBrowserAndroid() {
1488
  if ( stripos( $this->_agent, 'Android' ) !== false ) {
1489
  $aresult = explode( ' ', stristr( $this->_agent, 'Android' ) );
1490
  if ( isset( $aresult[1] ) ) {
1503
  /**
1504
  * Determine the user's platform (last updated 1.7)
1505
  */
1506
+ public function checkPlatform() {
1507
  if ( stripos( $this->_agent, 'windows' ) !== false ) {
1508
  $this->_platform = $this->PLATFORM_WINDOWS;
1509
  } elseif ( stripos( $this->_agent, 'iPad' ) !== false ) {
1539
  } elseif ( stripos( $this->_agent, 'win' ) !== false ) {
1540
  $this->_platform = $this->PLATFORM_WINDOWS;
1541
  }
 
1542
  }
1543
  }
sdk/freemius/includes/class-freemius.php CHANGED
@@ -2977,6 +2977,10 @@
2977
  * @since 1.1.7.3
2978
  */
2979
  static function _toggle_debug_mode() {
 
 
 
 
2980
  $is_on = fs_request_get( 'is_on', false, 'post' );
2981
 
2982
  if ( fs_request_is_post() && in_array( $is_on, array( 0, 1 ) ) ) {
@@ -3008,8 +3012,16 @@
3008
  * @since 1.2.1.7
3009
  */
3010
  static function _get_db_option() {
 
 
3011
  $option_name = fs_request_get( 'option_name' );
3012
 
 
 
 
 
 
 
3013
  $value = get_option( $option_name );
3014
 
3015
  $result = array(
@@ -3032,7 +3044,16 @@
3032
  * @since 1.2.1.7
3033
  */
3034
  static function _set_db_option() {
3035
- $option_name = fs_request_get( 'option_name' );
 
 
 
 
 
 
 
 
 
3036
  $option_value = fs_request_get( 'option_value' );
3037
 
3038
  if ( ! empty( $option_value ) ) {
@@ -3367,7 +3388,7 @@
3367
  if ( $is_connected ) {
3368
  FS_GDPR_Manager::instance()->store_is_required( $pong->is_gdpr_required );
3369
  }
3370
-
3371
  $this->store_connectivity_info( $pong, $is_connected );
3372
 
3373
  return $this->_has_api_connection;
@@ -11146,7 +11167,7 @@
11146
  */
11147
  function _activate_license_ajax_action() {
11148
  $this->_logger->entrance();
11149
-
11150
  $this->check_ajax_referer( 'activate_license' );
11151
 
11152
  $license_key = trim( fs_request_get( 'license_key' ) );
2977
  * @since 1.1.7.3
2978
  */
2979
  static function _toggle_debug_mode() {
2980
+ if ( ! is_super_admin() ) {
2981
+ return;
2982
+ }
2983
+
2984
  $is_on = fs_request_get( 'is_on', false, 'post' );
2985
 
2986
  if ( fs_request_is_post() && in_array( $is_on, array( 0, 1 ) ) ) {
3012
  * @since 1.2.1.7
3013
  */
3014
  static function _get_db_option() {
3015
+ check_admin_referer( 'fs_get_db_option' );
3016
+
3017
  $option_name = fs_request_get( 'option_name' );
3018
 
3019
+ if ( ! is_super_admin() ||
3020
+ ! fs_starts_with( $option_name, 'fs_' )
3021
+ ) {
3022
+ self::shoot_ajax_failure();
3023
+ }
3024
+
3025
  $value = get_option( $option_name );
3026
 
3027
  $result = array(
3044
  * @since 1.2.1.7
3045
  */
3046
  static function _set_db_option() {
3047
+ check_admin_referer( 'fs_set_db_option' );
3048
+
3049
+ $option_name = fs_request_get( 'option_name' );
3050
+
3051
+ if ( ! is_super_admin() ||
3052
+ ! fs_starts_with( $option_name, 'fs_' )
3053
+ ) {
3054
+ self::shoot_ajax_failure();
3055
+ }
3056
+
3057
  $option_value = fs_request_get( 'option_value' );
3058
 
3059
  if ( ! empty( $option_value ) ) {
3388
  if ( $is_connected ) {
3389
  FS_GDPR_Manager::instance()->store_is_required( $pong->is_gdpr_required );
3390
  }
3391
+
3392
  $this->store_connectivity_info( $pong, $is_connected );
3393
 
3394
  return $this->_has_api_connection;
11167
  */
11168
  function _activate_license_ajax_action() {
11169
  $this->_logger->entrance();
11170
+
11171
  $this->check_ajax_referer( 'activate_license' );
11172
 
11173
  $license_key = trim( fs_request_get( 'license_key' ) );
sdk/freemius/includes/debug/class-fs-debug-bar-panel.php CHANGED
@@ -6,9 +6,9 @@
6
  * @since 1.1.7.3
7
  */
8
 
9
- if ( ! defined( 'ABSPATH' ) ) {
10
- exit;
11
- }
12
 
13
  /**
14
  * Extends Debug Bar plugin by adding a panel to show all Freemius API requests.
@@ -18,47 +18,47 @@
18
  *
19
  * Class Freemius_Debug_Bar_Panel
20
  */
21
- class Freemius_Debug_Bar_Panel extends Debug_Bar_Panel {
22
- function init() {
23
- $this->title( 'Freemius' );
24
- }
25
-
26
- static function requests_count() {
27
- if ( class_exists( 'Freemius_Api_WordPress' ) ) {
28
- $logger = Freemius_Api_WordPress::GetLogger();
29
- } else {
30
- $logger = array();
31
- }
32
 
33
- return number_format( count( $logger ) );
 
 
 
 
34
  }
35
 
36
- static function total_time() {
37
- if ( class_exists( 'Freemius_Api_WordPress' ) ) {
38
- $logger = Freemius_Api_WordPress::GetLogger();
39
- } else {
40
- $logger = array();
41
- }
42
 
43
- $total_time = .0;
44
- foreach ( $logger as $l ) {
45
- $total_time += $l['total'];
46
- }
 
 
47
 
48
- return number_format( 100 * $total_time, 2 ) . ' ' . fs_text_x_inline( 'ms', 'milliseconds' );
 
 
49
  }
50
 
51
- function render() {
52
- ?>
53
- <div id='debug-bar-php'>
54
- <?php fs_require_template( '/debug/api-calls.php' ) ?>
55
- <br>
56
- <?php fs_require_template( '/debug/scheduled-crons.php' ) ?>
57
- <br>
58
- <?php fs_require_template( '/debug/plugins-themes-sync.php' ) ?>
59
- <br>
60
- <?php fs_require_template( '/debug/logger.php' ) ?>
 
 
 
61
  </div>
62
  <?php
63
- }
64
  }
 
6
  * @since 1.1.7.3
7
  */
8
 
9
+ if ( ! defined( 'ABSPATH' ) ) {
10
+ exit;
11
+ }
12
 
13
  /**
14
  * Extends Debug Bar plugin by adding a panel to show all Freemius API requests.
18
  *
19
  * Class Freemius_Debug_Bar_Panel
20
  */
21
+ class Freemius_Debug_Bar_Panel extends Debug_Bar_Panel {
22
+ public function init() {
23
+ $this->title( 'Freemius' );
24
+ }
 
 
 
 
 
 
 
25
 
26
+ public static function requests_count() {
27
+ if ( class_exists( 'Freemius_Api_WordPress' ) ) {
28
+ $logger = Freemius_Api_WordPress::GetLogger();
29
+ } else {
30
+ $logger = array();
31
  }
32
 
33
+ return number_format( count( $logger ) );
34
+ }
 
 
 
 
35
 
36
+ public static function total_time() {
37
+ if ( class_exists( 'Freemius_Api_WordPress' ) ) {
38
+ $logger = Freemius_Api_WordPress::GetLogger();
39
+ } else {
40
+ $logger = array();
41
+ }
42
 
43
+ $total_time = .0;
44
+ foreach ( $logger as $l ) {
45
+ $total_time += $l['total'];
46
  }
47
 
48
+ return number_format( 100 * $total_time, 2 ) . ' ' . fs_text_x_inline( 'ms', 'milliseconds' );
49
+ }
50
+
51
+ public function render() {
52
+ ?>
53
+ <div id='debug-bar-php'>
54
+ <?php fs_require_template( '/debug/api-calls.php' ); ?>
55
+ <br>
56
+ <?php fs_require_template( '/debug/scheduled-crons.php' ); ?>
57
+ <br>
58
+ <?php fs_require_template( '/debug/plugins-themes-sync.php' ); ?>
59
+ <br>
60
+ <?php fs_require_template( '/debug/logger.php' ); ?>
61
  </div>
62
  <?php
 
63
  }
64
+ }
sdk/freemius/includes/managers/class-fs-admin-menu-manager.php CHANGED
@@ -6,602 +6,595 @@
6
  * @since 1.1.3
7
  */
8
 
9
- if ( ! defined( 'ABSPATH' ) ) {
10
- exit;
11
- }
12
-
13
- class FS_Admin_Menu_Manager {
14
 
15
- #region Properties
16
 
17
- /**
18
- * @since 1.2.2
19
- *
20
- * @var string
21
- */
22
- protected $_module_unique_affix;
 
23
 
24
- /**
25
- * @since 1.2.2
26
- *
27
- * @var number
28
- */
29
- protected $_module_id;
30
 
31
- /**
32
- * @since 1.2.2
33
- *
34
- * @var string
35
- */
36
- protected $_module_type;
37
 
38
- /**
39
- * @since 1.0.6
40
- *
41
- * @var string
42
- */
43
- private $_menu_slug;
44
- /**
45
- * @since 1.1.3
46
- *
47
- * @var string
48
- */
49
- private $_parent_slug;
50
- /**
51
- * @since 1.1.3
52
- *
53
- * @var string
54
- */
55
- private $_parent_type;
56
- /**
57
- * @since 1.1.3
58
- *
59
- * @var string
60
- */
61
- private $_type;
62
- /**
63
- * @since 1.1.3
64
- *
65
- * @var bool
66
- */
67
- private $_is_top_level;
68
- /**
69
- * @since 1.1.3
70
- *
71
- * @var bool
72
- */
73
- private $_is_override_exact;
74
- /**
75
- * @since 1.1.3
76
- *
77
- * @var array<string,bool>
78
- */
79
- private $_default_submenu_items;
80
- /**
81
- * @since 1.1.3
82
- *
83
- * @var string
84
- */
85
- private $_first_time_path;
86
- /**
87
- * @since 1.2.2
88
- *
89
- * @var bool
90
- */
91
- private $_menu_exists;
92
- /**
93
- * @since 2.0.0
94
- *
95
- * @var bool
96
- */
97
- private $_network_menu_exists;
98
 
99
- #endregion Properties
 
 
 
 
100
 
101
- /**
102
- * @var FS_Logger
103
- */
104
- protected $_logger;
 
105
 
106
- #region Singleton
 
 
 
 
 
 
 
 
107
 
108
- /**
109
- * @var FS_Admin_Menu_Manager[]
110
- */
111
- private static $_instances = array();
112
 
113
- /**
114
- * @param number $module_id
115
- * @param string $module_type
116
- * @param string $module_unique_affix
117
- *
118
- * @return FS_Admin_Menu_Manager
119
- */
120
- static function instance( $module_id, $module_type, $module_unique_affix ) {
121
- $key = 'm_' . $module_id;
122
-
123
- if ( ! isset( self::$_instances[ $key ] ) ) {
124
- self::$_instances[ $key ] = new FS_Admin_Menu_Manager( $module_id, $module_type, $module_unique_affix );
125
- }
126
 
127
- return self::$_instances[ $key ];
128
- }
129
 
130
- protected function __construct( $module_id, $module_type, $module_unique_affix ) {
131
- $this->_logger = FS_Logger::get_logger( WP_FS__SLUG . '_' . $module_id . '_admin_menu', WP_FS__DEBUG_SDK, WP_FS__ECHO_DEBUG_SDK );
 
 
132
 
133
- $this->_module_id = $module_id;
134
- $this->_module_type = $module_type;
135
- $this->_module_unique_affix = $module_unique_affix;
136
- }
 
137
 
138
- #endregion Singleton
 
 
139
 
140
- #region Helpers
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
141
 
142
- private function get_option( &$options, $key, $default = false ) {
143
- return ! empty( $options[ $key ] ) ? $options[ $key ] : $default;
144
- }
145
 
146
- private function get_bool_option( &$options, $key, $default = false ) {
147
- return isset( $options[ $key ] ) && is_bool( $options[ $key ] ) ? $options[ $key ] : $default;
148
- }
149
 
150
- #endregion Helpers
 
 
 
151
 
152
- /**
153
- * @param array $menu
154
- * @param bool $is_addon
155
- */
156
- function init( $menu, $is_addon = false ) {
157
- $this->_menu_exists = ( isset( $menu['slug'] ) && ! empty( $menu['slug'] ) );
158
- $this->_network_menu_exists = ( ! empty( $menu['network'] ) && true === $menu['network'] );
159
-
160
- $this->_menu_slug = ( $this->_menu_exists ? $menu['slug'] : $this->_module_unique_affix );
161
-
162
- $this->_default_submenu_items = array();
163
- // @deprecated
164
- $this->_type = 'page';
165
- $this->_is_top_level = true;
166
- $this->_is_override_exact = false;
167
- $this->_parent_slug = false;
168
- // @deprecated
169
- $this->_parent_type = 'page';
170
-
171
- if ( isset( $menu ) ) {
172
- if ( ! $is_addon ) {
173
- $this->_default_submenu_items = array(
174
- 'contact' => $this->get_bool_option( $menu, 'contact', true ),
175
- 'support' => $this->get_bool_option( $menu, 'support', true ),
176
- 'affiliation' => $this->get_bool_option( $menu, 'affiliation', true ),
177
- 'account' => $this->get_bool_option( $menu, 'account', true ),
178
- 'pricing' => $this->get_bool_option( $menu, 'pricing', true ),
179
- 'addons' => $this->get_bool_option( $menu, 'addons', true ),
180
- );
181
-
182
- // @deprecated
183
- $this->_type = $this->get_option( $menu, 'type', 'page' );
184
- }
185
-
186
- $this->_is_override_exact = $this->get_bool_option( $menu, 'override_exact' );
187
-
188
- if ( isset( $menu['parent'] ) ) {
189
- $this->_parent_slug = $this->get_option( $menu['parent'], 'slug' );
190
- // @deprecated
191
- $this->_parent_type = $this->get_option( $menu['parent'], 'type', 'page' );
192
-
193
- // If parent's slug is different, then it's NOT a top level menu item.
194
- $this->_is_top_level = ( $this->_parent_slug === $this->_menu_slug );
195
- } else {
196
- /**
197
  * If no parent then top level if:
198
  * - Has custom admin menu ('page')
199
  * - CPT menu type ('cpt')
200
  */
201
- // $this->_is_top_level = in_array( $this->_type, array(
202
- // 'cpt',
203
- // 'page'
204
- // ) );
205
- }
206
-
207
- $this->_first_time_path = $this->get_option( $menu, 'first-path', false );
208
- if ( ! empty( $this->_first_time_path ) && is_string( $this->_first_time_path ) ) {
209
- $this->_first_time_path = admin_url( $this->_first_time_path, 'admin' );
210
- }
211
  }
212
- }
213
 
214
- /**
215
- * Check if top level menu.
216
- *
217
- * @author Vova Feldman (@svovaf)
218
- * @since 1.1.3
219
- *
220
- * @return bool False if submenu item.
221
- */
222
- function is_top_level() {
223
- return $this->_is_top_level;
224
  }
 
225
 
226
- /**
227
- * Check if the page should be override on exact URL match.
228
- *
229
- * @author Vova Feldman (@svovaf)
230
- * @since 1.1.3
231
- *
232
- * @return bool False if submenu item.
233
- */
234
- function is_override_exact() {
235
- return $this->_is_override_exact;
236
- }
237
 
 
 
 
 
 
 
 
 
 
 
 
238
 
239
- /**
240
- * Get the path of the page the user should be forwarded to after first activation.
241
- *
242
- * @author Vova Feldman (@svovaf)
243
- * @since 1.1.3
244
- *
245
- * @return string
246
- */
247
- function get_first_time_path() {
248
- return $this->_first_time_path;
249
- }
250
 
251
- /**
252
- * Check if plugin's menu item is part of a custom top level menu.
253
- *
254
- * @author Vova Feldman (@svovaf)
255
- * @since 1.1.3
256
- *
257
- * @return bool
258
- */
259
- function has_custom_parent() {
260
- return ! $this->_is_top_level && is_string( $this->_parent_slug );
261
- }
262
 
263
- /**
264
- * @author Leo Fajardo (@leorw)
265
- * @since 1.2.2
266
- *
267
- * @return bool
268
- */
269
- function has_menu() {
270
- return $this->_menu_exists;
271
- }
 
 
272
 
273
- /**
274
- * @author Vova Feldman (@svovaf)
275
- * @since 2.0.0
276
- *
277
- * @return bool
278
- */
279
- function has_network_menu() {
280
- return $this->_network_menu_exists;
281
- }
282
 
283
- /**
284
- * @author Leo Fajardo (@leorw)
285
- *
286
- * @param string $menu_slug
287
- *
288
- * @since 2.1.3
289
- */
290
- function set_slug_and_network_menu_exists_flag($menu_slug ) {
291
- $this->_menu_slug = $menu_slug;
292
- $this->_network_menu_exists = false;
293
- }
294
 
295
- /**
296
- * @author Vova Feldman (@svovaf)
297
- * @since 1.1.3
298
- *
299
- * @param string $id
300
- * @param bool $default
301
- * @param bool $ignore_menu_existence Since 1.2.2.7 If true, check if the submenu item visible even if there's no parent menu.
302
- *
303
- * @return bool
304
- */
305
- function is_submenu_item_visible( $id, $default = true, $ignore_menu_existence = false ) {
306
- if ( ! $ignore_menu_existence && ! $this->has_menu() ) {
307
- return false;
308
- }
309
 
310
- return fs_apply_filter(
311
- $this->_module_unique_affix,
312
- 'is_submenu_visible',
313
- $this->get_bool_option( $this->_default_submenu_items, $id, $default ),
314
- $id
315
- );
 
 
 
 
 
 
 
316
  }
317
 
318
- /**
319
- * Calculates admin settings menu slug.
320
- * If plugin's menu slug is a file (e.g. CPT), uses plugin's slug as the menu slug.
321
- *
322
- * @author Vova Feldman (@svovaf)
323
- * @since 1.1.3
324
- *
325
- * @param string $page
326
- *
327
- * @return string
328
- */
329
- function get_slug( $page = '' ) {
330
- return ( ( false === strpos( $this->_menu_slug, '.php?' ) ) ?
331
- $this->_menu_slug :
332
- $this->_module_unique_affix ) . ( empty( $page ) ? '' : ( '-' . $page ) );
333
- }
334
 
335
- /**
336
- * @author Vova Feldman (@svovaf)
337
- * @since 1.1.3
338
- *
339
- * @return string
340
- */
341
- function get_parent_slug() {
342
- return $this->_parent_slug;
343
- }
 
 
 
 
 
 
 
344
 
345
- /**
346
- * @author Vova Feldman (@svovaf)
347
- * @since 1.1.3
348
- *
349
- * @return string
350
- */
351
- function get_type() {
352
- return $this->_type;
353
- }
354
 
355
- /**
356
- * @author Vova Feldman (@svovaf)
357
- * @since 1.1.3
358
- *
359
- * @return bool
360
- */
361
- function is_cpt() {
362
- return ( 0 === strpos( $this->_menu_slug, 'edit.php?post_type=' ) ||
363
- // Back compatibility.
364
- 'cpt' === $this->_type
365
- );
366
- }
367
 
368
- /**
369
- * @author Vova Feldman (@svovaf)
370
- * @since 1.1.3
371
- *
372
- * @return string
373
- */
374
- function get_parent_type() {
375
- return $this->_parent_type;
376
- }
 
 
 
377
 
378
- /**
379
- * @author Vova Feldman (@svovaf)
380
- * @since 1.1.3
381
- *
382
- * @return string
383
- */
384
- function get_raw_slug() {
385
- return $this->_menu_slug;
386
- }
387
 
388
- /**
389
- * Get plugin's original menu slug.
390
- *
391
- * @author Vova Feldman (@svovaf)
392
- * @since 1.1.3
393
- *
394
- * @return string
395
- */
396
- function get_original_menu_slug() {
397
- if ( 'cpt' === $this->_type ) {
398
- return add_query_arg( array(
399
- 'post_type' => $this->_menu_slug
400
- ), 'edit.php' );
401
- }
402
 
403
- if ( false === strpos( $this->_menu_slug, '.php?' ) ) {
404
- return $this->_menu_slug;
405
- } else {
406
- return $this->_module_unique_affix;
407
- }
 
 
 
 
 
 
 
 
 
 
408
  }
409
 
410
- /**
411
- * @author Vova Feldman (@svovaf)
412
- * @since 1.1.3
413
- *
414
- * @return string
415
- */
416
- function get_top_level_menu_slug() {
417
- return $this->has_custom_parent() ?
418
- $this->get_parent_slug() :
419
- $this->get_raw_slug();
420
  }
 
421
 
422
- /**
423
- * Is user on plugin's admin activation page.
424
- *
425
- * @author Vova Feldman (@svovaf)
426
- * @since 1.0.8
427
- *
428
- * @return bool
429
- */
430
- function is_main_settings_page() {
431
- if ( $this->_menu_exists &&
432
- ( fs_is_plugin_page( $this->_menu_slug ) || fs_is_plugin_page( $this->_module_unique_affix ) )
433
- ) {
434
- /**
 
 
 
 
 
 
 
 
 
 
 
 
435
  * Module has a settings menu and the context page is the main settings page, so assume it's in
436
  * activation (doesn't really check if already opted-in/skipped or not).
437
  *
438
  * @since 1.2.2
439
  */
440
- return true;
441
- }
442
 
443
- global $pagenow;
444
- if ( ( WP_FS__MODULE_TYPE_THEME === $this->_module_type ) && Freemius::is_themes_page() ) {
445
- /**
446
  * In activation only when show_optin query string param is given.
447
  *
448
  * @since 1.2.2
449
  */
450
- return fs_request_get_bool( $this->_module_unique_affix . '_show_optin' );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
451
  }
 
452
 
 
 
453
  return false;
454
  }
455
 
456
- #region Submenu Override
 
 
457
 
458
- /**
459
- * Override submenu's action.
460
- *
461
- * @author Vova Feldman (@svovaf)
462
- * @since 1.1.0
463
- *
464
- * @param string $parent_slug
465
- * @param string $menu_slug
466
- * @param callable $function
467
- *
468
- * @return false|string If submenu exist, will return the hook name.
469
- */
470
- function override_submenu_action( $parent_slug, $menu_slug, $function ) {
471
- global $submenu;
472
-
473
- $menu_slug = plugin_basename( $menu_slug );
474
- $parent_slug = plugin_basename( $parent_slug );
475
-
476
- if ( ! isset( $submenu[ $parent_slug ] ) ) {
477
- // Parent menu not exist.
478
- return false;
479
- }
480
 
481
- $found_submenu_item = false;
482
- foreach ( $submenu[ $parent_slug ] as $submenu_item ) {
483
- if ( $menu_slug === $submenu_item[2] ) {
484
- $found_submenu_item = $submenu_item;
485
- break;
486
- }
487
- }
488
 
489
- if ( false === $found_submenu_item ) {
490
- // Submenu item not found.
491
- return false;
492
- }
 
 
 
 
 
 
 
 
493
 
494
- // Remove current function.
495
- $hookname = get_plugin_page_hookname( $menu_slug, $parent_slug );
496
- remove_all_actions( $hookname );
497
 
498
- // Attach new action.
499
- add_action( $hookname, $function );
500
 
501
- return $hookname;
 
 
 
 
 
 
502
  }
503
 
504
- #endregion Submenu Override
 
 
505
 
506
- #region Top level menu Override
 
 
 
 
 
507
 
508
- /**
509
- * Find plugin's admin dashboard main menu item.
510
- *
511
- * @author Vova Feldman (@svovaf)
512
- * @since 1.0.2
513
- *
514
- * @return string[]|false
515
- */
516
- private function find_top_level_menu() {
517
- global $menu;
518
 
519
- $position = - 1;
520
- $found_menu = false;
521
 
522
- $menu_slug = $this->get_raw_slug();
 
 
523
 
524
- $hook_name = get_plugin_page_hookname( $menu_slug, '' );
525
- foreach ( $menu as $pos => $m ) {
526
- if ( $menu_slug === $m[2] ) {
527
- $position = $pos;
528
- $found_menu = $m;
529
- break;
530
- }
531
- }
532
 
533
- if ( false === $found_menu ) {
534
- return false;
535
- }
536
 
537
- return array(
538
- 'menu' => $found_menu,
539
- 'position' => $position,
540
- 'hook_name' => $hook_name
541
- );
542
- }
543
 
544
- /**
545
- * Find plugin's admin dashboard main submenu item.
546
- *
547
- * @author Vova Feldman (@svovaf)
548
- * @since 1.2.1.6
549
- *
550
- * @return array|false
551
- */
552
- private function find_main_submenu() {
553
- global $submenu;
554
-
555
- $top_level_menu_slug = $this->get_top_level_menu_slug();
556
-
557
- if ( ! isset( $submenu[ $top_level_menu_slug ] ) ) {
558
- return false;
559
  }
 
560
 
561
- $submenu_slug = $this->get_raw_slug();
562
-
563
- $position = - 1;
564
- $found_submenu = false;
565
 
566
- $hook_name = get_plugin_page_hookname( $submenu_slug, '' );
 
 
 
 
 
 
567
 
568
- foreach ( $submenu[ $top_level_menu_slug ] as $pos => $sub ) {
569
- if ( $submenu_slug === $sub[2] ) {
570
- $position = $pos;
571
- $found_submenu = $sub;
572
- }
573
- }
 
 
 
 
574
 
575
- if ( false === $found_submenu ) {
576
- return false;
577
- }
578
 
579
- return array(
580
- 'menu' => $found_submenu,
581
- 'parent_slug' => $top_level_menu_slug,
582
- 'position' => $position,
583
- 'hook_name' => $hook_name
584
- );
585
  }
586
 
587
  /**
588
- * Remove all sub-menu items.
589
- *
590
- * @author Vova Feldman (@svovaf)
591
- * @since 1.0.7
592
- *
593
- * @return bool If submenu with plugin's menu slug was found.
594
- */
595
- private function remove_all_submenu_items() {
596
- global $submenu;
597
-
598
- $menu_slug = $this->get_raw_slug();
599
-
600
- if ( ! isset( $submenu[ $menu_slug ] ) ) {
601
- return false;
602
- }
603
-
604
- /**
605
  * This method is NOT executed for WordPress.org themes.
606
  * Since we maintain only one version of the SDK we added this small
607
  * hack to avoid the error from Theme Check since it's a false-positive.
@@ -609,129 +602,129 @@
609
  * @author Vova Feldman (@svovaf)
610
  * @since 1.2.2.7
611
  */
612
- $submenu_ref = &$submenu;
613
- $submenu_ref[ $menu_slug ] = array();
614
 
615
- return true;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
616
  }
617
 
618
- /**
619
- *
620
- * @author Vova Feldman (@svovaf)
621
- * @since 1.0.9
622
- *
623
- * @param bool $remove_top_level_menu
624
- *
625
- * @return false|array[string]mixed
626
- */
627
- function remove_menu_item( $remove_top_level_menu = false ) {
628
- $this->_logger->entrance();
629
-
630
- // Find main menu item.
631
- $top_level_menu = $this->find_top_level_menu();
632
-
633
- if ( false === $top_level_menu ) {
634
- return false;
635
- }
636
-
637
- // Remove it with its actions.
638
- remove_all_actions( $top_level_menu['hook_name'] );
639
-
640
- // Remove all submenu items.
641
- $this->remove_all_submenu_items();
642
-
643
- if ( $remove_top_level_menu ) {
644
- global $menu;
645
- unset( $menu[ $top_level_menu['position'] ] );
646
- }
647
-
648
- return $top_level_menu;
649
- }
650
 
651
- /**
652
- * Get module's main admin setting page URL.
653
- *
654
- * @todo This method was only tested for wp.org compliant themes with a submenu item. Need to test for plugins with top level, submenu, and CPT top level, menu items.
655
- *
656
- * @author Vova Feldman (@svovaf)
657
- * @since 1.2.2.7
658
- *
659
- * @return string
660
- */
661
- function main_menu_url() {
662
- $this->_logger->entrance();
663
-
664
- if ( $this->_is_top_level ) {
665
- $menu = $this->find_top_level_menu();
666
- } else {
667
- $menu = $this->find_main_submenu();
668
- }
669
 
670
- $parent_slug = isset( $menu['parent_slug'] ) ?
671
- $menu['parent_slug'] :
672
- 'admin.php';
673
 
674
- return admin_url( $parent_slug . '?page=' . $menu['menu'][2] );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
675
  }
676
 
677
- /**
678
- * @author Vova Feldman (@svovaf)
679
- * @since 1.1.4
680
- *
681
- * @param callable $function
682
- *
683
- * @return false|array[string]mixed
684
- */
685
- function override_menu_item( $function ) {
686
- $found_menu = $this->remove_menu_item();
687
-
688
- if ( false === $found_menu ) {
689
- return false;
690
- }
691
 
692
- if ( ! $this->is_top_level() || ! $this->is_cpt() ) {
693
- $menu_slug = plugin_basename( $this->get_slug() );
694
 
695
- $hookname = get_plugin_page_hookname( $menu_slug, '' );
 
 
 
 
 
 
 
 
 
696
 
697
- // Override menu action.
698
- add_action( $hookname, $function );
699
- } else {
700
- global $menu;
701
 
702
- // Remove original CPT menu.
703
- unset( $menu[ $found_menu['position'] ] );
704
 
705
- // Create new top-level menu action.
706
- $hookname = self::add_page(
707
- $found_menu['menu'][3],
708
- $found_menu['menu'][0],
709
- 'manage_options',
710
- $this->get_slug(),
711
- $function,
712
- $found_menu['menu'][6],
713
- $found_menu['position']
714
- );
715
- }
716
 
717
- return $hookname;
 
 
 
 
 
 
 
 
 
718
  }
719
 
720
- /**
721
- * Adds a counter to the module's top level menu item.
722
- *
723
- * @author Vova Feldman (@svovaf)
724
- * @since 1.2.1.5
725
- *
726
- * @param int $counter
727
- * @param string $class
728
- */
729
- function add_counter_to_menu_item( $counter = 1, $class = '' ) {
730
- global $menu, $submenu;
731
-
732
- $mask = '%s <span class="update-plugins %s count-%3$s" aria-hidden="true"><span>%3$s<span class="screen-reader-text">%3$s notifications</span></span></span>';
733
 
734
- /**
 
 
 
 
 
 
 
 
 
 
 
 
 
 
735
  * This method is NOT executed for WordPress.org themes.
736
  * Since we maintain only one version of the SDK we added this small
737
  * hack to avoid the error from Theme Check since it's a false-positive.
@@ -739,231 +732,231 @@
739
  * @author Vova Feldman (@svovaf)
740
  * @since 1.2.2.7
741
  */
742
- $menu_ref = &$menu;
743
- $submenu_ref = &$submenu;
744
-
745
- if ( $this->_is_top_level ) {
746
- // Find main menu item.
747
- $found_menu = $this->find_top_level_menu();
748
-
749
- if ( false !== $found_menu ) {
750
- // Override menu label.
751
- $menu_ref[ $found_menu['position'] ][0] = sprintf(
752
- $mask,
753
- $found_menu['menu'][0],
754
- $class,
755
- $counter
756
- );
757
- }
758
- } else {
759
- $found_submenu = $this->find_main_submenu();
760
-
761
- if ( false !== $found_submenu ) {
762
- // Override menu label.
763
- $submenu_ref[ $found_submenu['parent_slug'] ][ $found_submenu['position'] ][0] = sprintf(
764
- $mask,
765
- $found_submenu['menu'][0],
766
- $class,
767
- $counter
768
- );
769
- }
770
  }
771
  }
 
772
 
773
- #endregion Top level menu Override
774
-
775
- /**
776
- * Add a top-level menu page.
777
- *
778
- * Note for WordPress.org Theme/Plugin reviewer:
779
- *
780
- * This is a replication of `add_menu_page()` to avoid Theme Check warning.
781
- *
782
- * Why?
783
- * ====
784
- * Freemius is an SDK for plugin and theme developers. Since the core
785
- * of the SDK is relevant both for plugins and themes, for obvious reasons,
786
- * we only develop and maintain one code base.
787
- *
788
- * This method will not run for wp.org themes (only plugins) since theme
789
- * admin settings/options are now only allowed in the customizer.
790
- *
791
- * If you have any questions or need clarifications, please don't hesitate
792
- * pinging me on slack, my username is @svovaf.
793
- *
794
- * @author Vova Feldman (@svovaf)
795
- * @since 1.2.2
796
- *
797
- * @param string $page_title The text to be displayed in the title tags of the page when the menu is
798
- * selected.
799
- * @param string $menu_title The text to be used for the menu.
800
- * @param string $capability The capability required for this menu to be displayed to the user.
801
- * @param string $menu_slug The slug name to refer to this menu by (should be unique for this menu).
802
- * @param callable|string $function The function to be called to output the content for this page.
803
- * @param string $icon_url The URL to the icon to be used for this menu.
804
- * * Pass a base64-encoded SVG using a data URI, which will be colored to
805
- * match the color scheme. This should begin with
806
- * 'data:image/svg+xml;base64,'.
807
- * * Pass the name of a Dashicons helper class to use a font icon,
808
- * e.g. 'dashicons-chart-pie'.
809
- * * Pass 'none' to leave div.wp-menu-image empty so an icon can be added
810
- * via CSS.
811
- * @param int $position The position in the menu order this one should appear.
812
- *
813
- * @return string The resulting page's hook_suffix.
814
- */
815
- static function add_page(
 
 
 
 
 
 
 
 
 
 
816
  $page_title,
817
  $menu_title,
818
  $capability,
819
  $menu_slug,
820
- $function = '',
821
- $icon_url = '',
822
- $position = null
823
- ) {
824
- $fn = 'add_menu' . '_page';
825
-
826
- return $fn(
827
- $page_title,
828
- $menu_title,
829
- $capability,
830
- $menu_slug,
831
- $function,
832
- $icon_url,
833
- $position
834
- );
835
- }
836
 
837
- /**
838
- * Add page and update menu instance settings.
839
- *
840
- * @author Vova Feldman (@svovaf)
841
- * @since 2.0.0
842
- *
843
- * @param string $page_title
844
- * @param string $menu_title
845
- * @param string $capability
846
- * @param string $menu_slug
847
- * @param callable|string $function
848
- * @param string $icon_url
849
- * @param int|null $position
850
- *
851
- * @return string
852
- */
853
- function add_page_and_update(
854
- $page_title,
855
- $menu_title,
856
- $capability,
857
- $menu_slug,
858
- $function = '',
859
- $icon_url = '',
860
- $position = null
861
- ) {
862
- $this->_menu_slug = $menu_slug;
863
- $this->_is_top_level = true;
864
- $this->_menu_exists = true;
865
- $this->_network_menu_exists = true;
866
-
867
- return self::add_page(
868
- $page_title,
869
- $menu_title,
870
- $capability,
871
- $menu_slug,
872
- $function,
873
- $icon_url,
874
- $position
875
- );
876
- }
877
 
878
- /**
879
- * Add a submenu page.
880
- *
881
- * Note for WordPress.org Theme/Plugin reviewer:
882
- *
883
- * This is a replication of `add_submenu_page()` to avoid Theme Check warning.
884
- *
885
- * Why?
886
- * ====
887
- * Freemius is an SDK for plugin and theme developers. Since the core
888
- * of the SDK is relevant both for plugins and themes, for obvious reasons,
889
- * we only develop and maintain one code base.
890
- *
891
- * This method will not run for wp.org themes (only plugins) since theme
892
- * admin settings/options are now only allowed in the customizer.
893
- *
894
- * If you have any questions or need clarifications, please don't hesitate
895
- * pinging me on slack, my username is @svovaf.
896
- *
897
- * @author Vova Feldman (@svovaf)
898
- * @since 1.2.2
899
- *
900
- * @param string $parent_slug The slug name for the parent menu (or the file name of a standard
901
- * WordPress admin page).
902
- * @param string $page_title The text to be displayed in the title tags of the page when the menu is
903
- * selected.
904
- * @param string $menu_title The text to be used for the menu.
905
- * @param string $capability The capability required for this menu to be displayed to the user.
906
- * @param string $menu_slug The slug name to refer to this menu by (should be unique for this menu).
907
- * @param callable|string $function The function to be called to output the content for this page.
908
- *
909
- * @return false|string The resulting page's hook_suffix, or false if the user does not have the capability
910
- * required.
911
- */
912
- static function add_subpage(
 
 
 
 
 
 
 
 
 
 
913
  $parent_slug,
914
  $page_title,
915
  $menu_title,
916
  $capability,
917
  $menu_slug,
918
- $function = ''
919
- ) {
920
- $fn = 'add_submenu' . '_page';
921
-
922
- return $fn( $parent_slug,
923
- $page_title,
924
- $menu_title,
925
- $capability,
926
- $menu_slug,
927
- $function
928
- );
929
- }
930
 
931
- /**
932
- * Add sub page and update menu instance settings.
933
- *
934
- * @author Vova Feldman (@svovaf)
935
- * @since 2.0.0
936
- *
937
- * @param string $parent_slug
938
- * @param string $page_title
939
- * @param string $menu_title
940
- * @param string $capability
941
- * @param string $menu_slug
942
- * @param callable|string $function
943
- *
944
- * @return string
945
- */
946
- function add_subpage_and_update(
947
- $parent_slug,
948
- $page_title,
949
- $menu_title,
950
- $capability,
951
- $menu_slug,
952
- $function = ''
953
- ) {
954
- $this->_menu_slug = $menu_slug;
955
- $this->_parent_slug = $parent_slug;
956
- $this->_is_top_level = false;
957
- $this->_menu_exists = true;
958
- $this->_network_menu_exists = true;
959
-
960
- return self::add_subpage(
961
- $parent_slug,
962
- $page_title,
963
- $menu_title,
964
- $capability,
965
- $menu_slug,
966
- $function
967
- );
968
- }
969
- }
6
  * @since 1.1.3
7
  */
8
 
9
+ if ( ! defined( 'ABSPATH' ) ) {
10
+ exit;
11
+ }
 
 
12
 
13
+ class FS_Admin_Menu_Manager {
14
 
15
+ // region Properties
16
+ /**
17
+ * @since 1.2.2
18
+ *
19
+ * @var string
20
+ */
21
+ protected $_module_unique_affix;
22
 
23
+ /**
24
+ * @since 1.2.2
25
+ *
26
+ * @var number
27
+ */
28
+ protected $_module_id;
29
 
30
+ /**
31
+ * @since 1.2.2
32
+ *
33
+ * @var string
34
+ */
35
+ protected $_module_type;
36
 
37
+ /**
38
+ * @since 1.0.6
39
+ *
40
+ * @var string
41
+ */
42
+ private $_menu_slug;
43
+ /**
44
+ * @since 1.1.3
45
+ *
46
+ * @var string
47
+ */
48
+ private $_parent_slug;
49
+ /**
50
+ * @since 1.1.3
51
+ *
52
+ * @var string
53
+ */
54
+ private $_parent_type;
55
+ /**
56
+ * @since 1.1.3
57
+ *
58
+ * @var string
59
+ */
60
+ private $_type;
61
+ /**
62
+ * @since 1.1.3
63
+ *
64
+ * @var bool
65
+ */
66
+ private $_is_top_level;
67
+ /**
68
+ * @since 1.1.3
69
+ *
70
+ * @var bool
71
+ */
72
+ private $_is_override_exact;
73
+ /**
74
+ * @since 1.1.3
75
+ *
76
+ * @var array<string,bool>
77
+ */
78
+ private $_default_submenu_items;
79
+ /**
80
+ * @since 1.1.3
81
+ *
82
+ * @var string
83
+ */
84
+ private $_first_time_path;
85
+ /**
86
+ * @since 1.2.2
87
+ *
88
+ * @var bool
89
+ */
90
+ private $_menu_exists;
91
+ /**
92
+ * @since 2.0.0
93
+ *
94
+ * @var bool
95
+ */
96
+ private $_network_menu_exists;
97
 
98
+ // endregion Properties
99
+ /**
100
+ * @var FS_Logger
101
+ */
102
+ protected $_logger;
103
 
104
+ // region Singleton
105
+ /**
106
+ * @var FS_Admin_Menu_Manager[]
107
+ */
108
+ private static $_instances = array();
109
 
110
+ /**
111
+ * @param number $module_id
112
+ * @param string $module_type
113
+ * @param string $module_unique_affix
114
+ *
115
+ * @return FS_Admin_Menu_Manager
116
+ */
117
+ static function instance( $module_id, $module_type, $module_unique_affix ) {
118
+ $key = 'm_' . $module_id;
119
 
120
+ if ( ! isset( self::$_instances[ $key ] ) ) {
121
+ self::$_instances[ $key ] = new FS_Admin_Menu_Manager( $module_id, $module_type, $module_unique_affix );
122
+ }
 
123
 
124
+ return self::$_instances[ $key ];
125
+ }
 
 
 
 
 
 
 
 
 
 
 
126
 
127
+ protected function __construct( $module_id, $module_type, $module_unique_affix ) {
128
+ $this->_logger = FS_Logger::get_logger( WP_FS__SLUG . '_' . $module_id . '_admin_menu', WP_FS__DEBUG_SDK, WP_FS__ECHO_DEBUG_SDK );
129
 
130
+ $this->_module_id = $module_id;
131
+ $this->_module_type = $module_type;
132
+ $this->_module_unique_affix = $module_unique_affix;
133
+ }
134
 
135
+ // endregion Singleton
136
+ // region Helpers
137
+ private function get_option( &$options, $key, $default = false ) {
138
+ return ! empty( $options[ $key ] ) ? $options[ $key ] : $default;
139
+ }
140
 
141
+ private function get_bool_option( &$options, $key, $default = false ) {
142
+ return isset( $options[ $key ] ) && is_bool( $options[ $key ] ) ? $options[ $key ] : $default;
143
+ }
144
 
145
+ // endregion Helpers
146
+ /**
147
+ * @param array $menu
148
+ * @param bool $is_addon
149
+ */
150
+ public function init( $menu, $is_addon = false ) {
151
+ $this->_menu_exists = ( isset( $menu['slug'] ) && ! empty( $menu['slug'] ) );
152
+ $this->_network_menu_exists = ( ! empty( $menu['network'] ) && true === $menu['network'] );
153
+
154
+ $this->_menu_slug = ( $this->_menu_exists ? $menu['slug'] : $this->_module_unique_affix );
155
+
156
+ $this->_default_submenu_items = array();
157
+ // @deprecated
158
+ $this->_type = 'page';
159
+ $this->_is_top_level = true;
160
+ $this->_is_override_exact = false;
161
+ $this->_parent_slug = false;
162
+ // @deprecated
163
+ $this->_parent_type = 'page';
164
+
165
+ if ( isset( $menu ) ) {
166
+ if ( ! $is_addon ) {
167
+ $this->_default_submenu_items = array(
168
+ 'contact' => $this->get_bool_option( $menu, 'contact', true ),
169
+ 'support' => $this->get_bool_option( $menu, 'support', true ),
170
+ 'affiliation' => $this->get_bool_option( $menu, 'affiliation', true ),
171
+ 'account' => $this->get_bool_option( $menu, 'account', true ),
172
+ 'pricing' => $this->get_bool_option( $menu, 'pricing', true ),
173
+ 'addons' => $this->get_bool_option( $menu, 'addons', true ),
174
+ );
175
 
176
+ // @deprecated
177
+ $this->_type = $this->get_option( $menu, 'type', 'page' );
178
+ }
179
 
180
+ $this->_is_override_exact = $this->get_bool_option( $menu, 'override_exact' );
 
 
181
 
182
+ if ( isset( $menu['parent'] ) ) {
183
+ $this->_parent_slug = $this->get_option( $menu['parent'], 'slug' );
184
+ // @deprecated
185
+ $this->_parent_type = $this->get_option( $menu['parent'], 'type', 'page' );
186
 
187
+ // If parent's slug is different, then it's NOT a top level menu item.
188
+ $this->_is_top_level = ( $this->_parent_slug === $this->_menu_slug );
189
+ } else {
190
+ /**
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
191
  * If no parent then top level if:
192
  * - Has custom admin menu ('page')
193
  * - CPT menu type ('cpt')
194
  */
195
+ // $this->_is_top_level = in_array( $this->_type, array(
196
+ // 'cpt',
197
+ // 'page'
198
+ // ) );
 
 
 
 
 
 
199
  }
 
200
 
201
+ $this->_first_time_path = $this->get_option( $menu, 'first-path', false );
202
+ if ( ! empty( $this->_first_time_path ) && is_string( $this->_first_time_path ) ) {
203
+ $this->_first_time_path = admin_url( $this->_first_time_path, 'admin' );
204
+ }
 
 
 
 
 
 
205
  }
206
+ }
207
 
208
+ /**
209
+ * Check if top level menu.
210
+ *
211
+ * @author Vova Feldman (@svovaf)
212
+ * @since 1.1.3
213
+ *
214
+ * @return bool False if submenu item.
215
+ */
216
+ public function is_top_level() {
217
+ return $this->_is_top_level;
218
+ }
219
 
220
+ /**
221
+ * Check if the page should be override on exact URL match.
222
+ *
223
+ * @author Vova Feldman (@svovaf)
224
+ * @since 1.1.3
225
+ *
226
+ * @return bool False if submenu item.
227
+ */
228
+ public function is_override_exact() {
229
+ return $this->_is_override_exact;
230
+ }
231
 
 
 
 
 
 
 
 
 
 
 
 
232
 
233
+ /**
234
+ * Get the path of the page the user should be forwarded to after first activation.
235
+ *
236
+ * @author Vova Feldman (@svovaf)
237
+ * @since 1.1.3
238
+ *
239
+ * @return string
240
+ */
241
+ public function get_first_time_path() {
242
+ return $this->_first_time_path;
243
+ }
244
 
245
+ /**
246
+ * Check if plugin's menu item is part of a custom top level menu.
247
+ *
248
+ * @author Vova Feldman (@svovaf)
249
+ * @since 1.1.3
250
+ *
251
+ * @return bool
252
+ */
253
+ public function has_custom_parent() {
254
+ return ! $this->_is_top_level && is_string( $this->_parent_slug );
255
+ }
256
 
257
+ /**
258
+ * @author Leo Fajardo (@leorw)
259
+ * @since 1.2.2
260
+ *
261
+ * @return bool
262
+ */
263
+ public function has_menu() {
264
+ return $this->_menu_exists;
265
+ }
266
 
267
+ /**
268
+ * @author Vova Feldman (@svovaf)
269
+ * @since 2.0.0
270
+ *
271
+ * @return bool
272
+ */
273
+ public function has_network_menu() {
274
+ return $this->_network_menu_exists;
275
+ }
 
 
276
 
277
+ /**
278
+ * @author Leo Fajardo (@leorw)
279
+ *
280
+ * @param string $menu_slug
281
+ *
282
+ * @since 2.1.3
283
+ */
284
+ public function set_slug_and_network_menu_exists_flag( $menu_slug ) {
285
+ $this->_menu_slug = $menu_slug;
286
+ $this->_network_menu_exists = false;
287
+ }
 
 
 
288
 
289
+ /**
290
+ * @author Vova Feldman (@svovaf)
291
+ * @since 1.1.3
292
+ *
293
+ * @param string $id
294
+ * @param bool $default
295
+ * @param bool $ignore_menu_existence Since 1.2.2.7 If true, check if the submenu item visible even if there's no parent menu.
296
+ *
297
+ * @return bool
298
+ */
299
+ public function is_submenu_item_visible( $id, $default = true, $ignore_menu_existence = false ) {
300
+ if ( ! $ignore_menu_existence && ! $this->has_menu() ) {
301
+ return false;
302
  }
303
 
304
+ return fs_apply_filter(
305
+ $this->_module_unique_affix,
306
+ 'is_submenu_visible',
307
+ $this->get_bool_option( $this->_default_submenu_items, $id, $default ),
308
+ $id
309
+ );
310
+ }
 
 
 
 
 
 
 
 
 
311
 
312
+ /**
313
+ * Calculates admin settings menu slug.
314
+ * If plugin's menu slug is a file (e.g. CPT), uses plugin's slug as the menu slug.
315
+ *
316
+ * @author Vova Feldman (@svovaf)
317
+ * @since 1.1.3
318
+ *
319
+ * @param string $page
320
+ *
321
+ * @return string
322
+ */
323
+ public function get_slug( $page = '' ) {
324
+ return ( ( false === strpos( $this->_menu_slug, '.php?' ) ) ?
325
+ $this->_menu_slug :
326
+ $this->_module_unique_affix ) . ( empty( $page ) ? '' : ( '-' . $page ) );
327
+ }
328
 
329
+ /**
330
+ * @author Vova Feldman (@svovaf)
331
+ * @since 1.1.3
332
+ *
333
+ * @return string
334
+ */
335
+ public function get_parent_slug() {
336
+ return $this->_parent_slug;
337
+ }
338
 
339
+ /**
340
+ * @author Vova Feldman (@svovaf)
341
+ * @since 1.1.3
342
+ *
343
+ * @return string
344
+ */
345
+ public function get_type() {
346
+ return $this->_type;
347
+ }
 
 
 
348
 
349
+ /**
350
+ * @author Vova Feldman (@svovaf)
351
+ * @since 1.1.3
352
+ *
353
+ * @return bool
354
+ */
355
+ public function is_cpt() {
356
+ return ( 0 === strpos( $this->_menu_slug, 'edit.php?post_type=' ) ||
357
+ // Back compatibility.
358
+ 'cpt' === $this->_type
359
+ );
360
+ }
361
 
362
+ /**
363
+ * @author Vova Feldman (@svovaf)
364
+ * @since 1.1.3
365
+ *
366
+ * @return string
367
+ */
368
+ public function get_parent_type() {
369
+ return $this->_parent_type;
370
+ }
371
 
372
+ /**
373
+ * @author Vova Feldman (@svovaf)
374
+ * @since 1.1.3
375
+ *
376
+ * @return string
377
+ */
378
+ public function get_raw_slug() {
379
+ return $this->_menu_slug;
380
+ }
 
 
 
 
 
381
 
382
+ /**
383
+ * Get plugin's original menu slug.
384
+ *
385
+ * @author Vova Feldman (@svovaf)
386
+ * @since 1.1.3
387
+ *
388
+ * @return string
389
+ */
390
+ public function get_original_menu_slug() {
391
+ if ( 'cpt' === $this->_type ) {
392
+ return add_query_arg(
393
+ array(
394
+ 'post_type' => $this->_menu_slug,
395
+ ), 'edit.php'
396
+ );
397
  }
398
 
399
+ if ( false === strpos( $this->_menu_slug, '.php?' ) ) {
400
+ return $this->_menu_slug;
401
+ } else {
402
+ return $this->_module_unique_affix;
 
 
 
 
 
 
403
  }
404
+ }
405
 
406
+ /**
407
+ * @author Vova Feldman (@svovaf)
408
+ * @since 1.1.3
409
+ *
410
+ * @return string
411
+ */
412
+ public function get_top_level_menu_slug() {
413
+ return $this->has_custom_parent() ?
414
+ $this->get_parent_slug() :
415
+ $this->get_raw_slug();
416
+ }
417
+
418
+ /**
419
+ * Is user on plugin's admin activation page.
420
+ *
421
+ * @author Vova Feldman (@svovaf)
422
+ * @since 1.0.8
423
+ *
424
+ * @return bool
425
+ */
426
+ public function is_main_settings_page() {
427
+ if ( $this->_menu_exists &&
428
+ ( fs_is_plugin_page( $this->_menu_slug ) || fs_is_plugin_page( $this->_module_unique_affix ) )
429
+ ) {
430
+ /**
431
  * Module has a settings menu and the context page is the main settings page, so assume it's in
432
  * activation (doesn't really check if already opted-in/skipped or not).
433
  *
434
  * @since 1.2.2
435
  */
436
+ return true;
437
+ }
438
 
439
+ global $pagenow;
440
+ if ( ( WP_FS__MODULE_TYPE_THEME === $this->_module_type ) && Freemius::is_themes_page() ) {
441
+ /**
442
  * In activation only when show_optin query string param is given.
443
  *
444
  * @since 1.2.2
445
  */
446
+ return fs_request_get_bool( $this->_module_unique_affix . '_show_optin' );
447
+ }
448
+
449
+ return false;
450
+ }
451
+
452
+ // region Submenu Override
453
+ /**
454
+ * Override submenu's action.
455
+ *
456
+ * @author Vova Feldman (@svovaf)
457
+ * @since 1.1.0
458
+ *
459
+ * @param string $parent_slug
460
+ * @param string $menu_slug
461
+ * @param callable $function
462
+ *
463
+ * @return false|string If submenu exist, will return the hook name.
464
+ */
465
+ public function override_submenu_action( $parent_slug, $menu_slug, $function ) {
466
+ global $submenu;
467
+
468
+ $menu_slug = plugin_basename( $menu_slug );
469
+ $parent_slug = plugin_basename( $parent_slug );
470
+
471
+ if ( ! isset( $submenu[ $parent_slug ] ) ) {
472
+ // Parent menu not exist.
473
+ return false;
474
+ }
475
+
476
+ $found_submenu_item = false;
477
+ foreach ( $submenu[ $parent_slug ] as $submenu_item ) {
478
+ if ( $menu_slug === $submenu_item[2] ) {
479
+ $found_submenu_item = $submenu_item;
480
+ break;
481
  }
482
+ }
483
 
484
+ if ( false === $found_submenu_item ) {
485
+ // Submenu item not found.
486
  return false;
487
  }
488
 
489
+ // Remove current function.
490
+ $hookname = get_plugin_page_hookname( $menu_slug, $parent_slug );
491
+ remove_all_actions( $hookname );
492
 
493
+ // Attach new action.
494
+ add_action( $hookname, $function );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
495
 
496
+ return $hookname;
497
+ }
 
 
 
 
 
498
 
499
+ // endregion Submenu Override
500
+ // region Top level menu Override
501
+ /**
502
+ * Find plugin's admin dashboard main menu item.
503
+ *
504
+ * @author Vova Feldman (@svovaf)
505
+ * @since 1.0.2
506
+ *
507
+ * @return string[]|false
508
+ */
509
+ private function find_top_level_menu() {
510
+ global $menu;
511
 
512
+ $position = - 1;
513
+ $found_menu = false;
 
514
 
515
+ $menu_slug = $this->get_raw_slug();
 
516
 
517
+ $hook_name = get_plugin_page_hookname( $menu_slug, '' );
518
+ foreach ( $menu as $pos => $m ) {
519
+ if ( $menu_slug === $m[2] ) {
520
+ $position = $pos;
521
+ $found_menu = $m;
522
+ break;
523
+ }
524
  }
525
 
526
+ if ( false === $found_menu ) {
527
+ return false;
528
+ }
529
 
530
+ return array(
531
+ 'menu' => $found_menu,
532
+ 'position' => $position,
533
+ 'hook_name' => $hook_name,
534
+ );
535
+ }
536
 
537
+ /**
538
+ * Find plugin's admin dashboard main submenu item.
539
+ *
540
+ * @author Vova Feldman (@svovaf)
541
+ * @since 1.2.1.6
542
+ *
543
+ * @return array|false
544
+ */
545
+ private function find_main_submenu() {
546
+ global $submenu;
547
 
548
+ $top_level_menu_slug = $this->get_top_level_menu_slug();
 
549
 
550
+ if ( ! isset( $submenu[ $top_level_menu_slug ] ) ) {
551
+ return false;
552
+ }
553
 
554
+ $submenu_slug = $this->get_raw_slug();
 
 
 
 
 
 
 
555
 
556
+ $position = - 1;
557
+ $found_submenu = false;
 
558
 
559
+ $hook_name = get_plugin_page_hookname( $submenu_slug, '' );
 
 
 
 
 
560
 
561
+ foreach ( $submenu[ $top_level_menu_slug ] as $pos => $sub ) {
562
+ if ( $submenu_slug === $sub[2] ) {
563
+ $position = $pos;
564
+ $found_submenu = $sub;
 
 
 
 
 
 
 
 
 
 
 
565
  }
566
+ }
567
 
568
+ if ( false === $found_submenu ) {
569
+ return false;
570
+ }
 
571
 
572
+ return array(
573
+ 'menu' => $found_submenu,
574
+ 'parent_slug' => $top_level_menu_slug,
575
+ 'position' => $position,
576
+ 'hook_name' => $hook_name,
577
+ );
578
+ }
579
 
580
+ /**
581
+ * Remove all sub-menu items.
582
+ *
583
+ * @author Vova Feldman (@svovaf)
584
+ * @since 1.0.7
585
+ *
586
+ * @return bool If submenu with plugin's menu slug was found.
587
+ */
588
+ private function remove_all_submenu_items() {
589
+ global $submenu;
590
 
591
+ $menu_slug = $this->get_raw_slug();
 
 
592
 
593
+ if ( ! isset( $submenu[ $menu_slug ] ) ) {
594
+ return false;
 
 
 
 
595
  }
596
 
597
  /**
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
598
  * This method is NOT executed for WordPress.org themes.
599
  * Since we maintain only one version of the SDK we added this small
600
  * hack to avoid the error from Theme Check since it's a false-positive.
602
  * @author Vova Feldman (@svovaf)
603
  * @since 1.2.2.7
604
  */
605
+ $submenu_ref = &$submenu;
606
+ $submenu_ref[ $menu_slug ] = array();
607
 
608
+ return true;
609
+ }
610
+
611
+ /**
612
+ *
613
+ * @author Vova Feldman (@svovaf)
614
+ * @since 1.0.9
615
+ *
616
+ * @param bool $remove_top_level_menu
617
+ *
618
+ * @return false|array[string]mixed
619
+ */
620
+ function remove_menu_item( $remove_top_level_menu = false ) {
621
+ $this->_logger->entrance();
622
+
623
+ // Find main menu item.
624
+ $top_level_menu = $this->find_top_level_menu();
625
+
626
+ if ( false === $top_level_menu ) {
627
+ return false;
628
  }
629
 
630
+ // Remove it with its actions.
631
+ remove_all_actions( $top_level_menu['hook_name'] );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
632
 
633
+ // Remove all submenu items.
634
+ $this->remove_all_submenu_items();
635
+
636
+ if ( $remove_top_level_menu ) {
637
+ global $menu;
638
+ unset( $menu[ $top_level_menu['position'] ] );
639
+ }
 
 
 
 
 
 
 
 
 
 
 
640
 
641
+ return $top_level_menu;
642
+ }
 
643
 
644
+ /**
645
+ * Get module's main admin setting page URL.
646
+ *
647
+ * @todo This method was only tested for wp.org compliant themes with a submenu item. Need to test for plugins with top level, submenu, and CPT top level, menu items.
648
+ *
649
+ * @author Vova Feldman (@svovaf)
650
+ * @since 1.2.2.7
651
+ *
652
+ * @return string
653
+ */
654
+ function main_menu_url() {
655
+ $this->_logger->entrance();
656
+
657
+ if ( $this->_is_top_level ) {
658
+ $menu = $this->find_top_level_menu();
659
+ } else {
660
+ $menu = $this->find_main_submenu();
661
  }
662
 
663
+ $parent_slug = isset( $menu['parent_slug'] ) ?
664
+ $menu['parent_slug'] :
665
+ 'admin.php';
 
 
 
 
 
 
 
 
 
 
 
666
 
667
+ return admin_url( $parent_slug . '?page=' . $menu['menu'][2] );
668
+ }
669
 
670
+ /**
671
+ * @author Vova Feldman (@svovaf)
672
+ * @since 1.1.4
673
+ *
674
+ * @param callable $function
675
+ *
676
+ * @return false|array[string]mixed
677
+ */
678
+ function override_menu_item( $function ) {
679
+ $found_menu = $this->remove_menu_item();
680
 
681
+ if ( false === $found_menu ) {
682
+ return false;
683
+ }
 
684
 
685
+ if ( ! $this->is_top_level() || ! $this->is_cpt() ) {
686
+ $menu_slug = plugin_basename( $this->get_slug() );
687
 
688
+ $hookname = get_plugin_page_hookname( $menu_slug, '' );
689
+
690
+ // Override menu action.
691
+ add_action( $hookname, $function );
692
+ } else {
693
+ global $menu;
694
+
695
+ // Remove original CPT menu.
696
+ unset( $menu[ $found_menu['position'] ] );
 
 
697
 
698
+ // Create new top-level menu action.
699
+ $hookname = self::add_page(
700
+ $found_menu['menu'][3],
701
+ $found_menu['menu'][0],
702
+ 'manage_options',
703
+ $this->get_slug(),
704
+ $function,
705
+ $found_menu['menu'][6],
706
+ $found_menu['position']
707
+ );
708
  }
709
 
710
+ return $hookname;
711
+ }
 
 
 
 
 
 
 
 
 
 
 
712
 
713
+ /**
714
+ * Adds a counter to the module's top level menu item.
715
+ *
716
+ * @author Vova Feldman (@svovaf)
717
+ * @since 1.2.1.5
718
+ *
719
+ * @param int $counter
720
+ * @param string $class
721
+ */
722
+ function add_counter_to_menu_item( $counter = 1, $class = '' ) {
723
+ global $menu, $submenu;
724
+
725
+ $mask = '%s <span class="update-plugins %s count-%3$s" aria-hidden="true"><span>%3$s<span class="screen-reader-text">%3$s notifications</span></span></span>';
726
+
727
+ /**
728
  * This method is NOT executed for WordPress.org themes.
729
  * Since we maintain only one version of the SDK we added this small
730
  * hack to avoid the error from Theme Check since it's a false-positive.
732
  * @author Vova Feldman (@svovaf)
733
  * @since 1.2.2.7
734
  */
735
+ $menu_ref = &$menu;
736
+ $submenu_ref = &$submenu;
737
+
738
+ if ( $this->_is_top_level ) {
739
+ // Find main menu item.
740
+ $found_menu = $this->find_top_level_menu();
741
+
742
+ if ( false !== $found_menu ) {
743
+ // Override menu label.
744
+ $menu_ref[ $found_menu['position'] ][0] = sprintf(
745
+ $mask,
746
+ $found_menu['menu'][0],
747
+ $class,
748
+ $counter
749
+ );
750
+ }
751
+ } else {
752
+ $found_submenu = $this->find_main_submenu();
753
+
754
+ if ( false !== $found_submenu ) {
755
+ // Override menu label.
756
+ $submenu_ref[ $found_submenu['parent_slug'] ][ $found_submenu['position'] ][0] = sprintf(
757
+ $mask,
758
+ $found_submenu['menu'][0],
759
+ $class,
760
+ $counter
761
+ );
 
762
  }
763
  }
764
+ }
765
 
766
+ // endregion Top level menu Override
767
+ /**
768
+ * Add a top-level menu page.
769
+ *
770
+ * Note for WordPress.org Theme/Plugin reviewer:
771
+ *
772
+ * This is a replication of `add_menu_page()` to avoid Theme Check warning.
773
+ *
774
+ * Why?
775
+ * ====
776
+ * Freemius is an SDK for plugin and theme developers. Since the core
777
+ * of the SDK is relevant both for plugins and themes, for obvious reasons,
778
+ * we only develop and maintain one code base.
779
+ *
780
+ * This method will not run for wp.org themes (only plugins) since theme
781
+ * admin settings/options are now only allowed in the customizer.
782
+ *
783
+ * If you have any questions or need clarifications, please don't hesitate
784
+ * pinging me on slack, my username is @svovaf.
785
+ *
786
+ * @author Vova Feldman (@svovaf)
787
+ * @since 1.2.2
788
+ *
789
+ * @param string $page_title The text to be displayed in the title tags of the page when the menu is
790
+ * selected.
791
+ * @param string $menu_title The text to be used for the menu.
792
+ * @param string $capability The capability required for this menu to be displayed to the user.
793
+ * @param string $menu_slug The slug name to refer to this menu by (should be unique for this menu).
794
+ * @param callable|string $function The function to be called to output the content for this page.
795
+ * @param string $icon_url The URL to the icon to be used for this menu.
796
+ * * Pass a base64-encoded SVG using a data URI, which will be colored to
797
+ * match the color scheme. This should begin with
798
+ * 'data:image/svg+xml;base64,'.
799
+ * * Pass the name of a Dashicons helper class to use a font icon,
800
+ * e.g. 'dashicons-chart-pie'.
801
+ * * Pass 'none' to leave div.wp-menu-image empty so an icon can be added
802
+ * via CSS.
803
+ * @param int $position The position in the menu order this one should appear.
804
+ *
805
+ * @return string The resulting page's hook_suffix.
806
+ */
807
+ static function add_page(
808
+ $page_title,
809
+ $menu_title,
810
+ $capability,
811
+ $menu_slug,
812
+ $function = '',
813
+ $icon_url = '',
814
+ $position = null
815
+ ) {
816
+ $fn = 'add_menu' . '_page';
817
+
818
+ return $fn(
819
  $page_title,
820
  $menu_title,
821
  $capability,
822
  $menu_slug,
823
+ $function,
824
+ $icon_url,
825
+ $position
826
+ );
827
+ }
 
 
 
 
 
 
 
 
 
 
 
828
 
829
+ /**
830
+ * Add page and update menu instance settings.
831
+ *
832
+ * @author Vova Feldman (@svovaf)
833
+ * @since 2.0.0
834
+ *
835
+ * @param string $page_title
836
+ * @param string $menu_title
837
+ * @param string $capability
838
+ * @param string $menu_slug
839
+ * @param callable|string $function
840
+ * @param string $icon_url
841
+ * @param int|null $position
842
+ *
843
+ * @return string
844
+ */
845
+ function add_page_and_update(
846
+ $page_title,
847
+ $menu_title,
848
+ $capability,
849
+ $menu_slug,
850
+ $function = '',
851
+ $icon_url = '',
852
+ $position = null
853
+ ) {
854
+ $this->_menu_slug = $menu_slug;
855
+ $this->_is_top_level = true;
856
+ $this->_menu_exists = true;
857
+ $this->_network_menu_exists = true;
858
+
859
+ return self::add_page(
860
+ $page_title,
861
+ $menu_title,
862
+ $capability,
863
+ $menu_slug,
864
+ $function,
865
+ $icon_url,
866
+ $position
867
+ );
868
+ }
869
 
870
+ /**
871
+ * Add a submenu page.
872
+ *
873
+ * Note for WordPress.org Theme/Plugin reviewer:
874
+ *
875
+ * This is a replication of `add_submenu_page()` to avoid Theme Check warning.
876
+ *
877
+ * Why?
878
+ * ====
879
+ * Freemius is an SDK for plugin and theme developers. Since the core
880
+ * of the SDK is relevant both for plugins and themes, for obvious reasons,
881
+ * we only develop and maintain one code base.
882
+ *
883
+ * This method will not run for wp.org themes (only plugins) since theme
884
+ * admin settings/options are now only allowed in the customizer.
885
+ *
886
+ * If you have any questions or need clarifications, please don't hesitate
887
+ * pinging me on slack, my username is @svovaf.
888
+ *
889
+ * @author Vova Feldman (@svovaf)
890
+ * @since 1.2.2
891
+ *
892
+ * @param string $parent_slug The slug name for the parent menu (or the file name of a standard
893
+ * WordPress admin page).
894
+ * @param string $page_title The text to be displayed in the title tags of the page when the menu is
895
+ * selected.
896
+ * @param string $menu_title The text to be used for the menu.
897
+ * @param string $capability The capability required for this menu to be displayed to the user.
898
+ * @param string $menu_slug The slug name to refer to this menu by (should be unique for this menu).
899
+ * @param callable|string $function The function to be called to output the content for this page.
900
+ *
901
+ * @return false|string The resulting page's hook_suffix, or false if the user does not have the capability
902
+ * required.
903
+ */
904
+ static function add_subpage(
905
+ $parent_slug,
906
+ $page_title,
907
+ $menu_title,
908
+ $capability,
909
+ $menu_slug,
910
+ $function = ''
911
+ ) {
912
+ $fn = 'add_submenu' . '_page';
913
+
914
+ return $fn(
915
  $parent_slug,
916
  $page_title,
917
  $menu_title,
918
  $capability,
919
  $menu_slug,
920
+ $function
921
+ );
922
+ }
 
 
 
 
 
 
 
 
 
923
 
924
+ /**
925
+ * Add sub page and update menu instance settings.
926
+ *
927
+ * @author Vova Feldman (@svovaf)
928
+ * @since 2.0.0
929
+ *
930
+ * @param string $parent_slug
931
+ * @param string $page_title
932
+ * @param string $menu_title
933
+ * @param string $capability
934
+ * @param string $menu_slug
935
+ * @param callable|string $function
936
+ *
937
+ * @return string
938
+ */
939
+ function add_subpage_and_update(
940
+ $parent_slug,
941
+ $page_title,
942
+ $menu_title,
943
+ $capability,
944
+ $menu_slug,
945
+ $function = ''
946
+ ) {
947
+ $this->_menu_slug = $menu_slug;
948
+ $this->_parent_slug = $parent_slug;
949
+ $this->_is_top_level = false;
950
+ $this->_menu_exists = true;
951
+ $this->_network_menu_exists = true;
952
+
953
+ return self::add_subpage(
954
+ $parent_slug,
955
+ $page_title,
956
+ $menu_title,
957
+ $capability,
958
+ $menu_slug,
959
+ $function
960
+ );
961
+ }
962
+ }
sdk/freemius/start.php CHANGED
@@ -1,522 +1,522 @@
1
- <?php
2
- /**
3
- * @package Freemius
4
- * @copyright Copyright (c) 2015, Freemius, Inc.
5
- * @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3
6
- * @since 1.0.3
7
- */
8
-
9
- if ( ! defined( 'ABSPATH' ) ) {
10
- exit;
11
- }
12
-
13
- /**
14
- * Freemius SDK Version.
15
- *
16
- * @var string
17
- */
18
- $this_sdk_version = '2.2.3';
19
-
20
- #region SDK Selection Logic --------------------------------------------------------------------
21
-
22
- /**
23
- * Special logic added on 1.1.6 to make sure that every Freemius powered plugin
24
- * will ALWAYS be loaded with the newest SDK from the active Freemius powered plugins.
25
- *
26
- * Since Freemius SDK is backward compatible, this will make sure that all Freemius powered
27
- * plugins will run correctly.
28
- *
29
- * @since 1.1.6
30
- */
31
-
32
- global $fs_active_plugins;
33
-
34
- if ( ! function_exists( 'fs_find_caller_plugin_file' ) ) {
35
- // Require SDK essentials.
36
- require_once dirname( __FILE__ ) . '/includes/fs-essential-functions.php';
37
- }
38
-
39
- /**
40
- * This complex logic fixes symlink issues (e.g. with Vargant). The logic assumes
41
- * that if it's a file from an SDK running in a theme, the location of the SDK
42
- * is in the main theme's folder.
43
- *
44
- * @author Vova Feldman (@svovaf)
45
- * @since 1.2.2.6
46
- */
47
- $file_path = fs_normalize_path( __FILE__ );
48
- $fs_root_path = dirname( $file_path );
49
- /**
50
- * Get the themes directory where the active theme is located (not passing the stylesheet will make WordPress
51
- * assume that the themes directory is inside `wp-content`.
52
- *
53
- * @author Leo Fajardo (@leorw)
54
- * @since 2.2.3
55
- */
56
- $themes_directory = get_theme_root( get_stylesheet() );
57
- $themes_directory_name = basename( $themes_directory );
58
- $theme_candidate_basename = basename( dirname( $fs_root_path ) ) . '/' . basename( $fs_root_path );
59
-
60
- if ( $file_path == fs_normalize_path( realpath( trailingslashit( $themes_directory ) . $theme_candidate_basename . '/' . basename( $file_path ) ) )
61
- ) {
62
- $this_sdk_relative_path = '../' . $themes_directory_name . '/' . $theme_candidate_basename;
63
- $is_theme = true;
64
- } else {
65
- $this_sdk_relative_path = plugin_basename( $fs_root_path );
66
- $is_theme = false;
67
- }
68
-
69
- if ( ! isset( $fs_active_plugins ) ) {
70
- // Load all Freemius powered active plugins.
71
- $fs_active_plugins = get_option( 'fs_active_plugins', new stdClass() );
72
-
73
- if ( ! isset( $fs_active_plugins->plugins ) ) {
74
- $fs_active_plugins->plugins = array();
75
- }
76
- }
77
-
78
- if ( empty( $fs_active_plugins->abspath ) ) {
79
- /**
80
- * Store the WP install absolute path reference to identify environment change
81
- * while replicating the storage.
82
- *
83
- * @author Vova Feldman (@svovaf)
84
- * @since 1.2.1.7
85
- */
86
- $fs_active_plugins->abspath = ABSPATH;
87
- } else {
88
- if ( ABSPATH !== $fs_active_plugins->abspath ) {
89
- /**
90
- * WordPress path has changed, cleanup the SDK references cache.
91
- * This resolves issues triggered when spinning a staging environments
92
- * while replicating the database.
93
- *
94
- * @author Vova Feldman (@svovaf)
95
- * @since 1.2.1.7
96
- */
97
- $fs_active_plugins->abspath = ABSPATH;
98
- $fs_active_plugins->plugins = array();
99
- unset( $fs_active_plugins->newest );
100
- } else {
101
- /**
102
- * Make sure SDK references are still valid. This resolves
103
- * issues when users hard delete modules via FTP.
104
- *
105
- * @author Vova Feldman (@svovaf)
106
- * @since 1.2.1.7
107
- */
108
- $has_changes = false;
109
- foreach ( $fs_active_plugins->plugins as $sdk_path => $data ) {
110
- if ( ! file_exists( ( isset( $data->type ) && 'theme' === $data->type ? $themes_directory : WP_PLUGIN_DIR ) . '/' . $sdk_path ) ) {
111
- unset( $fs_active_plugins->plugins[ $sdk_path ] );
112
- $has_changes = true;
113
- }
114
- }
115
-
116
- if ( $has_changes ) {
117
- if ( empty( $fs_active_plugins->plugins ) ) {
118
- unset( $fs_active_plugins->newest );
119
- }
120
-
121
- update_option( 'fs_active_plugins', $fs_active_plugins );
122
- }
123
- }
124
- }
125
-
126
- if ( ! function_exists( 'fs_find_direct_caller_plugin_file' ) ) {
127
- require_once dirname( __FILE__ ) . '/includes/supplements/fs-essential-functions-1.1.7.1.php';
128
- }
129
-
130
- if ( ! function_exists( 'fs_get_plugins' ) ) {
131
- require_once dirname( __FILE__ ) . '/includes/supplements/fs-essential-functions-2.2.1.php';
132
- }
133
-
134
- // Update current SDK info based on the SDK path.
135
- if ( ! isset( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) ||
136
- $this_sdk_version != $fs_active_plugins->plugins[ $this_sdk_relative_path ]->version
137
- ) {
138
- if ( $is_theme ) {
139
- $plugin_path = basename( dirname( $this_sdk_relative_path ) );
140
- } else {
141
- $plugin_path = plugin_basename( fs_find_direct_caller_plugin_file( $file_path ) );
142
- }
143
-
144
- $fs_active_plugins->plugins[ $this_sdk_relative_path ] = (object) array(
145
- 'version' => $this_sdk_version,
146
- 'type' => ( $is_theme ? 'theme' : 'plugin' ),
147
- 'timestamp' => time(),
148
- 'plugin_path' => $plugin_path,
149
- );
150
- }
151
-
152
- $is_current_sdk_newest = isset( $fs_active_plugins->newest ) && ( $this_sdk_relative_path == $fs_active_plugins->newest->sdk_path );
153
-
154
- if ( ! isset( $fs_active_plugins->newest ) ) {
155
- /**
156
- * This will be executed only once, for the first time a Freemius powered plugin is activated.
157
- */
158
- fs_update_sdk_newest_version( $this_sdk_relative_path, $fs_active_plugins->plugins[ $this_sdk_relative_path ]->plugin_path );
159
-
160
- $is_current_sdk_newest = true;
161
- } else if ( version_compare( $fs_active_plugins->newest->version, $this_sdk_version, '<' ) ) {
162
- /**
163
- * Current SDK is newer than the newest stored SDK.
164
- */
165
- fs_update_sdk_newest_version( $this_sdk_relative_path, $fs_active_plugins->plugins[ $this_sdk_relative_path ]->plugin_path );
166
-
167
- if ( class_exists( 'Freemius' ) ) {
168
- // Older SDK version was already loaded.
169
-
170
- if ( ! $fs_active_plugins->newest->in_activation ) {
171
- // Re-order plugins to load this plugin first.
172
- fs_newest_sdk_plugin_first();
173
- }
174
-
175
- // Refresh page.
176
- fs_redirect( $_SERVER['REQUEST_URI'] );
177
- }
178
- } else {
179
- if ( ! function_exists( 'get_plugins' ) ) {
180
- require_once ABSPATH . 'wp-admin/includes/plugin.php';
181
- }
182
-
183
- $fs_newest_sdk = $fs_active_plugins->newest;
184
- $fs_newest_sdk = $fs_active_plugins->plugins[ $fs_newest_sdk->sdk_path ];
185
-
186
- $is_newest_sdk_type_theme = ( isset( $fs_newest_sdk->type ) && 'theme' === $fs_newest_sdk->type );
187
-
188
- if ( ! $is_newest_sdk_type_theme ) {
189
- $is_newest_sdk_plugin_active = is_plugin_active( $fs_newest_sdk->plugin_path );
190
- } else {
191
- $current_theme = wp_get_theme();
192
- $is_newest_sdk_plugin_active = ( $current_theme->stylesheet === $fs_newest_sdk->plugin_path );
193
-
194
- $current_theme_parent = $current_theme->parent();
195
-
196
- /**
197
- * If the current theme is a child of the theme that has the newest SDK, this prevents a redirects loop
198
- * from happening by keeping the SDK info stored in the `fs_active_plugins` option.
199
- */
200
- if ( ! $is_newest_sdk_plugin_active && $current_theme_parent instanceof WP_Theme ) {
201
- $is_newest_sdk_plugin_active = ( $fs_newest_sdk->plugin_path === $current_theme_parent->stylesheet );
202
- }
203
- }
204
-
205
- if ( $is_current_sdk_newest &&
206
- ! $is_newest_sdk_plugin_active &&
207
- ! $fs_active_plugins->newest->in_activation
208
- ) {
209
- // If current SDK is the newest and the plugin is NOT active, it means
210
- // that the current plugin in activation mode.
211
- $fs_active_plugins->newest->in_activation = true;
212
- update_option( 'fs_active_plugins', $fs_active_plugins );
213
- }
214
-
215
- if ( ! $is_theme ) {
216
- $sdk_starter_path = fs_normalize_path( WP_PLUGIN_DIR . '/' . $this_sdk_relative_path . '/start.php' );
217
- } else {
218
- $sdk_starter_path = fs_normalize_path(
219
- $themes_directory
220
- . '/'
221
- . str_replace( "../{$themes_directory_name}/", '', $this_sdk_relative_path )
222
- . '/start.php' );
223
- }
224
-
225
- $is_newest_sdk_path_valid = ( $is_newest_sdk_plugin_active || $fs_active_plugins->newest->in_activation ) && file_exists( $sdk_starter_path );
226
-
227
- if ( ! $is_newest_sdk_path_valid && ! $is_current_sdk_newest ) {
228
- // Plugin with newest SDK is no longer active, or SDK was moved to a different location.
229
- unset( $fs_active_plugins->plugins[ $fs_active_plugins->newest->sdk_path ] );
230
- }
231
-
232
- if ( ! ( $is_newest_sdk_plugin_active || $fs_active_plugins->newest->in_activation ) ||
233
- ! $is_newest_sdk_path_valid ||
234
- // Is newest SDK downgraded.
235
- ( $this_sdk_relative_path == $fs_active_plugins->newest->sdk_path &&
236
- version_compare( $fs_active_plugins->newest->version, $this_sdk_version, '>' ) )
237
- ) {
238
- /**
239
- * Plugin with newest SDK is no longer active.
240
- * OR
241
- * The newest SDK was in the current plugin. BUT, seems like the version of
242
- * the SDK was downgraded to a lower SDK.
243
- */
244
- // Find the active plugin with the newest SDK version and update the newest reference.
245
- fs_fallback_to_newest_active_sdk();
246
- } else {
247
- if ( $is_newest_sdk_plugin_active &&
248
- $this_sdk_relative_path == $fs_active_plugins->newest->sdk_path &&
249
- ( $fs_active_plugins->newest->in_activation ||
250
- ( class_exists( 'Freemius' ) && ( ! defined( 'WP_FS__SDK_VERSION' ) || version_compare( WP_FS__SDK_VERSION, $this_sdk_version, '<' ) ) )
251
- )
252
-
253
- ) {
254
- if ( $fs_active_plugins->newest->in_activation && ! $is_newest_sdk_type_theme ) {
255
- // Plugin no more in activation.
256
- $fs_active_plugins->newest->in_activation = false;
257
- update_option( 'fs_active_plugins', $fs_active_plugins );
258
- }
259
-
260
- // Reorder plugins to load plugin with newest SDK first.
261
- if ( fs_newest_sdk_plugin_first() ) {
262
- // Refresh page after re-order to make sure activated plugin loads newest SDK.
263
- if ( class_exists( 'Freemius' ) ) {
264
- fs_redirect( $_SERVER['REQUEST_URI'] );
265
- }
266
- }
267
- }
268
- }
269
- }
270
-
271
- if ( class_exists( 'Freemius' ) ) {
272
- // SDK was already loaded.
273
- return;
274
- }
275
-
276
- if ( version_compare( $this_sdk_version, $fs_active_plugins->newest->version, '<' ) ) {
277
- $newest_sdk = $fs_active_plugins->plugins[ $fs_active_plugins->newest->sdk_path ];
278
-
279
- $plugins_or_theme_dir_path = ( ! isset( $newest_sdk->type ) || 'theme' !== $newest_sdk->type ) ?
280
- WP_PLUGIN_DIR :
281
- $themes_directory;
282
-
283
- $newest_sdk_starter = fs_normalize_path(
284
- $plugins_or_theme_dir_path
285
- . '/'
286
- . str_replace( "../{$themes_directory_name}/", '', $fs_active_plugins->newest->sdk_path )
287
- . '/start.php' );
288
-
289
- if ( file_exists( $newest_sdk_starter ) ) {
290
- // Reorder plugins to load plugin with newest SDK first.
291
- fs_newest_sdk_plugin_first();
292
-
293
- // There's a newer SDK version, load it instead of the current one!
294
- require_once $newest_sdk_starter;
295
-
296
- return;
297
- }
298
- }
299
-
300
- #endregion SDK Selection Logic --------------------------------------------------------------------
301
-
302
- #region Hooks & Filters Collection --------------------------------------------------------------------
303
-
304
- /**
305
- * Freemius hooks (actions & filters) tags structure:
306
- *
307
- * fs_{filter/action_name}_{plugin_slug}
308
- *
309
- * --------------------------------------------------------
310
- *
311
- * Usage with WordPress' add_action() / add_filter():
312
- *
313
- * add_action('fs_{filter/action_name}_{plugin_slug}', $callable);
314
- *
315
- * --------------------------------------------------------
316
- *
317
- * Usage with Freemius' instance add_action() / add_filter():
318
- *
319
- * // No need to add 'fs_' prefix nor '_{plugin_slug}' suffix.
320
- * my_freemius()->add_action('{action_name}', $callable);
321
- *
322
- * --------------------------------------------------------
323
- *
324
- * Freemius filters collection:
325
- *
326
- * fs_connect_url_{plugin_slug}
327
- * fs_trial_promotion_message_{plugin_slug}
328
- * fs_is_long_term_user_{plugin_slug}
329
- * fs_uninstall_reasons_{plugin_slug}
330
- * fs_is_plugin_update_{plugin_slug}
331
- * fs_api_domains_{plugin_slug}
332
- * fs_email_template_sections_{plugin_slug}
333
- * fs_support_forum_submenu_{plugin_slug}
334
- * fs_support_forum_url_{plugin_slug}
335
- * fs_connect_message_{plugin_slug}
336
- * fs_connect_message_on_update_{plugin_slug}
337
- * fs_uninstall_confirmation_message_{plugin_slug}
338
- * fs_pending_activation_message_{plugin_slug}
339
- * fs_is_submenu_visible_{plugin_slug}
340
- * fs_plugin_icon_{plugin_slug}
341
- * fs_show_trial_{plugin_slug}
342
- *
343
- * --------------------------------------------------------
344
- *
345
- * Freemius actions collection:
346
- *
347
- * fs_after_license_loaded_{plugin_slug}
348
- * fs_after_license_change_{plugin_slug}
349
- * fs_after_plans_sync_{plugin_slug}
350
- *
351
- * fs_after_account_details_{plugin_slug}
352
- * fs_after_account_user_sync_{plugin_slug}
353
- * fs_after_account_plan_sync_{plugin_slug}
354
- * fs_before_account_load_{plugin_slug}
355
- * fs_after_account_connection_{plugin_slug}
356
- * fs_account_property_edit_{plugin_slug}
357
- * fs_account_email_verified_{plugin_slug}
358
- * fs_account_page_load_before_departure_{plugin_slug}
359
- * fs_before_account_delete_{plugin_slug}
360
- * fs_after_account_delete_{plugin_slug}
361
- *
362
- * fs_sdk_version_update_{plugin_slug}
363
- * fs_plugin_version_update_{plugin_slug}
364
- *
365
- * fs_initiated_{plugin_slug}
366
- * fs_after_init_plugin_registered_{plugin_slug}
367
- * fs_after_init_plugin_anonymous_{plugin_slug}
368
- * fs_after_init_plugin_pending_activations_{plugin_slug}
369
- * fs_after_init_addon_registered_{plugin_slug}
370
- * fs_after_init_addon_anonymous_{plugin_slug}
371
- * fs_after_init_addon_pending_activations_{plugin_slug}
372
- *
373
- * fs_after_premium_version_activation_{plugin_slug}
374
- * fs_after_free_version_reactivation_{plugin_slug}
375
- *
376
- * fs_after_uninstall_{plugin_slug}
377
- * fs_before_admin_menu_init_{plugin_slug}
378
- */
379
-
380
- #endregion Hooks & Filters Collection --------------------------------------------------------------------
381
-
382
- if ( ! class_exists( 'Freemius' ) ) {
383
-
384
- if ( ! defined( 'WP_FS__SDK_VERSION' ) ) {
385
- define( 'WP_FS__SDK_VERSION', $this_sdk_version );
386
- }
387
-
388
- $plugins_or_theme_dir_path = fs_normalize_path( trailingslashit( $is_theme ?
389
- $themes_directory :
390
- WP_PLUGIN_DIR ) );
391
-
392
- if ( 0 === strpos( $file_path, $plugins_or_theme_dir_path ) ) {
393
- // No symlinks
394
- } else {
395
- /**
396
- * This logic finds the SDK symlink and set WP_FS__DIR to use it.
397
- *
398
- * @author Vova Feldman (@svovaf)
399
- * @since 1.2.2.5
400
- */
401
- $sdk_symlink = null;
402
-
403
- // Try to load SDK's symlink from cache.
404
- if ( isset( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) &&
405
- is_object( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) &&
406
- ! empty( $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink )
407
- ) {
408
- $sdk_symlink = $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink;
409
- if ( 0 === strpos( $sdk_symlink, $plugins_or_theme_dir_path ) ) {
410
- /**
411
- * Make the symlink path relative.
412
- *
413
- * @author Leo Fajardo (@leorw)
414
- */
415
- $sdk_symlink = substr( $sdk_symlink, strlen( $plugins_or_theme_dir_path ) );
416
-
417
- $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink = $sdk_symlink;
418
- update_option( 'fs_active_plugins', $fs_active_plugins );
419
- }
420
-
421
- $realpath = realpath( $plugins_or_theme_dir_path . $sdk_symlink );
422
- if ( ! is_string( $realpath ) || ! file_exists( $realpath ) ) {
423
- $sdk_symlink = null;
424
- }
425
- }
426
-
427
- if ( empty( $sdk_symlink ) ) // Has symlinks, therefore, we need to configure WP_FS__DIR based on the symlink.
428
- {
429
- $partial_path_right = basename( $file_path );
430
- $partial_path_left = dirname( $file_path );
431
- $realpath = realpath( $plugins_or_theme_dir_path . $partial_path_right );
432
-
433
- while ( '/' !== $partial_path_left &&
434
- ( false === $realpath || $file_path !== fs_normalize_path( $realpath ) )
435
- ) {
436
- $partial_path_right = trailingslashit( basename( $partial_path_left ) ) . $partial_path_right;
437
- $partial_path_left_prev = $partial_path_left;
438
- $partial_path_left = dirname( $partial_path_left_prev );
439
-
440
- /**
441
- * Avoid infinite loop if for example `$partial_path_left_prev` is `C:/`, in this case,
442
- * `dirname( 'C:/' )` will return `C:/`.
443
- *
444
- * @author Leo Fajardo (@leorw)
445
- */
446
- if ( $partial_path_left === $partial_path_left_prev ) {
447
- $partial_path_left = '';
448
- break;
449
- }
450
-
451
- $realpath = realpath( $plugins_or_theme_dir_path . $partial_path_right );
452
- }
453
-
454
- if ( ! empty( $partial_path_left ) && '/' !== $partial_path_left ) {
455
- $sdk_symlink = fs_normalize_path( dirname( $partial_path_right ) );
456
-
457
- // Cache value.
458
- if ( isset( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) &&
459
- is_object( $fs_active_plugins->plugins[ $this_sdk_relative_path ] )
460
- ) {
461
- $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink = $sdk_symlink;
462
- update_option( 'fs_active_plugins', $fs_active_plugins );
463
- }
464
- }
465
- }
466
-
467
- if ( ! empty( $sdk_symlink ) ) {
468
- // Set SDK dir to the symlink path.
469
- define( 'WP_FS__DIR', $plugins_or_theme_dir_path . $sdk_symlink );
470
- }
471
- }
472
-
473
- // Load SDK files.
474
- require_once dirname( __FILE__ ) . '/require.php';
475
-
476
- /**
477
- * Quick shortcut to get Freemius for specified plugin.
478
- * Used by various templates.
479
- *
480
- * @param number $module_id
481
- *
482
- * @return Freemius
483
- */
484
- function freemius( $module_id ) {
485
- return Freemius::instance( $module_id );
486
- }
487
-
488
- /**
489
- * @param string $slug
490
- * @param number $plugin_id
491
- * @param string $public_key
492
- * @param bool $is_live Is live or test plugin.
493
- * @param bool $is_premium Hints freemius if running the premium plugin or not.
494
- *
495
- * @return Freemius
496
- *
497
- * @deprecated Please use fs_dynamic_init().
498
- */
499
- function fs_init( $slug, $plugin_id, $public_key, $is_live = true, $is_premium = true ) {
500
- $fs = Freemius::instance( $plugin_id, $slug, true );
501
- $fs->init( $plugin_id, $public_key, $is_live, $is_premium );
502
-
503
- return $fs;
504
- }
505
-
506
- /**
507
- * @param array <string,string> $module Plugin or Theme details.
508
- *
509
- * @return Freemius
510
- * @throws Freemius_Exception
511
- */
512
- function fs_dynamic_init( $module ) {
513
- $fs = Freemius::instance( $module['id'], $module['slug'], true );
514
- $fs->dynamic_init( $module );
515
-
516
- return $fs;
517
- }
518
-
519
- function fs_dump_log() {
520
- FS_Logger::dump();
521
- }
522
- }
1
+ <?php
2
+ /**
3
+ * @package Freemius
4
+ * @copyright Copyright (c) 2015, Freemius, Inc.
5
+ * @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3
6
+ * @since 1.0.3
7
+ */
8
+
9
+ if ( ! defined( 'ABSPATH' ) ) {
10
+ exit;
11
+ }
12
+
13
+ /**
14
+ * Freemius SDK Version.
15
+ *
16
+ * @var string
17
+ */
18
+ $this_sdk_version = '2.2.4';
19
+
20
+ // region SDK Selection Logic --------------------------------------------------------------------
21
+ /**
22
+ * Special logic added on 1.1.6 to make sure that every Freemius powered plugin
23
+ * will ALWAYS be loaded with the newest SDK from the active Freemius powered plugins.
24
+ *
25
+ * Since Freemius SDK is backward compatible, this will make sure that all Freemius powered
26
+ * plugins will run correctly.
27
+ *
28
+ * @since 1.1.6
29
+ */
30
+
31
+ global $fs_active_plugins;
32
+
33
+ if ( ! function_exists( 'fs_find_caller_plugin_file' ) ) {
34
+ // Require SDK essentials.
35
+ require_once dirname( __FILE__ ) . '/includes/fs-essential-functions.php';
36
+ }
37
+
38
+ /**
39
+ * This complex logic fixes symlink issues (e.g. with Vargant). The logic assumes
40
+ * that if it's a file from an SDK running in a theme, the location of the SDK
41
+ * is in the main theme's folder.
42
+ *
43
+ * @author Vova Feldman (@svovaf)
44
+ * @since 1.2.2.6
45
+ */
46
+ $file_path = fs_normalize_path( __FILE__ );
47
+ $fs_root_path = dirname( $file_path );
48
+ /**
49
+ * Get the themes directory where the active theme is located (not passing the stylesheet will make WordPress
50
+ * assume that the themes directory is inside `wp-content`.
51
+ *
52
+ * @author Leo Fajardo (@leorw)
53
+ * @since 2.2.3
54
+ */
55
+ $themes_directory = get_theme_root( get_stylesheet() );
56
+ $themes_directory_name = basename( $themes_directory );
57
+ $theme_candidate_basename = basename( dirname( $fs_root_path ) ) . '/' . basename( $fs_root_path );
58
+
59
+ if ( $file_path == fs_normalize_path( realpath( trailingslashit( $themes_directory ) . $theme_candidate_basename . '/' . basename( $file_path ) ) )
60
+ ) {
61
+ $this_sdk_relative_path = '../' . $themes_directory_name . '/' . $theme_candidate_basename;
62
+ $is_theme = true;
63
+ } else {
64
+ $this_sdk_relative_path = plugin_basename( $fs_root_path );
65
+ $is_theme = false;
66
+ }
67
+
68
+ if ( ! isset( $fs_active_plugins ) ) {
69
+ // Load all Freemius powered active plugins.
70
+ $fs_active_plugins = get_option( 'fs_active_plugins', new stdClass() );
71
+
72
+ if ( ! isset( $fs_active_plugins->plugins ) ) {
73
+ $fs_active_plugins->plugins = array();
74
+ }
75
+ }
76
+
77
+ if ( empty( $fs_active_plugins->abspath ) ) {
78
+ /**
79
+ * Store the WP install absolute path reference to identify environment change
80
+ * while replicating the storage.
81
+ *
82
+ * @author Vova Feldman (@svovaf)
83
+ * @since 1.2.1.7
84
+ */
85
+ $fs_active_plugins->abspath = ABSPATH;
86
+ } else {
87
+ if ( ABSPATH !== $fs_active_plugins->abspath ) {
88
+ /**
89
+ * WordPress path has changed, cleanup the SDK references cache.
90
+ * This resolves issues triggered when spinning a staging environments
91
+ * while replicating the database.
92
+ *
93
+ * @author Vova Feldman (@svovaf)
94
+ * @since 1.2.1.7
95
+ */
96
+ $fs_active_plugins->abspath = ABSPATH;
97
+ $fs_active_plugins->plugins = array();
98
+ unset( $fs_active_plugins->newest );
99
+ } else {
100
+ /**
101
+ * Make sure SDK references are still valid. This resolves
102
+ * issues when users hard delete modules via FTP.
103
+ *
104
+ * @author Vova Feldman (@svovaf)
105
+ * @since 1.2.1.7
106
+ */
107
+ $has_changes = false;
108
+ foreach ( $fs_active_plugins->plugins as $sdk_path => $data ) {
109
+ if ( ! file_exists( ( isset( $data->type ) && 'theme' === $data->type ? $themes_directory : WP_PLUGIN_DIR ) . '/' . $sdk_path ) ) {
110
+ unset( $fs_active_plugins->plugins[ $sdk_path ] );
111
+ $has_changes = true;
112
+ }
113
+ }
114
+
115
+ if ( $has_changes ) {
116
+ if ( empty( $fs_active_plugins->plugins ) ) {
117
+ unset( $fs_active_plugins->newest );
118
+ }
119
+
120
+ update_option( 'fs_active_plugins', $fs_active_plugins );
121
+ }
122
+ }
123
+ }
124
+
125
+ if ( ! function_exists( 'fs_find_direct_caller_plugin_file' ) ) {
126
+ require_once dirname( __FILE__ ) . '/includes/supplements/fs-essential-functions-1.1.7.1.php';
127
+ }
128
+
129
+ if ( ! function_exists( 'fs_get_plugins' ) ) {
130
+ require_once dirname( __FILE__ ) . '/includes/supplements/fs-essential-functions-2.2.1.php';
131
+ }
132
+
133
+ // Update current SDK info based on the SDK path.
134
+ if ( ! isset( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) ||
135
+ $this_sdk_version != $fs_active_plugins->plugins[ $this_sdk_relative_path ]->version
136
+ ) {
137
+ if ( $is_theme ) {
138
+ $plugin_path = basename( dirname( $this_sdk_relative_path ) );
139
+ } else {
140
+ $plugin_path = plugin_basename( fs_find_direct_caller_plugin_file( $file_path ) );
141
+ }
142
+
143
+ $fs_active_plugins->plugins[ $this_sdk_relative_path ] = (object) array(
144
+ 'version' => $this_sdk_version,
145
+ 'type' => ( $is_theme ? 'theme' : 'plugin' ),
146
+ 'timestamp' => time(),
147
+ 'plugin_path' => $plugin_path,
148
+ );
149
+ }
150
+
151
+ $is_current_sdk_newest = isset( $fs_active_plugins->newest ) && ( $this_sdk_relative_path == $fs_active_plugins->newest->sdk_path );
152
+
153
+ if ( ! isset( $fs_active_plugins->newest ) ) {
154
+ /**
155
+ * This will be executed only once, for the first time a Freemius powered plugin is activated.
156
+ */
157
+ fs_update_sdk_newest_version( $this_sdk_relative_path, $fs_active_plugins->plugins[ $this_sdk_relative_path ]->plugin_path );
158
+
159
+ $is_current_sdk_newest = true;
160
+ } elseif ( version_compare( $fs_active_plugins->newest->version, $this_sdk_version, '<' ) ) {
161
+ /**
162
+ * Current SDK is newer than the newest stored SDK.
163
+ */
164
+ fs_update_sdk_newest_version( $this_sdk_relative_path, $fs_active_plugins->plugins[ $this_sdk_relative_path ]->plugin_path );
165
+
166
+ if ( class_exists( 'Freemius' ) ) {
167
+ // Older SDK version was already loaded.
168
+ if ( ! $fs_active_plugins->newest->in_activation ) {
169
+ // Re-order plugins to load this plugin first.
170
+ fs_newest_sdk_plugin_first();
171
+ }
172
+
173
+ // Refresh page.
174
+ fs_redirect( $_SERVER['REQUEST_URI'] );
175
+ }
176
+ } else {
177
+ if ( ! function_exists( 'get_plugins' ) ) {
178
+ require_once ABSPATH . 'wp-admin/includes/plugin.php';
179
+ }
180
+
181
+ $fs_newest_sdk = $fs_active_plugins->newest;
182
+ $fs_newest_sdk = $fs_active_plugins->plugins[ $fs_newest_sdk->sdk_path ];
183
+
184
+ $is_newest_sdk_type_theme = ( isset( $fs_newest_sdk->type ) && 'theme' === $fs_newest_sdk->type );
185
+
186
+ if ( ! $is_newest_sdk_type_theme ) {
187
+ $is_newest_sdk_plugin_active = is_plugin_active( $fs_newest_sdk->plugin_path );
188
+ } else {
189
+ $current_theme = wp_get_theme();
190
+ $is_newest_sdk_plugin_active = ( $current_theme->stylesheet === $fs_newest_sdk->plugin_path );
191
+
192
+ $current_theme_parent = $current_theme->parent();
193
+
194
+ /**
195
+ * If the current theme is a child of the theme that has the newest SDK, this prevents a redirects loop
196
+ * from happening by keeping the SDK info stored in the `fs_active_plugins` option.
197
+ */
198
+ if ( ! $is_newest_sdk_plugin_active && $current_theme_parent instanceof WP_Theme ) {
199
+ $is_newest_sdk_plugin_active = ( $fs_newest_sdk->plugin_path === $current_theme_parent->stylesheet );
200
+ }
201
+ }
202
+
203
+ if ( $is_current_sdk_newest &&
204
+ ! $is_newest_sdk_plugin_active &&
205
+ ! $fs_active_plugins->newest->in_activation
206
+ ) {
207
+ // If current SDK is the newest and the plugin is NOT active, it means
208
+ // that the current plugin in activation mode.
209
+ $fs_active_plugins->newest->in_activation = true;
210
+ update_option( 'fs_active_plugins', $fs_active_plugins );
211
+ }
212
+
213
+ if ( ! $is_theme ) {
214
+ $sdk_starter_path = fs_normalize_path( WP_PLUGIN_DIR . '/' . $this_sdk_relative_path . '/start.php' );
215
+ } else {
216
+ $sdk_starter_path = fs_normalize_path(
217
+ $themes_directory
218
+ . '/'
219
+ . str_replace( "../{$themes_directory_name}/", '', $this_sdk_relative_path )
220
+ . '/start.php'
221
+ );
222
+ }
223
+
224
+ $is_newest_sdk_path_valid = ( $is_newest_sdk_plugin_active || $fs_active_plugins->newest->in_activation ) && file_exists( $sdk_starter_path );
225
+
226
+ if ( ! $is_newest_sdk_path_valid && ! $is_current_sdk_newest ) {
227
+ // Plugin with newest SDK is no longer active, or SDK was moved to a different location.
228
+ unset( $fs_active_plugins->plugins[ $fs_active_plugins->newest->sdk_path ] );
229
+ }
230
+
231
+ if ( ! ( $is_newest_sdk_plugin_active || $fs_active_plugins->newest->in_activation ) ||
232
+ ! $is_newest_sdk_path_valid ||
233
+ // Is newest SDK downgraded.
234
+ ( $this_sdk_relative_path == $fs_active_plugins->newest->sdk_path &&
235
+ version_compare( $fs_active_plugins->newest->version, $this_sdk_version, '>' ) )
236
+ ) {
237
+ /**
238
+ * Plugin with newest SDK is no longer active.
239
+ * OR
240
+ * The newest SDK was in the current plugin. BUT, seems like the version of
241
+ * the SDK was downgraded to a lower SDK.
242
+ */
243
+ // Find the active plugin with the newest SDK version and update the newest reference.
244
+ fs_fallback_to_newest_active_sdk();
245
+ } else {
246
+ if ( $is_newest_sdk_plugin_active &&
247
+ $this_sdk_relative_path == $fs_active_plugins->newest->sdk_path &&
248
+ ( $fs_active_plugins->newest->in_activation ||
249
+ ( class_exists( 'Freemius' ) && ( ! defined( 'WP_FS__SDK_VERSION' ) || version_compare( WP_FS__SDK_VERSION, $this_sdk_version, '<' ) ) )
250
+ )
251
+
252
+ ) {
253
+ if ( $fs_active_plugins->newest->in_activation && ! $is_newest_sdk_type_theme ) {
254
+ // Plugin no more in activation.
255
+ $fs_active_plugins->newest->in_activation = false;
256
+ update_option( 'fs_active_plugins', $fs_active_plugins );
257
+ }
258
+
259
+ // Reorder plugins to load plugin with newest SDK first.
260
+ if ( fs_newest_sdk_plugin_first() ) {
261
+ // Refresh page after re-order to make sure activated plugin loads newest SDK.
262
+ if ( class_exists( 'Freemius' ) ) {
263
+ fs_redirect( $_SERVER['REQUEST_URI'] );
264
+ }
265
+ }
266
+ }
267
+ }
268
+ }
269
+
270
+ if ( class_exists( 'Freemius' ) ) {
271
+ // SDK was already loaded.
272
+ return;
273
+ }
274
+
275
+ if ( version_compare( $this_sdk_version, $fs_active_plugins->newest->version, '<' ) ) {
276
+ $newest_sdk = $fs_active_plugins->plugins[ $fs_active_plugins->newest->sdk_path ];
277
+
278
+ $plugins_or_theme_dir_path = ( ! isset( $newest_sdk->type ) || 'theme' !== $newest_sdk->type ) ?
279
+ WP_PLUGIN_DIR :
280
+ $themes_directory;
281
+
282
+ $newest_sdk_starter = fs_normalize_path(
283
+ $plugins_or_theme_dir_path
284
+ . '/'
285
+ . str_replace( "../{$themes_directory_name}/", '', $fs_active_plugins->newest->sdk_path )
286
+ . '/start.php'
287
+ );
288
+
289
+ if ( file_exists( $newest_sdk_starter ) ) {
290
+ // Reorder plugins to load plugin with newest SDK first.
291
+ fs_newest_sdk_plugin_first();
292
+
293
+ // There's a newer SDK version, load it instead of the current one!
294
+ require_once $newest_sdk_starter;
295
+
296
+ return;
297
+ }
298
+ }
299
+
300
+ // endregion SDK Selection Logic --------------------------------------------------------------------
301
+ // region Hooks & Filters Collection --------------------------------------------------------------------
302
+ /**
303
+ * Freemius hooks (actions & filters) tags structure:
304
+ *
305
+ * fs_{filter/action_name}_{plugin_slug}
306
+ *
307
+ * --------------------------------------------------------
308
+ *
309
+ * Usage with WordPress' add_action() / add_filter():
310
+ *
311
+ * add_action('fs_{filter/action_name}_{plugin_slug}', $callable);
312
+ *
313
+ * --------------------------------------------------------
314
+ *
315
+ * Usage with Freemius' instance add_action() / add_filter():
316
+ *
317
+ * // No need to add 'fs_' prefix nor '_{plugin_slug}' suffix.
318
+ * my_freemius()->add_action('{action_name}', $callable);
319
+ *
320
+ * --------------------------------------------------------
321
+ *
322
+ * Freemius filters collection:
323
+ *
324
+ * fs_connect_url_{plugin_slug}
325
+ * fs_trial_promotion_message_{plugin_slug}
326
+ * fs_is_long_term_user_{plugin_slug}
327
+ * fs_uninstall_reasons_{plugin_slug}
328
+ * fs_is_plugin_update_{plugin_slug}
329
+ * fs_api_domains_{plugin_slug}
330
+ * fs_email_template_sections_{plugin_slug}
331
+ * fs_support_forum_submenu_{plugin_slug}
332
+ * fs_support_forum_url_{plugin_slug}
333
+ * fs_connect_message_{plugin_slug}
334
+ * fs_connect_message_on_update_{plugin_slug}
335
+ * fs_uninstall_confirmation_message_{plugin_slug}
336
+ * fs_pending_activation_message_{plugin_slug}
337
+ * fs_is_submenu_visible_{plugin_slug}
338
+ * fs_plugin_icon_{plugin_slug}
339
+ * fs_show_trial_{plugin_slug}
340
+ *
341
+ * --------------------------------------------------------
342
+ *
343
+ * Freemius actions collection:
344
+ *
345
+ * fs_after_license_loaded_{plugin_slug}
346
+ * fs_after_license_change_{plugin_slug}
347
+ * fs_after_plans_sync_{plugin_slug}
348
+ *
349
+ * fs_after_account_details_{plugin_slug}
350
+ * fs_after_account_user_sync_{plugin_slug}
351
+ * fs_after_account_plan_sync_{plugin_slug}
352
+ * fs_before_account_load_{plugin_slug}
353
+ * fs_after_account_connection_{plugin_slug}
354
+ * fs_account_property_edit_{plugin_slug}
355
+ * fs_account_email_verified_{plugin_slug}
356
+ * fs_account_page_load_before_departure_{plugin_slug}
357
+ * fs_before_account_delete_{plugin_slug}
358
+ * fs_after_account_delete_{plugin_slug}
359
+ *
360
+ * fs_sdk_version_update_{plugin_slug}
361
+ * fs_plugin_version_update_{plugin_slug}
362
+ *
363
+ * fs_initiated_{plugin_slug}
364
+ * fs_after_init_plugin_registered_{plugin_slug}
365
+ * fs_after_init_plugin_anonymous_{plugin_slug}
366
+ * fs_after_init_plugin_pending_activations_{plugin_slug}
367
+ * fs_after_init_addon_registered_{plugin_slug}
368
+ * fs_after_init_addon_anonymous_{plugin_slug}
369
+ * fs_after_init_addon_pending_activations_{plugin_slug}
370
+ *
371
+ * fs_after_premium_version_activation_{plugin_slug}
372
+ * fs_after_free_version_reactivation_{plugin_slug}
373
+ *
374
+ * fs_after_uninstall_{plugin_slug}
375
+ * fs_before_admin_menu_init_{plugin_slug}
376
+ */
377
+
378
+ // endregion Hooks & Filters Collection --------------------------------------------------------------------
379
+ if ( ! class_exists( 'Freemius' ) ) {
380
+
381
+ if ( ! defined( 'WP_FS__SDK_VERSION' ) ) {
382
+ define( 'WP_FS__SDK_VERSION', $this_sdk_version );
383
+ }
384
+
385
+ $plugins_or_theme_dir_path = fs_normalize_path(
386
+ trailingslashit(
387
+ $is_theme ?
388
+ $themes_directory :
389
+ WP_PLUGIN_DIR
390
+ )
391
+ );
392
+
393
+ if ( 0 === strpos( $file_path, $plugins_or_theme_dir_path ) ) {
394
+ // No symlinks
395
+ } else {
396
+ /**
397
+ * This logic finds the SDK symlink and set WP_FS__DIR to use it.
398
+ *
399
+ * @author Vova Feldman (@svovaf)
400
+ * @since 1.2.2.5
401
+ */
402
+ $sdk_symlink = null;
403
+
404
+ // Try to load SDK's symlink from cache.
405
+ if ( isset( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) &&
406
+ is_object( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) &&
407
+ ! empty( $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink )
408
+ ) {
409
+ $sdk_symlink = $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink;
410
+ if ( 0 === strpos( $sdk_symlink, $plugins_or_theme_dir_path ) ) {
411
+ /**
412
+ * Make the symlink path relative.
413
+ *
414
+ * @author Leo Fajardo (@leorw)
415
+ */
416
+ $sdk_symlink = substr( $sdk_symlink, strlen( $plugins_or_theme_dir_path ) );
417
+
418
+ $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink = $sdk_symlink;
419
+ update_option( 'fs_active_plugins', $fs_active_plugins );
420
+ }
421
+
422
+ $realpath = realpath( $plugins_or_theme_dir_path . $sdk_symlink );
423
+ if ( ! is_string( $realpath ) || ! file_exists( $realpath ) ) {
424
+ $sdk_symlink = null;
425
+ }
426
+ }
427
+
428
+ if ( empty( $sdk_symlink ) ) {
429
+ $partial_path_right = basename( $file_path );
430
+ $partial_path_left = dirname( $file_path );
431
+ $realpath = realpath( $plugins_or_theme_dir_path . $partial_path_right );
432
+
433
+ while ( '/' !== $partial_path_left &&
434
+ ( false === $realpath || $file_path !== fs_normalize_path( $realpath ) )
435
+ ) {
436
+ $partial_path_right = trailingslashit( basename( $partial_path_left ) ) . $partial_path_right;
437
+ $partial_path_left_prev = $partial_path_left;
438
+ $partial_path_left = dirname( $partial_path_left_prev );
439
+
440
+ /**
441
+ * Avoid infinite loop if for example `$partial_path_left_prev` is `C:/`, in this case,
442
+ * `dirname( 'C:/' )` will return `C:/`.
443
+ *
444
+ * @author Leo Fajardo (@leorw)
445
+ */
446
+ if ( $partial_path_left === $partial_path_left_prev ) {
447
+ $partial_path_left = '';
448
+ break;
449
+ }
450
+
451
+ $realpath = realpath( $plugins_or_theme_dir_path . $partial_path_right );
452
+ }
453
+
454
+ if ( ! empty( $partial_path_left ) && '/' !== $partial_path_left ) {
455
+ $sdk_symlink = fs_normalize_path( dirname( $partial_path_right ) );
456
+
457
+ // Cache value.
458
+ if ( isset( $fs_active_plugins->plugins[ $this_sdk_relative_path ] ) &&
459
+ is_object( $fs_active_plugins->plugins[ $this_sdk_relative_path ] )
460
+ ) {
461
+ $fs_active_plugins->plugins[ $this_sdk_relative_path ]->sdk_symlink = $sdk_symlink;
462
+ update_option( 'fs_active_plugins', $fs_active_plugins );
463
+ }
464
+ }
465
+ }
466
+
467
+ if ( ! empty( $sdk_symlink ) ) {
468
+ // Set SDK dir to the symlink path.
469
+ define( 'WP_FS__DIR', $plugins_or_theme_dir_path . $sdk_symlink );
470
+ }
471
+ }
472
+
473
+ // Load SDK files.
474
+ require_once dirname( __FILE__ ) . '/require.php';
475
+
476
+ /**
477
+ * Quick shortcut to get Freemius for specified plugin.
478
+ * Used by various templates.
479
+ *
480
+ * @param number $module_id
481
+ *
482
+ * @return Freemius
483
+ */
484
+ function freemius( $module_id ) {
485
+ return Freemius::instance( $module_id );
486
+ }
487
+
488
+ /**
489
+ * @param string $slug
490
+ * @param number $plugin_id
491
+ * @param string $public_key
492
+ * @param bool $is_live Is live or test plugin.
493
+ * @param bool $is_premium Hints freemius if running the premium plugin or not.
494
+ *
495
+ * @return Freemius
496
+ *
497
+ * @deprecated Please use fs_dynamic_init().
498
+ */
499
+ function fs_init( $slug, $plugin_id, $public_key, $is_live = true, $is_premium = true ) {
500
+ $fs = Freemius::instance( $plugin_id, $slug, true );
501
+ $fs->init( $plugin_id, $public_key, $is_live, $is_premium );
502
+
503
+ return $fs;
504
+ }
505
+
506
+ /**
507
+ * @param array <string,string> $module Plugin or Theme details.
508
+ *
509
+ * @return Freemius
510
+ * @throws Freemius_Exception
511
+ */
512
+ function fs_dynamic_init( $module ) {
513
+ $fs = Freemius::instance( $module['id'], $module['slug'], true );
514
+ $fs->dynamic_init( $module );
515
+
516
+ return $fs;
517
+ }
518
+
519
+ function fs_dump_log() {
520
+ FS_Logger::dump();
521
+ }
522
+ }
sdk/freemius/templates/connect.php CHANGED
@@ -1,932 +1,964 @@
1
- <?php
2
- /**
3
- * @package Freemius
4
- * @copyright Copyright (c) 2015, Freemius, Inc.
5
- * @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3
6
- * @since 1.0.7
7
- */
8
-
9
- if ( ! defined( 'ABSPATH' ) ) {
10
- exit;
11
- }
12
-
13
- /**
14
- * @var array $VARS
15
- * @var Freemius $fs
16
- */
17
- $fs = freemius( $VARS['id'] );
18
- $slug = $fs->get_slug();
19
-
20
- $is_pending_activation = $fs->is_pending_activation();
21
- $is_premium_only = $fs->is_only_premium();
22
- $has_paid_plans = $fs->has_paid_plan();
23
- $is_premium_code = $fs->is_premium();
24
- $is_freemium = $fs->is_freemium();
25
-
26
- $fs->_enqueue_connect_essentials();
27
-
28
- $current_user = Freemius::_get_current_wp_user();
29
-
30
- $first_name = $current_user->user_firstname;
31
- if ( empty( $first_name ) ) {
32
- $first_name = $current_user->nickname;
33
- }
34
-
35
- $site_url = get_site_url();
36
- $protocol_pos = strpos( $site_url, '://' );
37
- if ( false !== $protocol_pos ) {
38
- $site_url = substr( $site_url, $protocol_pos + 3 );
39
- }
40
-
41
- $freemius_site_www = 'https://freemius.com';
42
-
43
- $freemius_usage_tracking_url = $freemius_site_www . '/wordpress/usage-tracking/' . $fs->get_id() . "/{$slug}/";
44
- $freemius_plugin_terms_url = $freemius_site_www . '/terms/' . $fs->get_id() . "/{$slug}/";
45
-
46
- $freemius_site_url = $fs->is_premium() ?
47
- $freemius_site_www :
48
- $freemius_usage_tracking_url;
49
-
50
- if ( $fs->is_premium() ) {
51
- $freemius_site_url .= '?' . http_build_query( array(
52
- 'id' => $fs->get_id(),
53
- 'slug' => $slug,
54
- ) );
55
- }
56
-
57
- $freemius_link = '<a href="' . $freemius_site_url . '" target="_blank" tabindex="1">freemius.com</a>';
58
-
59
- $error = fs_request_get( 'error' );
60
-
61
- $require_license_key = $is_premium_only ||
62
- ( $is_freemium && $is_premium_code && fs_request_get_bool( 'require_license', true ) );
63
-
64
- if ( $is_pending_activation ) {
65
- $require_license_key = false;
66
- }
67
-
68
- if ( $require_license_key ) {
69
- $fs->_add_license_activation_dialog_box();
70
- }
71
-
72
- $is_optin_dialog = (
73
- $fs->is_theme() &&
74
- $fs->is_themes_page() &&
75
- ( ! $fs->has_settings_menu() || $fs->is_free_wp_org_theme() )
76
- );
77
-
78
- if ( $is_optin_dialog ) {
79
- $show_close_button = false;
80
- $previous_theme_activation_url = '';
81
-
82
- if ( ! $is_premium_code ) {
83
- $show_close_button = true;
84
- } else if ( $is_premium_only ) {
85
- $previous_theme_activation_url = $fs->get_previous_theme_activation_url();
86
- $show_close_button = ( ! empty( $previous_theme_activation_url ) );
87
- }
88
- }
89
-
90
- $is_network_level_activation = (
91
- fs_is_network_admin() &&
92
- $fs->is_network_active() &&
93
- ! $fs->is_network_delegated_connection()
94
- );
95
-
96
- $fs_user = Freemius::_get_user_by_email( $current_user->user_email );
97
-
98
- $activate_with_current_user = (
99
- is_object( $fs_user ) &&
100
- ! $is_pending_activation &&
101
- // If requires a license for activation, use the user associated with the license for the opt-in.
102
- ! $require_license_key &&
103
- ! $is_network_level_activation
104
- );
105
-
106
- $optin_params = $fs->get_opt_in_params( array(), $is_network_level_activation );
107
- $sites = isset( $optin_params['sites'] ) ? $optin_params['sites'] : array();
108
-
109
- $is_network_upgrade_mode = ( fs_is_network_admin() && $fs->is_network_upgrade_mode() );
110
-
111
- /* translators: %s: name (e.g. Hey John,) */
112
- $hey_x_text = esc_html( sprintf( fs_text_x_inline( 'Hey %s,', 'greeting', 'hey-x', $slug ), $first_name ) );
113
-
114
- $is_gdpr_required = ( ! $is_pending_activation && ! $require_license_key ) ?
115
- FS_GDPR_Manager::instance()->is_required() :
116
- false;
117
-
118
- if ( is_null( $is_gdpr_required ) ) {
119
- $is_gdpr_required = $fs->fetch_and_store_current_user_gdpr_anonymously();
120
- }
121
- ?>
122
- <?php
123
- if ( $is_optin_dialog ) { ?>
124
- <div id="fs_theme_connect_wrapper">
125
- <?php
126
- if ( $show_close_button ) { ?>
127
- <button class="close dashicons dashicons-no"><span class="screen-reader-text">Close connect dialog</span>
128
- </button>
129
- <?php
130
- }
131
- ?>
132
- <?php
133
- }
134
- ?>
135
- <div id="fs_connect"
136
- class="wrap<?php if ( ! fs_is_network_admin() && ( ! $fs->is_enable_anonymous() || $is_pending_activation || $require_license_key ) ) {
137
- echo ' fs-anonymous-disabled';
138
- } ?><?php echo $require_license_key ? ' require-license-key' : '' ?>">
139
- <div class="fs-visual">
140
- <b class="fs-site-icon"><i class="dashicons dashicons-wordpress"></i></b>
141
- <i class="dashicons dashicons-plus fs-first"></i>
142
- <?php
143
- $vars = array( 'id' => $fs->get_id() );
144
- fs_require_once_template( 'plugin-icon.php', $vars );
145
- ?>
146
- <i class="dashicons dashicons-plus fs-second"></i>
147
- <img class="fs-connect-logo" width="80" height="80" src="//img.freemius.com/connect-logo.png"/>
148
- </div>
149
- <div class="fs-content">
150
- <?php if ( ! empty( $error ) ) : ?>
151
- <p class="fs-error"><?php echo esc_html( $error ) ?></p>
152
- <?php endif ?>
153
- <p><?php
154
- $button_label = fs_text_inline( 'Allow & Continue', 'opt-in-connect', $slug );
155
- $message = '';
156
-
157
- if ( $is_pending_activation ) {
158
- $button_label = fs_text_inline( 'Re-send activation email', 'resend-activation-email', $slug );
159
-
160
- $message = $fs->apply_filters( 'pending_activation_message', sprintf(
161
- /* translators: %s: name (e.g. Thanks John!) */
162
- fs_text_inline( 'Thanks %s!', 'thanks-x', $slug ) . '<br>' .
163
- fs_text_inline( 'You should receive an activation email for %s to your mailbox at %s. Please make sure you click the activation button in that email to %s.', 'pending-activation-message', $slug ),
164
- $first_name,
165
- '<b>' . $fs->get_plugin_name() . '</b>',
166
- '<b>' . $current_user->user_email . '</b>',
167
- fs_text_inline( 'complete the install', 'complete-the-install', $slug )
168
- ) );
169
- } else if ( $require_license_key ) {
170
- $button_label = $is_network_upgrade_mode ?
171
- fs_text_inline( 'Activate License', 'agree-activate-license', $slug ) :
172
- fs_text_inline( 'Agree & Activate License', 'agree-activate-license', $slug );
173
-
174
- $message = $fs->apply_filters(
175
- 'connect-message_on-premium',
176
- ($is_network_upgrade_mode ?
177
- '' :
178
- /* translators: %s: name (e.g. Hey John,) */
179
- $hey_x_text . '<br>'
180
- ) .
181
- sprintf( fs_text_inline( 'Thanks for purchasing %s! To get started, please enter your license key:', 'thanks-for-purchasing', $slug ), '<b>' . $fs->get_plugin_name() . '</b>' ),
182
- $first_name,
183
- $fs->get_plugin_name()
184
- );
185
- } else {
186
- $filter = 'connect_message';
187
- $default_optin_message = $is_gdpr_required ?
188
- fs_text_inline( 'Never miss an important update - opt in to our security & feature updates notifications, educational content, offers, and non-sensitive diagnostic tracking with %4$s.', 'connect-message', $slug) :
189
- fs_text_inline( 'Never miss an important update - opt in to our security and feature updates notifications, and non-sensitive diagnostic tracking with %4$s.', 'connect-message', $slug);
190
-
191
- if ( $fs->is_plugin_update() ) {
192
- // If Freemius was added on a plugin update, set different
193
- // opt-in message.
194
- $default_optin_message = $is_gdpr_required ?
195
- fs_text_inline( 'Never miss an important update - opt in to our security & feature updates notifications, educational content, offers, and non-sensitive diagnostic tracking with %4$s. If you skip this, that\'s okay! %1$s will still work just fine.', 'connect-message_on-update', $slug ) :
196
- fs_text_inline( 'Never miss an important update - opt in to our security & feature updates notifications, and non-sensitive diagnostic tracking with %4$s. If you skip this, that\'s okay! %1$s will still work just fine.', 'connect-message_on-update', $slug );
197
-
198
- // If user customized the opt-in message on update, use
199
- // that message. Otherwise, fallback to regular opt-in
200
- // custom message if exist.
201
- if ( $fs->has_filter( 'connect_message_on_update' ) ) {
202
- $filter = 'connect_message_on_update';
203
- }
204
- }
205
-
206
- $message = $fs->apply_filters(
207
- $filter,
208
- ($is_network_upgrade_mode ?
209
- '' :
210
- /* translators: %s: name (e.g. Hey John,) */
211
- $hey_x_text . '<br>'
212
- ) .
213
- sprintf(
214
- esc_html( $default_optin_message ),
215
- '<b>' . esc_html( $fs->get_plugin_name() ) . '</b>',
216
- '<b>' . $current_user->user_login . '</b>',
217
- '<a href="' . $site_url . '" target="_blank">' . $site_url . '</a>',
218
- $freemius_link
219
- ),
220
- $first_name,
221
- $fs->get_plugin_name(),
222
- $current_user->user_login,
223
- '<a href="' . $site_url . '" target="_blank">' . $site_url . '</a>',
224
- $freemius_link,
225
- $is_gdpr_required
226
- );
227
- }
228
-
229
- if ( $is_network_upgrade_mode ) {
230
- $network_integration_text = esc_html( fs_text_inline( 'We\'re excited to introduce the Freemius network-level integration.', 'connect_message_network_upgrade', $slug ) );
231
-
232
- if ($is_premium_code){
233
- $message = $network_integration_text . ' ' . sprintf( fs_text_inline( 'During the update process we detected %d site(s) that are still pending license activation.', 'connect_message_network_upgrade-premium', $slug ), count( $sites ) );
234
-
235
- $message .= '<br><br>' . sprintf( fs_text_inline( 'If you\'d like to use the %s on those sites, please enter your license key below and click the activation button.', 'connect_message_network_upgrade-premium-activate-license', $slug ), $is_premium_only ? $fs->get_module_label( true ) : sprintf(
236
- /* translators: %s: module type (plugin, theme, or add-on) */
237
- fs_text_inline( "%s's paid features", 'x-paid-features', $slug ),
238
- $fs->get_module_label( true )
239
- ) );
240
-
241
- /* translators: %s: module type (plugin, theme, or add-on) */
242
- $message .= ' ' . sprintf( fs_text_inline( 'Alternatively, you can skip it for now and activate the license later, in your %s\'s network-level Account page.', 'connect_message_network_upgrade-premium-skip-license', $slug ), $fs->get_module_label( true ) );
243
- }else {
244
- $message = $network_integration_text . ' ' . sprintf( fs_text_inline( 'During the update process we detected %s site(s) in the network that are still pending your attention.', 'connect_message_network_upgrade-free', $slug ), count( $sites ) ) . '<br><br>' . ( fs_starts_with( $message, $hey_x_text . '<br>' ) ? substr( $message, strlen( $hey_x_text . '<br>' ) ) : $message );
245
- }
246
- }
247
-
248
- echo $message;
249
- ?></p>
250
- <?php if ( $require_license_key ) : ?>
251
- <div class="fs-license-key-container">
252
- <input id="fs_license_key" name="fs_key" type="text" required maxlength="<?php echo $fs->apply_filters('license_key_maxlength', 32) ?>"
253
- placeholder="<?php fs_esc_attr_echo_inline( 'License key', 'license-key', $slug ) ?>" tabindex="1"/>
254
- <i class="dashicons dashicons-admin-network"></i>
255
- <a class="show-license-resend-modal show-license-resend-modal-<?php echo $fs->get_unique_affix() ?>"
256
- href="#"><?php fs_esc_html_echo_inline( "Can't find your license key?", 'cant-find-license-key', $slug ); ?></a>
257
- </div>
258
-
259
- <?php
260
- /**
261
- * Allows developers to include custom HTML after the license input container.
262
- *
263
- * @author Vova Feldman
264
- * @since 2.1.2
265
- */
266
- $fs->do_action( 'connect/after_license_input' );
267
  ?>
268
-
269
- <?php
270
- $send_updates_text = sprintf(
271
- '%s<span class="action-description"> - %s</span>',
272
- $fs->get_text_inline( 'Yes', 'yes' ),
273
- $fs->get_text_inline( 'send me security & feature updates, educational content and offers.', 'send-updates' )
274
- );
275
-
276
- $do_not_send_updates_text = sprintf(
277
- '%s<span class="action-description"> - %s</span>',
278
- $fs->get_text_inline( 'No', 'no' ),
279
- sprintf(
280
- $fs->get_text_inline( 'do %sNOT%s send me security & feature updates, educational content and offers.', 'do-not-send-updates' ),
281
- '<span class="underlined">',
282
- '</span>'
283
- )
284
- );
285
- ?>
286
- <div id="fs_marketing_optin">
287
- <span class="fs-message"><?php fs_echo_inline( "Please let us know if you'd like us to contact you for security & feature updates, educational content, and occasional offers:", 'contact-for-updates' ) ?></span>
288
- <div class="fs-input-container">
289
- <label>
290
- <input type="radio" name="allow-marketing" value="true" tabindex="1" />
291
- <span class="fs-input-label"><?php echo $send_updates_text ?></span>
292
- </label>
293
- <label>
294
- <input type="radio" name="allow-marketing" value="false" tabindex="1" />
295
- <span class="fs-input-label"><?php echo $do_not_send_updates_text ?></span>
296
- </label>
297
- </div>
298
- </div>
299
- <?php endif ?>
300
- <?php if ( $is_network_level_activation ) : ?>
301
- <?php
302
- $vars = array(
303
- 'id' => $fs->get_id(),
304
- 'sites' => $sites,
305
- 'require_license_key' => $require_license_key
306
- );
307
-
308
- echo fs_get_template( 'partials/network-activation.php', $vars );
309
- ?>
310
- <?php endif ?>
311
- </div>
312
- <div class="fs-actions">
313
- <?php if ( $fs->is_enable_anonymous() && ! $is_pending_activation && ( ! $require_license_key || $is_network_upgrade_mode ) ) : ?>
314
- <a id="skip_activation" href="<?php echo fs_nonce_url( $fs->_get_admin_page_url( '', array( 'fs_action' => $fs->get_unique_affix() . '_skip_activation' ), $is_network_level_activation ), $fs->get_unique_affix() . '_skip_activation' ) ?>"
315
- class="button button-secondary" tabindex="2"><?php fs_esc_html_echo_x_inline( 'Skip', 'verb', 'skip', $slug ) ?></a>
316
- <?php endif ?>
317
- <?php if ( $is_network_level_activation ) : ?>
318
- <a id="delegate_to_site_admins" class="fs-tooltip-trigger <?php echo is_rtl() ? ' rtl' : '' ?>" href="<?php echo fs_nonce_url( $fs->_get_admin_page_url( '', array( 'fs_action' => $fs->get_unique_affix() . '_delegate_activation' ) ), $fs->get_unique_affix() . '_delegate_activation' ) ?>"><?php fs_esc_html_echo_inline( 'Delegate to Site Admins', 'delegate-to-site-admins', $slug ) ?><span class="fs-tooltip"><?php fs_esc_html_echo_inline( 'If you click it, this decision will be delegated to the sites administrators.', 'delegate-sites-tooltip', $slug ) ?></span></a>
319
- <?php endif ?>
320
- <?php if ( $activate_with_current_user ) : ?>
321
- <form action="" method="POST">
322
- <input type="hidden" name="fs_action"
323
- value="<?php echo $fs->get_unique_affix() ?>_activate_existing">
324
- <?php wp_nonce_field( 'activate_existing_' . $fs->get_public_key() ) ?>
325
- <button class="button button-primary" tabindex="1"
326
- type="submit"><?php echo esc_html( $button_label ) ?></button>
327
- </form>
328
- <?php else : ?>
329
- <form method="post" action="<?php echo WP_FS__ADDRESS ?>/action/service/user/install/">
330
- <?php unset( $optin_params['sites']); ?>
331
- <?php foreach ( $optin_params as $name => $value ) : ?>
332
- <input type="hidden" name="<?php echo $name ?>" value="<?php echo esc_attr( $value ) ?>">
333
- <?php endforeach ?>
334
- <button class="button button-primary" tabindex="1"
335
- type="submit"<?php if ( $require_license_key ) {
336
- echo ' disabled="disabled"';
337
- } ?>><?php echo esc_html( $button_label ) ?></button>
338
- </form>
339
- <?php endif ?>
340
- </div><?php
341
-
342
- // Set core permission list items.
343
- $permissions = array(
344
- 'profile' => array(
345
- 'icon-class' => 'dashicons dashicons-admin-users',
346
- 'label' => $fs->get_text_inline( 'Your Profile Overview', 'permissions-profile' ),
347
- 'desc' => $fs->get_text_inline( 'Name and email address', 'permissions-profile_desc' ),
348
- 'priority' => 5,
349
- ),
350
- 'site' => array(
351
- 'icon-class' => 'dashicons dashicons-admin-settings',
352
- 'label' => $fs->get_text_inline( 'Your Site Overview', 'permissions-site' ),
353
- 'desc' => $fs->get_text_inline( 'Site URL, WP version, PHP info, plugins & themes', 'permissions-site_desc' ),
354
- 'priority' => 10,
355
- ),
356
- 'notices' => array(
357
- 'icon-class' => 'dashicons dashicons-testimonial',
358
- 'label' => $fs->get_text_inline( 'Admin Notices', 'permissions-admin-notices' ),
359
- 'desc' => $fs->get_text_inline( 'Updates, announcements, marketing, no spam', 'permissions-newsletter_desc' ),
360
- 'priority' => 13,
361
- ),
362
- 'events' => array(
363
- 'icon-class' => 'dashicons dashicons-admin-plugins',
364
- 'label' => sprintf( $fs->get_text_inline( 'Current %s Events', 'permissions-events' ), ucfirst( $fs->get_module_type() ) ),
365
- 'desc' => $fs->get_text_inline( 'Activation, deactivation and uninstall', 'permissions-events_desc' ),
366
- 'priority' => 20,
367
- ),
368
- );
369
-
370
- // Add newsletter permissions if enabled.
371
- if ( $is_gdpr_required || $fs->is_permission_requested( 'newsletter' ) ) {
372
- $permissions['newsletter'] = array(
373
- 'icon-class' => 'dashicons dashicons-email-alt',
374
- 'label' => $fs->get_text_inline( 'Newsletter', 'permissions-newsletter' ),
375
- 'desc' => $fs->get_text_inline( 'Updates, announcements, marketing, no spam', 'permissions-newsletter_desc' ),
376
- 'priority' => 15,
377
- );
378
- }
379
-
380
- // Allow filtering of the permissions list.
381
- $permissions = $fs->apply_filters( 'permission_list', $permissions );
382
-
383
- // Sort by priority.
384
- uasort( $permissions, 'fs_sort_by_priority' );
385
-
386
- if ( ! empty( $permissions ) ) : ?>
387
- <div class="fs-permissions">
388
- <?php if ( $require_license_key ) : ?>
389
- <p class="fs-license-sync-disclaimer"><?php
390
- echo sprintf(
391
- fs_esc_html_inline( 'The %1$s will be periodically sending data to %2$s to check for security and feature updates, and verify the validity of your license.', 'license-sync-disclaimer', $slug ),
392
- $fs->get_module_label( true ),
393
- $freemius_link
394
- ) ?></p>
395
- <?php endif ?>
396
- <a class="fs-trigger" href="#" tabindex="1"><?php fs_esc_html_echo_inline( 'What permissions are being granted?', 'what-permissions', $slug ) ?></a>
397
- <ul><?php
398
- foreach ( $permissions as $id => $permission ) : ?>
399
- <li id="fs-permission-<?php echo esc_attr( $id ); ?>"
400
- class="fs-permission fs-<?php echo esc_attr( $id ); ?>">
401
- <i class="<?php echo esc_attr( $permission['icon-class'] ); ?>"></i>
402
-
403
- <div>
404
- <span><?php echo esc_html( $permission['label'] ); ?></span>
405
-
406
- <p><?php echo esc_html( $permission['desc'] ); ?></p>
407
- </div>
408
- </li>
409
- <?php endforeach; ?>
410
- </ul>
411
  </div>
412
- <?php endif ?>
413
- <?php if ( $is_premium_code && $is_freemium ) : ?>
414
- <div class="fs-freemium-licensing">
415
- <p>
416
- <?php if ( $require_license_key ) : ?>
417
- <?php fs_esc_html_echo_inline( 'Don\'t have a license key?', 'dont-have-license-key', $slug ) ?>
418
- <a data-require-license="false" tabindex="1"><?php fs_esc_html_echo_inline( 'Activate Free Version', 'activate-free-version', $slug ) ?></a>
419
- <?php else : ?>
420
- <?php fs_echo_inline( 'Have a license key?', 'have-license-key', $slug ) ?>
421
- <a data-require-license="true" tabindex="1"><?php fs_esc_html_echo_inline( 'Activate License', 'activate-license', $slug ) ?></a>
422
- <?php endif ?>
423
- </p>
424
- </div>
425
- <?php endif ?>
426
- <div class="fs-terms">
427
- <a href="https://freemius.com/privacy/" target="_blank"
428
- tabindex="1"><?php fs_esc_html_echo_inline( 'Privacy Policy', 'privacy-policy', $slug ) ?></a>
429
- &nbsp;&nbsp;-&nbsp;&nbsp;
430
- <a href="<?php echo $require_license_key ? $freemius_plugin_terms_url : $freemius_usage_tracking_url ?>" target="_blank" tabindex="1"><?php $require_license_key ? fs_echo_inline( 'License Agreement', 'license-agreement', $slug ) : fs_echo_inline( 'Terms of Service', 'tos', $slug ) ?></a>
431
- </div>
432
- </div>
433
- <?php
434
- if ( $is_optin_dialog ) { ?>
435
- </div>
436
- <?php
437
- }
438
- ?>
439
- <script type="text/javascript">
440
- (function ($) {
441
- var $html = $('html');
442
-
443
- <?php
444
- if ( $is_optin_dialog ) {
445
- if ( $show_close_button ) { ?>
446
- var $themeConnectWrapper = $('#fs_theme_connect_wrapper');
447
-
448
- $themeConnectWrapper.find('button.close').on('click', function () {
449
- <?php if ( ! empty( $previous_theme_activation_url ) ) { ?>
450
- location.href = '<?php echo html_entity_decode( $previous_theme_activation_url ); ?>';
451
- <?php } else { ?>
452
- $themeConnectWrapper.remove();
453
- $html.css({overflow: $html.attr('fs-optin-overflow')});
454
- <?php } ?>
455
- });
456
- <?php
457
- }
458
- ?>
459
-
460
- $html.attr('fs-optin-overflow', $html.css('overflow'));
461
- $html.css({overflow: 'hidden'});
462
-
463
- <?php
464
- }
465
- ?>
466
-
467
- var $primaryCta = $('.fs-actions .button.button-primary'),
468
- primaryCtaLabel = $primaryCta.html(),
469
- $form = $('.fs-actions form'),
470
- isNetworkActive = <?php echo $is_network_level_activation ? 'true' : 'false' ?>,
471
- requireLicenseKey = <?php echo $require_license_key ? 'true' : 'false' ?>,
472
- hasContextUser = <?php echo $activate_with_current_user ? 'true' : 'false' ?>,
473
- isNetworkUpgradeMode = <?php echo $is_network_upgrade_mode ? 'true' : 'false' ?>,
474
- $licenseSecret,
475
- $licenseKeyInput = $('#fs_license_key'),
476
- pauseCtaLabelUpdate = false,
477
- /**
478
- * @author Leo Fajardo (@leorw)
479
- * @since 2.1.0
480
- */
481
- resetLoadingMode = function() {
482
- // Reset loading mode.
483
- $primaryCta.html(primaryCtaLabel);
484
- $primaryCta.prop('disabled', false);
485
- $(document.body).css({'cursor': 'auto'});
486
- $('.fs-loading').removeClass('fs-loading');
487
-
488
- console.log('resetLoadingMode - Primary button was enabled');
489
- },
490
- setLoadingMode = function () {
491
- $(document.body).css({'cursor': 'wait'});
492
- };
493
-
494
- $('.fs-actions .button').on('click', function () {
495
- setLoadingMode();
496
-
497
- var $this = $(this);
498
-
499
- setTimeout(function () {
500
- if ( ! requireLicenseKey || ! $marketingOptin.hasClass( 'error' ) ) {
501
- $this.attr('disabled', 'disabled');
502
- }
503
- }, 200);
504
- });
505
-
506
- if ( isNetworkActive ) {
507
- var
508
- $multisiteOptionsContainer = $( '#multisite_options_container' ),
509
- $allSitesOptions = $( '#all_sites_options' ),
510
- $applyOnAllSites = $( '#apply_on_all_sites' ),
511
- $sitesListContainer = $( '#sites_list_container' ),
512
- totalSites = <?php echo count( $sites ) ?>,
513
- maxSitesListHeight = null,
514
- $skipActivationButton = $( '#skip_activation' ),
515
- $delegateToSiteAdminsButton = $( '#delegate_to_site_admins' );
516
-
517
- $applyOnAllSites.click(function() {
518
- var isChecked = $( this ).is( ':checked' );
519
-
520
- if ( isChecked ) {
521
- $multisiteOptionsContainer.find( '.action' ).removeClass( 'selected' );
522
- updatePrimaryCtaText( 'allow' );
523
- }
524
-
525
- $multisiteOptionsContainer.find( '.action-allow' ).addClass( 'selected' );
526
-
527
- $skipActivationButton.toggle();
528
-
529
- $delegateToSiteAdminsButton.toggle();
530
-
531
- $multisiteOptionsContainer.toggleClass( 'apply-on-all-sites', isChecked );
532
-
533
- $sitesListContainer.toggle( ! isChecked );
534
- if ( ! isChecked && null === maxSitesListHeight ) {
535
- /**
536
- * Set the visible number of rows to 5 (5 * height of the first row).
537
- *
538
- * @author Leo Fajardo (@leorw)
539
- */
540
- maxSitesListHeight = ( 5 * $sitesListContainer.find( 'tr:first' ).height() );
541
- $sitesListContainer.css( 'max-height', maxSitesListHeight );
542
- }
543
- });
544
-
545
- $allSitesOptions.find( '.action' ).click(function( evt ) {
546
- var actionType = $( evt.target ).data( 'action-type' );
547
-
548
- $multisiteOptionsContainer.find( '.action' ).removeClass( 'selected' );
549
- $multisiteOptionsContainer.find( '.action-' + actionType ).toggleClass( 'selected' );
550
-
551
- updatePrimaryCtaText( actionType );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
552
  });
553
-
554
- $sitesListContainer.delegate( '.action', 'click', function( evt ) {
555
- var $this = $( evt.target );
556
- if ( $this.hasClass( 'selected' ) ) {
557
- return false;
558
- }
559
-
560
- $this.parents( 'tr:first' ).find( '.action' ).removeClass( 'selected' );
561
- $this.toggleClass( 'selected' );
562
-
563
- var
564
- singleSiteActionType = $this.data( 'action-type' ),
565
- totalSelected = $sitesListContainer.find( '.action-' + singleSiteActionType + '.selected' ).length;
566
-
567
- $allSitesOptions.find( '.action.selected' ).removeClass( 'selected' );
568
-
569
- if ( totalSelected === totalSites ) {
570
- $allSitesOptions.find( '.action-' + singleSiteActionType ).addClass( 'selected' );
571
-
572
- updatePrimaryCtaText( singleSiteActionType );
573
- } else {
574
- updatePrimaryCtaText( 'mixed' );
575
- }
576
- });
577
-
578
- if (isNetworkUpgradeMode) {
579
- $skipActivationButton.click(function(){
580
- $delegateToSiteAdminsButton.hide();
581
-
582
- $skipActivationButton.html('<?php fs_esc_js_echo_inline( 'Skipping, please wait', 'skipping-wait', $slug ) ?>...');
583
-
584
- pauseCtaLabelUpdate = true;
585
-
586
- // Check all sites to be skipped.
587
- $allSitesOptions.find('.action.action-skip').click();
588
-
589
- $form.submit();
590
-
591
- pauseCtaLabelUpdate = false;
592
-
593
- return false;
594
- });
595
-
596
- $delegateToSiteAdminsButton.click(function(){
597
- $delegateToSiteAdminsButton.html('<?php fs_esc_js_echo_inline( 'Delegating, please wait', 'delegating-wait', $slug ) ?>...');
598
-
599
- pauseCtaLabelUpdate = true;
600
-
601
- // Check all sites to be skipped.
602
- $allSitesOptions.find('.action.action-delegate').click();
603
-
604
- $form.submit();
605
-
606
- pauseCtaLabelUpdate = false;
607
-
608
- return false;
609
- });
610
- }
611
- }
612
-
613
- /**
614
- * @author Leo Fajardo (@leorw)
615
- */
616
- function updatePrimaryCtaText( actionType ) {
617
- if (pauseCtaLabelUpdate)
618
- return;
619
-
620
- var text = '<?php fs_esc_js_echo_inline( 'Continue', 'continue', $slug ) ?>';
621
-
622
- switch ( actionType ) {
623
- case 'allow':
624
- text = '<?php fs_esc_js_echo_inline( 'Allow & Continue', 'opt-in-connect', $slug ) ?>';
625
- break;
626
- case 'delegate':
627
- text = '<?php fs_esc_js_echo_inline( 'Delegate to Site Admins & Continue', 'delegate-to-site-admins-and-continue', $slug ) ?>';
628
- break;
629
- case 'skip':
630
- text = '<?php fs_esc_js_echo_x_inline( 'Skip', 'verb', 'skip', $slug ) ?>';
631
- break;
632
- }
633
-
634
- $primaryCta.html( text );
635
- }
636
-
637
- var ajaxOptin = ( requireLicenseKey || isNetworkActive );
638
-
639
- $form.on('submit', function () {
640
  /**
641
- * @author Vova Feldman (@svovaf)
642
- * @since 1.1.9
643
  */
644
- if ( ajaxOptin ) {
645
- if (!hasContextUser || isNetworkUpgradeMode) {
646
- <?php $action = $require_license_key ? 'activate_license' : 'network_activate' ?>
647
-
648
- $('.fs-error').remove();
649
-
650
- var
651
- licenseKey = $licenseKeyInput.val(),
652
- data = {
653
- action : '<?php echo $fs->get_ajax_action( $action ) ?>',
654
- security : '<?php echo $fs->get_ajax_security( $action ) ?>',
655
- license_key: licenseKey,
656
- module_id : '<?php echo $fs->get_id() ?>'
657
- };
658
-
659
- if (requireLicenseKey &&
660
- isMarketingAllowedByLicense.hasOwnProperty(licenseKey)
661
- ) {
662
- var
663
- isMarketingAllowed = null,
664
- $isMarketingAllowed = $marketingOptin.find( 'input[type="radio"][name="allow-marketing"]:checked');
665
-
666
-
667
- if ($isMarketingAllowed.length > 0)
668
- isMarketingAllowed = ('true' == $isMarketingAllowed.val());
669
-
670
- if ( null == isMarketingAllowedByLicense[ licenseKey ] &&
671
- null == isMarketingAllowed
672
- ) {
673
- $marketingOptin.addClass( 'error' ).show();
674
- resetLoadingMode();
675
- return false;
676
- } else if ( null == isMarketingAllowed ) {
677
- isMarketingAllowed = isMarketingAllowedByLicense[ licenseKey ];
678
- }
679
-
680
- data.is_marketing_allowed = isMarketingAllowed;
681
- }
682
-
683
- $marketingOptin.removeClass( 'error' );
684
-
685
- if ( isNetworkActive ) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
686
  var
687
- sites = [],
688
- applyOnAllSites = $applyOnAllSites.is( ':checked' );
689
-
690
- $sitesListContainer.find( 'tr' ).each(function() {
691
- var
692
- $this = $( this ),
693
- includeSite = ( ! requireLicenseKey || applyOnAllSites || $this.find( 'input' ).is( ':checked' ) );
694
-
695
- if ( ! includeSite )
696
- return;
697
-
698
- var site = {
699
- uid : $this.find( '.uid' ).val(),
700
- url : $this.find( '.url' ).val(),
701
- title : $this.find( '.title' ).val(),
702
- language: $this.find( '.language' ).val(),
703
- charset : $this.find( '.charset' ).val(),
704
- blog_id : $this.find( '.blog-id' ).find( 'span' ).text()
705
- };
706
-
707
- if ( ! requireLicenseKey) {
708
- site.action = $this.find('.action.selected').data('action-type');
709
- }
710
-
711
- sites.push( site );
712
- });
713
-
714
- data.sites = sites;
715
- }
716
-
717
- /**
718
- * Use the AJAX opt-in when license key is required to potentially
719
- * process the after install failure hook.
720
- *
721
- * @author Vova Feldman (@svovaf)
722
- * @since 1.2.1.5
723
- */
724
- $.ajax({
725
- url : ajaxurl,
726
- method : 'POST',
727
- data : data,
728
- success: function (result) {
729
- var resultObj = $.parseJSON(result);
730
- if (resultObj.success) {
731
- // Redirect to the "Account" page and sync the license.
732
- window.location.href = resultObj.next_page;
733
- } else {
734
- resetLoadingMode();
735
-
736
- // Show error.
737
- $('.fs-content').prepend('<p class="fs-error">' + (resultObj.error.message ? resultObj.error.message : resultObj.error) + '</p>');
738
- }
739
- },
740
- error: function () {
741
  resetLoadingMode();
 
 
 
742
  }
743
- });
744
-
745
- return false;
746
- }
747
- else {
748
- if (null == $licenseSecret) {
749
- $licenseSecret = $('<input type="hidden" name="license_secret_key" value="" />');
750
- $form.append($licenseSecret);
751
  }
752
-
753
- // Update secret key if premium only plugin.
754
- $licenseSecret.val($licenseKeyInput.val());
755
- }
756
- }
757
-
758
- return true;
759
- });
760
-
761
- $primaryCta.on('click', function () {
762
- console.log('Primary button was clicked');
763
-
764
- $(this).addClass('fs-loading');
765
- $(this).html('<?php echo esc_js( $is_pending_activation ?
766
- fs_text_x_inline( 'Sending email', 'as in the process of sending an email', 'sending-email', $slug ) :
767
- fs_text_x_inline( 'Activating', 'as activating plugin', 'activating', $slug )
768
- ) ?>...');
769
- });
770
-
771
- $('.fs-permissions .fs-trigger').on('click', function () {
772
- $('.fs-permissions').toggleClass('fs-open');
773
-
774
- return false;
775
- });
776
-
777
- if (requireLicenseKey) {
778
- /**
779
- * Submit license key on enter.
780
- *
781
- * @author Vova Feldman (@svovaf)
782
- * @since 1.1.9
783
- */
784
- $licenseKeyInput.keypress(function (e) {
785
- if (e.which == 13) {
786
- if ('' !== $(this).val()) {
787
- $primaryCta.click();
788
- return false;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
789
  }
790
- }
791
- });
792
-
793
- /**
794
- * Disable activation button when empty license key.
795
- *
796
- * @author Vova Feldman (@svovaf)
797
- * @since 1.1.9
798
- */
799
- $licenseKeyInput.on('keyup paste delete cut', function () {
800
- setTimeout(function () {
801
- var key = $licenseKeyInput.val();
802
-
803
- if (key == previousLicenseKey){
804
- return;
805
- }
806
-
807
- if ('' === key) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
808
  $primaryCta.attr('disabled', 'disabled');
809
- $marketingOptin.hide();
810
- } else {
811
- $primaryCta.prop('disabled', false);
812
-
813
- if (32 <= key.length){
814
- fetchIsMarketingAllowedFlagAndToggleOptin();
815
- } else {
816
- $marketingOptin.hide();
817
- }
818
- }
819
-
820
- previousLicenseKey = key;
821
- }, 100);
822
- }).focus();
823
- }
824
-
825
- /**
826
- * Set license mode trigger URL.
827
- *
828
- * @author Vova Feldman (@svovaf)
829
- * @since 1.1.9
830
- */
831
- var
832
- $connectLicenseModeTrigger = $('#fs_connect .fs-freemium-licensing a'),
833
- href = window.location.href;
834
-
835
- if (href.indexOf('?') > 0) {
836
- href += '&';
837
- } else {
838
- href += '?';
839
- }
840
-
841
- if ($connectLicenseModeTrigger.length > 0) {
842
- $connectLicenseModeTrigger.attr(
843
- 'href',
844
- href + 'require_license=' + $connectLicenseModeTrigger.attr('data-require-license')
845
- );
846
- }
847
-
848
- //--------------------------------------------------------------------------------
849
- //region GDPR
850
- //--------------------------------------------------------------------------------
851
- var isMarketingAllowedByLicense = {},
852
- $marketingOptin = $('#fs_marketing_optin'),
853
- previousLicenseKey = null;
854
-
855
- if (requireLicenseKey) {
856
-
857
- var
858
- afterMarketingFlagLoaded = function () {
859
- var licenseKey = $licenseKeyInput.val();
860
-
861
- if (null == isMarketingAllowedByLicense[licenseKey]) {
862
- $marketingOptin.show();
863
-
864
- if ($marketingOptin.find('input[type=radio]:checked').length > 0){
865
- // Focus on button if GDPR opt-in already selected is already selected.
866
- $primaryCta.focus();
867
- } else {
868
- // Focus on the GDPR opt-in radio button.
869
- $($marketingOptin.find('input[type=radio]')[0]).focus();
870
- }
871
- } else {
872
- $marketingOptin.hide();
873
- $primaryCta.focus();
874
- }
875
- },
876
- /**
877
- * @author Leo Fajardo (@leorw)
878
- * @since 2.1.0
879
- */
880
- fetchIsMarketingAllowedFlagAndToggleOptin = function () {
881
- var licenseKey = $licenseKeyInput.val();
882
-
883
- if (licenseKey.length < 32) {
884
- $marketingOptin.hide();
885
- return;
886
- }
887
-
888
- if (isMarketingAllowedByLicense.hasOwnProperty(licenseKey)) {
889
- afterMarketingFlagLoaded();
890
- return;
891
- }
892
-
893
- $marketingOptin.hide();
894
-
895
- setLoadingMode();
896
-
897
- $primaryCta.addClass('fs-loading');
898
- $primaryCta.attr('disabled', 'disabled');
899
- $primaryCta.html('<?php fs_esc_js_echo_inline( 'Please wait', 'please-wait', $slug ) ?>...');
900
-
901
- $.ajax({
902
- url : ajaxurl,
903
- method : 'POST',
904
- data : {
905
- action : '<?php echo $fs->get_ajax_action( 'fetch_is_marketing_required_flag_value' ) ?>',
906
- security : '<?php echo $fs->get_ajax_security( 'fetch_is_marketing_required_flag_value' ) ?>',
907
- license_key: licenseKey,
908
- module_id : '<?php echo $fs->get_id() ?>'
909
- },
910
- success: function (result) {
911
- resetLoadingMode();
912
-
913
- if (result.success) {
914
- result = result.data;
915
-
916
- // Cache result.
917
- isMarketingAllowedByLicense[licenseKey] = result.is_marketing_allowed;
918
- }
919
-
920
- afterMarketingFlagLoaded();
921
- }
922
- });
923
- };
924
-
925
- $marketingOptin.find( 'input' ).click(function() {
926
- $marketingOptin.removeClass( 'error' );
927
- });
928
- }
929
-
930
- //endregion
931
- })(jQuery);
932
- </script>
1
+ <?php
2
+ /**
3
+ * @package Freemius
4
+ * @copyright Copyright (c) 2015, Freemius, Inc.
5
+ * @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3
6
+ * @since 1.0.7
7
+ */
8
+
9
+ if ( ! defined( 'ABSPATH' ) ) {
10
+ exit;
11
+ }
12
+
13
+ /**
14
+ * @var array $VARS
15
+ * @var Freemius $fs
16
+ */
17
+ $fs = freemius( $VARS['id'] );
18
+ $slug = $fs->get_slug();
19
+
20
+ $is_pending_activation = $fs->is_pending_activation();
21
+ $is_premium_only = $fs->is_only_premium();
22
+ $has_paid_plans = $fs->has_paid_plan();
23
+ $is_premium_code = $fs->is_premium();
24
+ $is_freemium = $fs->is_freemium();
25
+
26
+ $fs->_enqueue_connect_essentials();
27
+
28
+ $current_user = Freemius::_get_current_wp_user();
29
+
30
+ $first_name = $current_user->user_firstname;
31
+ if ( empty( $first_name ) ) {
32
+ $first_name = $current_user->nickname;
33
+ }
34
+
35
+ $site_url = get_site_url();
36
+ $protocol_pos = strpos( $site_url, '://' );
37
+ if ( false !== $protocol_pos ) {
38
+ $site_url = substr( $site_url, $protocol_pos + 3 );
39
+ }
40
+
41
+ $freemius_site_www = 'https://freemius.com';
42
+
43
+ $freemius_usage_tracking_url = $freemius_site_www . '/wordpress/usage-tracking/' . $fs->get_id() . "/{$slug}/";
44
+ $freemius_plugin_terms_url = $freemius_site_www . '/terms/' . $fs->get_id() . "/{$slug}/";
45
+
46
+ $freemius_site_url = $fs->is_premium() ?
47
+ $freemius_site_www :
48
+ $freemius_usage_tracking_url;
49
+
50
+ if ( $fs->is_premium() ) {
51
+ $freemius_site_url .= '?' . http_build_query(
52
+ array(
53
+ 'id' => $fs->get_id(),
54
+ 'slug' => $slug,
55
+ )
56
+ );
57
+ }
58
+
59
+ $freemius_link = '<a href="' . $freemius_site_url . '" target="_blank" tabindex="1">freemius.com</a>';
60
+
61
+ $error = fs_request_get( 'error' );
62
+
63
+ $require_license_key = $is_premium_only ||
64
+ ( $is_freemium && $is_premium_code && fs_request_get_bool( 'require_license', true ) );
65
+
66
+ if ( $is_pending_activation ) {
67
+ $require_license_key = false;
68
+ }
69
+
70
+ if ( $require_license_key ) {
71
+ $fs->_add_license_activation_dialog_box();
72
+ }
73
+
74
+ $is_optin_dialog = (
75
+ $fs->is_theme() &&
76
+ $fs->is_themes_page() &&
77
+ ( ! $fs->has_settings_menu() || $fs->is_free_wp_org_theme() )
78
+ );
79
+
80
+ if ( $is_optin_dialog ) {
81
+ $show_close_button = false;
82
+ $previous_theme_activation_url = '';
83
+
84
+ if ( ! $is_premium_code ) {
85
+ $show_close_button = true;
86
+ } elseif ( $is_premium_only ) {
87
+ $previous_theme_activation_url = $fs->get_previous_theme_activation_url();
88
+ $show_close_button = ( ! empty( $previous_theme_activation_url ) );
89
+ }
90
+ }
91
+
92
+ $is_network_level_activation = (
93
+ fs_is_network_admin() &&
94
+ $fs->is_network_active() &&
95
+ ! $fs->is_network_delegated_connection()
96
+ );
97
+
98
+ $fs_user = Freemius::_get_user_by_email( $current_user->user_email );
99
+
100
+ $activate_with_current_user = (
101
+ is_object( $fs_user ) &&
102
+ ! $is_pending_activation &&
103
+ // If requires a license for activation, use the user associated with the license for the opt-in.
104
+ ! $require_license_key &&
105
+ ! $is_network_level_activation
106
+ );
107
+
108
+ $optin_params = $fs->get_opt_in_params( array(), $is_network_level_activation );
109
+ $sites = isset( $optin_params['sites'] ) ? $optin_params['sites'] : array();
110
+
111
+ $is_network_upgrade_mode = ( fs_is_network_admin() && $fs->is_network_upgrade_mode() );
112
+
113
+ /* translators: %s: name (e.g. Hey John,) */
114
+ $hey_x_text = esc_html( sprintf( fs_text_x_inline( 'Hey %s,', 'greeting', 'hey-x', $slug ), $first_name ) );
115
+
116
+ $is_gdpr_required = ( ! $is_pending_activation && ! $require_license_key ) ?
117
+ FS_GDPR_Manager::instance()->is_required() :
118
+ false;
119
+
120
+ if ( is_null( $is_gdpr_required ) ) {
121
+ $is_gdpr_required = $fs->fetch_and_store_current_user_gdpr_anonymously();
122
+ }
123
+ ?>
124
+ <?php
125
+ if ( $is_optin_dialog ) {
126
+ ?>
127
+ <div id="fs_theme_connect_wrapper">
128
+ <?php
129
+ if ( $show_close_button ) {
130
+ ?>
131
+ <button class="close dashicons dashicons-no"><span class="screen-reader-text">Close connect dialog</span>
132
+ </button>
133
+ <?php
134
+ }
135
+ ?>
136
+ <?php
137
+ }
138
+ ?>
139
+ <div id="fs_connect"
140
+ class="wrap
141
+ <?php
142
+ if ( ! fs_is_network_admin() && ( ! $fs->is_enable_anonymous() || $is_pending_activation || $require_license_key ) ) {
143
+ echo ' fs-anonymous-disabled';
144
+ }
145
+ ?>
146
+ <?php echo $require_license_key ? ' require-license-key' : ''; ?>">
147
+ <div class="fs-visual">
148
+ <b class="fs-site-icon"><i class="dashicons dashicons-wordpress"></i></b>
149
+ <i class="dashicons dashicons-plus fs-first"></i>
150
+ <?php
151
+ $vars = array( 'id' => $fs->get_id() );
152
+ fs_require_once_template( 'plugin-icon.php', $vars );
153
+ ?>
154
+ <i class="dashicons dashicons-plus fs-second"></i>
155
+ <img class="fs-connect-logo" width="80" height="80" src="//img.freemius.com/connect-logo.png"/>
156
+ </div>
157
+ <div class="fs-content">
158
+ <?php if ( ! empty( $error ) ) : ?>
159
+ <p class="fs-error"><?php echo esc_html( $error ); ?></p>
160
+ <?php endif ?>
161
+ <p>
162
+ <?php
163
+ $button_label = fs_text_inline( 'Allow & Continue', 'opt-in-connect', $slug );
164
+ $message = '';
165
+
166
+ if ( $is_pending_activation ) {
167
+ $button_label = fs_text_inline( 'Re-send activation email', 'resend-activation-email', $slug );
168
+
169
+ $message = $fs->apply_filters(
170
+ 'pending_activation_message', sprintf(
171
+ /* translators: %s: name (e.g. Thanks John!) */
172
+ fs_text_inline( 'Thanks %s!', 'thanks-x', $slug ) . '<br>' .
173
+ fs_text_inline( 'You should receive an activation email for %s to your mailbox at %s. Please make sure you click the activation button in that email to %s.', 'pending-activation-message', $slug ),
174
+ $first_name,
175
+ '<b>' . $fs->get_plugin_name() . '</b>',
176
+ '<b>' . $current_user->user_email . '</b>',
177
+ fs_text_inline( 'complete the install', 'complete-the-install', $slug )
178
+ )
179
+ );
180
+ } elseif ( $require_license_key ) {
181
+ $button_label = $is_network_upgrade_mode ?
182
+ fs_text_inline( 'Activate License', 'agree-activate-license', $slug ) :
183
+ fs_text_inline( 'Agree & Activate License', 'agree-activate-license', $slug );
184
+
185
+ $message = $fs->apply_filters(
186
+ 'connect-message_on-premium',
187
+ ( $is_network_upgrade_mode ?
188
+ '' :
189
+ /* translators: %s: name (e.g. Hey John,) */
190
+ $hey_x_text . '<br>'
191
+ ) .
192
+ sprintf( fs_text_inline( 'Thanks for purchasing %s! To get started, please enter your license key:', 'thanks-for-purchasing', $slug ), '<b>' . $fs->get_plugin_name() . '</b>' ),
193
+ $first_name,
194
+ $fs->get_plugin_name()
195
+ );
196
+ } else {
197
+ $filter = 'connect_message';
198
+ $default_optin_message = $is_gdpr_required ?
199
+ fs_text_inline( 'Never miss an important update - opt in to our security & feature updates notifications, educational content, offers, and non-sensitive diagnostic tracking with %4$s.', 'connect-message', $slug ) :
200
+ fs_text_inline( 'Never miss an important update - opt in to our security and feature updates notifications, and non-sensitive diagnostic tracking with %4$s.', 'connect-message', $slug );
201
+
202
+ if ( $fs->is_plugin_update() ) {
203
+ // If Freemius was added on a plugin update, set different
204
+ // opt-in message.
205
+ $default_optin_message = $is_gdpr_required ?
206
+ fs_text_inline( 'Never miss an important update - opt in to our security & feature updates notifications, educational content, offers, and non-sensitive diagnostic tracking with %4$s. If you skip this, that\'s okay! %1$s will still work just fine.', 'connect-message_on-update', $slug ) :
207
+ fs_text_inline( 'Never miss an important update - opt in to our security & feature updates notifications, and non-sensitive diagnostic tracking with %4$s. If you skip this, that\'s okay! %1$s will still work just fine.', 'connect-message_on-update', $slug );
208
+
209
+ // If user customized the opt-in message on update, use
210
+ // that message. Otherwise, fallback to regular opt-in
211
+ // custom message if exist.
212
+ if ( $fs->has_filter( 'connect_message_on_update' ) ) {
213
+ $filter = 'connect_message_on_update';
214
+ }
215
+ }
216
+
217
+ $message = $fs->apply_filters(
218
+ $filter,
219
+ ( $is_network_upgrade_mode ?
220
+ '' :
221
+ /* translators: %s: name (e.g. Hey John,) */
222
+ $hey_x_text . '<br>'
223
+ ) .
224
+ sprintf(
225
+ esc_html( $default_optin_message ),
226
+ '<b>' . esc_html( $fs->get_plugin_name() ) . '</b>',
227
+ '<b>' . $current_user->user_login . '</b>',
228
+ '<a href="' . $site_url . '" target="_blank">' . $site_url . '</a>',
229
+ $freemius_link
230
+ ),
231
+ $first_name,
232
+ $fs->get_plugin_name(),
233
+ $current_user->user_login,
234
+ '<a href="' . $site_url . '" target="_blank">' . $site_url . '</a>',
235
+ $freemius_link,
236
+ $is_gdpr_required
237
+ );
238
+ }
239
+
240
+ if ( $is_network_upgrade_mode ) {
241
+ $network_integration_text = esc_html( fs_text_inline( 'We\'re excited to introduce the Freemius network-level integration.', 'connect_message_network_upgrade', $slug ) );
242
+
243
+ if ( $is_premium_code ) {
244
+ $message = $network_integration_text . ' ' . sprintf( fs_text_inline( 'During the update process we detected %d site(s) that are still pending license activation.', 'connect_message_network_upgrade-premium', $slug ), count( $sites ) );
245
+
246
+ $message .= '<br><br>' . sprintf(
247
+ fs_text_inline( 'If you\'d like to use the %s on those sites, please enter your license key below and click the activation button.', 'connect_message_network_upgrade-premium-activate-license', $slug ), $is_premium_only ? $fs->get_module_label( true ) : sprintf(
248
+ /* translators: %s: module type (plugin, theme, or add-on) */
249
+ fs_text_inline( "%s's paid features", 'x-paid-features', $slug ),
250
+ $fs->get_module_label( true )
251
+ )
252
+ );
253
+
254
+ /* translators: %s: module type (plugin, theme, or add-on) */
255
+ $message .= ' ' . sprintf( fs_text_inline( 'Alternatively, you can skip it for now and activate the license later, in your %s\'s network-level Account page.', 'connect_message_network_upgrade-premium-skip-license', $slug ), $fs->get_module_label( true ) );
256
+ } else {
257
+ $message = $network_integration_text . ' ' . sprintf( fs_text_inline( 'During the update process we detected %s site(s) in the network that are still pending your attention.', 'connect_message_network_upgrade-free', $slug ), count( $sites ) ) . '<br><br>' . ( fs_starts_with( $message, $hey_x_text . '<br>' ) ? substr( $message, strlen( $hey_x_text . '<br>' ) ) : $message );
258
+ }
259
+ }
260
+
261
+ echo $message;
 
 
 
 
 
262
  ?>
263
+ </p>
264
+ <?php if ( $require_license_key ) : ?>
265
+ <div class="fs-license-key-container">
266
+ <input id="fs_license_key" name="fs_key" type="text" required maxlength="<?php echo $fs->apply_filters( 'license_key_maxlength', 32 ); ?>"
267
+ placeholder="<?php fs_esc_attr_echo_inline( 'License key', 'license-key', $slug ); ?>" tabindex="1"/>
268
+ <i class="dashicons dashicons-admin-network"></i>
269
+ <a class="show-license-resend-modal show-license-resend-modal-<?php echo $fs->get_unique_affix(); ?>"
270
+ href="#"><?php fs_esc_html_echo_inline( "Can't find your license key?", 'cant-find-license-key', $slug ); ?></a>
271
+ </div>
272
+
273
+ <?php
274
+ /**
275
+ * Allows developers to include custom HTML after the license input container.
276
+ *
277
+ * @author Vova Feldman
278
+ * @since 2.1.2
279
+ */
280
+ $fs->do_action( 'connect/after_license_input' );
281
+ ?>
282
+
283
+ <?php
284
+ $send_updates_text = sprintf(
285
+ '%s<span class="action-description"> - %s</span>',
286
+ $fs->get_text_inline( 'Yes', 'yes' ),
287
+ $fs->get_text_inline( 'send me security & feature updates, educational content and offers.', 'send-updates' )
288
+ );
289
+
290
+ $do_not_send_updates_text = sprintf(
291
+ '%s<span class="action-description"> - %s</span>',
292
+ $fs->get_text_inline( 'No', 'no' ),
293
+ sprintf(
294
+ $fs->get_text_inline( 'do %sNOT%s send me security & feature updates, educational content and offers.', 'do-not-send-updates' ),
295
+ '<span class="underlined">',
296
+ '</span>'
297
+ )
298
+ );
299
+ ?>
300
+ <div id="fs_marketing_optin">
301
+ <span class="fs-message"><?php fs_echo_inline( "Please let us know if you'd like us to contact you for security & feature updates, educational content, and occasional offers:", 'contact-for-updates' ); ?></span>
302
+ <div class="fs-input-container">
303
+ <label>
304
+ <input type="radio" name="allow-marketing" value="true" tabindex="1" />
305
+ <span class="fs-input-label"><?php echo $send_updates_text; ?></span>
306
+ </label>
307
+ <label>
308
+ <input type="radio" name="allow-marketing" value="false" tabindex="1" />
309
+ <span class="fs-input-label"><?php echo $do_not_send_updates_text; ?></span>
310
+ </label>
311
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
312
  </div>
313
+ <?php endif ?>
314
+ <?php if ( $is_network_level_activation ) : ?>
315
+ <?php
316
+ $vars = array(
317
+ 'id' => $fs->get_id(),
318
+ 'sites' => $sites,
319
+ 'require_license_key' => $require_license_key,
320
+ );
321
+
322
+ echo fs_get_template( 'partials/network-activation.php', $vars );
323
+ ?>
324
+ <?php endif ?>
325
+ </div>
326
+ <div class="fs-actions">
327
+ <?php if ( $fs->is_enable_anonymous() && ! $is_pending_activation && ( ! $require_license_key || $is_network_upgrade_mode ) ) : ?>
328
+ <a id="skip_activation" href="<?php echo fs_nonce_url( $fs->_get_admin_page_url( '', array( 'fs_action' => $fs->get_unique_affix() . '_skip_activation' ), $is_network_level_activation ), $fs->get_unique_affix() . '_skip_activation' ); ?>"
329
+ class="button button-secondary" tabindex="2"><?php fs_esc_html_echo_x_inline( 'Skip', 'verb', 'skip', $slug ); ?></a>
330
+ <?php endif ?>
331
+ <?php if ( $is_network_level_activation && $fs->apply_filters( 'show_delegation_option', true ) ) : ?>
332
+ <a id="delegate_to_site_admins" class="fs-tooltip-trigger <?php echo is_rtl() ? ' rtl' : ''; ?>" href="<?php echo fs_nonce_url( $fs->_get_admin_page_url( '', array( 'fs_action' => $fs->get_unique_affix() . '_delegate_activation' ) ), $fs->get_unique_affix() . '_delegate_activation' ); ?>"><?php fs_esc_html_echo_inline( 'Delegate to Site Admins', 'delegate-to-site-admins', $slug ); ?><span class="fs-tooltip"><?php fs_esc_html_echo_inline( 'If you click it, this decision will be delegated to the sites administrators.', 'delegate-sites-tooltip', $slug ); ?></span></a>
333
+ <?php endif ?>
334
+ <?php if ( $activate_with_current_user ) : ?>
335
+ <form action="" method="POST">
336
+ <input type="hidden" name="fs_action"
337
+ value="<?php echo $fs->get_unique_affix(); ?>_activate_existing">
338
+ <?php wp_nonce_field( 'activate_existing_' . $fs->get_public_key() ); ?>
339
+ <button class="button button-primary" tabindex="1"
340
+ type="submit"><?php echo esc_html( $button_label ); ?></button>
341
+ </form>
342
+ <?php else : ?>
343
+ <form method="post" action="<?php echo WP_FS__ADDRESS; ?>/action/service/user/install/">
344
+ <?php unset( $optin_params['sites'] ); ?>
345
+ <?php foreach ( $optin_params as $name => $value ) : ?>
346
+ <input type="hidden" name="<?php echo $name; ?>" value="<?php echo esc_attr( $value ); ?>">
347
+ <?php endforeach ?>
348
+ <button class="button button-primary" tabindex="1"
349
+ type="submit"
350
+ <?php
351
+ if ( $require_license_key ) {
352
+ echo ' disabled="disabled"';
353
+ }
354
+ ?>
355
+ ><?php echo esc_html( $button_label ); ?></button>
356
+ </form>
357
+ <?php endif ?>
358
+ </div>
359
+ <?php
360
+
361
+ // Set core permission list items.
362
+ $permissions = array(
363
+ 'profile' => array(
364
+ 'icon-class' => 'dashicons dashicons-admin-users',
365
+ 'label' => $fs->get_text_inline( 'Your Profile Overview', 'permissions-profile' ),
366
+ 'desc' => $fs->get_text_inline( 'Name and email address', 'permissions-profile_desc' ),
367
+ 'priority' => 5,
368
+ ),
369
+ 'site' => array(
370
+ 'icon-class' => 'dashicons dashicons-admin-settings',
371
+ 'label' => $fs->get_text_inline( 'Your Site Overview', 'permissions-site' ),
372
+ 'desc' => $fs->get_text_inline( 'Site URL, WP version, PHP info, plugins & themes', 'permissions-site_desc' ),
373
+ 'priority' => 10,
374
+ ),
375
+ 'notices' => array(
376
+ 'icon-class' => 'dashicons dashicons-testimonial',
377
+ 'label' => $fs->get_text_inline( 'Admin Notices', 'permissions-admin-notices' ),
378
+ 'desc' => $fs->get_text_inline( 'Updates, announcements, marketing, no spam', 'permissions-newsletter_desc' ),
379
+ 'priority' => 13,
380
+ ),
381
+ 'events' => array(
382
+ 'icon-class' => 'dashicons dashicons-admin-plugins',
383
+ 'label' => sprintf( $fs->get_text_inline( 'Current %s Events', 'permissions-events' ), ucfirst( $fs->get_module_type() ) ),
384
+ 'desc' => $fs->get_text_inline( 'Activation, deactivation and uninstall', 'permissions-events_desc' ),
385
+ 'priority' => 20,
386
+ ),
387
+ );
388
+
389
+ // Add newsletter permissions if enabled.
390
+ if ( $is_gdpr_required || $fs->is_permission_requested( 'newsletter' ) ) {
391
+ $permissions['newsletter'] = array(
392
+ 'icon-class' => 'dashicons dashicons-email-alt',
393
+ 'label' => $fs->get_text_inline( 'Newsletter', 'permissions-newsletter' ),
394
+ 'desc' => $fs->get_text_inline( 'Updates, announcements, marketing, no spam', 'permissions-newsletter_desc' ),
395
+ 'priority' => 15,
396
+ );
397
+ }
398
+
399
+ // Allow filtering of the permissions list.
400
+ $permissions = $fs->apply_filters( 'permission_list', $permissions );
401
+
402
+ // Sort by priority.
403
+ uasort( $permissions, 'fs_sort_by_priority' );
404
+
405
+ if ( ! empty( $permissions ) ) :
406
+ ?>
407
+ <div class="fs-permissions">
408
+ <?php if ( $require_license_key ) : ?>
409
+ <p class="fs-license-sync-disclaimer">
410
+ <?php
411
+ echo sprintf(
412
+ fs_esc_html_inline( 'The %1$s will be periodically sending data to %2$s to check for security and feature updates, and verify the validity of your license.', 'license-sync-disclaimer', $slug ),
413
+ $fs->get_module_label( true ),
414
+ $freemius_link
415
+ )
416
+ ?>
417
+ </p>
418
+ <?php endif ?>
419
+ <a class="fs-trigger" href="#" tabindex="1"><?php fs_esc_html_echo_inline( 'What permissions are being granted?', 'what-permissions', $slug ); ?></a>
420
+ <ul>
421
+ <?php
422
+ foreach ( $permissions as $id => $permission ) :
423
+ ?>
424
+ <li id="fs-permission-<?php echo esc_attr( $id ); ?>"
425
+ class="fs-permission fs-<?php echo esc_attr( $id ); ?>">
426
+ <i class="<?php echo esc_attr( $permission['icon-class'] ); ?>"></i>
427
+
428
+ <div>
429
+ <span><?php echo esc_html( $permission['label'] ); ?></span>
430
+
431
+ <p><?php echo esc_html( $permission['desc'] ); ?></p>
432
+ </div>
433
+ </li>
434
+ <?php endforeach; ?>
435
+ </ul>
436
+ </div>
437
+ <?php endif ?>
438
+ <?php if ( $is_premium_code && $is_freemium ) : ?>
439
+ <div class="fs-freemium-licensing">
440
+ <p>
441
+ <?php if ( $require_license_key ) : ?>
442
+ <?php fs_esc_html_echo_inline( 'Don\'t have a license key?', 'dont-have-license-key', $slug ); ?>
443
+ <a data-require-license="false" tabindex="1"><?php fs_esc_html_echo_inline( 'Activate Free Version', 'activate-free-version', $slug ); ?></a>
444
+ <?php else : ?>
445
+ <?php fs_echo_inline( 'Have a license key?', 'have-license-key', $slug ); ?>
446
+ <a data-require-license="true" tabindex="1"><?php fs_esc_html_echo_inline( 'Activate License', 'activate-license', $slug ); ?></a>
447
+ <?php endif ?>
448
+ </p>
449
+ </div>
450
+ <?php endif ?>
451
+ <div class="fs-terms">
452
+ <a href="https://freemius.com/privacy/" target="_blank"
453
+ tabindex="1"><?php fs_esc_html_echo_inline( 'Privacy Policy', 'privacy-policy', $slug ); ?></a>
454
+ &nbsp;&nbsp;-&nbsp;&nbsp;
455
+ <a href="<?php echo $require_license_key ? $freemius_plugin_terms_url : $freemius_usage_tracking_url; ?>" target="_blank" tabindex="1"><?php $require_license_key ? fs_echo_inline( 'License Agreement', 'license-agreement', $slug ) : fs_echo_inline( 'Terms of Service', 'tos', $slug ); ?></a>
456
+ </div>
457
+ </div>
458
+ <?php
459
+ if ( $is_optin_dialog ) {
460
+ ?>
461
+ </div>
462
+ <?php
463
+ }
464
+ ?>
465
+ <script type="text/javascript">
466
+ (function ($) {
467
+ var $html = $('html');
468
+
469
+ <?php
470
+ if ( $is_optin_dialog ) {
471
+ if ( $show_close_button ) {
472
+ ?>
473
+ var $themeConnectWrapper = $('#fs_theme_connect_wrapper');
474
+
475
+ $themeConnectWrapper.find('button.close').on('click', function () {
476
+ <?php if ( ! empty( $previous_theme_activation_url ) ) { ?>
477
+ location.href = '<?php echo html_entity_decode( $previous_theme_activation_url ); ?>';
478
+ <?php } else { ?>
479
+ $themeConnectWrapper.remove();
480
+ $html.css({overflow: $html.attr('fs-optin-overflow')});
481
+ <?php } ?>
482
  });
483
+ <?php
484
+ }
485
+ ?>
486
+
487
+ $html.attr('fs-optin-overflow', $html.css('overflow'));
488
+ $html.css({overflow: 'hidden'});
489
+
490
+ <?php
491
+ }
492
+ ?>
493
+
494
+ var $primaryCta = $('.fs-actions .button.button-primary'),
495
+ primaryCtaLabel = $primaryCta.html(),
496
+ $form = $('.fs-actions form'),
497
+ isNetworkActive = <?php echo $is_network_level_activation ? 'true' : 'false'; ?>,
498
+ requireLicenseKey = <?php echo $require_license_key ? 'true' : 'false'; ?>,
499
+ hasContextUser = <?php echo $activate_with_current_user ? 'true' : 'false'; ?>,
500
+ isNetworkUpgradeMode = <?php echo $is_network_upgrade_mode ? 'true' : 'false'; ?>,
501
+ $licenseSecret,
502
+ $licenseKeyInput = $('#fs_license_key'),
503
+ pauseCtaLabelUpdate = false,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
504
  /**
505
+ * @author Leo Fajardo (@leorw)
506
+ * @since 2.1.0
507
  */
508
+ resetLoadingMode = function() {
509
+ // Reset loading mode.
510
+ $primaryCta.html(primaryCtaLabel);
511
+ $primaryCta.prop('disabled', false);
512
+ $(document.body).css({'cursor': 'auto'});
513
+ $('.fs-loading').removeClass('fs-loading');
514
+
515
+ console.log('resetLoadingMode - Primary button was enabled');
516
+ },
517
+ setLoadingMode = function () {
518
+ $(document.body).css({'cursor': 'wait'});
519
+ };
520
+
521
+ $('.fs-actions .button').on('click', function () {
522
+ setLoadingMode();
523
+
524
+ var $this = $(this);
525
+
526
+ setTimeout(function () {
527
+ if ( ! requireLicenseKey || ! $marketingOptin.hasClass( 'error' ) ) {
528
+ $this.attr('disabled', 'disabled');
529
+ }
530
+ }, 200);
531
+ });
532
+
533
+ if ( isNetworkActive ) {
534
+ var
535
+ $multisiteOptionsContainer = $( '#multisite_options_container' ),
536
+ $allSitesOptions = $( '#all_sites_options' ),
537
+ $applyOnAllSites = $( '#apply_on_all_sites' ),
538
+ $sitesListContainer = $( '#sites_list_container' ),
539
+ totalSites = <?php echo count( $sites ); ?>,
540
+ maxSitesListHeight = null,
541
+ $skipActivationButton = $( '#skip_activation' ),
542
+ $delegateToSiteAdminsButton = $( '#delegate_to_site_admins' );
543
+
544
+ $applyOnAllSites.click(function() {
545
+ var isChecked = $( this ).is( ':checked' );
546
+
547
+ if ( isChecked ) {
548
+ $multisiteOptionsContainer.find( '.action' ).removeClass( 'selected' );
549
+ updatePrimaryCtaText( 'allow' );
550
+ }
551
+
552
+ $multisiteOptionsContainer.find( '.action-allow' ).addClass( 'selected' );
553
+
554
+ $skipActivationButton.toggle();
555
+
556
+ $delegateToSiteAdminsButton.toggle();
557
+
558
+ $multisiteOptionsContainer.toggleClass( 'apply-on-all-sites', isChecked );
559
+
560
+ $sitesListContainer.toggle( ! isChecked );
561
+ if ( ! isChecked && null === maxSitesListHeight ) {
562
+ /**
563
+ * Set the visible number of rows to 5 (5 * height of the first row).
564
+ *
565
+ * @author Leo Fajardo (@leorw)
566
+ */
567
+ maxSitesListHeight = ( 5 * $sitesListContainer.find( 'tr:first' ).height() );
568
+ $sitesListContainer.css( 'max-height', maxSitesListHeight );
569
+ }
570
+ });
571
+
572
+ $allSitesOptions.find( '.action' ).click(function( evt ) {
573
+ var actionType = $( evt.target ).data( 'action-type' );
574
+
575
+ $multisiteOptionsContainer.find( '.action' ).removeClass( 'selected' );
576
+ $multisiteOptionsContainer.find( '.action-' + actionType ).toggleClass( 'selected' );
577
+
578
+ updatePrimaryCtaText( actionType );
579
+ });
580
+
581
+ $sitesListContainer.delegate( '.action', 'click', function( evt ) {
582
+ var $this = $( evt.target );
583
+ if ( $this.hasClass( 'selected' ) ) {
584
+ return false;
585
+ }
586
+
587
+ $this.parents( 'tr:first' ).find( '.action' ).removeClass( 'selected' );
588
+ $this.toggleClass( 'selected' );
589
+
590
+ var
591
+ singleSiteActionType = $this.data( 'action-type' ),
592
+ totalSelected = $sitesListContainer.find( '.action-' + singleSiteActionType + '.selected' ).length;
593
+
594
+ $allSitesOptions.find( '.action.selected' ).removeClass( 'selected' );
595
+
596
+ if ( totalSelected === totalSites ) {
597
+ $allSitesOptions.find( '.action-' + singleSiteActionType ).addClass( 'selected' );
598
+
599
+ updatePrimaryCtaText( singleSiteActionType );
600
+ } else {
601
+ updatePrimaryCtaText( 'mixed' );
602
+ }
603
+ });
604
+
605
+ if (isNetworkUpgradeMode) {
606
+ $skipActivationButton.click(function(){
607
+ $delegateToSiteAdminsButton.hide();
608
+
609
+ $skipActivationButton.html('<?php fs_esc_js_echo_inline( 'Skipping, please wait', 'skipping-wait', $slug ); ?>...');
610
+
611
+ pauseCtaLabelUpdate = true;
612
+
613
+ // Check all sites to be skipped.
614
+ $allSitesOptions.find('.action.action-skip').click();
615
+
616
+ $form.submit();
617
+
618
+ pauseCtaLabelUpdate = false;
619
+
620
+ return false;
621
+ });
622
+
623
+ $delegateToSiteAdminsButton.click(function(){
624
+ $delegateToSiteAdminsButton.html('<?php fs_esc_js_echo_inline( 'Delegating, please wait', 'delegating-wait', $slug ); ?>...');
625
+
626
+ pauseCtaLabelUpdate = true;
627
+
628
+ // Check all sites to be skipped.
629
+ $allSitesOptions.find('.action.action-delegate').click();
630
+
631
+ $form.submit();
632
+
633
+ pauseCtaLabelUpdate = false;
634
+
635
+ return false;
636
+ });
637
+ }
638
+ }
639
+
640
+ /**
641
+ * @author Leo Fajardo (@leorw)
642
+ */
643
+ function updatePrimaryCtaText( actionType ) {
644
+ if (pauseCtaLabelUpdate)
645
+ return;
646
+
647
+ var text = '<?php fs_esc_js_echo_inline( 'Continue', 'continue', $slug ); ?>';
648
+
649
+ switch ( actionType ) {
650
+ case 'allow':
651
+ text = '<?php fs_esc_js_echo_inline( 'Allow & Continue', 'opt-in-connect', $slug ); ?>';
652
+ break;
653
+ case 'delegate':
654
+ text = '<?php fs_esc_js_echo_inline( 'Delegate to Site Admins & Continue', 'delegate-to-site-admins-and-continue', $slug ); ?>';
655
+ break;
656
+ case 'skip':
657
+ text = '<?php fs_esc_js_echo_x_inline( 'Skip', 'verb', 'skip', $slug ); ?>';
658
+ break;
659
+ }
660
+
661
+ $primaryCta.html( text );
662
+ }
663
+
664
+ var ajaxOptin = ( requireLicenseKey || isNetworkActive );
665
+
666
+ $form.on('submit', function () {
667
+ /**
668
+ * @author Vova Feldman (@svovaf)
669
+ * @since 1.1.9
670
+ */
671
+ if ( ajaxOptin ) {
672
+ if (!hasContextUser || isNetworkUpgradeMode) {
673
+ <?php $action = $require_license_key ? 'activate_license' : 'network_activate'; ?>
674
+
675
+ $('.fs-error').remove();
676
+
677
+ var
678
+ licenseKey = $licenseKeyInput.val(),
679
+ data = {
680
+ action : '<?php echo $fs->get_ajax_action( $action ); ?>',
681
+ security : '<?php echo $fs->get_ajax_security( $action ); ?>',
682
+ license_key: licenseKey,
683
+ module_id : '<?php echo $fs->get_id(); ?>'
684
+ };
685
+
686
+ if (requireLicenseKey &&
687
+ isMarketingAllowedByLicense.hasOwnProperty(licenseKey)
688
+ ) {
689
  var
690
+ isMarketingAllowed = null,
691
+ $isMarketingAllowed = $marketingOptin.find( 'input[type="radio"][name="allow-marketing"]:checked');
692
+
693
+
694
+ if ($isMarketingAllowed.length > 0)
695
+ isMarketingAllowed = ('true' == $isMarketingAllowed.val());
696
+
697
+ if ( null == isMarketingAllowedByLicense[ licenseKey ] &&
698
+ null == isMarketingAllowed
699
+ ) {
700
+ $marketingOptin.addClass( 'error' ).show();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
701
  resetLoadingMode();
702
+ return false;
703
+ } else if ( null == isMarketingAllowed ) {
704
+ isMarketingAllowed = isMarketingAllowedByLicense[ licenseKey ];
705
  }
706
+
707
+ data.is_marketing_allowed = isMarketingAllowed;
 
 
 
 
 
 
708
  }
709
+
710
+ $marketingOptin.removeClass( 'error' );
711
+
712
+ if ( isNetworkActive ) {
713
+ var
714
+ sites = [],
715
+ applyOnAllSites = $applyOnAllSites.is( ':checked' );
716
+
717
+ $sitesListContainer.find( 'tr' ).each(function() {
718
+ var
719
+ $this = $( this ),
720
+ includeSite = ( ! requireLicenseKey || applyOnAllSites || $this.find( 'input' ).is( ':checked' ) );
721
+
722
+ if ( ! includeSite )
723
+ return;
724
+
725
+ var site = {
726
+ uid : $this.find( '.uid' ).val(),
727
+ url : $this.find( '.url' ).val(),
728
+ title : $this.find( '.title' ).val(),
729
+ language: $this.find( '.language' ).val(),
730
+ charset : $this.find( '.charset' ).val(),
731
+ blog_id : $this.find( '.blog-id' ).find( 'span' ).text()
732
+ };
733
+
734
+ if ( ! requireLicenseKey) {
735
+ site.action = $this.find('.action.selected').data('action-type');
736
+ }
737
+
738
+ sites.push( site );
739
+ });
740
+
741
+ data.sites = sites;
742
+ }
743
+
744
+ /**
745
+ * Use the AJAX opt-in when license key is required to potentially
746
+ * process the after install failure hook.
747
+ *
748
+ * @author Vova Feldman (@svovaf)
749
+ * @since 1.2.1.5
750
+ */
751
+ $.ajax({
752
+ url : ajaxurl,
753
+ method : 'POST',
754
+ data : data,
755
+ success: function (result) {
756
+ var resultObj = $.parseJSON(result);
757
+ if (resultObj.success) {
758
+ // Redirect to the "Account" page and sync the license.
759
+ window.location.href = resultObj.next_page;
760
+ } else {
761
+ resetLoadingMode();
762
+
763
+ // Show error.
764
+ $('.fs-content').prepend('<p class="fs-error">' + (resultObj.error.message ? resultObj.error.message : resultObj.error) + '</p>');
765
+ }
766
+ },
767
+ error: function () {
768
+ resetLoadingMode();
769
+ }
770
+ });
771
+
772
+ return false;
773
+ }
774
+ else {
775
+ if (null == $licenseSecret) {
776
+ $licenseSecret = $('<input type="hidden" name="license_secret_key" value="" />');
777
+ $form.append($licenseSecret);
778
+ }
779
+
780
+ // Update secret key if premium only plugin.
781
+ $licenseSecret.val($licenseKeyInput.val());
782
+ }
783
+ }
784
+
785
+ return true;
786
+ });
787
+
788
+ $primaryCta.on('click', function () {
789
+ console.log('Primary button was clicked');
790
+
791
+ $(this).addClass('fs-loading');
792
+ $(this).html('
793
+ <?php
794
+ echo esc_js(
795
+ $is_pending_activation ?
796
+ fs_text_x_inline( 'Sending email', 'as in the process of sending an email', 'sending-email', $slug ) :
797
+ fs_text_x_inline( 'Activating', 'as activating plugin', 'activating', $slug )
798
+ )
799
+ ?>
800
+ ...');
801
+ });
802
+
803
+ $('.fs-permissions .fs-trigger').on('click', function () {
804
+ $('.fs-permissions').toggleClass('fs-open');
805
+
806
+ return false;
807
+ });
808
+
809
+ if (requireLicenseKey) {
810
+ /**
811
+ * Submit license key on enter.
812
+ *
813
+ * @author Vova Feldman (@svovaf)
814
+ * @since 1.1.9
815
+ */
816
+ $licenseKeyInput.keypress(function (e) {
817
+ if (e.which == 13) {
818
+ if ('' !== $(this).val()) {
819
+ $primaryCta.click();
820
+ return false;
821
+ }
822
+ }
823
+ });
824
+
825
+ /**
826
+ * Disable activation button when empty license key.
827
+ *
828
+ * @author Vova Feldman (@svovaf)
829
+ * @since 1.1.9
830
+ */
831
+ $licenseKeyInput.on('keyup paste delete cut', function () {
832
+ setTimeout(function () {
833
+ var key = $licenseKeyInput.val();
834
+
835
+ if (key == previousLicenseKey){
836
+ return;
837
  }
838
+
839
+ if ('' === key) {
840
+ $primaryCta.attr('disabled', 'disabled');
841
+ $marketingOptin.hide();
842
+ } else {
843
+ $primaryCta.prop('disabled', false);
844
+
845
+ if (32 <= key.length){
846
+ fetchIsMarketingAllowedFlagAndToggleOptin();
847
+ } else {
848
+ $marketingOptin.hide();
849
+ }
850
+ }
851
+
852
+ previousLicenseKey = key;
853
+ }, 100);
854
+ }).focus();
855
+ }
856
+
857
+ /**
858
+ * Set license mode trigger URL.
859
+ *
860
+ * @author Vova Feldman (@svovaf)
861
+ * @since 1.1.9
862
+ */
863
+ var
864
+ $connectLicenseModeTrigger = $('#fs_connect .fs-freemium-licensing a'),
865
+ href = window.location.href;
866
+
867
+ if (href.indexOf('?') > 0) {
868
+ href += '&';
869
+ } else {
870
+ href += '?';
871
+ }
872
+
873
+ if ($connectLicenseModeTrigger.length > 0) {
874
+ $connectLicenseModeTrigger.attr(
875
+ 'href',
876
+ href + 'require_license=' + $connectLicenseModeTrigger.attr('data-require-license')
877
+ );
878
+ }
879
+
880
+ //--------------------------------------------------------------------------------
881
+ //region GDPR
882
+ //--------------------------------------------------------------------------------
883
+ var isMarketingAllowedByLicense = {},
884
+ $marketingOptin = $('#fs_marketing_optin'),
885
+ previousLicenseKey = null;
886
+
887
+ if (requireLicenseKey) {
888
+
889
+ var
890
+ afterMarketingFlagLoaded = function () {
891
+ var licenseKey = $licenseKeyInput.val();
892
+
893
+ if (null == isMarketingAllowedByLicense[licenseKey]) {
894
+ $marketingOptin.show();
895
+
896
+ if ($marketingOptin.find('input[type=radio]:checked').length > 0){
897
+ // Focus on button if GDPR opt-in already selected is already selected.
898
+ $primaryCta.focus();
899
+ } else {
900
+ // Focus on the GDPR opt-in radio button.
901
+ $($marketingOptin.find('input[type=radio]')[0]).focus();
902
+ }
903
+ } else {
904
+ $marketingOptin.hide();
905
+ $primaryCta.focus();
906
+ }
907
+ },
908
+ /**
909
+ * @author Leo Fajardo (@leorw)
910
+ * @since 2.1.0
911
+ */
912
+ fetchIsMarketingAllowedFlagAndToggleOptin = function () {
913
+ var licenseKey = $licenseKeyInput.val();
914
+
915
+ if (licenseKey.length < 32) {
916
+ $marketingOptin.hide();
917
+ return;
918
+ }
919
+
920
+ if (isMarketingAllowedByLicense.hasOwnProperty(licenseKey)) {
921
+ afterMarketingFlagLoaded();
922
+ return;
923
+ }
924
+
925
+ $marketingOptin.hide();
926
+
927
+ setLoadingMode();
928
+
929
+ $primaryCta.addClass('fs-loading');
930
  $primaryCta.attr('disabled', 'disabled');
931
+ $primaryCta.html('<?php fs_esc_js_echo_inline( 'Please wait', 'please-wait', $slug ); ?>...');
932
+
933
+ $.ajax({
934
+ url : ajaxurl,
935
+ method : 'POST',
936
+ data : {
937
+ action : '<?php echo $fs->get_ajax_action( 'fetch_is_marketing_required_flag_value' ); ?>',
938
+ security : '<?php echo $fs->get_ajax_security( 'fetch_is_marketing_required_flag_value' ); ?>',
939
+ license_key: licenseKey,
940
+ module_id : '<?php echo $fs->get_id(); ?>'
941
+ },
942
+ success: function (result) {
943
+ resetLoadingMode();
944
+
945
+ if (result.success) {
946
+ result = result.data;
947
+
948
+ // Cache result.
949
+ isMarketingAllowedByLicense[licenseKey] = result.is_marketing_allowed;
950
+ }
951
+
952
+ afterMarketingFlagLoaded();
953
+ }
954
+ });
955
+ };
956
+
957
+ $marketingOptin.find( 'input' ).click(function() {
958
+ $marketingOptin.removeClass( 'error' );
959
+ });
960
+ }
961
+
962
+ //endregion
963
+ })(jQuery);
964
+ </script>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
sdk/freemius/templates/debug.php CHANGED
@@ -113,6 +113,7 @@
113
  if (optionName) {
114
  $.post(ajaxurl, {
115
  action : 'fs_get_db_option',
 
116
  option_name: optionName
117
  }, function (response) {
118
  if (response.data.value)
@@ -132,6 +133,7 @@
132
  if (optionValue) {
133
  $.post(ajaxurl, {
134
  action : 'fs_set_db_option',
 
135
  option_name : optionName,
136
  option_value: optionValue
137
  }, function () {
113
  if (optionName) {
114
  $.post(ajaxurl, {
115
  action : 'fs_get_db_option',
116
+ _wpnonce : '<?php echo wp_create_nonce( 'fs_get_db_option' ) ?>',
117
  option_name: optionName
118
  }, function (response) {
119
  if (response.data.value)
133
  if (optionValue) {
134
  $.post(ajaxurl, {
135
  action : 'fs_set_db_option',
136
+ _wpnonce : '<?php echo wp_create_nonce( 'fs_set_db_option' ) ?>',
137
  option_name : optionName,
138
  option_value: optionValue
139
  }, function () {
sdk/freemius/templates/partials/network-activation.php CHANGED
@@ -9,9 +9,13 @@
9
 
10
  $sites = $VARS['sites'];
11
  $require_license_key = $VARS['require_license_key'];
 
 
 
12
  ?>
13
  <?php $separator = '<td>|</td>' ?>
14
- <div id="multisite_options_container" class="apply-on-all-sites">
 
15
  <table id="all_sites_options">
16
  <tbody>
17
  <tr>
@@ -35,7 +39,9 @@
35
  <?php if ( ! $require_license_key ) : ?>
36
  <td><a class="action action-allow" data-action-type="allow" href="#"><?php fs_esc_html_echo_inline( 'allow', 'allow', $slug ) ?></a></td>
37
  <?php echo $separator ?>
 
38
  <td><a class="action action-delegate" data-action-type="delegate" href="#"><?php fs_esc_html_echo_inline( 'delegate', 'delegate', $slug ) ?></a></td>
 
39
  <?php if ( $fs->is_enable_anonymous() ) : ?>
40
  <?php echo $separator ?>
41
  <td><a class="action action-skip" data-action-type="skip" href="#"><?php echo strtolower( fs_esc_html_inline( 'skip', 'skip', $slug ) ) ?></a></td>
@@ -67,7 +73,9 @@
67
  <?php if ( ! $require_license_key ) : ?>
68
  <td><a class="action action-allow selected" data-action-type="allow" href="#"><?php fs_esc_html_echo_inline( 'allow', 'allow', $slug ) ?></a></td>
69
  <?php echo $separator ?>
 
70
  <td><a class="action action-delegate" data-action-type="delegate" href="#"><?php fs_esc_html_echo_inline( 'delegate', 'delegate', $slug ) ?></a></td>
 
71
  <?php if ( $fs->is_enable_anonymous() ) : ?>
72
  <?php echo $separator ?>
73
  <td><a class="action action-skip" data-action-type="skip" href="#"><?php echo strtolower( fs_esc_html_inline( 'skip', 'skip', $slug ) ) ?></a></td>
@@ -78,4 +86,4 @@
78
  </tbody>
79
  </table>
80
  </div>
81
- </div>
9
 
10
  $sites = $VARS['sites'];
11
  $require_license_key = $VARS['require_license_key'];
12
+
13
+ $show_delegation_option = $fs->apply_filters( 'show_delegation_option', true );
14
+ $enable_per_site_activation = $fs->apply_filters( 'enable_per_site_activation', true );
15
  ?>
16
  <?php $separator = '<td>|</td>' ?>
17
+ <div id="multisite_options_container" class="apply-on-all-sites"<?php if ( ! $enable_per_site_activation )
18
+ echo ' style="display: none;"' ?>>
19
  <table id="all_sites_options">
20
  <tbody>
21
  <tr>
39
  <?php if ( ! $require_license_key ) : ?>
40
  <td><a class="action action-allow" data-action-type="allow" href="#"><?php fs_esc_html_echo_inline( 'allow', 'allow', $slug ) ?></a></td>
41
  <?php echo $separator ?>
42
+ <?php if ( $show_delegation_option ) : ?>
43
  <td><a class="action action-delegate" data-action-type="delegate" href="#"><?php fs_esc_html_echo_inline( 'delegate', 'delegate', $slug ) ?></a></td>
44
+ <?php endif; ?>
45
  <?php if ( $fs->is_enable_anonymous() ) : ?>
46
  <?php echo $separator ?>
47
  <td><a class="action action-skip" data-action-type="skip" href="#"><?php echo strtolower( fs_esc_html_inline( 'skip', 'skip', $slug ) ) ?></a></td>
73
  <?php if ( ! $require_license_key ) : ?>
74
  <td><a class="action action-allow selected" data-action-type="allow" href="#"><?php fs_esc_html_echo_inline( 'allow', 'allow', $slug ) ?></a></td>
75
  <?php echo $separator ?>
76
+ <?php if ( $show_delegation_option ) : ?>
77
  <td><a class="action action-delegate" data-action-type="delegate" href="#"><?php fs_esc_html_echo_inline( 'delegate', 'delegate', $slug ) ?></a></td>
78
+ <?php endif; ?>
79
  <?php if ( $fs->is_enable_anonymous() ) : ?>
80
  <?php echo $separator ?>
81
  <td><a class="action action-skip" data-action-type="skip" href="#"><?php echo strtolower( fs_esc_html_inline( 'skip', 'skip', $slug ) ) ?></a></td>
86
  </tbody>
87
  </table>
88
  </div>
89
+ </div>
wp-security-audit-log.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin URI: http://www.wpsecurityauditlog.com/
5
  * Description: Identify WordPress security issues before they become a problem. Keep track of everything happening on your WordPress including WordPress users activity. Similar to Windows Event Log and Linux Syslog, WP Security Audit Log generates a security alert for everything that happens on your WordPress blogs and websites. Use the Audit Log Viewer included in the plugin to see all the security alerts.
6
  * Author: WP White Security
7
- * Version: 3.3.1.1
8
  * Text Domain: wp-security-audit-log
9
  * Author URI: http://www.wpwhitesecurity.com/
10
  * License: GPL2
@@ -54,7 +54,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
54
  *
55
  * @var string
56
  */
57
- public $version = '3.3.1.1';
58
 
59
  // Plugin constants.
60
  const PLG_CLS_PRFX = 'WSAL_';
@@ -234,7 +234,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
234
  * @since 3.3
235
  */
236
  public function init_hooks() {
237
- // Listen for installation event.
238
  register_activation_hook( __FILE__, array( $this, 'Install' ) );
239
 
240
  // Listen for init event.
@@ -282,6 +282,8 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
282
  wsal_freemius()->add_filter( 'show_first_trial_after_n_sec', array( $this, 'change_show_first_trial_period' ), 10, 1 );
283
  wsal_freemius()->add_filter( 'reshow_trial_after_every_n_sec', array( $this, 'change_reshow_trial_period' ), 10, 1 );
284
  wsal_freemius()->add_filter( 'show_admin_notice', array( $this, 'freemius_show_admin_notice' ), 10, 2 );
 
 
285
  }
286
 
287
  /**
@@ -315,7 +317,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
315
  if ( isset( $post_data['action'] ) ) {
316
  switch ( $post_data['action'] ) {
317
  case 'check_wsal':
318
- $info = new stdClass();
319
  $info->wsal_installed = true;
320
  $info->is_premium = false;
321
 
@@ -337,7 +339,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
337
 
338
  // Set the return object.
339
  if ( isset( $event[0] ) ) {
340
- $info = new stdClass();
341
  $info->alert_id = $event[0]->alert_id;
342
  $info->created_on = $event[0]->created_on;
343
  } else {
@@ -810,26 +812,29 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
810
  * Install all assets required for a useable system.
811
  */
812
  public function Install() {
813
- if ( version_compare( PHP_VERSION, self::MIN_PHP_VERSION ) < 0 ) :
 
 
 
 
 
 
 
 
 
 
 
 
 
 
814
  ?>
815
  <html>
816
- <head>
817
- <style>
818
- .warn-icon-tri{top:5px;left:5px;position:absolute;border-left:16px solid #FFF;border-right:16px solid #FFF;border-bottom:28px solid #C33;height:3px;width:4px}.warn-icon-chr{top:8px;left:18px;position:absolute;color:#FFF;font:26px Georgia}.warn-icon-cir{top:2px;left:0;position:absolute;overflow:hidden;border:6px solid #FFF;border-radius:32px;width:34px;height:34px}.warn-wrap{position:relative;color:#A00;font:14px Arial;padding:6px 48px}.warn-wrap a,.warn-wrap a:hover{color:#F56}
819
- </style>
820
- </head>
821
- <body>
822
- <div class="warn-wrap">
823
- <div class="warn-icon-tri"></div><div class="warn-icon-chr">!</div><div class="warn-icon-cir"></div>
824
- <?php /* Translators: %s: PHP Version */ echo sprintf( esc_html__( 'You are using a version of PHP that is older than %s, which is no longer supported.', 'wp-security-audit-log' ), esc_html( self::MIN_PHP_VERSION ) ); ?>
825
- <br />
826
- <?php echo wp_kses( __( 'Contact us on <a href="mailto:plugins@wpwhitesecurity.com">plugins@wpwhitesecurity.com</a> to help you switch the version of PHP you are using.', 'wp-security-audit-log' ), $this->allowed_html_tags ); ?>
827
- </div>
828
- </body>
829
  </html>
830
  <?php
831
  die( 1 );
832
- endif;
833
 
834
  // Set the settings object temporarily.
835
  if ( empty( $this->settings ) ) {
@@ -863,7 +868,6 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
863
  // Setting the prunig date with the old value or the default value.
864
  // $pruning_date = $this->settings->GetPruningDate();
865
  // $this->settings->SetPruningDate( $pruning_date );
866
-
867
  $old_disabled = $this->GetGlobalOption( 'disabled-alerts' );
868
  // If old setting is empty disable alert 2099 by default.
869
  if ( empty( $old_disabled ) ) {
@@ -898,11 +902,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
898
  if ( ! $this->IsInstalled() ) :
899
  ?>
900
  <html>
901
- <head>
902
- <style>
903
- .warn-icon-tri{top:5px;left:5px;position:absolute;border-left:16px solid #FFF;border-right:16px solid #FFF;border-bottom:28px solid #C33;height:3px;width:4px}.warn-icon-chr{top:8px;left:18px;position:absolute;color:#FFF;font:26px Georgia}.warn-icon-cir{top:2px;left:0;position:absolute;overflow:hidden;border:6px solid #FFF;border-radius:32px;width:34px;height:34px}.warn-wrap{position:relative;color:#A00;font:14px Arial;padding:6px 48px}.warn-wrap a,.warn-wrap a:hover{color:#F56}
904
- </style>
905
- </head>
906
  <body>
907
  <div class="warn-wrap">
908
  <div class="warn-icon-tri"></div><div class="warn-icon-chr">!</div><div class="warn-icon-cir"></div>
@@ -1203,7 +1203,7 @@ if ( ! function_exists( 'wsal_freemius' ) ) {
1203
  $n = '<strong>%s</strong>';
1204
  $l = strlen( $n );
1205
  while ( ( $pos = strpos( $mesg, $n ) ) !== false ) {
1206
- $mesg = substr_replace( $mesg, '%MigratedArg' . ($c++) . '%', $pos, $l );
1207
  }
1208
  $data['MigratedMesg'] = $mesg;
1209
  // Generate new meta data args.
4
  * Plugin URI: http://www.wpsecurityauditlog.com/
5
  * Description: Identify WordPress security issues before they become a problem. Keep track of everything happening on your WordPress including WordPress users activity. Similar to Windows Event Log and Linux Syslog, WP Security Audit Log generates a security alert for everything that happens on your WordPress blogs and websites. Use the Audit Log Viewer included in the plugin to see all the security alerts.
6
  * Author: WP White Security
7
+ * Version: 3.3.1.2
8
  * Text Domain: wp-security-audit-log
9
  * Author URI: http://www.wpwhitesecurity.com/
10
  * License: GPL2
54
  *
55
  * @var string
56
  */
57
+ public $version = '3.3.1.2';
58
 
59
  // Plugin constants.
60
  const PLG_CLS_PRFX = 'WSAL_';
234
  * @since 3.3
235
  */
236
  public function init_hooks() {
237
+ // Register plugin specific activation hook.
238
  register_activation_hook( __FILE__, array( $this, 'Install' ) );
239
 
240
  // Listen for init event.
282
  wsal_freemius()->add_filter( 'show_first_trial_after_n_sec', array( $this, 'change_show_first_trial_period' ), 10, 1 );
283
  wsal_freemius()->add_filter( 'reshow_trial_after_every_n_sec', array( $this, 'change_reshow_trial_period' ), 10, 1 );
284
  wsal_freemius()->add_filter( 'show_admin_notice', array( $this, 'freemius_show_admin_notice' ), 10, 2 );
285
+ wsal_freemius()->add_filter( 'show_delegation_option', '__return_false' );
286
+ wsal_freemius()->add_filter( 'enable_per_site_activation', '__return_false' );
287
  }
288
 
289
  /**
317
  if ( isset( $post_data['action'] ) ) {
318
  switch ( $post_data['action'] ) {
319
  case 'check_wsal':
320
+ $info = new stdClass();
321
  $info->wsal_installed = true;
322
  $info->is_premium = false;
323
 
339
 
340
  // Set the return object.
341
  if ( isset( $event[0] ) ) {
342
+ $info = new stdClass();
343
  $info->alert_id = $event[0]->alert_id;
344
  $info->created_on = $event[0]->created_on;
345
  } else {
812
  * Install all assets required for a useable system.
813
  */
814
  public function Install() {
815
+ $installation_errors = false;
816
+
817
+ // Check for minimum PHP version.
818
+ if ( version_compare( PHP_VERSION, self::MIN_PHP_VERSION ) < 0 ) {
819
+ /* Translators: %s: PHP Version */
820
+ $installation_errors = sprintf( esc_html__( 'You are using a version of PHP that is older than %s, which is no longer supported.', 'wp-security-audit-log' ), esc_html( self::MIN_PHP_VERSION ) );
821
+ $installation_errors .= '<br />';
822
+ $installation_errors .= __( 'Contact us on <a href="mailto:plugins@wpwhitesecurity.com">plugins@wpwhitesecurity.com</a> to help you switch the version of PHP you are using.', 'wp-security-audit-log' );
823
+ } elseif ( $this->IsMultisite() && is_super_admin() && ! is_network_admin() ) {
824
+ $installation_errors = esc_html__( 'The WP Security Audit Log plugin is a multisite network tool, so it has to be activated at network level.', 'wp-security-audit-log' );
825
+ $installation_errors .= '<br />';
826
+ $installation_errors .= '<a href="javascript:;" onclick="window.top.location.href=\'' . esc_url( network_admin_url( 'plugins.php' ) ) . '\'">' . esc_html__( 'Redirect me to the network dashboard', 'wp-security-audit-log' ) . '</a> ';
827
+ }
828
+
829
+ if ( $installation_errors ) {
830
  ?>
831
  <html>
832
+ <head><style>body{margin:0;}.warn-icon-tri{top:7px;left:5px;position:absolute;border-left:16px solid #FFF;border-right:16px solid #FFF;border-bottom:28px solid #C33;height:3px;width:4px}.warn-icon-chr{top:10px;left:18px;position:absolute;color:#FFF;font:26px Georgia}.warn-icon-cir{top:4px;left:0;position:absolute;overflow:hidden;border:6px solid #FFF;border-radius:32px;width:34px;height:34px}.warn-wrap{position:relative;font-size:13px;font-family:sans-serif;padding:6px 48px;line-height:1.4;}</style></head>
833
+ <body><div class="warn-wrap"><div class="warn-icon-tri"></div><div class="warn-icon-chr">!</div><div class="warn-icon-cir"></div><span><?php echo $installation_errors; // @codingStandardsIgnoreLine ?></span></div></body>
 
 
 
 
 
 
 
 
 
 
 
834
  </html>
835
  <?php
836
  die( 1 );
837
+ }
838
 
839
  // Set the settings object temporarily.
840
  if ( empty( $this->settings ) ) {
868
  // Setting the prunig date with the old value or the default value.
869
  // $pruning_date = $this->settings->GetPruningDate();
870
  // $this->settings->SetPruningDate( $pruning_date );
 
871
  $old_disabled = $this->GetGlobalOption( 'disabled-alerts' );
872
  // If old setting is empty disable alert 2099 by default.
873
  if ( empty( $old_disabled ) ) {
902
  if ( ! $this->IsInstalled() ) :
903
  ?>
904
  <html>
905
+ <head><style>body{margin:0;}.warn-icon-tri{top:7px;left:5px;position:absolute;border-left:16px solid #FFF;border-right:16px solid #FFF;border-bottom:28px solid #C33;height:3px;width:4px}.warn-icon-chr{top:10px;left:18px;position:absolute;color:#FFF;font:26px Georgia}.warn-icon-cir{top:4px;left:0;position:absolute;overflow:hidden;border:6px solid #FFF;border-radius:32px;width:34px;height:34px}.warn-wrap{position:relative;color:#A00;font-size:13px;font-family:sans-serif;padding:6px 48px;line-height:1.4;}.warn-wrap a,.warn-wrap a:hover{color:#F56}</style></head>
 
 
 
 
906
  <body>
907
  <div class="warn-wrap">
908
  <div class="warn-icon-tri"></div><div class="warn-icon-chr">!</div><div class="warn-icon-cir"></div>
1203
  $n = '<strong>%s</strong>';
1204
  $l = strlen( $n );
1205
  while ( ( $pos = strpos( $mesg, $n ) ) !== false ) {
1206
+ $mesg = substr_replace( $mesg, '%MigratedArg' . ( $c++ ) . '%', $pos, $l );
1207
  }
1208
  $data['MigratedMesg'] = $mesg;
1209
  // Generate new meta data args.