开发者

Use javascript to call web service

开发者 https://www.devze.com 2023-03-18 02:29 出处:网络
There\'s a web service, for example this http://www.w3schools.com/webservices/tempconvert.as开发者_StackOverflow社区mx

There's a web service, for example this http://www.w3schools.com/webservices/tempconvert.as开发者_StackOverflow社区mx

How to invoke its web methods from javascript?


Due to same origin policy restriction you cannot invoke it with javascript as this web service is not hosted on the domain where your script will be served from. In order to invoke it you will need to setup a server side script on your domain which invokes the service and then send an AJAX request to your script.

0

精彩评论

暂无评论...
验证码 换一张
取 消