|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2008-08-07 09:42 UTC] jani@php.net
[2008-08-07 14:51 UTC] pavel at icewarp dot com
|
|||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 23:00:01 2025 UTC |
Description: ------------ Hi, is there any chance to write my own command to stream opened by imap_open ??? Since there is no function suitable to perform deletemailboxacl,I really need some solution I want to do something like this: <?php $stream = imap_open('127.0.0.1:143','john','doe'); fputs($stream,'a LIST "" "*"'); $response = fread($stream,4096); ?> I really do not want to do something like this: <?php //This is already done in my code $stream = imap_open('{127.0.0.1:143}','john','doe'); $folder = 'INBOX'; imap_reopen($stream,'{127.0.0.1:143}'.$folder); $opened = $folder; //Now I want to remove ACL for user 'mary@domain.com' //so I've got to following operation to remove acl and return //my application to the previus state: //Close php imap stream imap_close($stream); //Open my imap stream $stream = fsockopen('127.0.0.1','143'); //Re-login fputs($stream,'a LOGIN john doe'."\n"); $response = fread($stream,4096); //Re-select folder fputs($stream,'a SELECT '.$folder."\n"); $response = fread($stream,4096); //Remove ACL fputs($stream,'a DELETEACL '.$folder.' mary@domain.com'."\n"); $response = fread($stream,4096); //Close my imap stream connection fclose($stream); //Re-open php imap stream $stream = imap_open('{127.0.0.1:143}','john','doe'); //Re-open last folder imap_reopen($stream,$folder); //Continue with work..... ?>