I had issues with imap_status not working correctly, while other imap functions seemed okay. I always got the ['flags']=0 response. No notes here and Google searching suggests it doesn't working properly with Exchange, so I wrote a little workaround, to at least get some information.
function my_imap_status($stream, $mailbox='', $info=SA_ALL)
if(!$curr_obj) return false;
if( (empty($mailbox)) || ($mailbox==$curr_obj->Mailbox) ) return $curr_obj;
if(!imap_reopen($stream, $mailbox)) return false;