Cross site Ajax plugin for Prototype

2 בדצמבר 2008

Thierry Schellenbach has implemented a Prototype plugin that allows you to do cross site remoting using the dynamic script tag method that other frameworks such as Dojo and jQuery have supported for awhile.

You can implement this by simply setting crossSite: true as a config parameter to Ajax.Request.

Code example:

new Ajax.Request('myurl', {
method: 'GET',
crossSite: true,
parameters: Form.serialize(obj),
onLoading: function() {
//things to do at the start
onSuccess: function(transport) {
//things to do when everything goes well
onFailure: function(transport) {
//things to do when we encounter a failure
the full information can be found on Thierry Schellenbach blog

Add comment
facebook linkedin twitter email

Leave a Reply to Jonathan Ranes Cancel Reply

Your email address will not be published.

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>


one comment

  1. Jonathan Ranes27 במרץ 2009 ב 18:07

    The Schellenbach plugin is tested to work with Safari and several other browsers. Is there one for JQuery this is also tested for all browsers? I am not aware of one.