Skip to:
Content

BuddyPress.org

Changes between Initial Version and Version 1 of Ticket #5687, comment 3


Ignore:
Timestamp:
06/07/2014 02:23:02 PM (12 years ago)
Author:
slaFFik

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #5687, comment 3

    initial v1  
    22
    33And now regarding the situation I have.
    4 Using `bp_activity_type_tabs` action I add tabs (`<li><a></a></li>`). Javascript in BuddyPress works in that way, that if that `<li>` has and `<id>` attribute - its second part (after `-`) will be converted to scope, and the first one is treated as object. So in my case I add `<li id="activity-whatever">...` there. And js sends a POST on clicking the tab with the scope=whatever. After that I'm adding a filter to `bp_ajax_querystring` with a relatively low priority (in my case 99) and modify the `bp_has_activities()` arguments like I need. That's the whole magic :)
     4Using `bp_activity_type_tabs` action I add tabs (`<li><a></a></li>`). Javascript in BuddyPress works in that way, that if that `<li>` has and `<id>` attribute - its second part (after `-`) will be converted to scope, and the first one is treated as object. So in my case I add `<li id="activity-whatever">...` there. And js sends a POST on clicking the tab with the `scope=whatever`. After that I'm adding a filter to `bp_ajax_querystring` with a relatively low priority (in my case 99) and modify the `bp_has_activities()` arguments like I need. That's the whole magic :)
    55
    66But as I found out, load more and heartbeat ignores that js (rather handy) behaviour.