mirror of
https://github.com/fofolee/uTools-Manuals.git
synced 2025-06-18 13:57:03 +08:00
114 lines
4.4 KiB
HTML
114 lines
4.4 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<html>
|
|
<head>
|
|
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
|
<title>Check current mailbox</title>
|
|
</head>
|
|
<body class="docs"><div id="layout">
|
|
<div id="layout-content"><div id="function.imap-check" class="refentry">
|
|
<div class="refnamediv">
|
|
<h1 class="refname">imap_check</h1>
|
|
<p class="verinfo">(PHP 4, PHP 5, PHP 7)</p><p class="refpurpose"><span class="refname">imap_check</span> — <span class="dc-title">Check current mailbox</span></p>
|
|
|
|
</div>
|
|
<div class="refsect1 description" id="refsect1-function.imap-check-description">
|
|
<h3 class="title">说明</h3>
|
|
<div class="methodsynopsis dc-description">
|
|
<span class="methodname"><strong>imap_check</strong></span>
|
|
( <span class="methodparam"><span class="type">resource</span> <code class="parameter">$imap_stream</code></span>
|
|
) : <span class="type">object</span></div>
|
|
|
|
<p class="para rdfs-comment">
|
|
Checks information about the current mailbox.
|
|
</p>
|
|
</div>
|
|
|
|
<div class="refsect1 parameters" id="refsect1-function.imap-check-parameters">
|
|
<h3 class="title">参数</h3>
|
|
<p class="para">
|
|
<dl>
|
|
|
|
<dt>
|
|
<code class="parameter">
|
|
imap_stream</code></dt>
|
|
<dd>
|
|
<p class="para">由 <span class="function"><a href="imap_open.html" class="function">imap_open()</a></span> 返回的 IMAP 流。</p></dd>
|
|
|
|
</dl>
|
|
|
|
</p>
|
|
</div>
|
|
|
|
<div class="refsect1 returnvalues" id="refsect1-function.imap-check-returnvalues">
|
|
<h3 class="title">返回值</h3>
|
|
<p class="para">
|
|
Returns the information in an object with following properties:
|
|
<ul class="itemizedlist">
|
|
<li class="listitem">
|
|
<span class="simpara">
|
|
<strong><code>Date</code></strong> - current system time formatted according to <a href="http://www.faqs.org/rfcs/rfc2822" class="link external">» RFC2822</a>
|
|
</span>
|
|
</li>
|
|
<li class="listitem">
|
|
<span class="simpara">
|
|
<strong><code>Driver</code></strong> - protocol used to access this mailbox:
|
|
<acronym title="Post Office Protocol version 3">POP3</acronym>, <acronym title="Internet Message Access Protocol">IMAP</acronym>, <acronym title="Network News Transfer Protocol">NNTP</acronym>
|
|
</span>
|
|
</li>
|
|
<li class="listitem">
|
|
<span class="simpara">
|
|
<strong><code>Mailbox</code></strong> - the mailbox name
|
|
</span>
|
|
</li>
|
|
<li class="listitem">
|
|
<span class="simpara">
|
|
<strong><code>Nmsgs</code></strong> - number of messages in the mailbox
|
|
</span>
|
|
</li>
|
|
<li class="listitem">
|
|
<span class="simpara">
|
|
<strong><code>Recent</code></strong> - number of recent messages in the mailbox
|
|
</span>
|
|
</li>
|
|
</ul>
|
|
</p>
|
|
<p class="para">
|
|
Returns <strong><code>FALSE</code></strong> on failure.
|
|
</p>
|
|
</div>
|
|
|
|
<div class="refsect1 examples" id="refsect1-function.imap-check-examples">
|
|
<h3 class="title">范例</h3>
|
|
<p class="para">
|
|
<div class="example" id="example-4016">
|
|
<p><strong>Example #1 <span class="function"><strong>imap_check()</strong></span> example</strong></p>
|
|
<div class="example-contents">
|
|
<div class="phpcode"><pre><span style="color: #000000">
|
|
<span style="color: #0000BB"><?php<br /><br />$imap_obj </span><span style="color: #007700">= </span><span style="color: #0000BB">imap_check</span><span style="color: #007700">(</span><span style="color: #0000BB">$imap_stream</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">$imap_obj</span><span style="color: #007700">);<br /><br /></span><span style="color: #0000BB">?></span>
|
|
</span>
|
|
</pre></div>
|
|
</div>
|
|
|
|
<div class="example-contents"><p>以上例程的输出类似于:</p></div>
|
|
<div class="example-contents screen">
|
|
<div class="cdata"><pre>
|
|
object(stdClass)(5) {
|
|
["Date"]=>
|
|
string(37) "Wed, 10 Dec 2003 17:56:54 +0100 (CET)"
|
|
["Driver"]=>
|
|
string(4) "imap"
|
|
["Mailbox"]=>
|
|
string(54)
|
|
"{www.example.com:143/imap/user="foo@example.com"}INBOX"
|
|
["Nmsgs"]=>
|
|
int(1)
|
|
["Recent"]=>
|
|
int(0)
|
|
}
|
|
</pre></div>
|
|
</div>
|
|
</div>
|
|
</p>
|
|
</div>
|
|
|
|
</div></div></div></body></html> |