| | |
| | | $page = $page ? $page : $this->list_page; |
| | | |
| | | // use saved message set |
| | | if ($this->search_string && $folder == $this->folder) { |
| | | if ($this->search_string) { |
| | | return $this->list_search_messages($folder, $page, $slice); |
| | | } |
| | | |
| | |
| | | |
| | | /** |
| | | * Get mailbox quota information |
| | | * added by Nuny |
| | | * |
| | | * @param string $folder Folder name |
| | | * |
| | | * @return mixed Quota info or False if not supported |
| | | */ |
| | | public function get_quota() |
| | | public function get_quota($folder = null) |
| | | { |
| | | if ($this->get_capability('QUOTA') && $this->check_connection()) { |
| | | return $this->conn->getQuota(); |
| | | return $this->conn->getQuota($folder); |
| | | } |
| | | |
| | | return false; |
| | |
| | | // request \Subscribed flag in LIST response as performance improvement for folder_exists() |
| | | $folders = $this->conn->listMailboxes('', '*', array('SUBSCRIBED'), array('SPECIAL-USE')); |
| | | |
| | | foreach ($folders as $folder) { |
| | | if ($flags = $this->conn->data['LIST'][$folder]) { |
| | | foreach ($types as $type) { |
| | | if (in_array($type, $flags)) { |
| | | $type = strtolower(substr($type, 1)); |
| | | $special[$type] = $folder; |
| | | if (!empty($folders)) { |
| | | foreach ($folders as $folder) { |
| | | if ($flags = $this->conn->data['LIST'][$folder]) { |
| | | foreach ($types as $type) { |
| | | if (in_array($type, $flags)) { |
| | | $type = strtolower(substr($type, 1)); |
| | | $special[$type] = $folder; |
| | | } |
| | | } |
| | | } |
| | | } |