Support » Plugin: Adminimize » The plugin is not exporting the settings

  • i dont know why, but when i try to export the settings of this plugin that i have made on my development server with the aim of putting them on the stage server it refuses to do this. When i click export the plugin just brings a blank page. what could be the cause and how can i solve it?

Viewing 9 replies - 16 through 24 (of 24 total)
  • i dont have a multi site setup, but am getting the same problem.

    Has the author tried different browsers? I am using CHrome
    Obviously there is something wrong somewhere, but the plugin is useless to us if we can’t export the settings.
    We have disabled all other plugins, and get the same result. A blank tab

    Plugin Author Frank Bueltge

    (@bueltge)

    Please can you activate the debug mode of WP, so that you get an error message. Yes, I’m try this in different browsers and installs. Also a lot of users get me the feedback it works. SO that it maybe a an topic for different server environment and I can only help if you get me an error messages.

    Frank, I have done that and posted the error messages to you twice.

    https://wordpress.org/support/topic/the-plugin-is-not-exporting-the-settings/#post-9313528

    Perhaps if you could respond more than once a week, we could figure out what’s going on, but you have others reporting the same problem. We are running a virtual server in a Debian distro

    Plugin Author Frank Bueltge

    (@bueltge)

    Hi @shoqvalue
    the error message with the constant is not an topic from the plugin. This constant by wordpress core, so that I mean your core install is wrong.
    See my answer here: https://wordpress.org/support/topic/the-plugin-is-not-exporting-the-settings/#post-9348470

    Sorry, I like to help, but I can’t without an error message, hint in the right direction. I will check other install to try this to get a problem.

    Ok frank, my coder, Charles fixed it. Here’s the solution for your reference:

    CHARLES: The problem was that he was calling the export function outside of the WordPress context, then checking for user capabilities – but the user object hasn’t been set until everything has loaded. So it failed.
    I fixed it by putting the call to the export function inside the ‘plugins_loaded’ hook, so it happens after everything is up and running.

    CHARLES:
    This was the faulty code in adminimize_page.php:

    // Export the options to local client.
    if ( array_key_exists( '_mw_adminimize_export', $_GET ) ) {
        _mw_adminimize_export_json();
        die();
    }
    
    I CHANGED IT TO: 
    // Export the options to local client.
    add_action(
        'plugins_loaded',
        function() {
            if ( array_key_exists( '_mw_adminimize_export', $_GET ) ) {
                _mw_adminimize_export_json();
                return;
            }
        }
    );
    • This reply was modified 1 year, 1 month ago by  shoqvalue.

    Frank, so we solved that.

    Now, suppose we had a 1000 subsites we needed to migrate your settings to, how many we go about it? You don’t have CLI acccess to this plugin, do you? If not, how we might approach it. We’re pretty clever.

    Plugin Author Frank Bueltge

    (@bueltge)

    The plugin haven’t cli access or the chance to change this in this plugin version to get this. Since longer time I would write a new version without this code structure, there I don’t like. But you can easy copy the database entry from each options table to each site, maybe a custom plugin or a migration plugin, that give you the chance to copy database items in other tables.

    Thanks for the fix to export, but normally is the export not outside the wp context, so that a run again in the plugins_loaded should no necessary. However I will try and debug this add this to the next version.

Viewing 9 replies - 16 through 24 (of 24 total)
  • The topic ‘The plugin is not exporting the settings’ is closed to new replies.