sorry, can you explain further.
There is no ‘update’ button on a topic unless this is lost in translation, there is edit and submit.
can you detail a series of steps and what you want to happen?
Okay, I mean the submit button. I just want the topic to be updated (as if I was hitting the submit button) when a reply is posted, that’s all.
sorry, still need more.
Do you mean that you don’t want anyone to have replies, but instead replies by anyone to update topic content and not leave a reply ?
I do not want the standard behaviour to be modified in any way, except that the topic itself be updated when a reply is posted to it. Nothing will look any different to standard bbpress behaviour as far as the user is concerned – I just want to simulate hitting the submit button on the topic when a reply is posted, nothing more.
sorry, I am trying to help you, but am still unclear what it is you want.
Can you define what you mean by ‘updated’??
Like I said, as if I was hitting the submit button on the topic. There won’t actually be anything new within the topic itself, I just want it to be updated, as if it was saved but without any actual changes in the topic itself. I simply want a reply to the topic to trigger a save within the topic itself. I think you’re thinking I must be wanting something more complicated, but it really is that simple.
ok, I now understand what you want.
Put this in your child theme’s function file –
ie wp-content/themes/%your-theme-name%/functions.php
where %your-theme-name% is the name of your theme
or use
Code Snippets
add_action ('bbp_new_reply_post_extras' , 'rew_update_topic') ;
add_action ('bbp_edit_reply_post_extras' , 'rew_update_topic') ;
function rew_update_topic ($reply_id) {
$topic_id = bbp_get_reply_topic_id( $reply_id );
$topic_data = apply_filters( 'rew_update_topic', array(
'ID' => $topic_id,
) );
$topic_id = wp_update_post( $topic_data );
}