09-17-2012 07:31 AM
Hi
can you please tell me how to call soap based web service in phonegap.?
actually i have some methods having parameter in web service want to call that those methods, can you please help me.
Thanks
09-17-2012 08:27 AM
Hi there,
Did these examples not work? http://supportforums.blackberry.com/t5/Web-and-Web
09-17-2012 08:28 AM
NO sir ........
where i write method name..?
09-17-2012 08:32 AM
Hi
it doesn't help me because in my web service i want to call web method ..
http://railapps.firstgroup.com/FirstGroupRailApps/
example : getversion.
but where i write my web method please help
09-17-2012 12:03 PM
Hi
i want to call soap based web service i got simple way to call web service from this url..
http://stackoverflow.com/questions/124269/simplest
But i don't understand where to add method name so that it call that method from service, in web service there are some method which i want to call but unable to call
can you please help me..
<html>
<head>
<title>SOAP JavaScript Client Test</title>
<script type="text/javascript">
function soap() {
var xmlhttp = new XMLHttpRequest();
********here is my url ******but where is method name which i want to call
xmlhttp.open('POST', 'https://somesoapurl.com/', true);
// build SOAP request
var sr =
'<?xml version="1.0" encoding="utf-8"?>' +
'<soapenv:Envelope ' +
'xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ' +
'xmlns:api="http://127.0.0.1/Integrics/Enswitch/API" ' +
'xmlns:xsd="http://www.w3.org/2001/XMLSchema" ' +
'xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">' +
'<soapenv:Body>' +
'<api:some_api_call soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">' +
'<username xsi:type="xsd:string">login_username</username>' +
'<password xsi:type="xsd:string">password</password>' +
'</api:some_api_call>' +
'</soapenv:Body>' +
'</soapenv:Envelope>';
xmlhttp.onreadystatechange = function () {
if (xmlhttp.readyState == 4) {
if (xmlhttp.status == 200) {
alert('done use firebug to see responce');
}
}
}
// Send the POST request
xmlhttp.setRequestHeader('Content-Type', 'text/xml');
xmlhttp.send(sr);
// send request
// ...
}
</script>
</head>
<body>
<form name="Demo" action="" method="post">
<div>
<input type="button" value="Soap" onclick="soap();" />
</div>
</form>
</body>
<html>
09-17-2012 12:37 PM
I suggest you learn how to build a SOAP request first. The methods will be in the message you send.
09-17-2012 12:41 PM
can you please expain in detail..
actually i have this url http://railapps.firstgroup.com/FirstGroupRailApps/
i have lot of method there.
example getversion :
response will be 1.3
can you please give me some help
09-17-2012 12:52 PM - edited 09-17-2012 12:53 PM
This should give you an idea of what to look for:
http://wscep.sourceforge.net/createrequest.html
This will help you build the query:
http://www.soapclient.com/soapmsg.html
but this is not a WebWorks specific issue. You would have more luck asking in a forum dealing with SOAP queries.
09-17-2012 01:01 PM
sorry sir i am not getting any thing....![]()
actually i used this url http://www.codeproject.com/Articles/12816/JavaScri