SharePoint中传递Search参数的Url的一些研究
2008-04-07 16:48
232 查看
首先创建两个站点,主站点名字叫 Search, 在它下面有一个子站点, 名字叫Search_111。
在主站点的 default page中,SearchBox有三个选项:
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
This site: Search:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
在主站点的List中:
在Shared Documents list中, 他有4个选项.
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
This site: Search:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325
This List:Shared Documents:http://localhost:6325/_layouts/ OSSSearchResults.aspx?k=c&cs=This List&u=http://localhost:6325/Shared Documents
在子站点的 default page中.
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
This site: Search_111:http://localhost:6325/MMM/_layouts/ OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325/MMM
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
在子站点的Task List 中的选项如下:
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
This site: Search_111:http://localhost:6325/MMM/_layouts/ OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325/MMM
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
This List:Task:http://localhost:6325/MMM/_layouts/OSSSearchResults.aspx?k=c&cs=This List&u=http://localhost:6325/MMM/Lists/Tasks
所以,我猜测他在使用Url传递参数的时候,有两个规则:
Rule1:所有的 search box 包含三项, People, All sites 和 This Site: site name. 如果是 People 或 All sites, 参数为 k=keyword 和s= the scope(All sites or People).如果是This Site: site name,参数为 k=keyword, cs=This Site, u=current site's url.
Rule2: 如果当前是在一个List里面,他将包含另外一项, This List: List name. 参数为 k=keyword, cs=This List, u=current list's url.
但是在List里面没有Url这一项,
一些 list's 属性.
Documents->Shared Documents
ParentWeb.Url: http://localhost:6325
ParentWebUrl: /
DefaultViewUrl: /Shared Documents/Forms/AllItems.aspx
Description: Share a document with the team by adding it to this document library.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Shared Documents
Lists->Tasks
ParentWeb.Url: http://localhost:6325
ParentWeb.Url: /
DefaultViewUrl: /Lists/Tasks/AllItems.aspx
Description: Use the Tasks list to keep track of work your team needs to complete.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Tasks
Lists->Calendar
ParentWeb.Url: http://localhost:6325
ParentWeb.Url: /
DefaultViewUrl: /Lists/Calendar/calendar.aspx
Description: Use the Calendar list to keep in, deadlines, and other important events.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Calendar
Sub Lists->Document
ParentWeb.Url: http://localhost:6325/MMM
ParentWebUrl: /MMM
DefaultViewUrl: /MMM/Shared Documents/Forms/AllItems.aspx
Description: Share a document with the document library.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Shared Documents
我发现他有两个属性, DefaultViewUrl 和 Title, 所以我们可以通过这两个属性把它拼出来.
在主站点的 default page中,SearchBox有三个选项:
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
This site: Search:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
在主站点的List中:
在Shared Documents list中, 他有4个选项.
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
This site: Search:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325
This List:Shared Documents:http://localhost:6325/_layouts/ OSSSearchResults.aspx?k=c&cs=This List&u=http://localhost:6325/Shared Documents
在子站点的 default page中.
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
This site: Search_111:http://localhost:6325/MMM/_layouts/ OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325/MMM
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
在子站点的Task List 中的选项如下:
All sites:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=All Sites
This site: Search_111:http://localhost:6325/MMM/_layouts/ OSSSearchResults.aspx?k=c&cs=This Site&u=http://localhost:6325/MMM
People:http://localhost:6325/_layouts/OSSSearchResults.aspx?k=c&s=People
This List:Task:http://localhost:6325/MMM/_layouts/OSSSearchResults.aspx?k=c&cs=This List&u=http://localhost:6325/MMM/Lists/Tasks
所以,我猜测他在使用Url传递参数的时候,有两个规则:
Rule1:所有的 search box 包含三项, People, All sites 和 This Site: site name. 如果是 People 或 All sites, 参数为 k=keyword 和s= the scope(All sites or People).如果是This Site: site name,参数为 k=keyword, cs=This Site, u=current site's url.
Rule2: 如果当前是在一个List里面,他将包含另外一项, This List: List name. 参数为 k=keyword, cs=This List, u=current list's url.
但是在List里面没有Url这一项,
一些 list's 属性.
Documents->Shared Documents
ParentWeb.Url: http://localhost:6325
ParentWebUrl: /
DefaultViewUrl: /Shared Documents/Forms/AllItems.aspx
Description: Share a document with the team by adding it to this document library.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Shared Documents
Lists->Tasks
ParentWeb.Url: http://localhost:6325
ParentWeb.Url: /
DefaultViewUrl: /Lists/Tasks/AllItems.aspx
Description: Use the Tasks list to keep track of work your team needs to complete.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Tasks
Lists->Calendar
ParentWeb.Url: http://localhost:6325
ParentWeb.Url: /
DefaultViewUrl: /Lists/Calendar/calendar.aspx
Description: Use the Calendar list to keep in, deadlines, and other important events.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Calendar
Sub Lists->Document
ParentWeb.Url: http://localhost:6325/MMM
ParentWebUrl: /MMM
DefaultViewUrl: /MMM/Shared Documents/Forms/AllItems.aspx
Description: Share a document with the document library.
Direction: none
SendToLocationUrl:
SendToLocationUrl:
Title: Shared Documents
我发现他有两个属性, DefaultViewUrl 和 Title, 所以我们可以通过这两个属性把它拼出来.
相关文章推荐
- 关于一些url中传递参数有空格问题
- 通过window.location.search获取页面url传递的参数
- 前些天面试,发现原来做一个找回密码的链接是这么难的,大家想一下url应该传递一些什么参数。
- location对象,将url解析为独立片段search属性截取传递的参数
- 关于一些url中传递参数有空格问题
- Jni接口-深入研究参数的传递(一)
- JS,C#URL传递参数时的编码问题
- 如何防止url参数传递中文+乱码
- 关于前台URL传递中文参数到java后台乱码的问题
- 关于jsp中,以url形式传递中文参数的乱码的问题
- 在Silverligh中调用J“.NET研究”avascript (四种调用方法+简单与复杂参数的传递)
- ASP.NET页面通过URL传递参数(一)(转载)
- ThinkPHP pathinfo 模式下 url传递参数导致htim 无法加载css样式
- ASP.net使用URL传递中文参数
- 解决get方法传递URL参数中文乱码问题
- JS URL参数传递 谷歌乱码解决
- 通过JS获取url传递的参数(html可用)
- js的url传递中文参数乱码的解决方案
- asp中传递URL参数字符型转换为长整型
- 解决get方法传递URL参数中文乱码问题