borisreitman / crossxhr Goto Github PK
View Code? Open in Web Editor NEWCross Domain XHR: A drop-in replacement for XmlHttpRequest object.
Home Page: http://code.google.com/p/crossxhr/wiki/CrossXhr
Cross Domain XHR: A drop-in replacement for XmlHttpRequest object.
Home Page: http://code.google.com/p/crossxhr/wiki/CrossXhr
Cross Domain XHR: A drop-in replacement for XmlHttpRequest object. Demo: http://random.hypervolume.com/crossxhr.html Wiki: http://code.google.com/p/crossxhr/wiki/CrossXhr Props: http://www.propster.me/tipjar/crossxhr_1
I tried to do:
$.ajax({
type: 'GET',
dataType: 'html',
xhr: function(){return new CrossXHR();},
url: "http://"+ encodeURI(opt.url),
success:function(data){
console.log('success');
console.log(data);
//callback(data);
},
error: function(jqXHR,errtype,errObj) {
console.log("jqXHR");
console.log(jqXHR);
console.log("errtype");
console.log(errtype);
console.log("errObj");
console.log(errObj);
}
});
But I get:
"'undefined' is not a function (evaluating 'xhr.getAllResponseHeaders()')"
There are other things like this out there (ex: http://www.jimbojw.com/wiki/index.php?title=SWFHttpRequest.hx ) but this is the only one I was able to see work (at least without jQuery) on my MacBook Pro with the latest Flash Plugin installed.
There's no JS errors and I'm not very familiar with flash debugging so I can't provide any more details. The only thing I see is that there is a network request, but the result does not appear on the webpage.
The JS could be a little more nice. Ex. Use of closures. document.write is a no no for lazy loading.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.