jQuery Encrypted API - XML display -


is there way parse xml encrypted api via jquery? need use ajax? have examples? have:

http://www.mysite.com/net/webservice.aspx?login=email@email.com& encryptedpassword=xxxxx&edi_name=generic\products&  select_columns=p.productcode,pe.productprice 

this returned xml return , parse table or something:

<?xml version="1.0" encoding="iso-8859-1"?> <export> <products_joined>   <productcode>product 1</productcode>   <productprice>1500</productprice> </products_joined> </export> 

yes, assuming have access run javascript on server, this:

var url = 'http://www.mysite.com/net/webservice.aspx?...'; $.ajax({     type: 'get',     url: url,     datatype: 'xml',     success: function(xml) {         var table = $('#mytable-id');         $(xml).find('products_joined').each(function(){             var product = $(this),                 code = product.find('productcode').text(),                 price = product.find('productprice').text();              $('<tr />').append('<td>' + code + '</td>')                 .append('<td>' + price + '</td>')                 .appendto(table);         })     } }); 

Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -