Roundcube Community Forum

News and Announcements => General Discussion => Topic started by: JAB Creations on February 24, 2025, 08:08:25 PM

Title: Dev-to-Dev: How does Roundcube know system folders from custom folders?
Post by: JAB Creations on February 24, 2025, 08:08:25 PM
On my server Roundcube seems to know which folders are system folders and which are custom. I'm going through the code though... I'm a bit lost. Is it a static list? A detection of a mail server provider type? Here is an example of what I get via PHP's IMAP extension (yes, I know it's no longer maintained):

0 = INBOX
1 = INBOX.Test 123
2 = INBOX.Archive
3 = INBOX.spam
4 = INBOX.Trash
5 = INBOX.Sent
6 = INBOX.Drafts

So array item 1 is the only custom folder here. But how does Roundcube make that determination?
Title: Re: Dev-to-Dev: How does Roundcube know system folders from custom folders?
Post by: SKaero on February 24, 2025, 08:26:48 PM
I believe Roundcube follows RFC 6154 https://www.rfc-editor.org/rfc/rfc6154 its handled in <RC root>/program/lib/Roundcube/rcube.php with the special use names being changeable in the config, you can see them in <RC root>/config/defaults.inc.php with config options that have "_mbox" in them.
Title: Re: Dev-to-Dev: How does Roundcube know system folders from custom folders?
Post by: JAB Creations on February 24, 2025, 09:26:40 PM
@SKaero Thank you for the quick reply and an official reference.