Основы PHP
  Что такое PHP?
  Возможности PHP
  Преимущества PHP
  История развития
  Что нового в PHP5?
  «Движок» PHP
  Переход на PHP 5.3
New Переход на PHP 5.6
  Введение в PHP
  Изучение PHP
  Основы CGI
  Синтаксис PHP
  Типы данных PHP
  Переменные в PHP
  Константы PHP
  Выражения PHP
  Операторы PHP
  Конструкции PHP
  Ссылки в PHP
  PHP и ООП
  Безопасность
  Функции PHP
  Функции по категориям
  Функции по алфавиту
  Стандартные функции
  Пользовательские
  PHP и HTTP
  Работа с формами
  PHP и Upload
  PHP и Cookies
  PHP и базы данных
  PHP и MySQL
  Документация MySQL
  Учебники
  Учебники по PHP
  Учебники по MySQL
  Другие учебники
  Уроки PHP
  Введение
  Самые основы
  Управление
  Функции
  Документация
  Математика
  Файлы
  Основы SQL
  Дата и время
  CURL
  Изображения
  Стили
  Безопасность
  Установка
  Проектирование БД
  Регулярные выражения
  Подготовка к работе
  Быстрый старт
  Установка PHP
  Установка MySQL
  Конфигурация PHP
  Download / Скачать
  Скачать Apache
  Скачать PHP
  Скачать PECL
  Скачать PEAR
  Скачать MySQL
  Редакторы PHP
  Полезные утилиты
  Документация
  PHP скрипты
  Скачать скрипты
  Инструменты
  PHP в примерах
  Новости портала
 Главная   »  Функции PHP
 
 
Функции PHP »»» Функции электронной почты IMAP, POP3 and NNTP

imap_get_quotaroot

(PHP 4 >= 4.3.0, PHP 5)

imap_get_quotaroot --  Retrieve the quota settings per user

Описание

array imap_get_quotaroot ( resource imap_stream, string quota_root )

Returns an array of integer values pertaining to the specified user mailbox. All values contain a key based upon the resource name, and a corresponding array with the usage and limit values within.

The limit value represents the total amount of space allowed for this user's total mailbox usage. The usage value represents the user's current total mailbox capacity. This function will return FALSE in the case of call failure, and an array of information about the connection upon an un-parsable response from the server.

This function is currently only available to users of the c-client2000 or greater library.

imap_stream should be the value returned from an imap_open() call. This stream should be opened as the user whose mailbox you wish to check. quota_root should normally be in the form of which mailbox (i.e. INBOX).


Пример 1. imap_get_quotaroot() example

<?php
$mbox 
imap_open("{your.imap.host}""kalowsky""password"OP_HALFOPEN)
      or die(
"can't connect: " imap_last_error());
 
$quota imap_get_quotaroot($mbox"INBOX");
if (
is_array($quota)) {
   
$storage $quota_values['STORAGE'];
   echo 
"STORAGE usage level is: " .  $storage['usage'];
   echo 
"STORAGE limit level is: " .  $storage['limit'];

   
$message $quota_values['MESSAGE']; 
   echo 
"MESSAGE usage level is: " .  $message['usage'];
   echo 
"MESSAGE usage level is: " .  $message['limit'];

   
/* ...  */ 


 
imap_close($mbox); 
?>

See also imap_open(), imap_set_quota() and imap_get_quota().

 
 
 Функции по алфавиту 
   Содержание   
 Функции по категориям 

Есть еще вопросы или что-то непонятно - добро пожаловать на наш  форум портала PHP.SU 
 

 
Powered by PHP  Powered By MySQL  Powered by Nginx  Valid CSS