07-03-2015 01:26 PM
07-08-2015 10:36 AM
How about we try these ideas for making the jQuery call work.
Browsers often append to the contentType (unknown to you). Which is why it might work in a browser. Try fully qualifying the contentType, for example add …charset=utf-8 (for example: “application/xml; charset=utf-8”), or do not set the contentType, and let jQuery provide a default value.
You may need the headers set (json or xml)…
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json'
},
Or, simplify the “accept” option, to json or xml.
07-08-2015 10:51 AM
Thanks I got it to work beautifully. The login dialog was suppressed and I was able to get an XML back from the ajax call
Using these ajax options:
Now I am trying to connect jabber getting this error when connecting. Any ideas? Am I sending the incorrect values/format?
With this call
These are the values being passed:
07-08-2015 10:59 AM
Could you debug in to the error, using Firebug in Firefox, or example. Try to see the value and what errors specifically are being sent. For example, what is the value of xmlstr.
It is probably not an issue with the jabberwersk.js file. I might be some setting, or how it is being used.
07-08-2015 11:13 AM
Here it is:
"<wrapper><body xmlns=\"http://jabber.org/protocol/httpbind\"
xmlns:NS1=\"\" NS1:xmlns:xmpp=\"urn:xmpp:xbosh\"
hold=\"1\" ver=\"1.9\" to=\"localhost\"
secure=\"true\" wait=\"30\" xmlns:NS2=\"\"
NS2:xmpp:version=\"1.0\" rid=\"1342545527\" /></wrapper><wrapper><body xmlns=\"http://jabber.org/protocol/httpbind\" xmlns:NS1=\"\" NS1:xmlns:xmpp=\"urn:xmpp:xbosh\" hold=\"1\" ver=\"1.9\" to=\"localhost\" secure=\"true\" wait=\"30\" xmlns:NS2=\"\" NS2:xmpp:version=\"1.0\" rid=\"1342545527\" /></wrapper>"
07-23-2015 08:02 AM
I apologize if I am not understanding the issue.
From reading the above returned XML, it don't see the error. is it just that there is no content? Is this the complete XML (is it SOAP)?
You will need to parse out the XML to find a response. And, there might not be a response with content, if a message was not created.
07-24-2015 12:50 PM
Hello,
After line 72 is called, it throws TypeError exception:
Its throwing TypeError exception once the XML string response is being parsed.
That XML string in the variable xmlstr was
""
So somehow the response from the Connect() is returning back an invalid XML string.
Thanks,
Jason Gonzales
1500 Dale Mabry HWY. Tampa, FL 33629
O 813.258.7055
C 813.657.6636
07-27-2015 08:59 AM
Is the XML you cut and pasted above, the entire XML being returned that is causing the problems, starting with <wrapper>?
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide