Skip to:
Content
Pages
Categories
Search
Top
Bottom

Show custom activity in stream


  • Mr3k
    Participant

    @mr3k

    Hello,

    I’ve managed to create custom activities. I used the following code in functions.php:

    function add_news_to_activity(){
        bp_activity_add( array(     
            'action' => '<a href="https://www.google.se/?q=Fishes">Fishes</a>',
            'content' => 'This also contains the content',
            'component' => 'news',
            'primary_link' => '<a href="https://www.google.se/?q=Fishes">Fishes</a>',
            'type' => 'new_news_item',
            'hide_sitewide' => false
        ));
    }

    I can see this adds the item to the activity table in the database – awesome!

    Now I want this item also to be shown in the Activity stream. I use the theme Socialize and their shortcode for activity. I can then chose the scope between “just-me”, “friends”, “groups”, “favorites”, “mentions”. However, my news items aren’t shown and I don’t know how I can make it visible. What is the scope when creating a custom activity like this?

    Thanks in advance!

Viewing 1 replies (of 1 total)

  • djsteveb
    Participant

    @djsteveb

    @mr3k – I assume “their shortcode for activity” this has to do with the paid version of said theme.. and if you are trying to get something to work with a paid theme, then you are likely not going to get any help in the bp forums from what I have seen over the years.

    I wish you luck. Modding the activity stream in bp is such a pain point.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.
Skip to toolbar