Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

34 lines (27 sloc) 0.805 kB
One second request, though requested second, should return before the 3 second request.<br />
<small>(Might not work in Opera because they do not support the async attribute at the moment)</small>
<button id="fetch">fetch!</button>
<pre id="returned"></pre>
<script src="/depender/build?require=More/Request.JSONP,Core/Element.Event"></script>
var returned ='returned');
$('fetch').addEvent('click', function(){
new Request.JSONP({
url: '/echo/jsonp/',
data: {delay: 3},
onComplete: function(){
returned.appendText('Three second request returned.\n');
new Request.JSONP({
url: '/echo/jsonp/',
data: {delay: 1},
onComplete: function(data){
returned.appendText('One second request returned.\n');
Jump to Line
Something went wrong with that request. Please try again.