http://forums.devshed.com/javascript-development-115/prototype-returning-xml-379021.html
On Jan 17, 2:30 pm, Oishe
<jewel.cse....-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> Hi every body!
> Hope all fine
>
> I m here just for ur help.
>
> i want to return a ajax request which return type will in XML using
> prototype.
>
> What will the prototype ajax option configuration?
>
> Please help me if possible with in today
>
> Bye all
>
> My code like this
> function Claulate()
> {
> busyFunction(true);
> var empID = $F(''tField1'');
> var amountTK = $F(''amountTK'');
> var url =
''http://localhost/jibon/jlab/calculateAjaxFunction.php'';
> var a = {
> empID: empID,
> amountTK: amountTK,
> third: 30
> };
> var pars = new Hash(a).toQueryString();
>
> var myAjax = new Ajax.Request(
> url,
> {
> method: ''get'',
> parameters: pars,
> contentType :
''application/XML'',
> requestHeaders:
''XMLHttpRequest'',
> onComplete: showResponse
> });
>
> }
>
> function showResponse(xmlHttpRequest, responseHeader)
> {
> var xmlMessage = xmlHttpRequest.responseXML;
> var textMessage = xmlHttpRequest.responseText;
> busyFunction(false);
> alert(textMessage); //Working nice
> alert(xmlMessage); //Not working
> }
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to
rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---