Get item by sharepoint web service jquery
对于sp2010,在ie浏览器中这个代码无法生效,只有chrome可以生效。
//获取附件id
function GetAttachments(listName) {
var soapEnv = '<?xml version="1.0" encoding="utf-8"?>' +
' <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">' +
' <soap:Body>'+
' <GetListItems xmlns="http://schemas.microsoft.com/sharepoint/soap/">'+
' <listName>'+listName+'</listName>'+
' <viewName></viewName>'+
' <query><Query><Where><And><Contains><FieldRef Name=\'FileRef\'/><Value Type=\'Text\'>'+folderName+'</Value></Contains><Eq><FieldRef Name=\'ContentType\'/><Value Type=\'Text\'>图像</Value></Eq></And></Where></Query></query>'+
' <viewFields></viewFields>'+
' <rowLimit>10</rowLimit>'+
' <queryOptions xmlns:SOAPSDK9="http://schemas.microsoft.com/sharepoint/soap/"><QueryOptions><ViewAttributes Scope="Recursive" /></QueryOptions></queryOptions>'+
' </GetListItems>'+
' </soap:Body>'+
' </soap:Envelope>';
return $.ajax({
async: false,
url: "http://192.168.245.50:81/_vti_bin/lists.asmx",
type: "POST",
dataType: "xml",
data: soapEnv,
complete: ParseFirstAttachmentURL,
contentType: "text/xml; charset=\"utf-8\""
});
} function ParseFirstAttachmentURL(xmlData, textStatus) {
//alert(xmlData.responseText);
imageURL = $(xmlData.responseXML).find("Attachment").eq(0).text();
}
Get item by sharepoint web service jquery的更多相关文章
- SharePoint Web service and template
SharePoint Web service对应的映射列表 WSS Web Services Web Reference Administration Service http://<s ...
- Visual Studio 2010中创建ASP.Net Web Service
转自:http://blog.csdn.net/xinyaping/article/details/7331375 很多人在论坛里说,在Visual Studio 2010中不能创建“ASP.Net ...
- 在 Visual Studio 2010 中创建 ASP.Net Web Service
第一步:创建一个“ASP.Net Empty Web Application”项目 第二步:在项目中添加“Web Service”新项目 第一步之后,Visual Studio 2010会创建一个仅含 ...
- (转)在 Visual Studio 2010 中创建 ASP.Net Web Service
很多人在论坛里说,在Visual Studio 2010中不能创建“ASP.Net Web Service”这种project了,下面跟帖者云云,有的说这是因为微软已经将Web Service整合进W ...
- 如何使用Web Service新建和更新Wiki页面的内容
公司内部有很多部门都创建了Wiki库,来做知识共享.公司是Hosting的SharePoint环境,不能写服务器端代码,要操作Wiki只能通过Web Service来完成,所以,碰到两个情况: 1)W ...
- SharePoint 2013 APP 开发示例 (五)跨域访问 Web Service (REST API)
虽然 JQuery 也能通过授权header实现跨域, 但SharePoint 提供了更简单的方法,它被实现在SP.RequestExecutor里 .它能访问跨域的服务包括REST AP ...
- Customize the SharePoint 2013 search experience with a Content Enrichment web service
Did you ever wish you had more control over how your content is indexed and presented as search resu ...
- SharePoint 2013 APP 开发示例 (六)服务端跨域访问 Web Service (REST API)
上个示例(SharePoint 2013 APP 开发示例 (五)跨域访问 Web Service (REST API))是基于JavaScript,运行在web browser内去访问REST AP ...
- 在SharePoint中无代码开发InfoPath应用: 一个测试Web Service的工具
这是这个系列的第一篇,介绍一个小工具,主要是用在Web Service测试的. 因为为了用一点高级的东西,就免不了和web service打交道. 你可以使用按照KB819267来修改web.conf ...
随机推荐
- HTML5第二节
第二回合:HTML5的新特性 与之前的HTML4.01相比,HTML5增加了非常多的改变: ① 新的语义元素:<article>.<aside>.<figure>. ...
- 24个 HTML5 & CSS3 下拉菜单效果及制作教程
下拉菜单是一个很常见的效果,在网站设计中被广泛使用.通过使用下拉菜单,设计者不仅可以在网站设计中营造出色的视觉吸引力,但也可以为网站提供了一个有效的导航方案.使用 HTML5 和 CSS3 可以更容易 ...
- 对于placeholder浏览器兼容性(包括密码输入框)解决办法
将以下脚本和样式引入你的页面(对于密码输入框,要设置ID属性值): <script type="text/javascript"> $(function () { // ...
- Windows Azure Web Site (9) Web Site公网IP地址
<Windows Azure Platform 系列文章目录> 本文会同时介绍国内由世纪互联运维的Azure China和海外Azure Global. 熟悉Windows Azure平台 ...
- JS魔法堂:彻底理解0.1 + 0.2 === 0.30000000000000004的背后
Brief 一天有个朋友问我“JS中计算0.7 * 180怎么会等于125.99999999998,坑也太多了吧!”那时我猜测是二进制表示数值时发生round-off error所导致,但并不清楚具体 ...
- Lambda表达式演变
Lambda表达式是一种匿名函数. 演变步骤: 一般的方法委托 => 匿名函数委托 => Lambda表达式 Lambda表达式其实并不陌生,他的前生就是匿名函数,所以要谈La ...
- Razor练习3
Razor语法中,物质循环处理,它使用到三种: for, while,foreach. 下面Insus.NET分别在ASP.NET MVC环境中列举一个例子,附加源代码: while:<br / ...
- Needham-Schroeder加密算法小结
自己整理了下关于Needham-Schroeder加密算法的相关知识,如下图示.
- EF生成 类型“System.Data.Entity.DbContext”在未被引用的程序集中定义
错误描述: 1 类型“System.Data.Entity.DbContext”在未被引用的程序集中定义.必须添加对程序集“EntityFramework, Version=5.0.0.0, Cult ...
- Delphi 10.1 Berlin UTF8String Test
Delphi 10.1 Berlin UTF8String Test procedure TForm1.Button1Click(Sender: TObject); var s: UTF8String ...