
We can call a web service in Internet Explorer using the webservice.htc approach. But this does not work in firefox. Working on a website which required web service for polling, I developed this code which uses XMLHttpRequest object to call a web service and even post data. It is actually availaible at multiple places, webservice.htc at one place, post using XMLHttpRequest at another place and so on. I've aggregated it. The most important thing to be here would be that for this approach to work, web service must be able to communicate using HTTP Post and HTTP Get.
|