Display data returned from Ajaxservices!!


Posted on 16th Feb 2014 07:03 pm by admin

I have a question about displaying results using ajax. I have part of the code below.
$.ajax({ type: "POST", url: "AJAXServices.asmx/GetTechInfo", data: '{ "fieldName": ' + hoverElement.attr("id"), contentType: "application/json; charset=utf-8", dataType: "json", success: function(results) { $.each(results.d, function() { //var html = results.d[0]; var html = $('.ttTopLeft').append(results.d[0]); $(contentElement).html(html); });

$.ajax({ type: "POST", url: "Service.asmx/GetMethod", data: '{ "field": ' + id, contentType: "application/json; charset=utf-8", dataType: "json", success: function(results) { $.each(results.d, function() { //var html = results.d[0]; var html = $('.ttTopLeft').append(results.d[0]); $('type').html(html); });
Need to display the data in d[0]. It consists of 3 pieces of data - product id, product name, product description. I need to figure out a way to display it (with css and having more control on my end). Please help
Thanks,SA
Filed under: JSON AJAX ASP.NET

No comments posted yet

Your Answer:

Login to answer
93 Like 45 Dislike
Previous forums Next forums
Other forums

jquery validation in codeIgniter
hai i need to add client side validation to my fiels which are selected in a forloop.the fields are

My XSRF Prevention code isn't working
First of all, thanks for the generous help you guys have given me in the past on this forum.
Seco

need to apply an if/else statement to Tim Thumb script
Not sure how to work this. I essentially want to call a variety of image sizes based on which style

Production of mango in processing industry
Hi,

We have one scenario ,company is in process industry,they are manufacturing MANGO pul

From Header Showing 'Unkown' In Hotmail? Why?
Code: $to = $row_GetID['email_addr'].',sales@mywebaddress.co.uk';
$subject = 'Thank you for you

path to include folder
Hi everyone,

When I'm testing locally, I have to add the name of the site folder as part of t

PHP Display Telephone Number On Referrer
I have used the php below to show a different telephone number in the header of the site depending u

WHYISNT THIS MYSQL STATEMNT NOT WORKING? (php)
caps because its absolutely rediculous.
i dontunderstand why its not working. there is a column c

WORDPRESS - Multiple Loops Only Going to One Post?
I have various pages with multiple loops and i need them to be individual to all other categories.

value not going in data base
hello friends....
i am having a working javascript....when i am selecting any

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash