Skip to:
Content
Pages
Categories
Search
Top
Bottom

Query/Call @mentions List


  • alanchrishughes
    Participant

    @alanchrishughes

    If you wanted to create a unique page that includes a list of your @mentions like on the actual mentions page, would that be possible somehow? I’ve never been able to figure out how Buddypress calls up each list, I’m pretty sure it’s magic.

Viewing 9 replies - 1 through 9 (of 9 total)

  • Virtuali
    Participant

    @gunju2221

    If you want to have it on a different page, just change the permalink on the profile to something different, or “URL”. This may help. https://codex.buddypress.org/extending-buddypress/customizing-labels-messages-and-urls/


    alanchrishughes
    Participant

    @alanchrishughes

    @Virtuali @gunju2221 I’m not trying to change the URL of the page it is already on, I am wanting to put it on an additional page.


    alanchrishughes
    Participant

    @alanchrishughes

    Any ideas? I’m sure it won’t be as easy as WordPress and querying things like

    ?php query_posts(“category_name=?php echo bp_loggedin_user_domain()@mentions”);
    ?php while (have_posts()) : the_post();

    but is there anything similar?


    Paul Wong-Gibbs
    Keymaster

    @djpaul

    Nothing magical. It’s the regular activity stream loop (look in /activity/activity-loop.php if you need a reference). In your call to bp_has_activities(), set ‘scope’ to ‘mentions’. This may need some trial and error, but like this:

    `if ( bp_has_activities( ‘scope=mentions’ ) )`


    alanchrishughes
    Participant

    @alanchrishughes

    Thanks @djpaul

    Do you know how you would write that to include favorites also?


    alanchrishughes
    Participant

    @alanchrishughes

    I’ve tried a few obvious things like

    if ( bp_has_activities( ‘scope=mentions&favorites’ ) )


    Paul Wong-Gibbs
    Keymaster

    @djpaul

    Scope has to be a single keyword at the moment. This sounds like a good enhancement request; could you post on https://trac.buddypress.org/, using your username and password from this site? Thanks.


    alanchrishughes
    Participant

    @alanchrishughes

    @djpaul will do. Do you know any other way of accomplishing this? Ultimately my goal is just to have all activity stream through one page (everything but the activity of your friends).

    PS: https://buddypress.trac.wordpress.org/ticket/3192

    nothing here either !??!

    using the if ( bp_has_activities( ‘scope=mentions’ ) ) is messing up the load function on the bottom by the way … so if you click on load, all the already loaded actions will be loaded again … 2 times, 3 times, n times, as many times you click on “load” :-(

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Query/Call @mentions List’ is closed to new replies.
Skip to toolbar