next up previous contents
Next: left_main.php Up: 目錄 src Previous: configtest.php   Contents

empty_trash.php

  1. 清空垃圾桶中郵件程式,加入自訂的 Spam 目錄,也有清空的連結按鈕。
    [root@mail squirrelmail-1.4.8]# diff -wuN ./src/empty_trash.php /var/www/squirrelmail/src/empty_trash.php
    --- ./src/empty_trash.php	2006-04-15 06:27:08.000000000 +0800
    +++ /var/www/squirrelmail/src/empty_trash.php	2013-03-29 09:42:33.000000000 +0800
    @@ -37,7 +37,8 @@
     
     sqimap_mailbox_list($imap_stream);
     
    -$mailbox = $trash_folder;
    +//$mailbox = $trash_folder;
    +$mailbox = $_GET['purge']; //dywang
     $boxes = sqimap_mailbox_list($imap_stream);
     
     /*
    @@ -66,9 +67,8 @@
             addChildNodeToTree($boxes[$i]['unformatted'], $boxes[$i]['unformatted-dm'], $foldersTree);
         }
     }
    -
     // now lets go through the tree and delete the folders
    -walkTreeInPreOrderEmptyTrash(0, $imap_stream, $foldersTree);
    +walkTreeInPreOrderEmptyTrash(0, $imap_stream, $foldersTree,$mailbox); //dywang
     sqimap_logout($imap_stream);
     
     // close session properly before redirecting
    



2016-03-11