Skip to content

Commit

Permalink
v 0.25.1
Browse files Browse the repository at this point in the history
- Update dependencies
  • Loading branch information
Darklg committed Sep 17, 2024
1 parent ec8c38e commit 5759a4c
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 4 deletions.
15 changes: 13 additions & 2 deletions inc/WPUBaseSettings/WPUBaseSettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
/*
Class Name: WPU Base Settings
Description: A class to handle native settings in WordPress admin
Version: 0.21.0
Version: 0.22.0
Class URI: https://github.com/WordPressUtilities/wpubaseplugin
Author: Darklg
Author URI: https://darklg.me/
Expand Down Expand Up @@ -486,6 +486,9 @@ public function admin_head() {
public function admin_footer_medias() {
echo <<<EOT
<script>
(function(){
{$this->admin_footer_js_check_correct_page()}
/* Delete image */
jQuery('.wpubasesettings-mediabox .x').click(function(e) {
var \$this = jQuery(this),
Expand Down Expand Up @@ -520,18 +523,25 @@ public function admin_footer_medias() {
e.preventDefault();
});
}());
</script>
EOT;
}

public function admin_footer_js_check_correct_page() {
return <<<EOT
if(!jQuery('[name="option_page"][value="{$this->settings_details['option_id']}"]').length){return;}
EOT;
}

public function admin_footer() {
$option_id = $this->settings_details['option_id'];
$languages = json_encode($this->get_languages());
$label_txt = __('Language');
echo <<<EOT
<script>
(function(){
{$this->admin_footer_js_check_correct_page()}
/* Check langs */
var _langs = {$languages};
if(!_langs){
Expand Down Expand Up @@ -583,6 +593,7 @@ function admin_footer_checkall() {
echo <<<EOT
<script>
jQuery(document).ready(function() {
{$this->admin_footer_js_check_correct_page()}
jQuery(".wpubasesettings-check-all").each(function() {
var _btn = jQuery(this),
_table = _btn.prev(".form-table"),
Expand Down
4 changes: 2 additions & 2 deletions wpuactionlogs.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Plugin URI: https://github.com/WordPressUtilities/wpuactionlogs
Update URI: https://github.com/WordPressUtilities/wpuactionlogs
Description: Useful logs about what’s happening on your website admin.
Version: 0.25.0
Version: 0.25.1
Author: Darklg
Author URI: https://darklg.me/
Text Domain: wpuactionlogs
Expand All @@ -26,7 +26,7 @@ class WPUActionLogs {
public $baseadmindatas;
public $settings_details;
public $settings;
private $plugin_version = '0.25.0';
private $plugin_version = '0.25.1';
private $transient_active_duration = 60;
private $plugin_settings = array(
'id' => 'wpuactionlogs',
Expand Down

0 comments on commit 5759a4c

Please sign in to comment.