Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Single group activites help – Buddypress
- This topic has 9 replies, 2 voices, and was last updated 7 years ago by
mahinur.
-
AuthorPosts
-
May 10, 2019 at 11:30 am #22535
mahinur
ParticipantHi,
I need help. Please go to this link http://nabetalk.16mb.com/groups/washington-heights/ And see there has a search field of ajax pro plugin.
The search field is showing us all the results of all single group page activities.
But we want a result only for a specific single group page.
That means we have 3 groups.
1: WASHINGTON HEIGHTS
2: HUDSON HEIGHTS
3: INWOODAnd we’ll have different different post in our 3 groups. but for users, we don’t want to show them all the search results of 3 single group page’s activities.
Suppose you go to this page http://nabetalk.16mb.com/groups/washington-heights And only we want to show you search results of this group(WASHINGTON HEIGHTS) only.
Do you understand what I mean? I want to show my visitors only spesific single group activities results. Don’t show them multiple groups result.
And other things,
Group posts are going to members, events & etc.
But I want to show in my group home/activities. Like it’s going to this page http://nabetalk.16mb.com/members/admin/wall/151/
But that should be shown in the single group page.So please let me know about it also.
Thanks,
MahinurMay 10, 2019 at 11:38 am #22537mahinur
ParticipantIf you want to change any setting of shortcode, please use it. see my attachment. Because this one for only my all groups.
May 10, 2019 at 11:39 am #22539mahinur
ParticipantAlso, I used that shortcode here.
I hope my information will help you and you can help me fast 🙂
May 10, 2019 at 12:59 pm #22542Ernest Marcinko
KeymasterHi,
Well this might be possible, but only by making core changes to one of the plugin files, as well as using a custom code. Please follow the instcutions below:
1. Add this custom code to the functions.php in your theme/child theme directory. Before editing, please make sure to have a full site back-up just in case!
add_action('asp_layout_in_form', 'asp_add_bp_group_id', 10, 1); function asp_add_bp_group_id() { $guid = @bp_get_group_id(); if ( !empty($guid) ) echo "<input type='hidden' name='bp_group_id' value='$guid'>"; }2. Then replace the wp-content/plugins/ajax-search-pro/includes/classes/search/class-asp-search-buddypress.php file contents on your server with this.
Save the files, and reload the page. The results should be limited to the currently open group. This solution may not work in all cases though.
May 10, 2019 at 1:07 pm #22544mahinur
ParticipantSure, let me do this. And i have backup my site 🙂
May 10, 2019 at 1:40 pm #22545mahinur
ParticipantBut not working…
here is no post. But showing all group posts.
Please take a look again.
May 10, 2019 at 9:00 pm #22563mahinur
ParticipantPlease let me know i’m waiting for your response
May 10, 2019 at 9:34 pm #22565mahinur
ParticipantHey,
One thing need to note: I see the posts are working. But showing events for all groups. And showing the post just for a specific group.
so now for events what can i do?
Please let me know.
Thanks
May 13, 2019 at 9:53 am #22583Ernest Marcinko
KeymasterHi,
I re-checked the code, but based on the bp database it should be the correct solution, so I honestly don’t know what exactly is wrong here. The ‘item_id’ column should be the foreign key to the group related to the activity, as far as I was able to tell.
Please let me know if you know anything about this, and I will try to update the code accordingly. Unfortunately I cannot guarantee customizations to work in all cases.May 13, 2019 at 10:08 am #22587mahinur
ParticipantOkay, I found the problem, maybe database problem of that group. because for the test I create some multiple groups. all are work perfectly.
So now please check my another ticket, and try to reply
thanks
-
AuthorPosts
- You must be logged in to reply to this topic.