Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hiya -
I've installed the mailhandler module on my Drupal 4.7.6 install. In setup, I entered the path to a local folder that I'd like mailhandler to access. Underneath the "Folder" text entry box it says:
"Optional. The folder where the mail is stored. If you want this mailbox to read from a local folder, give the full path. Leave domain, port, name, and pass empty below. Remember to set the folder to readable and writable by the webserver."
So, as per instructions I left those items empty. But when I attempt to save my configuration, I get this error:
Mailbox domain field is required.
Comments
Comment #1
Clemens CreditAttribution: Clemens commentedSame problem with version 5.x-1.0... I have tried to use mailhandler several times since it was released over the years.
It appears to be a much needed module.
The 'IMAP dynamic extension' does not appear to be available on my server.
Without a fix for this bug I will not be able to use Mailhandler. That is sad.
Comment #2
ChrisKennedy CreditAttribution: ChrisKennedy commentedFixed in HEAD, DRUPAL-5, and DRUPAL-4-7.
Comment #3
Clemens CreditAttribution: Clemens commentedAfter installing the latest 5.x-1.1 dated 15/03 the configuration indeed accepts a path to a folder as suggested. Thank you.
However, when you the 'retrieve' e-mail from that folder the following error occurs: warning: imap_open() [function.imap-open]: Couldn't open stream /var/www/test/ in /var/www/drupal/modules/mailhandler/mailhandler.module on line 21.
I did not expect to see an 'imap' error here... :-(
Comment #4
muhammadyaseen CreditAttribution: muhammadyaseen commentedComment #5
sime@clemens. http://php.net/imap_open states that this function can be used to access POP accounts as well, so I wouldn't worry about that.
I personally tried the direct access method and got this error. Reading php.net I don't see that how mailhandler was accessing the mailbox is consistent with the documentation, the only example I found of skipping the second and third parameters is this one:
Soo. I just did the normal access method with username/password etc, and it works fine. In fact making a mail directory 777 so that apache can read it is IMHO probably not the best option, but I'm sure it is preferable in some cases.
Comment #6
ilo CreditAttribution: ilo commented'folder' is a wrong assumption for local mailboxes. When working with local mailboxes you must specify the full file path. In any case, the imap class is unable to handle the folder at: "Couldn't open stream /var/www/test/", wich is a clear error about wrong folder configuration.