Login for Webservice

Login for Webservice

Hey guys ,
Please take a look

function AutheUser ()
         {
                

                var soapRequest =
                        '<?xml version="1.0" encoding="utf-8"?> \
                        <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" \
                            xmlns:xsd="http://www.w3.org/2001/XMLSchema" \
                            xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> \
                          <soap:Body> \
                            <Authenticate xmlns="http://tempuri.org/"> \
                              <strUsername>' + $("#uname").val() + '</strUsername> \
                              <strPassword>' + $("#upass").val() + '</strPassword> \
                            </Authenticate> \
                          </soap:Body> \
                        </soap:Envelope>';
                        
                $.ajax({
                    type: "POST",
                    url: "http://XXXXXXXX/XXXXXXXX/Service1.asmx?op=Authenticate",
                    contentType: "text/xml",
                    dataType: "xml",
                    data: soapRequest,
                    success: processSuccess,
                    error: processError
                });

           
        }

        function processSuccess() {
            if (status == "success")
                alert("CONNECT");
        }

        function processError() {
            alert("NOT CONNECT");
        }  
 }


this codes is put in other js file. i hve a button calling this function to request the response from the Web service. but i think there is problem in my code. by the way Im using Icenium with Jquery Mobile Framework. Thanks for response