This topic has 37 replies, 5 voices, and was last updated 5 years by contemplate.

  • Author
  • #40953
     valuser
    Participant

    Have your fix ( from https://archived.seventhqueen.com/forums/topic/buddypress-whats-new-options-ajax-no-show-on-one-server) operating.

    But NO activity comments can be made.

    This only happens on one host – wpengine.

    Your theme works perfectly on other hosts.

    Another fix would be hugely appreciated!!!

    #41113
     valuser
    Participant

    The fix you kindly provided allows the top activity “What’s new?, Joe” box to function properly

    But comments can’t be made.

    Both “Allow comments” & “Allow trackbacks and pingbacks on this page.” are checked.

    Unchecking them makes no difference.

    Again, all this is only on one server.

    #41167
     sharmstr
    Moderator

    This is not a theme issue, just to be clear. The way I figured out the first fix was to compare the all the scripts that should be loaded against the scripts that are being loaded, then loaded the missing scripts via the add_action function. You can do the same by viewing the source code generated on the demo site to the source code generated on your site. Or get wpengine to fix their servers. You can switch to a theme that comes standard with WP so they can’t say its “theme related”.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41184
     valuser
    Participant

    Fully aware that this is not a theme issue – as (as stated) all is OK on other servers and on localhost xampp.
    So, I’m not in any way suggesting that seventhqueen is “responsible”.
    Frankly wpengine’s support is not what it should be.
    They have suggested it is “buddypress” related which is nonsense given that i can use this setup on very very cheap shared hosting.
    Perhaps, like some hosts, they would really like buddypress users to go elsewhere!!
    Wil try to examine it as you have suggested. and will come back

    #41189
     sharmstr
    Moderator

    I wasn’t accusing you of blaming Kleo. Just making it clear for others. Kleo gets blamed for a lot of problems 🙂

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41227
     valuser
    Participant

    no problem.

    Now, if possible bear with me on this.

    First cursory comparison: the file at mydomain/wp-includes/js/heartbeat.min.js?ver=4.1 is not being loaded to the unresponsive site while it is being loaded to the “good” site on the “good” server.

    the missing bit (thats not on the “bad” server) is

    COPY CODE
    <script type="text/javascript">
    /* <![CDATA[ */
    var heartbeatSettings = {"ajaxurl":"\/wp-admin\/admin-ajax.php","nonce":"ef57d07069"};
    /* ]]> */
    </script>
    <script type="text/javascript" src="http://mydomain.com/wp-includes/js/heartbeat.min.js?ver=4.1"></script>

    Could that possibly be relevant ??

    /**
    * Heartbeat API
    *
    * Heartbeat is a simple server polling API that sends XHR requests to
    * the server every 15 – 60 seconds and triggers events (or callbacks) upon
    * receiving data. Currently these ‘ticks’ handle transports for post locking,
    * login-expiration warnings, autosave, and related tasks while a user is logged in.

    If not I will do a detailed comparision, hopefully, tomorrow.

    #41241
     sharmstr
    Moderator

    I doubt it has anything to do with the heartbeat, but I dont know for sure. You’ll have to test it for yourself. We cant test because we dont have sites on WPEngine.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41242
     sharmstr
    Moderator

    On second thought, it might? But the heartbeat is an api that allows you to do polling for new events and such. Being able to comment on something doesnt really fit that scenario. WPEngine might have disabled that since it does slow down servers. There’s tons of posts about it.

    Again, you can test by forcing it to load.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41297
     valuser
    Participant

    added
    wp_enqueue_script( 'heartbeat_js', get_template_directory_uri() . '/wp-includes/js/heartbeat.min.js', array(), '4.1', true );
    to your function but it did not have the desired effect.

    then added
    <script type="text/javascript" src="<?php bloginfo('template_url'); ?>/wp-includes/js/heartbeat.min.js?ver=4.1"></script>
    to header.php but but it also did not have the desired effect.

    If i haven’t done this properly please let me know.

    (btw the undeclared crippling of a core file by a wordpress host is an issue in itself!!!!!!)

    so i presume i will now have to do a very detailed comparison of the source files of two sites on different hosts

    #41300
     valuser
    Participant

    ok so far – just a more complete rendition of what is missing in the “bad” server compared to a similar setup on a “good” server.
    immediately following the heartbeat line is also missing —–
    <script type=”text/javascript”>var BP_DTheme{}</script>

    COPY CODE
    <script type="text/javascript">
    /* <![CDATA[ */
    var heartbeatSettings = {"ajaxurl":"\/wp-admin\/admin-ajax.php","nonce":"1d1a7d444d"};
    /* ]]> */
    </script>
    <script type="text/javascript" src="http://mydomain.com/wp-includes/js/heartbeat.min.js?ver=4.1"></script>
    <script type="text/javascript">
    /* <![CDATA[ */
    var BP_DTheme = {"accepted":"Accepted","close":"Close","comments":"comments","leave_group_confirm":"Are you sure you want to leave this group?","mark_as_fav":" ","my_favs":"My Favorites","rejected":"Rejected","remove_fav":" ","show_all":"Show all","show_all_comments":"Show all comments for this thread","show_x_comments":"Show all %d comments","unsaved_changes":"Your profile has unsaved changes. If you leave the page, the changes will be lost.","view":"View","newest":"Load Newest","pulse":"15"};
    /* ]]> */
    </script>

    Whe i googled var BP_DTheme the first result is a three year old thread https://buddypress.org/support/topic/comments-are-not-working/ which must mean i’m getting closer!!

    Please understand I just haven’t any great clue about this stuff but would greatly appreciate any help that you van give

    #41322
     valuser
    Participant

    put the above into header.php – no improvement

    #41390
     valuser
    Participant

    I now have examined two (almost) identical sites on different servers.

    The differences (in regard to javascripts) are as follows:

    The five scripts put into functions.php – as per your advice – are coming in to the “bad” server (wpengine) like this: (with the wp version 4.1 not the bp version 2.1.1 as in the “good” server (bluehost).)

    COPY CODE
    <script type='text/javascript' src='http://dogdrill.com/wp-content/plugins/buddypress/bp-core/js/jquery-query.min.js?ver=4.1'></script>
    <script type='text/javascript' src='http://dogdrill.com/wp-content/plugins/buddypress/bp-core/js/widget-members.min.js?ver=4.1'></script>
    <script type='text/javascript' src='http://dogdrill.com/wp-content/plugins/buddypress/bp-core/js/jquery-cookie.min.js?ver=4.1'></script>
    <script type='text/javascript' src='http://dogdrill.com/wp-content/plugins/buddypress/bp-core/depreciated/js/jquery-scroll-to.min.js?ver=4.1'></script>
    <script type='text/javascript' src='http://dogdrill.com/wp-content/themes/kleo/buddypress/js/buddypress.min.js?ver=4.1'></script>

    AND

    only on the good server this (the “heartbeat” file) comes in:

    COPY CODE
    <script type='text/javascript'>
    /* <![CDATA[ */
    var heartbeatSettings = {"ajaxurl":"\/wp-admin\/admin-ajax.php","nonce":"3ca3c1a148"};
    /* ]]> */
    </script>
    <script type='text/javascript' src='http://www.rvews.com/wp-includes/js/heartbeat.min.js?ver=4.1'></script>
    <script type='text/javascript'>
    /* <![CDATA[ */
    var BP_DTheme = {"accepted":"Accepted","close":"Close","comments":"comments","leave_group_confirm":"Are you sure you want to leave this group?","mark_as_fav":" ","my_favs":"My Favorites","rejected":"Rejected","remove_fav":" ","show_all":"Show all","show_all_comments":"Show all comments for this thread","show_x_comments":"Show all %d comments","unsaved_changes":"Your profile has unsaved changes. If you leave the page, the changes will be lost.","view":"View","newest":"Load Newest","pulse":"15"};
    /* ]]> */
    </script>

    this is not to be seen on the “bad” server.

    Any help at all very much appreciated

    #41392
     sharmstr
    Moderator

    All of your info is confusing. Can you give me a link to the bad site so I can see what you are talking about?

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41393
     sharmstr
    Moderator

    Also include a test account so I can log in.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41394
     valuser
    Participant
    This reply has been set as private.
    #41405
     sharmstr
    Moderator

    Sorry for not wanting to search for login info. Very busy. Will get back to you.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41406
     valuser
    Participant

    no problem. i’ll leave it with you. thanks

    #41407
     sharmstr
    Moderator

    I was able to post a comment on an activity.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41411
     sharmstr
    Moderator

    Also, I believe that the reason the page is jumping to the top when you click comment is because your site is throwing a 404 error on /wp-content/plugins/buddypress/bp-core/deprecated/js/jquery-scroll-to.min.js

    That should fix everything.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41413
     valuser
    Participant

    because your site is throwing a 404 error on /wp-content/plugins/buddypress/bp-core/deprecated/js/jquery-scroll-to.min.js

    That should fix everything.

    ? how?

    #41415
     sharmstr
    Moderator

    404 means it doesnt exist. Make sure it exists.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41417
     valuser
    Participant

    i have changed “depreciated” to “deprecated”

    #41418
     sharmstr
    Moderator

    🙂

    Okay. So to help everyone else that might have this issue, what did you end up doing to make it work, beyond what I did months ago?

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #41419
     valuser
    Participant

    ok the solution is at

    https://archived.seventhqueen.com/forums/topic/attachment-and-post-buttons-for-whats-new-posts-on-groups-were-hidden

    add this to your functions.php

    add_action( 'wp_enqueue_scripts', 'load_buddypress_js' );
    function load_buddypress_js () {
    if (bp_is_group() || is_page( 'activity' )) {
    wp_enqueue_script('buddypress_query',plugins_url() . '/buddypress/bp-core/js/jquery-query.min.js',array("jquery"));
    wp_enqueue_script('buddypress_members',plugins_url() . '/buddypress/bp-core/js/widget-members.min.js',array("jquery"));
    wp_enqueue_script('buddypress_cookie',plugins_url() . '/buddypress/bp-core/js/jquery-cookie.min.js',array("jquery"));
    wp_enqueue_script('buddypress_scroll',plugins_url() . '/buddypress/bp-core/depreciated/js/jquery-scroll-to.min.js',array("jquery"));
    wp_enqueue_script('buddypress_js',get_template_directory_uri() . '/buddypress/js/buddypress.min.js',array("jquery"));
    }
    }

    BUT BUT BUT BUT

    PLease be sure to replace “depreciated” with “deprecated” !!!!!!!!!

    #41420
     valuser
    Participant

    ok the solution is at

    https://archived.seventhqueen.com/forums/topic/attachment-and-post-buttons-for-whats-new-posts-on-groups-were-hidden

    add this to your functions.php

    COPY CODE
    add_action( 'wp_enqueue_scripts', 'load_buddypress_js' );
    function load_buddypress_js () {
    if (bp_is_group() || is_page( 'activity' )) {
    wp_enqueue_script('buddypress_query',plugins_url() . '/buddypress/bp-core/js/jquery-query.min.js',array("jquery"));
    wp_enqueue_script('buddypress_members',plugins_url() . '/buddypress/bp-core/js/widget-members.min.js',array("jquery"));
    wp_enqueue_script('buddypress_cookie',plugins_url() . '/buddypress/bp-core/js/jquery-cookie.min.js',array("jquery"));
    wp_enqueue_script('buddypress_scroll',plugins_url() . '/buddypress/bp-core/deprecated/js/jquery-scroll-to.min.js',array("jquery"));
    wp_enqueue_script('buddypress_js',get_template_directory_uri() . '/buddypress/js/buddypress.min.js',array("jquery"));
    }
    }
    #45318
     troy7890
    Participant

    Thanks for this info – however adding this scripts to my functions did not change the problem with making the “What’s New Submit” button visible for me on my group’s pages. I suspect it’s a css positioning issue because I can make it partly visible with some tweaks to #buddypress #whats-new-options. I will post a private reply with my login info, thanks.

    Attachments:
    You must be logged in to view attached files.
    #45320
     troy7890
    Participant
    This reply has been set as private.
    #45321
     sharmstr
    Moderator

    Credentials dont work. Do a search on here for the css to fix your problem. Its been discussed.

    Love the color combos on the site. Looks great!

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #45324
     troy7890
    Participant
    This reply has been set as private.
    #45333
     sharmstr
    Moderator

    Your wp-content/plugins/buddypress-media/app/assets/css/main.css isn’t loading. That puts a float: left on the attach files button which will allow the post update button to display inline.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #45342
     troy7890
    Participant

    Thanks for taking a look
    I wonder if this is related to me prematurely updating to BuddyPress 2.2.0 ?
    I honestly did that update on accident – I did know better but things like that happen once in a blue moon.

    Anyways, any tips to forcing the main.css file to load would be appreciated.

    #47045
     troy7890
    Participant

    FYI
    I was able to get the submit button on the activity page to display by disabling the “Allow upload from activity stream” option in the rtMedia – Buddypress options page.

    Having that option enabled was pushing down the “post update” button off screen.

    Just something to note.

    #47296
     sharmstr
    Moderator

    You’re just putting a band-aid on it. You’re not fixing the real issue which is wp-content/plugins/buddypress-media/app/assets/css/main.css not loading.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #47305
     troy7890
    Participant

    I understand that, but what I don’t know is what is causing this .css file to not load.
    To test for conflicts, I have disabled the non-packaged plugins but that did not make a difference in the file not loading.

    I’ve provided admin access above, if possible, please investigate this issue.
    Thanks.

    #71561
     tylerjohnson
    Participant

    Just wanted to comment and say, thank you valuser! I’m on WPEngine as well and this fixed my issue.

    COPY CODE
    add_action( 'wp_enqueue_scripts', 'load_buddypress_js' );
    function load_buddypress_js () {
    if (bp_is_group() || is_page( 'activity' )) {
    wp_enqueue_script('buddypress_query',plugins_url() . '/buddypress/bp-core/js/jquery-query.min.js',array("jquery"));
    wp_enqueue_script('buddypress_members',plugins_url() . '/buddypress/bp-core/js/widget-members.min.js',array("jquery"));
    wp_enqueue_script('buddypress_cookie',plugins_url() . '/buddypress/bp-core/js/jquery-cookie.min.js',array("jquery"));
    wp_enqueue_script('buddypress_scroll',plugins_url() . '/buddypress/bp-core/deprecated/js/jquery-scroll-to.min.js',array("jquery"));
    wp_enqueue_script('buddypress_js',get_template_directory_uri() . '/buddypress/js/buddypress.min.js',array("jquery"));
    }
    }
    #71562
     sharmstr
    Moderator

    That’s old code and its been updated to work with newer versions of BP. Please see the Kleo documentation: https://archived.seventhqueen.com/documentation/kleo#wp-engine

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    This support site is not about custom work. If you need custom development please contact cornel@seventhqueen.com

    #71563
     tylerjohnson
    Participant

    Thanks! I updated it to the new code.

    #202505
     contemplate
    Participant

    In case anyone is still having this issue on WP Engine after this fix we found we had to disable the following in Buddypress:

    goto Settings -> Buddypress
    on the Options tab
    disable “Activity auto-refresh”

Viewing 38 posts - 1 through 38 (of 38 total)

The forum ‘KLEO’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?