dtf1111 2012-08-16 17:04
浏览 101
已采纳

PHP SharePoint API文档子目录列表

I've just implemented the SharePointAPI for PHP which can be found https://github.com/thybag/PHP-SharePoint-Lists-API

I was able to retrieve all of the SharePoint Lists from the WSDL, and was able to use the ->read($list) function to retrieve a List which holds Document folders and files.

Within the list, if the item is a file, I'm able to download it fine. However, if the item is another folder (a subdirectory), how do I access that directory's folders and files?

The ->read($list) function doesn't work, and I'm kind of at a loss. Does anybody know how I can read a List item's folders and files as it were a List?

Thanks alot

  • 写回答

1条回答 默认 最新

  • drzrzzkh462254 2013-07-01 14:26
    关注

    Although part of me suspects you are probably the person who ended up managing to answer their own question over on the github issues; I thought I may as well repost that answer here in case others have the same problem.

    Essentially (although its a bit of a work around) you can get a listing of the contents of a folder in a sharepoint list, by calling the following method:

    $sp->read($listName,
              NULL,//$limit 
              NULL,//$query
              NULL,//$view 
              NULL,//$sort 
              "<Folder>" . $listName . "\\" . $folderName . "</Folder>"//$options 
    )
    

    Hopefully once manage to find a bit of spare time, I'll add a dedciated method for doing this to the library, just to make it a little more straight forward in future.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 目标检测项目无法读取视频
  • ¥15 GEO datasets中基因芯片数据仅仅提供了normalized signal如何进行差异分析
  • ¥15 小红薯封设备能解决的来
  • ¥100 求采集电商背景音乐的方法
  • ¥15 数学建模竞赛求指导帮助
  • ¥15 STM32控制MAX7219问题求解答
  • ¥20 在本地部署CHATRWKV时遇到了AttributeError: 'str' object has no attribute 'requires_grad'
  • ¥15 vue+element项目中多tag时,切换Tab时iframe套第三方html页面需要实现不刷新
  • ¥50 深度强化学习解决能源调度问题
  • ¥15 一道计算机组成原理问题