BuddyDev

Search

[Resolved] how do I show full posts on the profile feed without 'read more'?

  • Participant
    Level: Enlightened
    Posts: 26
    Peter Fae on #13908

    hey. I’d like to show the full post on the profile feed, removing the excerpts and read more.

    what would be the way to do that?

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #13912

    Hi Peter,
    For the activity, Please see the code here.
    https://buddydev.com/buddypress/buddypress-activity-without-read-more/

    Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 26
    Peter Fae on #13914

    Thank You for responding Brajesh. Unfortunately,t he code did not work.

    Would You please use the supporthero login that I gave You and let me know what I have done incorrectly? I placed it into the Custom CSS portion of my Customizer.

    When that did not work, I attempted to put the code in a bp-custom.php file, which I had placed in the ‘plugins’ folder of my SFTP, yet this produces a showing of the code at the top of my dashboard and front-end, which is obviously incorrect.

    When I place the code in the Customizer, I get no additional line, yet the ‘read more’ on both the activity feed and the profile feeds remains.

    As minor of an issue as this is, it actually plays out strongly for my site. Getting this dialed is KEY to our presentation as we want a smooth flow of entries for Readers to peruse the content of the Authors. As part of the concept, we are using an SEO plugin which auto-hyperlinks certain words. When the Ajax of Buddypress ‘unfolds’ the entry with the ‘read more’ it erases those links in the reformat.

    Regardless, the ideal is a reading experience for users in which they may smoothly witness the unfoldment of the Story told by the Authors on their profiles, so I wish to remove the ‘read more’.

    Thank you so much for your support. In this as well as the other thread on mediapress.

  • Participant
    Level: Enlightened
    Posts: 26
    Peter Fae on #13916

    Ah. I see. I needed to put that code into the function.php of my child theme. I’ve figured it out. Thank you so much Brajesh. The quick support truly moves me in the direction of working more deeply with Buddydev, buying plugins and the support. You are most kind.

    Question. How can we show the ‘read more’ on the Activity feed, yet not on the Profile feed?

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #13917

    Thank you for the kind words Peter.

    You can use the updated function like this

    
    /**
     * Show all activity content instead of the trimmed content with read more.
     */
    function buddydev_show_all_activity_content() {
    	if ( bp_is_user() ) {
    		remove_filter( 'bp_get_activity_content_body', 'bp_activity_truncate_entry', 5 );
    		remove_filter( 'bp_get_activity_content', 'bp_activity_truncate_entry', 5 );
    	}
    }
    
    add_action( 'bp_init', 'buddydev_show_all_activity_content' );
    add_action( 'bp_activity_sent_reply_to_reply_notification', 'buddydev_show_all_activity_content' );
    
    

    Hope this helps.

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #13946

    Hi Peter,
    Can you please confirm if the above code worked?

    Best Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 26
    Peter Fae on #13949

    mmm … first off, You guys are AMAZING. We’re definitely going further with buddydev and looking into more plugins and all that as a result of this excellent service. It is REALLY appreciated.

    You know, that code caused a whiteout on my screen. The other one, once we fixed the issue with the bp-custom.php file syntax, is working. The revolution slider is appearing at the top of the activity feed, which his awesome.

    What I’m wondering, is how to make it fit on the *TOP* of the screen, just below the masthead, yet *above* the sidebar and the content container. Like, above where it is now

    https://intothemythica.com/activity-streams/

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #13962

    Hi Peter,
    Thank you.

    Can you please point what you want to accomplish on the page by marking a screenshot and linking me.

    Thank you
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 26
    Peter Fae on #13967

    Okay. So I consulted the people at X-Theme as well as BuddyDev and this was our exchange regarding –

    PETER_FAE
    14h
    a bit confused at this. I only want the revolution slider BELOW the masthead on the ‘Activity-Streams’ page of buddypress, not all over the place. I’ve already got the post carousel for that.

    as I copy over the wp-header.php file how to specify that it works with the Activity page?

    Along those lines, can I change the slider for specific profile pages in buddypress as well?

    Secure Note

    CHRISTIAN_Y
    Staff
    5h
    Hey @Peter_Fae,

    Please disregard the previous advice. To output custom content in above the masthead, you can hook to x_after_site_begin action. The next thing is to detect if the page is an activity page and display your slider in the area using the do_shortcode function and your slider’s shortcode. Regretfully, the bp_is_activity conditional of BuddyPress does not seam to work so you will need to hire a third party developer who is an expert in BuddyPress or contact BuddyPress support to know what is the correct conditional. The code should look like this.

    ‘add_action(‘x_after_site_begin’, ‘slider_above_activity’);

    function slider_above_activity() {
    if ( bp_is_activity() ) {
    echo do_shortcode(‘[rev_slider alias=”gym-classes”]’);
    }
    }’

    my *intention* is to understand how to put a slider *below* the masthead, like in this example –> https://www.intothemythica.com

    The code You gave me is awesome. It puts a slider right at the top of the activity feed within the container, next to the sidebar, as seen here –> https://intothemythica.com/activity-streams/

    what I would like are TWO things. One, I’d like to know how to put the slider *above* the container and sidebar, like in this example –> https://intothemythica.com/akasha/ (rather than within the container and next to the sidebar), yet below the masthead.

    Two, I’d like to know how to put a slider on the Profile page like we did on the Activity page, *within* the container and next to the sidebar.

    It’s like this … I want the Activity page to have a BIG slider that sits above the sidebar/content container, yet below the masthead. And I want to put a slider *in* the container and *next* to the sidebar on the PROFILE pages, so. big for Activity feed above, smaller and in container for Profile. That way I can put an Author-specific slider on the Profile page for that Authors, and a general, big slider above the Activity feed.

    I am learning very, very much from our dialogues and the excellent support that You are providing.

    does that make sense?

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #14082

    Hi Peter,
    I am marking it as resolved as it dealt with the original issue.

    For your last question, let us continue discussion at
    https://buddydev.com/support/forums/topic/how-to-add-shortcode-to-top-of-activity-feed/

    Thank you
    Brajesh

The topic ‘ [Resolved] how do I show full posts on the profile feed without 'read more'?’ is closed to new replies.

This topic is: resolved