I used the following code to access the sharepoint from javascript
var soapDataString = "<soap:Envelope xmlns:xsi='http://ift.tt/ra1lAU' xmlns:xsd='http://ift.tt/tphNwY' xmlns:soap='http://ift.tt/sVJIaE'> \
<soap:Body> \
<Login xmlns='http://ift.tt/rrg8m0'> \
<username>testUser</username> \
<password>testPwd</password> \
</Login> \
</soap:Body> \
</soap:Envelope>"
// Call web service
$.ajax({
url: "http://abc-xyz-sp06/YY-SHAREPOINT/_vti_bin/Authentication.asmx",
type: "POST",
dataType: "xml",
data: soapDataString,
success: resultsFeedback,
contentType: "text/xml; charset=\"utf-8\""
});
function resultsFeedback(xData, status) {
alert(xData);
alert(status);
}
I followed from this article. I even put the above code in the ready
function. But the function not entering into resultsFeedback
and nothing happens. I am not able to sign-in
from the javascript
.
0 commentaires:
Enregistrer un commentaire