| | |
| | | $old_count = $RCMAIL->storage->count(NULL, $threading ? 'THREADS' : 'ALL'); |
| | | $old_pages = ceil($old_count / $RCMAIL->storage->get_pagesize()); |
| | | $sources = array(); |
| | | |
| | | $trash = $RCMAIL->config->get('trash_mbox'); |
| | | |
| | | // move messages |
| | |
| | | $OUTPUT->command('list_mailbox'); |
| | | $RCMAIL->display_server_error('errormoving', null, $target == $trash ? 'delete' : ''); |
| | | $OUTPUT->send(); |
| | | exit; |
| | | } |
| | | else { |
| | | $OUTPUT->show_message('messagemoved', 'confirmation'); |
| | |
| | | $OUTPUT->command('list_mailbox'); |
| | | $RCMAIL->display_server_error('errordeleting'); |
| | | $OUTPUT->send(); |
| | | exit; |
| | | } |
| | | else { |
| | | $OUTPUT->show_message('messagedeleted', 'confirmation'); |
| | |
| | | else { |
| | | $OUTPUT->show_message('internalerror', 'error'); |
| | | $OUTPUT->send(); |
| | | exit; |
| | | } |
| | | |
| | | $search_request = rcube_utils::get_input_value('_search', rcube_utils::INPUT_GPC); |
| | |
| | | } |
| | | |
| | | if ($_POST['_from'] == 'show') { |
| | | if ($next = rcube_utils::get_input_value('_next_uid', rcube_utils::INPUT_GPC)) |
| | | if ($next = rcube_utils::get_input_value('_next_uid', rcube_utils::INPUT_GPC)) { |
| | | $OUTPUT->command('show_message', $next); |
| | | else |
| | | $OUTPUT->command('command', 'list'); |
| | | } |
| | | else { |
| | | $OUTPUT->command('command', 'list'); |
| | | } |
| | | |
| | | $OUTPUT->send(); |
| | | } |
| | | |
| | | $mbox = $RCMAIL->storage->get_folder(); |
| | | $msg_count = $RCMAIL->storage->count(NULL, $threading ? 'THREADS' : 'ALL'); |
| | | $exists = $RCMAIL->storage->count($mbox, 'EXISTS', true); |
| | | $page_size = $RCMAIL->storage->get_pagesize(); |
| | |
| | | $OUTPUT->set_env('exists', $exists); |
| | | |
| | | // update mailboxlist |
| | | $mbox = $RCMAIL->storage->get_folder(); |
| | | $unseen_count = $msg_count ? $RCMAIL->storage->count($mbox, 'UNSEEN') : 0; |
| | | $old_unseen = rcmail_get_unseen_count($mbox); |
| | | |
| | |
| | | } |
| | | else if ($target !== null && $target === $trash) { |
| | | $OUTPUT->command('set_trash_count', $RCMAIL->storage->count($trash, 'EXISTS', true)); |
| | | } |
| | | } |
| | | |
| | | // send response |