Began rework of options page. Also added 3 plugins (filters, translate, and squirrels...
[squirrelmail.git] / src / folders_rename_do.php
index 4c0dcfff3eb74b8ce6ce950848b7cb13250678fd..8807f6456c2bd9a72a3937e7c142942e143dfabb 100644 (file)
    else
       $newone = "$new_name";
 
-   $cmd = "a024 RENAME \"" . quoteIMAP($orig) . "\" \"" .
+   $cmd = sqimap_session_id() . " RENAME \"" . quoteIMAP($orig) . "\" \"" .
       quoteIMAP($newone) . "\"\r\n";
    fputs ($imapConnection, $cmd);
-   $data = sqimap_read_data($imapConnection, "a024", true, $a, $b);
+   $data = sqimap_read_data($imapConnection, sqimap_session_id(), true, $a, $b);
 
    // Renaming a folder doesn't renames the folder but leaves you unsubscribed
    //    at least on Cyrus IMAP servers.
@@ -47,9 +47,9 @@
    sqimap_unsubscribe($imapConnection, $orig);
    sqimap_subscribe($imapConnection, $newone);
 
-   fputs ($imapConnection, "a001 LIST \"\" \"" . quoteIMAP($newone) .
+   fputs ($imapConnection, sqimap_session_id() . " LIST \"\" \"" . quoteIMAP($newone) .
       "*\"\r\n");
-   $data = sqimap_read_data($imapConnection, "a001", true, $a, $b);
+   $data = sqimap_read_data($imapConnection, sqimap_session_id(), true, $a, $b);
    for ($i=0; $i < count($data); $i++)
    {
       $name = find_mailbox_name($data[$i]);