2 Replies Latest reply: Jan 23, 2008 2:12 PM by John Lockwood
John Lockwood Level 5 Level 5 (6,825 points)
Squirrelmail as included with Mac OS X Server lets you remotely access your Inbox via a web-browser. It also automatically creates sub-folders to store drafts, sent, and trashed emails as done during a Squirrelmail session.

These have a folder structure like this


When you look at this in Apple mail you will see a triangle next to your Inbox and turning it down reveals the same sub-folders.

The purpose of this posting, is that I believe this structure is not the same as the default Apple Mail structure and as such Apple Mail and Squirrelmail will not automatically be using the same IMAP folders to store drafts, sent and trash.

It is possible in Apple Mail to select one of these Squirrelmail created folders, and go to the Mailbox menu and select the "Use This Mailbox For..." command to make it the folder to use for that purpose. It is also possible to edit the Squirrelmail config.php file to adjust its settings which as default will be

$defaultfolderprefix = 'INBOX/';
$trash_folder = 'Trash';
$sent_folder = 'Sent';
$draft_folder = 'Drafts';

My question is what if any, would be a better setting for Squirrelmail so that Squirrelmail puts the folders in the right place for Apple Mail and uses the right names for Apple Mail so that an Apple Mail user does not have to change anything?

The benefit would be that rather each and every user having to alter the Apple Mail setup, I could do one edit of the config file for Squirrelmail and this would then apply forever for all users.

PowerBook G4, Mac OS X (10.4.10)
  • John Lockwood Level 5 Level 5 (6,825 points)
    Ok, I may have worked out the answer myself.

    Apple Mail in the Apple Mail program uses the folder names


    However it appears to use +on the server+

    Sent Messages
    Deleted Messages

    So it appears that in order to get Squirrelmail to match the settings Apple Mail uses and therefore save the Apple Mail user the hassle at their end you need to do two things.

    1. Change the IMAP folder path in Squirrelmail from the default 'INBOX/' to '' (nothing)
    2. Change the special IMAP folder names in Squirrelmail from the default to match Apple Mail

    Therefore in the the Squirrelmail config.php you will go from the default

    $defaultfolderprefix = 'INBOX/';
    $trash_folder = 'Trash';
    $sent_folder = 'Sent';
    $draft_folder = 'Drafts';


    $defaultfolderprefix = '';
    $trash_folder = 'Deleted Messages';
    $sent_folder = 'Sent Messages';
    $draft_folder = 'Drafts';

    which matches what Apple Mail is using.
  • John Lockwood Level 5 Level 5 (6,825 points)
    As was pointed out to me by a Mark via a private email, Apple have made this change standard in Squirrelmail as included in Mac OS X 10.5.1 Server.


    Apple could have thanked me though