• Hello, I have a problem, I want to use the plugin BuddyPress Docs but the button is not attaching the file, however in a local installation it works but not on a web server, could you help me or if someone had the same problem could you give me a solution please, thanks in advance.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author David Cavins

    (@dcavins)

    Hi, It’s possible that your host has disabled the WordPress heartbeat protocol (like at SiteGround, WP Engine and other hosts), or an “optimization” plugin has shut down heartbeat, which breaks BP Doc’s JavaScript code. You can read about that issue and try a code fix that is included here: https://github.com/boonebgorges/buddypress-docs/issues/704

    If this is the issue and the code fix solves the problem or not, please let us know.

    Thanks!

    Thread Starter jesusp86

    (@jesusp86)

    Hello, I come with the same problem with BP Doc, I had not been able to respond before because we were waiting for a response from Siteground, the server where we have hosted our website.

    We applied the code solution that you passed and the problem still persists, it does not allow to attach a document for both groups and users, we communicated with the service provider and they told us that there is an error in a JavaScript plugin, I will send a capture of the message that Siteground sent us to verify yourselves the error.

    https://prnt.sc/FDWywQRGrV1M

    Plugin Author David Cavins

    (@dcavins)

    Ha, yes, so it is Siteground. Yep, the issue is BP Docs’ use of WP’s Heartbeat script, which Siteground dequeues globally.

    Just to be sure, can you verify that your version of buddypress-docs/includes/component.php matches this snapshot of the file exactly? https://github.com/boonebgorges/buddypress-docs/blob/ea09b22caaeb41d3c8276a43807d8cb6456349ef/includes/component.php

    Thanks!

    Thread Starter jesusp86

    (@jesusp86)

    Yes, I just checked it and to be sure I copied the code and it is exactly the same but it still does not allow to attach documents.

    Plugin Author David Cavins

    (@dcavins)

    Huh. Can you look at the page code and see if bp-docs.js and heartbeat.js are being included? These script tags looks something like:

    <script src="https://bpdocstest.local/wp-includes/js/heartbeat.js?ver=6.0.1" id="heartbeat-js"></script>
    <script src="https://bpdocstest.local/wp-content/plugins/buddypress-docs/includes/js/bp-docs.js?ver=6.0.1" id="bp-docs-js-js"></script>

    Thread Starter jesusp86

    (@jesusp86)

    You tell me that I should go to this directory? https://prnt.sc/NQgDhgzTNMrR however the heartbeat.js file is not included.

    Plugin Author David Cavins

    (@dcavins)

    Hi,

    I was asking, if, on your doc edit page, those assets were being included in the source code of the page.

    Thanks!

    Thread Starter jesusp86

    (@jesusp86)

    Hi, they were not there, I included them and the result is the same ??

    Thread Starter jesusp86

    (@jesusp86)

    Hi, what solution can you give me, I made the changes you mentioned and still the problem remains, does not open the window to choose a document and attach it in the groups and users, is it possible to make an update of the plugin and adapt it to siteground?

    Plugin Author David Cavins

    (@dcavins)

    The changes suggested have worked for other users of hosts that disable the WP Heartbeat API. I’m not sure what to tell you if that doesn’t also work for Siteground. They have software engineers that specialize in WP (that are also familiar with Siteground’s inner customizations, which I am not); what do they think the answer should be?

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Attach button does not work’ is closed to new replies.