Title: Dynamically assign topic to different forums
Last modified: November 2, 2021

---

# Dynamically assign topic to different forums

 *  ResolvedPlugin Author [Nick](https://wordpress.org/support/users/nickchomey/)
 * (@nickchomey)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/)
 * This plugin is fantastic, but one important thing appears to be missing – the
   ability to dynamically assign a topic to a particular forum, based on which post
   is being created/viewed.
 * Specifically, I have buddypress groups that are each dedicated to a specific 
   topic/theme/domain. Each group has one bbpress forum attached to it, and as various
   posts attached to it as well.
 * So, if I’m creating a post that is related to group ABC, I’d love if I could 
   create a comments topic in Forum ABC as well. If the post is related to group
   XYZ, topic goes in XYZ.
 * Is this currently possible? Is there a specific spot in the code (perhaps even
   a hook?) that I could modify to allow for this? I really just need to be able
   to pass the forum ID, which I would generate/retrieve through other code, to 
   the Topics for Posts plugin mechanism.
 * Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [Nick](https://wordpress.org/support/users/nickchomey/)
 * (@nickchomey)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/#post-15030626)
 * I now see that you can manually set the Forum from the Topics for Posts tab in
   the post editor sidebar. That will definitely suffice for the most-part, but 
   I suspect I’ll want to add some sort of front-end post-submission mechanism. 
   So, I’ll still want to be able to set the forum dynamically.
 *  Plugin Author [Robin W](https://wordpress.org/support/users/robin-w/)
 * (@robin-w)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/#post-15043174)
 * >  but I suspect I’ll want to add some sort of front-end post-submission mechanism.
 * That should be possible, but what ‘front-end’ post submission method will you
   be using? It is probably a hook to the post submission of that as a ‘post extra’
   that you will need, and some forum entry area on whatever form the front end 
   is using to create posts.
 *  Plugin Author [Nick](https://wordpress.org/support/users/nickchomey/)
 * (@nickchomey)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/#post-15043180)
 * Thanks for the response. I’m not sure what mechanism I’ll be using – probably
   Toolset Forms.
 * I’m not sure it’s terribly relevant though – I believe that all I need is to 
   know how to hook into the BBpress Topics for Posts mechanism during the post 
   creation so that it can create its relevant meta fields. Is there such a hook,
   or a place in the code that I could add one?
 * Thanks!
 *  Plugin Author [Robin W](https://wordpress.org/support/users/robin-w/)
 * (@robin-w)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/#post-15043305)
 * so on post creation the plugin hooks to
 * `add_action( 'save_post', array( &$bbp_post_topics, 'process_topic_option' ),
   10, 3 );`
 * save post is a wordpress action from the backend and uses $post and $_POST for
   the settings
 * process_topic_option is a function in index.php
 *  Plugin Author [Nick](https://wordpress.org/support/users/nickchomey/)
 * (@nickchomey)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/#post-15043413)
 * Thanks, I’m sure I can figure it out from here!

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Dynamically assign topic to different forums’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/bbpress-post-topics.svg)
 * [Post Comments as bbPress Topics](https://wordpress.org/plugins/bbpress-post-topics/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/bbpress-post-topics/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/bbpress-post-topics/)
 * [Active Topics](https://wordpress.org/support/plugin/bbpress-post-topics/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/bbpress-post-topics/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/bbpress-post-topics/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Nick](https://wordpress.org/support/users/nickchomey/)
 * Last activity: [4 years, 7 months ago](https://wordpress.org/support/topic/dynamically-assign-topic-to-different-forums/#post-15043413)
 * Status: resolved