XMLHTTPJSClass - JSON Class for Ajax Operations(aspdotnetmatters.blogspot.com)

submitted by ashishsarda99ashishsarda99(220) 1 year, 9 months ago

In the development of Ajax application many times we may come across following issues. * Need to update multiple text boxes simultaneously. * Fill more that one dropdown lists. * Combination of text boxes, dropdown lists and div tags. * Calling different web pages and different webservices Means one event may lead to updating of many html elements. In such cases we will have to send Ajax request in a loop. Again for each request we will have to take care of timeouts and request failures. Here if data is static we can keep it on HTML page and using JavaScript can directly hide and show the contents. But if we have to use real time data and also choices of display vary according to choices of the user, in such case looping of Ajax request may not be a good idea. In this article we will discuss about XMLHTTPRequest object and JavaScript. We will develop a JavaScript class in which we can vary our choices and also be able to update multiple HTML contents. Also this class can be extended as per the requirements. We will first talk about class in JavaScript, there is no keyword called class in JavaScript but we can use function as a class.

add a comment |category: |Views: 9

tags: another

new Add a live kick counter to your blog >> liveImage

You can even customize the image by choosing your own colors, and then clicking the button below to update the preview and the html code:

  • "Kick It" text
  • "Kick It" background
  • kick count text
  • kick count background
  • border

Simply copy and paste this HTML into your blog post.


Users who kicked this story:
Comments:

No comments so far

information Login or create an account to comment on this story