php-ews
php-ews copied to clipboard
Help Wanted: Enumerating Exch2010 Public Folder structure
Version (e.g. 1.0, dev-master): 1.0 PHP version: 7.0 Microsoft Exchange version: 2010 SP3
Looking for a little info from anyone that understands EWS better than I at present. I'm retooling a script I wrote for my employer - the old script automagically copied emails from staff Inbox and Sent Items into the Public Folders structure (Exchange 2003) using WEBDAV and Troy Wolf's screen scraping classes for HTTP and XML. It wasn't pretty or elegant (or fast), but it worked.
We've now upgraded to Exchange 2010, and I'm having to revisit code I wrote the best part of a decade ago. I'm beginning to get my head around php-ews (and it's great James, BTW), but...
I'm starting out with trying to enumerate the Public Folders structure (eventually into a DB table, but to screen to start with). I munged the Find Items example with some code from StackExchange and got the first level PF contents (Display Name and ID) no problem, but now I'm trying to get the code iterating I'm hitting the hurdle - the ID I get back in the response message (FolderId->Id) isn't the same as the ID that DistinguishedFolderId->Id is expecting to receive. Have I gotten things very messed up in my head? I kinda hoped that FolderId->Id would have "just worked".