Handling incoming emails as replys to a thread instead of new threads.

dazhdbog - August 23, 2008 - 01:35
Project:Listhandler
Version:HEAD
Component:Code
Category:support request
Priority:normal
Assigned:philipnet
Status:postponed (maintainer needs more info)
Description

Hi,

Just have a question, is it possible to set up a mailbox to post new emails as replys to a thread instead of new threads? I tried doing it by setting the commands as below but it didn't work (the posts get created not tied to any forum or thread). Thanks!

type: node
tid: 34

#1

rmyoung - September 5, 2008 - 05:35

That's because you are creating new nodes. You need to create comments on the original node. So use the commands:

type: comment
nid: x
where x is the ID of the node you want to attach the comments to.

This is in the documentation: http://drupal.org/node/38943

#2

dazhdbog - September 9, 2008 - 20:53

Thanks! works like a charm! I did read the docs, but didn't notice this..

#3

philipnet - September 18, 2008 - 20:58
Component:Miscellaneous» Documentation
Assigned to:Anonymous» philipnet

Note to self:
Add the URL to the Listhandler documentation.

P.

#4

mziegmann - October 9, 2008 - 23:17

I'm sorry, but I'm not following how to do this - can I ask you to spell this out more for me. How do I make this work so anyone on the list can reply to a post by replying to the listhandler-generated email?

I get how to put the command lines in the mailhandler setup, and I understand that if I manually put the above commands in the body of the email reply (after first looking up the nid), it posts the reply correctly. But obviously my list recipients aren't going to look up the nid and add these commands, so I don't understand how to apply the above solution so everyone on the list can create comments on a node?

#5

rmyoung - October 10, 2008 - 11:43

The way I have set it up my forum/list is by adding the following default commands to your mailhandler configuration:

tid: xx
status: 1
comment: 2

Where xx is the term id of your forum.

The commands talked about previously in this issue are to set a comment to a known node.

There is currently an issue with the comment: 2 command though - see http://drupal.org/node/224809

I am not sure that this is the correct way to do it anymore but it works when you use the patch for mailhandler in that issue.

#6

philipnet - October 10, 2008 - 13:04

Re: the issue with "comment: 2"

It's easiest to modify the "Forum topic" content type; setting "Default comment setting:" to "Read/Write".

That sure beats messing with patches!

P.

#7

mziegmann - October 10, 2008 - 14:44

The commands talked about previously in this issue are to set a comment to a known node.

Right, that's what I'm trying to do. I do have the default commands set up in my mailhandler configuration, but that doesn't allow comments to be created as threaded discussions. I need a reply to an email to be submitted as a comment to the forum post that generated the original email.

#8

philipnet - October 10, 2008 - 15:31
Status:active» postponed (maintainer needs more info)

Hi mziegmann,

Can you tell us:
1. Have you gone through the documentation in the Handbook at http://drupal.org/node/40777 ?
2. What 'Mailhandler commands' you have for the list?
3. What you expect to happen?
4. What actually happens?

Thanks.

#9

mziegmann - October 13, 2008 - 17:54

I have gone through those steps, but must have missed something the first time. I reset everything up again from scratch, and now my comments are coming in as threaded replies as I was expecting - thanks!

So everything seems to be working for me now, except one thing: my replies (comments) are coming in as unpublished. I get this message when I do a retrieve for the mailbox:

"Your comment has been queued for moderation by site administrators and will be published after approval."

Here are my default settings in Mailhandler.

TID: 18
status: 1
promote: 0
publish: 1

I have the default Comment settings for a forum topic set to "Read/Write".

Can you help me figure out what I'm missing?

Thanks!

#10

philipnet - October 19, 2008 - 08:00
Component:Documentation» Code

Does the "authenticated user" have permission to "post comments without approval" ?

Listhandler finds out if the role that the user belongs too has the right to "post comments without approval", and acts accordingly when creating the node/comment.

Regards.

P.

 
 

Drupal is a registered trademark of Dries Buytaert.