You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Matej Knopp (JIRA)" <ji...@apache.org> on 2007/05/05 11:19:15 UTC

[jira] Commented: (WICKET-534) Add a parameter to toggle an AJAX call between asynchronous and synchronous

    [ https://issues.apache.org/jira/browse/WICKET-534?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12493869 ] 

Matej Knopp commented on WICKET-534:
------------------------------------

I don't say this would be difficult to add but why on earth would anyone want to do that? Synchronous requests are evil and they lock the browser...

> Add a parameter to toggle an AJAX call between asynchronous and synchronous
> ---------------------------------------------------------------------------
>
>                 Key: WICKET-534
>                 URL: https://issues.apache.org/jira/browse/WICKET-534
>             Project: Wicket
>          Issue Type: Improvement
>          Components: wicket
>    Affects Versions: 1.2.6
>            Reporter: James Renfro
>         Assigned To: Matej Knopp
>            Priority: Minor
>
> When using AJAX in certain special cases it may be helpful to make XMLHttpRequest calls with the async parameter set to 'false'. This can be accomplished by modifying the code under wicket-ajax.js -- but it would be nice to have a parameter in the Java code that set the request to synchronous for the length of that call. 
> <snip file="wicket-ajax.js">
> Wicket.Ajax.Request.prototype = {
>    initialize: function(url, loadedCallback, parseResponse, randomURL, failureHandler, channel) {
>        this.url = url;
>        this.loadedCallback = loadedCallback;
>        this.parseResponse = parseResponse != null ? parseResponse : true;
>        this.randomURL = randomURL != null ? randomURL : true;
>        this.failureHandler = failureHandler != null ? failureHandler : function() { };
>        this.async = true;
>        this.channel = channel;
>        this.suppressDone = false;
>        this.instance = Math.random();
>        this.debugContent = true;
>    },
> </snip> 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.