PHP: imap_rfc822_parse_adrlist - Manual in Deutsh
PHP: imap_rfc822_parse_adrlist - Manual in French
PHP: imap_rfc822_parse_adrlist - Manual in Polish

You Are At PHP: imap_rfc822_parse_adrlist - Manual Area


recent searches:
include functions , variable functions , post functions...




If you are new to PHP or just need to refresh your skills, this is the place to start. This series of tutorials will give you the basic knowledge you will need to create a simple PHP website.

PHP is a reflective programming language originally designed for producing dynamic web pages.[1] PHP is used mainly in server-side scripting, but can be used from a command line interface or in standalone graphical applications. Textual User Interfaces can also be created using ncurses.

PHP Manual
PrevNext

imap_rfc822_parse_adrlist

(PHP 3 >= 3.0.2, PHP 4, PHP 5)

imap_rfc822_parse_adrlist -- Parses an address string

Description

array imap_rfc822_parse_adrlist ( string address, string default_host )

Parses the address string as defined in RFC2822 and for each address.

Parameters

address

A string containing addresses

default_host

The default host name

Return Values

Returns an array of objects. The objects properties are:

Examples

Example 1. imap_rfc822_parse_adrlist() 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\n");
}

foreach (
$address_array as $id => $val) {
    echo
"# $id\n";
    echo
"  mailbox : " . $val->mailbox . "\n";
    echo
"  host    : " . $val->host . "\n";
    echo
"  personal: " . $val->personal . "\n";
    echo
"  adl     : " . $val->adl . "\n";
}
?>

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()

Grzejniki
Wycieraczki
kredyt hipoteczny doradca finansowy wrocław
kredyt banki
Koszulki

Another Useful functions:


function.imap-utf8 | function.imap-utf7-encode | function.imap-utf7-decode | function.imap-unsubscribe | function.imap-undelete | function.imap-uid | function.imap-timeout | function.imap-thread | function.imap-subscribe | function.imap-status | function.imap-sort | function.imap-setflag-full | function.imap-setacl | function.imap-set-quota | function.imap-search | function.imap-scanmailbox | function.imap-savebody | function.imap-rfc822-write-address | function.imap-rfc822-parse-headers | function.imap-rfc822-parse-adrlist | function.imap-reopen | function.imap-renamemailbox | function.imap-qprint | function.imap-ping | function.imap-open | function.imap-num-recent | function.imap-num-msg | function.imap-msgno | function.imap-mime-header-decode | function.imap-mailboxmsginfo | function.imap-mail | function.imap-mail-move | function.imap-mail-copy | function.imap-mail-compose | function.imap-lsub | function.imap-listsubscribed | function.imap-listscan | function.imap-listmailbox | function.imap-list | function.imap-last-error | function.imap-headers | function.imap-headerinfo | function.imap-header | function.imap-getsubscribed | function.imap-getmailboxes | function.imap-getacl | function.imap-get-quotaroot | function.imap-get-quota | function.imap-fetchstructure | function.imap-fetchheader | function.imap-fetchbody | function.imap-fetch-overview | function.imap-expunge | function.imap-errors | function.imap-deletemailbox | function.imap-delete | function.imap-createmailbox | function.imap-close | function.imap-clearflag-full | function.imap-check | function.imap-bodystruct | function.imap-body | function.imap-binary | function.imap-base64 | function.imap-append | function.imap-alerts | function.imap-8bit |


PHP is a widely-used general-purpose scripting language that is especially suited for Web development and can be embedded into HTML. If you are new to PHP and want to get some idea of how it works, try the introductory tutorial. After that, check out the online manual, and the example archive sites and some of the other resources available in the links section.