|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2000-08-18 19:27 UTC] eric at otherways dot com
hi, guys
I found a weird problem, I suspect it is a version bug.
$mbox = imap_open("{".$server.":143}".$folder,$name,$passwd);
actually only can open my imap server INBOX folder,
whatever the value of $folder is.
It affects all other functions which only specific the stream name.
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 19:00:01 2025 UTC |
yeah, It was my mistake, could you please colse this bug ticket. sorry for that. anyway, I do have a problem about the imap_mailboxmsginfo, I know probably this is not place to ask this question, but I am anxious to get answer, if you think it is not proper, just delete my new comment. I tried to display all mailboxes information in on e page, but the following scripts doesn't work. does one page only can open one stream? <? $server="server"; $name="name"; $passwd="password"; $mbox = imap_open("{".$server."}","$name","$passwd") || die("can't connect: ".imap_last_error()); $list = imap_getmailboxes($mbox,"{".$server."}","%"); if(is_array($list)) { reset($list); while (list($key, $val) = each($list)) { $folder=$val->name; $mbox1 = imap_open("{".$server."}".$folder,"$name","$passwd",OP_HALFOPEN) || die("can't connect: ".imap_last_error()); $check = imap_mailboxmsginfo($mbox1); if($check) { $messages= $check->Nmsgs; $recent = $check->Recent; $unread = $check->Unread; $size = $check->Size; echo "(".$key.")".$folder."|".$messages."|".$recent."|".$unread."|".$size."<br>"; } else { print "imap_check() failed: ".imap_lasterror(). "<br>\n"; } imap_close($mbox1); } } else { print "imap_getmailboxes failed: ".imap_last_error()."\n"; } imap_close($mbox); ?>