Adding attachments to replies (not parent topic)
-
I have a problem with the attachments…. all attachments (no matter if they have an reply_id or not) are attached to the main topic_id
<input id=”bbp_topic_id” type=”hidden” value=”122″ name=”bbp_topic_id”></input>
<input id=”bbp_reply_to” type=”hidden” value=”0″ name=”bbp_reply_to”></input> for normal reply form in forum and
<input id=”bbp_topic_id” type=”hidden” value=”122″ name=”bbp_topic_id”></input>
<input id=”bbp_reply_to” type=”hidden” value=”3512″ name=”bbp_reply_to”></input> for replying to an existing reply.But if i understand your code correctly
public function save_topic($topic_id, $forum_id, $anonymous_data, $topic_author) {
$this->save_reply(0, $topic_id, $forum_id, $anonymous_data, $topic_author);
}public function save_reply($reply_id, $topic_id, $forum_id, $anonymous_data, $reply_author) {
$uploads = array();
you never use the reply_id to store attachments.I want to save attachments to the correct reply_id (post_parent = reply_id).
And no additional attachment link should be created by your plugin if i use inline images (adding images from media library).Besides that great plugin !
https://www.ads-software.com/plugins/gd-bbpress-attachments/
- The topic ‘Adding attachments to replies (not parent topic)’ is closed to new replies.