[Support request] GP hooks timeout

Home Forums Support [Support request] GP hooks timeout

Home Forums Support GP hooks timeout

Viewing 15 posts - 1 through 15 (of 16 total)
  • Author
  • #358721

    I’m having some really frustrating problems with this theme. Pages are slow to load, and according to Safari’s Web Inspector, it’s javascript that is taking about 6 seconds to run before anything starts loading. I found that there was a Jetpack issue with a font, and I fixed that, but it hasn’t made much of a difference.

    Related is a problem with the GP Hooks page. I’m unable to save anything. I get a timeout with this error in the inspector:

    XMLHttpRequest cannot load http://www.kirkville.com/wordpress/wp-admin/admin-ajax.php due to access control checks.

    I’ve Googled this, and it is apparently not uncommon, and I’ve tried one of the solutions offered – something about a Heartbeat API – but that does nothing. As it stands, I’m unable to use the GP hooks, and the site overall is simply not as fast as it should be.


    GP Premium 1.3.1
    Customer Support

    Hi there,

    Sorry about your experience so far. GP should definitely be light and fast.

    Can you please disable all non-GP plugins to see if it fixes the problem for the hook?

    Let us know. Thanks!


    No, that doesn’t change anything.

    Load the page and check in Safari’s or another web inspector. There are all sorts of spots in the timeline where styles are invalidated and recalculated. What does all that mean?

    As for the error coming from the GP Hooks page, that seems to be something to do with too many ajax calls, but I don’t really understand that.

    Customer Support

    I have forwarded to Tom to have look 🙂

    Lead Developer
    Lead Developer

    For overall front-end page speed, it looks like the issue is your hosting: https://tools.pingdom.com/#!/4X3a7/http://www.kirkville.com/

    Check out file requests. The big yellow bar is how long it’s taking your server just to connect (“waiting”). The actual receiving of data is super fast.

    The next slowest parts are your Amazon ads.

    As for GP Hooks – there’s no AJAX required for GP Hooks to work at all. However, many parts of the WP Dashboard rely on AJAX. Again, I’m willing to bet there’s hosting/server issues causing these issues.

    Do you have another server to test on?


    No, I don’t have another server. However, I have a staging server on the same host (staging.mcelhearn.com), and the hooks work perfectly there. So it’s not my hosting; nor is it my hosting for the general wait at the beginning of the page load, because on the staging server – without several plugins – it runs very fast.

    I just tried again, deactivating all plugins. The Hooks feature works. Then when I activate Jetpack, it fails. So there’s something going on with Jetpack. I would expect that, of all the many plugins, this theme be compatible with Jetpack, because many people use it (notably for VaultPress backups).

    Also, everything on the dashboard is very slow with this theme.

    Lead Developer
    Lead Developer

    So when you activate Jetpack on the staging server, do you get the same issues?

    I personally use VaultPress here on this site with no issues. Many people use Jetpack with GP with no issues as well – it could very well be a server configuration not playing well with Jetpack on your site.

    GP doesn’t add any resources to your dashboard, except in “Appearance > GeneratePress” and “Appearance > GP Hooks”, so those are the only two pages it could actually slow down.


    I just added Jetpack to the staging server. I can’t replicate the exact same setup, since on the production server I have Jetpack Premium, so I set it up with the free version.

    The same thing happens; when I add something to Hooks, it times out.

    So, how can we debug this? The Hooks feature is very useful to me, to add some code – Google Analytics and Amazon ads – and not have to mess around with the .php files. I’d like to be able to use it. As I mentioned earlier, this is the error I get in Safari’s Web Inspector:

    XMLHttpRequest cannot load http://staging.kirkville.com/wp-admin/admin-ajax.php due to access control checks.

    I would assume you have an idea what that means; I certainly don’t.


    There’s some stuff here on Stack Exchange, but, again, I don’t quite understand it, and, when there are several solutions offered, I’m not sure which is safest:


    Lead Developer
    Lead Developer

    Try this solution: https://wordpress.stackexchange.com/a/248729/90661

    Add it using these instructions: https://docs.generatepress.com/article/adding-php/

    These kinds of errors usually happen when the URL you’re visiting (in your browser bar), doesn’t match the URLs you have set in “Settings > General”.

    For example, if my URLs in “Settings > General” are:


    But the site I’m visiting is:

    https://tomusborne.com (with the added s to http)

    I can get access controls errors.


    Nope, not working.

    FWIW, my WordPress address is:


    But the site address is:


    Could that be the problem?

    Lead Developer
    Lead Developer

    That is likely the problem.

    There’s probably workarounds you can add to your .htaccess file, but I would suggest moving your WP installation into the root of your site instead of it being a “wordpress” folder. If you contact your hosting, they might be able to help you make that change.


    I can’t do that. I have a number of sites on the server, and each needs to be in its own folder.

    So if the code you suggested above doesn’t work, is there a modification to it that will work?

    Lead Developer
    Lead Developer

    You could try adding this to your .htaccess file:

    <IfModule mod_headers.c>
       Header add Access-Control-Allow-Origin: *

    This kind of stuff is pretty advanced though, so you might be better off contacting your hosting support and asking what they think the best method to resolve this would be.


    Nope, that doesn’t work either.

    Frankly, I find it a bit odd that you don’t have a solution for this. It’s not like it’s odd for people to have a WordPress blog point to a folder on a domain. I have three clients for whom I write who have blogs at .com/blog/

    And I can’t really ask my host how to fix this, because I don’t really understand what “this” is. I don’t understand what the error is and why your theme is causing it.

Viewing 15 posts - 1 through 15 (of 16 total)
  • You must be logged in to reply to this topic.