imap_rfc822_parse_adrlist(3) php man page | unix.com

Man Page: imap_rfc822_parse_adrlist

Operating Environment: php

Section: 3

IMAP_RFC822_PARSE_ADRLIST(3)						 1					      IMAP_RFC822_PARSE_ADRLIST(3)

imap_rfc822_parse_adrlist - Parses an address string

SYNOPSIS
array imap_rfc822_parse_adrlist (string $address, string $default_host)
DESCRIPTION
Parses the address string as defined in RFC2822 and for each address.
PARAMETERS
o $address - A string containing addresses o $default_host - The default host name
RETURN VALUES
Returns an array of objects. The objects properties are: o mailbox - the mailbox name (username) o host - the host name o personal - the personal name o adl - at domain source route
EXAMPLES
Example #1 imap_rfc822_parse_adrlist(3) example <?php $address_string = "Joe Doe <doe@example.com>, postmaster@example.com, root"; $address_array = imap_rfc822_parse_adrlist($address_string, "example.com"); if (!is_array($address_array) || count($address_array) < 1) { die("something is wrong "); } foreach ($address_array as $id => $val) { echo "# $id "; echo " mailbox : " . $val->mailbox . " "; echo " host : " . $val->host . " "; echo " personal: " . $val->personal . " "; echo " adl : " . $val->adl . " "; } ?> The above example will output: # 0 mailbox : doe host : example.com personal: Joe Doe adl : # 1 mailbox : postmaster host : example.com personal: adl : # 2 mailbox : root host : example.com personal: adl :
SEE ALSO
imap_rfc822_parse_headers(3). PHP Documentation Group IMAP_RFC822_PARSE_ADRLIST(3)
Related Man Pages
net::dns::mailbox5.18(3) - mojave
imap_createmailbox(3) - php
imap_append(3) - php
imap_getmailboxes(3) - php
imap_status(3) - php
Similar Topics in the Unix Linux Community
which language will be the best
pattern match question
How to use one variable value to another variable?
tweets and personal sites
How can i secure my personal data and E-mail id?