yo peeps

i'm integrating a mailing list to my drupal site. mail sent to the listserv is posted as a new topic, but mail replies are not threaded as comments, they are posted as new forum topics.

i've looked into the module code to see how it works, and checked that the mail headers have the correct In_Reply_To data, things look ok.

i can try to debug this but i'm new to module coding. if someone could tell me how to write debug data into a log it would help a lot. in particular i want to check if the nodes are being written with the correct mail header data.

any other help would be appreciated

thanks

Comments

hutch’s picture

Here is some code:

function _mailhandler_debugfunc($message) {
  $log = "/path/to/your/files/test.log";
  $hh = fopen($log, 'a');
  fwrite($hh, $message);
  fclose($hh);
}

and something like

_mailhandler_debugfunc("in mailhandler_function_xx 'stuff you want to check' \n");

wherever you want to find out how things are going

Alternately use watchdog()

moshe weitzman’s picture

listhandler and og2list both attempt to handle this threading.

ssutankayo’s picture

i thought listhandler and og2list were still under development for drupal 5.x? also i haven't added organic groups yet as my site doesn't need that functionality and i already have many modules installed. but if it's a recommended practice to go to organic groups i could reconsider...

greggles’s picture

Status: Active » Closed (works as designed)