• Resolved Andeh86

    (@andeh86)


    What happens is that i hit save options and check pages, then get told to go to the report list tab. Once there, a loading bar appears, but does nothing else.

    I only have 8 things for it to report on, but it doesnt do anything?

    Any help?

    my install is correct, my API is set up and the pagespeed API is activated. The key is also correct, but it just hangs. 🙁

    https://wordpress.org/plugins/google-pagespeed-insights/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter Andeh86

    (@andeh86)

    also, my dev console has made note of each request that it has made to the API, with no errors.

    Plugin Author Matt Keys

    (@mattkeys)

    This happened to another user recently and when I was diagnosing the issue, I found that everything worked until the plugin tried to save the results into their database.

    The problem in their case was resolved by simply uninstalling and reinstalling the plugin.

    If you are technically inclined you could check first to see if the wp_gpi_* tables exist as they should in your database. If you are not, just go ahead with an uninstall/reinstall to let the plugin recreate these tables.

    If this does solve your problem, let me know if there is anything unique about *how* you installed my plugin. The previous person with this problem had used a multisite installation tool to bulk install it.

    If this doesn’t solve your problem, I would be willing to login to your site and take a look. You can send me credentials via my sites contact form here: http://mattkeys.me/about/.

    Let me know how it goes. Thanks.

    Thread Starter Andeh86

    (@andeh86)

    It has indeed created the database tables, but they are empty.

    The only thing i can think of is that it possibly isn’t getting permission to write to the DB… which would be weird to say the least!

    No offence, but i am hesitant in giving out access to the site, as it is not my site and belongs to another organisation, i am only a dev for them. Is there anything else you can think of that might be causing the issue? I have tried a simple re-install and had a look at the other guy who had the same option but see no answers.

    I have disabled all my other plugins also but no change.

    Another thought is just that the server host I’m using is genuinely that rubbish that it doesn’t like the requests being made from it…

    Plugin Author Matt Keys

    (@mattkeys)

    In the advanced options do you have it set to log API errors? With that enabled, if the response from the Google API contains an error, it will create a log file inside of the plugins ‘log’ folder on the server. If logs are enabled, and that folder is blank, that means the response from Google is good.

    I understand not being able to give out access to the site, I usually start there just because it can be very difficult to diagnose these issues without being able to take a look at things directly.

    With that said, what I normally do when given that access, is to edit the plugins core.php file to add in some additional error logging to see what is happening.

    The following code snippet can be added into some functions to gain some insight into what is going on:

    file_put_contents(GPI_DIRECTORY . '/logs/DEBUG_LOG_X' . '.txt', print_r($THE_THING_TO_LOG, true), FILE_APPEND);

    Change the letter X in the filename with a unique number for each item you want to log, and change $THE_THING_TO_LOG to a variable from the function you want to log. Keep in mind that these log files append, so new data is appended to the bottom of the file whenever data is written. You will want to make sure to remove any logging you add when you are done so that the files do not keep filling up with data.

    I will often use this right after line #180 of core.php to log the $result variable, which contains the response from google.

    Also, Changing line #284 to:

    $db_response = $wpdb->insert( $gpi_page_stats, $gpi_page_stats_values);

    And then logging the value of the $db_response variable right after it would give you the response from WordPress when trying to store the data. If the new log file is created on the server, but it is blank, then the operation failed, and this would suggest that there is something wrong with the tables or the permissions. If the log file has a 1, that means the save operation was successful. And if the log file isn’t there at all, that means things failed before it ever got to this step.

    Another thing you could do, is ensure wp_debug is turned on inside of your wp-config.php file, and watch for any errrors. If you have access to your PHP error logs, you can check there for any fatal errors or warnings.

    Let me know what kind of data you see while running any of the above diagnostics and I will do my best to help interpret. If you are able to provide me access to the environment, or you are able to reproduce the issue in a separate environment that I am able to access, I would be more than happy to help you look.

    Plugin Author Matt Keys

    (@mattkeys)

    Andeh86,

    There is a new version of the plugin out today that resolves this issue.

    Thanks,

    Matt

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘loading bar doesnt move’ is closed to new replies.