如何将一堆 aspx 文件添加到站点定义 sp2010 vs2010 项目
当配置站点(子站点,又名 Web)时,我需要能够部署一堆 aspx 文件。我添加了一个功能,但与 2010 或 sp2010 相比,似乎整个功能都发生了变化。我完全迷路了。我想做的就是在配置网络时部署这些页面。是否可以?
I need to be able to deploy bunch of aspx files when a site (sub-site aka web) is provisioned. I added a feature but it seems whole feature thing has changed with vs 2010 or sp2010. I am totally lost. All I want to do is to deploy these pages when a web is provisioned. Is it possible?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您不能将 aspx 页面放入 SharePoint 中。如果您想添加功能,一些选项是:
1) 使用 Web 部件 - 可能是最流行的方法
2) 用户控件
最终,您将在 VS 中使用 VSeWSS 3.0 将其创建为功能并打包/将其作为解决方案进行部署。避免尝试在 SharePoint Designer 中解决此问题 - 首先,您不会像功能那样拥有源代码控制。
http://www.andrewconnell.com/blog/articles/UsingCodeBehindFilesInSharePointSites.aspx
http://www.codersbarn.com/?tag=/webpart
You can't drop aspx pages into SharePoint per say. If you want to add functionality, some of the options are:
1) Using Web Parts - probably the most popular method
2) User Controls
At the end of the day, you will create it as a Feature using VSeWSS 3.0 in VS and packaging/deploying it as a solution. Steer clear of trying to hack this up in SharePoint Designer - for one, you won't have source control like you have with a Feature.
http://www.andrewconnell.com/blog/articles/UsingCodeBehindFilesInSharePointSites.aspx
http://www.codersbarn.com/?tag=/webpart