title: How to call webservice in Javascript for Firefox 3.0
body: <p>I have a problem with calling .Net web services with a Firefox
  client. A simple example will be enough for me.</p>
  
  <p>Server side code is like this:</p>
  
  <pre><code>[WebService(Namespace = "http://tempuri.org/")]
  [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
  [ToolboxItem(false)]
  public class Service1 : System.Web.Services.WebService
  {
  [WebMethod]
  public string HelloWorld()
  {
  return "Hello World";
  }
  }
  </code></pre>
  
  <p>Client side .html code:</p>
  
  <pre><code>Hello World Denemesi&lt;br /&gt;
  type="text" disabled="disabled" /&gt;&lt;/td&gt; 
  value="Print"           onclick="print()"&gt; &lt;/td&gt;
  </code></pre>
  
  <p>Client side .js code:</p>
  
  <pre><code>var callObject;
  function init(){
  service.useService( "Service1.asmx?WSDL","Service");
  callObject = service.createCallOptions();
  callObject.async = false;
  
  }
  function print(){
  callObject.funcName = "HelloWorld";
  var oResult = service.Service.callService(callObject );
  if( !oResult.error )
  {
  edtHelloWorld.value = oResult.value;
  }
  }
  </code></pre>
  
  <p>This web service works on IE but doesn't run at firefox because
  webservice.htc (behaviour file) doesn't work for firefox. I need a
  javascript or something like that wihch I cann use instead of htc
  file...</p>