#6478 closed defect (bug) (worksforme)
Comment tracking between blog posts and SWA
Reported by: | shanebp | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Blogs | Keywords: | reporter-feedback |
Cc: | shane@… |
Description
This is a follow-up to #6306.
WP 4.2.2, BP 2.3.0, no other plugs enabled, theme: 2013
Site Tracking is enabled.
Blog & Forum Comments is enabled.
After publishing a standard post:
- a SWA item is created
- comments made on that SWA item appear in the comments on the post page
- comments made on the post page Do Not appear in the SWA for that item
Is the last item a bug? Since the sync is only one way?
From #6306
Since BuddyPress 2.0, when activating the option 'Allow activity stream commenting on blog and forum posts'. The comments made on regular post or on the activity of this post are synced. Meaning commenting an activity generates a comment and vice versa.
[Once this is settled, I have some questions about CPT issues.]
Change History (16)
#4
@
10 years ago
- Version changed from 2.3.0 to 2.1
Thanks for testing, shanebp. Just for sanity's sake, can you duplicate this on 2.0.x?
#6
@
10 years ago
- Keywords reporter-feedback added
- Version 2.1 deleted
I cannot duplicate on 2.3.0, 2.2.3.1 or 2.1.1.
Tested on Twenty Twelve on a fresh single-site install.
My steps:
- Enable "
Allow activity stream commenting on blog and forum posts
" under "Settings > BuddyPress > Settings
" - Enable site tracking module under "
Settings > BuddyPress > Components
" - Create a new blog post. (This may be the difference.)
- Go to blog post permalink and comment. Comment shows up as an activity comment to the blog post activity item on the SWA page.
Perhaps check if the activity comment is being marked as spam by Akismet (if you have Akismet enabled) under the "Activity" dashboard?
Also make sure you do not have any code that may be interfering with this.
#7
@
10 years ago
My steps were the same as yours.
My testing was done on localhost using xampp.
Just tested on a public domain using 2.3.0 - cannot duplicate - iow. there is 2 way sync.
The localhost & public installs are the same - at least at the WP & BP level.
So I don't know why there is a discrepancy in the results.
Anyhow... I'm having issues getting sync either way for CPTs [ on local & public ].
Activity items are being created when a new CPT instance is created, as part of a plugin that creates a new component, but there is no sync.
Should I open a new ticket?
Or maybe you could post a 2.3.0 gist example re register_post_type with sync?
The examples shown here do not work - for commenting syncing:
https://codex.buddypress.org/plugindev/post-types-activities/
#9
@
10 years ago
- Keywords dev-feedback removed
@shanebp as i've explained in this ticket #6306 "post types comments" are not supported in the new way of registering post types activities. It's still something we need to work on in future releases.
Then you've asked for :
All I'm asking for is consistency in how BP 2+ handles comment syncing for custom post types
So r9837 is making sure plugins still using the deprecated filters will behave like before the introduction of the post types activities feature.
This means for now you need to choose between :
- Using the new way of registering post types activities (to get the activity dropdown filters etc...)
- Or use the deprecated filters
bp_blogs_record_post_post_types
andbp_blogs_record_comment_post_types
so that your post type activity action is somehow "merged" into the "post" post type one and as a result comment syncing also works for your post type. Because to have comment syncing the activity action needs to be new_blog_post
I hope, this will clarify the situation.
Should I open a new ticket?
Feel free to open an "enhancement" ticket to add "post types comment" support in Post types activities.
#10
@
10 years ago
Thanks for the clarification.
I'll open an enhancement ticket.
Meanwhile, can you edit this codex page:
https://codex.buddypress.org/plugindev/post-types-activities/
so that it indicates the need to make a choice between comment syncing and 'new way of registering post types activities'.
Currently it states that both 'buddypress-activity' features and comment syncing are possible.
#11
@
10 years ago
- Keywords reporter-feedback added
I've edited the page: see https://codex.buddypress.org/plugindev/post-types-activities/#notes
But again please note that when you say this:
Currently it states that both 'buddypress-activity' features and comment syncing are possible.
It's somehow not enough. As i've said in my previous comment :
as i've explained in this ticket #6306 "post types comments" are not supported in the new way of registering post types activities. It's still something we need to work on in future releases.
This means :
- if a comment is added to the post type from the single template of the post type, no activity will be generated for this comment. Is this clear for you ?
- the $activity_comment argument if set to true will allow activity comments for the generated activity, if set to false (default value) will not allow activity comments for the generated activity. Is this clear for you ?
Feel free to edit the codex page if you think my explanations are not clear enough. On a side note, i don't think i've ever wrote something saying that "comment syncing" was supported for other post types than the "post" one.
Back to the original description of this ticket and r-a-y's reply, it looks like there's no problem with comments about the "post" post type. Am i wrong ?
If i'm not wrong, can we close this ticket ?
#12
@
10 years ago
- Milestone Awaiting Review deleted
- Resolution set to worksforme
- Status changed from new to closed
I've created an enhancement ticket:
https://buddypress.trac.wordpress.org/ticket/6482
And added a note to the codex page.
Thanks for your input.
#13
@
9 years ago
Apologies for late posting on a closed ticket, but it seems more relevant here than in a new ticket.
I have also experienced activity items not being created when "Allow activity stream commenting on blog and forum posts" is on. It appears that @r-a-y's observation that "Create a new blog post. (This may be the difference.)" is correct.
The reason is that when a new activity item's parent activity item is not found then, instead of falling back to creating an "independent" activity item, no activity item is created at all.
See: https://buddypress.trac.wordpress.org/browser/trunk/src/bp-blogs/bp-blogs-functions.php#L684
There are a number of possible reasons for the absence of a parent item, including:
- BuddyPress has been enabled on an existing WordPress instance
- Site Tracking component has been enabled after posts have already been published.
If this is considered a bug, I'll open a new ticket.
#14
@
9 years ago
Hi @needle, this ticket was about custom post types and was closed in favor of #6482.
For your specific point, i think it does not concern custom post types but "regular" posts. You can eventually open a new ticket, but i don't think it's a bug.
Sounds like a bug. This was working when it was introduced in 2.0.
Is this a regression from 2.3? Can you duplicate this on 2.2.x or 2.1.x?