imap_header problem?
| From: | Bram de Kruijff | Date: | Thu, 04 May 2000 15:38:33 +0000 |
| Subject: | imap_header problem? | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-14472@lists.php.net to get a copy of this message | ||
Hi all,
I'm having some trouble getting info out of
e-mailheaders using the imap_header function
and now have run out of ideas/documentation :(
What do I want?
-> To retrieve all cc-addresses..
Did I rtfm?
-> Yes I did :)
What does the manual say?
-> cc[] (returns an array of objects from the Cc line, containing:)
So what's the problem?
-> If I use $header->cc[] nothing happens besides besides the
fact that I get a "Document contained no data" from ns.
If I use $header->cc I do get an array, but it only contains
one object corresponding to the first cc-address.
What do I do?
<?
$header = imap_header($imap_stream,$mesg_number);
if($tempArr = $header->cc){
while($tempObj = current($tempArr)){
$mailAdr .= $tempObj->mailbox."@".$tempObj->host;
if(next($tempArr)){
$mailAdr .= ",";
}
}
}
?>
Could anyone please tell me what I'm doing wrong??
many thanks!
Bram
--
__\/__
. / ^ _ \ .
|\| (o)(o) |/|
#----------------.OOOo--oo--oOOO.-----------#
# #
# e-mail : bram@atoom.net #
# www : http://www.atoom.net #
# phone : +31(0)243604137 #
# mobile/sms: +31(0)627124875 #
# #
#_________________________Oooo._____________#
.oooO ( )
( ) ) /
\ ( (_/
\_)