RoundCubeMail - Error at deleting of mails

Discussion in 'Tips/Tricks/Mods' started by TobiasTM, Jul 21, 2006.

  1. TobiasTM

    TobiasTM New Member HowtoForge Supporter

    RoundCubeMail - Solution for error by deleting of mails

    I have found the solution of the problem.

    Following "BUG" is known:
    You have created a new mail-box, get a mail and want delete it, but there comes an error-message, that the mail couldn´t delete.

    Solution for the problem:
    Log into roundcube, go to settings, and create a new folder with name: "Trash" That´s it. The problem should now eliminated ;)
     
    Last edited: Jul 22, 2006
  2. Davide

    Davide Member

    Make roundcube create all needed folders

    I think this is far better solution:

    Create a text file in /home/admispconfig/ispconfig/web/roundcubemail (for example patch.diff)
    with the following content:

    --- program/include/rcube_imap.inc (revision 260)
    +++ program/include/rcube_imap.inc (working copy)
    @@ -362,13 +362,18 @@
    if (!is_array($a_folders) || !sizeof($a_folders))
    $a_folders = array();

    - // create INBOX if it does not exist
    - if (!in_array_nocase('INBOX', $a_folders))
    + // create Default folders if they do not exist
    + global $CONFIG;
    + foreach ($CONFIG['default_imap_folders'] as $folder)
    {
    - $this->create_mailbox('INBOX', TRUE);
    - array_unshift($a_folders, 'INBOX');
    + if (!in_array_nocase($folder, $a_folders))
    + {
    + $this->create_mailbox($folder, TRUE);
    + $this->subscribe($folder);
    + }
    }

    + $a_folders = iil_C_ListSubscribed($this->conn, $this->_mod_mailbox($root), $filter);
    $a_mailbox_cache = array();

    // write mailboxlist to cache


    patch roundcube mail:

    machine:/home/admispconfig/ispconfig/web/roundcubemail# patch -p0 < patch.diff

    And... voilà!

    Every user who log in roundmail, get all needed folders created (not only Trash)
     
  3. TobiasTM

    TobiasTM New Member HowtoForge Supporter

    I try it some times, but there come evetime a Error-Message like this:

    When I delete this file I´ll get error-messages at other places in you little skript.

    Is it possible that you have forgotten some + or - or other things ?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Davide, thanks for the patch!

    May you please attach a copy of the pached file (program/include/rcube_imap.inc) as .zip to this thraed?

    I guess it might be easier for users to replace the file instead of patching it, even if patching is technically the correct way of handling this :)
     
  5. Davide

    Davide Member

    I attach patched file to this post

    It should work with roundcube 0.1 beta (that is the packaged version for ISPConfig)

    Simply make a backup of your /home/admispconfig/ispconfig/web/roundcubemail/rcube_imap.php and substitute it with the attached one.
     

    Attached Files:

    Last edited: Jul 25, 2006
  6. schmidtedv

    schmidtedv Member HowtoForge Supporter

    ...newest beta-package in other thread does this already...
     
  7. m u r

    m u r Member

    This file doesn't exist on my system? Can anyone tell me how to make it autocreate the folders?
     
  8. ubuntuman

    ubuntuman New Member

    applyng the patch

    hi, to apply patch

    1- download the rcube_imap.zip
    2- uncompress it
    3- check if exist rcube_imap.inc in your "roundcubefolder"/program/includes/
    4- if exist put the rcube_imap.inc in "roundcubefolder"/program/includes/ and replace the old file..

    sorry for my english
    Ubuntuman from Argentina
     

Share This Page