Created
December 23, 2025 09:03
-
-
Save webtoffee-git/9361327afd7dd13d869d89f03818c16b to your computer and use it in GitHub Desktop.
Re-enable admin module in WebToffee import export plugins - By WebToffee( Import export plugin for WooCommerce)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php //Do not copy this line of code | |
| add_action('admin_init', 'wt_ier_alter_admin_module_status'); | |
| if (!function_exists('wt_ier_alter_admin_module_status')) { | |
| function wt_ier_alter_admin_module_status() { | |
| $module = get_option('wt_iew_admin_modules'); | |
| if (!empty($module) && is_array($module)) { | |
| foreach ($module as $mkey => $value) { | |
| if ($value == 0) { | |
| $module[$mkey] = 1; | |
| } | |
| } | |
| update_option('wt_iew_admin_modules', $module); | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment