imap_ping(3) php man page | unix.com

Man Page: imap_ping

Operating Environment: php

Section: 3

IMAP_PING(3)								 1							      IMAP_PING(3)

imap_ping - Check if the IMAP stream is still active

SYNOPSIS
bool imap_ping (resource $imap_stream)
DESCRIPTION
imap_ping(3) pings the stream to see if it's still active. It may discover new mail; this is the preferred method for a periodic "new mail check" as well as a "keep alive" for servers which have inactivity timeout.
PARAMETERS
o $ imap_stream -An IMAP stream returned by imap_open(3).
RETURN VALUES
Returns TRUE if the stream is still alive, FALSE otherwise.
EXAMPLES
Example #1 imap_ping(3) Example <?php $imap = imap_open("{imap.example.org}", "mailadmin", "password"); // after some sleeping if (!imap_ping($imap)) { // do some stuff to reconnect } ?> PHP Documentation Group IMAP_PING(3)
Related Man Pages
imap_setflag_full(3) - php
imap_createmailbox(3) - php
imap_get_quotaroot(3) - php
imap_reopen(3) - php
imap_search(3) - php
Similar Topics in the Unix Linux Community
UNIX.COM 2017 Year End Summary
Status of UNIX.COM Forum Transformation
Please Welcome Ravinder Singh to the Moderation Team
The Order of the Wizard's Hat - Lifetime Achievement Award 2019 - Congrats to Don Cragun
The Order of the Wizard's Hat - Lifetime Achievement Award 2019 - Congrats to Wolf Machowitsch