Hi, > In place of "add.php" I want to pass a url of a third party site, > where my form elements will be submitted. > > such as - "http://www.aweber.com/scripts/addlead.pl" > > how do I pass this url to the Ajax.Updater??
In exactly the same way as "add.php". But having done that, you're trying to initiate a cross-origin request, which is a violation of the Same Origin Policy[1] and will typically be denied. To do this with Ajax.Updater, the remote site will have to implement CORS[2], granting permission to the origin of your document to POST it data, and your user would have to be using a CORS-enabled browser. Firefox, Chrome, and Safari (at least) implement CORS transparently (you don't have to do anything in your client code); IE6 and IE7 don't implement it at all; and IE8 implements it, but only if you use their special API for it (which Ajax.Updater currently doesn't). Another approach which is currently more broadly-supported on the client is to use JSONP[3], if the remote site supports that. You'll have to do it a bit manually, I don't think Prototype currently has any direct JSONP support. [1] http://en.wikipedia.org/wiki/Same_origin_policy [2] http://www.w3.org/TR/access-control/ [3] http://en.wikipedia.org/wiki/JSONP#JSONP HTH, -- T.J. Crowder Independent Software Consultant tj / crowder software / com www.crowdersoftware.com On Jun 6, 2:15 pm, arnab0143 <arnab0...@gmail.com> wrote: > Hi All, > > I'm trying to do the following... > > new Ajax.Updater( 'result', 'add.php', { method: 'post', parameters: $ > ('myform').serialize() } ); > > In place of "add.php" I want to pass a url of a third party site, > where my form elements will be submitted. > > such as - "http://www.aweber.com/scripts/addlead.pl" > > how do I pass this url to the Ajax.Updater?? > > Thanks & Regards, > > Arnab -- You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send email to prototype-scriptacul...@googlegroups.com. To unsubscribe from this group, send email to prototype-scriptaculous+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/prototype-scriptaculous?hl=en.