惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

月光博客
月光博客
Microsoft Security Blog
Microsoft Security Blog
T
Threatpost
D
DataBreaches.Net
B
Blog RSS Feed
GbyAI
GbyAI
T
The Blog of Author Tim Ferriss
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
N
Netflix TechBlog - Medium
O
OpenAI News
Webroot Blog
Webroot Blog
Stack Overflow Blog
Stack Overflow Blog
Recent Announcements
Recent Announcements
Google Online Security Blog
Google Online Security Blog
SecWiki News
SecWiki News
H
Help Net Security
Forbes - Security
Forbes - Security
N
News and Events Feed by Topic
aimingoo的专栏
aimingoo的专栏
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
腾讯CDC
B
Blog
H
Heimdal Security Blog
博客园 - 三生石上(FineUI控件)
C
CERT Recently Published Vulnerability Notes
L
Lohrmann on Cybersecurity
G
Google Developers Blog
Scott Helme
Scott Helme
C
CXSECURITY Database RSS Feed - CXSecurity.com
罗磊的独立博客
V
Visual Studio Blog
L
LINUX DO - 热门话题
T
Threat Research - Cisco Blogs
T
The Exploit Database - CXSecurity.com
F
Full Disclosure
C
Cisco Blogs
The Last Watchdog
The Last Watchdog
Security Archives - TechRepublic
Security Archives - TechRepublic
F
Fortinet All Blogs
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Google DeepMind News
Google DeepMind News
S
Security Affairs
P
Privacy & Cybersecurity Law Blog
S
Secure Thoughts
V
V2EX
雷峰网
雷峰网
Security Latest
Security Latest
H
Hacker News: Front Page
TaoSecurity Blog
TaoSecurity Blog
M
MIT News - Artificial intelligence

博客园 - sdxd.bgl

将SQL Server中的数据显示到SharePoint中 拓展训练总结 在PowerShell中,如何获取SharePoint的默认数据库服务器 恢复导出XSLT List View WebPart 实战部署FAST Search Server 2010 for SharePoint Sharepoint开发中代码运行权限级别 在InfoPath中如何获取当前用户的信息(Profile) 晒晒我的家乡 关于模式的思考 小心委托 利用System.Linq.Expressions实现四则运算计算器(三) 利用System.Linq.Expressions实现四则运算计算器(二) 利用System.Linq.Expressions实现四则运算计算器(一) 初识System.Linq.Expressions 请拆招:将两个已排序集合分解成两个独立部分的集合和一个共有部分的集合? 如何实现Windows服务 用javascript实现下拉列表的自动筛选功能 - sdxd.bgl - 博客园 我的生活 电脑是个神奇的东西!
在SharePoint页面中如何显示来自其他网站的List
sdxd.bgl · 2011-09-30 · via 博客园 - sdxd.bgl

(作者:闪电,转载请注明出处

  为了方便用户使用,我们会把SharePoint网站设计成层次结构,并希望用户在主页上看到来自子网站的内容。比如希望把放在父网站的一个列表的内容显示在子网站的主页上面。这种需求看起来稀松平常,但实际上不容易。

  为了说明方便,我把列表所在的网站称为源网站,需要显示WebPart的网站称为目标网站。

  实现思路很简单:在源网站的页面上插入一个列表WebPart,然后导出该WebPart,在目标网站上,将刚导出的WebPart导入,之后在目标网站的页面上插入导入的WebPart。

  如何导出一个WebPart。首先打开页面,进入编辑模式,在WebPart右上角有个小三角,点开是一个菜单,有个命令"导出",页面会弹出保存WebPart文件,先把它保存到本地。

  如果没有导出命令怎么办?请看《恢复导出XSLT List View WebPart

  来一段小插曲,为了在其他网站能够使用该WebPart,需要修改下导出来的文件。用记事本打开它。找到<property name="WebId"节点,将源网站的WebID替换节点内容。WebID可以通过下面的PowerShell脚本获得。

if ((Get-PSSnapin | Where {$_.Name -eq "Microsoft.SharePoint.PowerShell"}) -eq $null)
{
Add-PSSnapin Microsoft.SharePoint.PowerShell;
}
$web = Get-SPWeb http://chenweifeng
Write-Output $web.ID

  为了能够在插入WebPart的时候能够选到刚才导出的WebPart,需要将刚才导出的WebPart上传到Web部件库中。Web部件库的地址是/catalogs/wp/ 。

  现在就可以在同一网站集的任何网站插入刚才的WebPart了!

  插入之后,还可以对该WebPart进行编辑。