« Back to IP Phone Services Questions

RE: Sending XML Object Using Javascript

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
I'm not getting errors from this, so I believe the authorization is successfull. However, I am not able to make my IP Phone 7942 chime. Any suggestions please? I am using Javascript.   var xml = new XMLHttpRequest();   xml.open("post", "http://172.25.11.59/CGI/Execute"); xml.setRequestHeader("Authorization", "Basic MTgyMjg6MTgyMjg="); xml.setRequestHeader('Content-Type', 'text/xml'); xml.send("");    

Modern browsers prevent 'cross origin' requests like this, where the host that provided the javascript is different from the host that the XMLhttpRequest is going to.
http://en.wikipedia.org/wiki/Same_origin_policy
The usual recourse is to have the javascript post a custom request back to the origin web server, and have the web server make the actual post to the phone (i.e. proxy)