Latest AJAX Interview Questions and Answers

Read Top AJAX Interview Questions and Answers Experienced, Freshers for Job Interview Quiz with Solutions.

What are the protocols used by Ajax?

XMLHttpRequest for placing a request with the web server
Uses JSON to communicate between the client and server
UED or URL encoded data.

What are all the security issues of Ajax?

Security issues that can be encountered
When Ajax calls are sent through plain text and it may lead to know the database details
Inserting scripts can also be possible and attackers can easily penetrate into the system.

How can we handle concurrent requests?

Javascript functions should be written to handle concurrent requests and call back function can be passed as a parameter. Those parameters are passed to AjaxInteraction(URL, callback) object.

Define the role of the Update Panel?

Update Panel is used to add functionality to the existing ASP.NET applications. By using partial page rendering, it can be used to update the content. Refresh can be made for the partial page instead of whole page.

Can we use nested update panel in Ajax?

Yes, we can use nested update panel in Ajax. Update panels can be nested to have more control over the Page Refresh.

What are the types of post back in Ajax?

There are two types of post backs:
Synchronous Postback
Asynchronous Postback

How can we handle exception handling in Ajax?

ErrorTemplate which is the child tag of Script Manager is used to handle exception handling in Ajax.

What are the components of the ASP.NET Ajax Client Library?

Following components are used in Ajax client library:
Component Layer
Core Services Layer
Browser Compatibility Layer

What are the controls of the Script Management group?

The controls of script Management group are:

What are all the different data types that JSON supports?

JSON supports following data types:

What are the goals of Ajax?

The basic goals of ASP.NET Ajax are:
Reduced web server hits
Reduced Network load
Interactive user interface
Platform and architecture neutrality
Support for both synchronous and asynchronous communication
Provide a server- and client-side framework

What is the difference between proxied and proxyless calls in AJAX?

Proxied calls are made through stub objects which can be called from PHP classes on the JavaScript side in AJAX.
Proxyless calls are made using utility JavaScript functions like HTML_AJAX.replace() and HTML_AJAX.append() in AJAX.

How many types of ready states in Ajax?

There are four ready states in Ajax:

What is the difference between RegisterClientScriptBlock, RegisterClientScriptInclude and RegisterClientScriptResource?

Following are the functions:
RegisterClientScriptBlock – The script is specified as a string parameter.
RegisterClientScriptInclude – By setting the source attribute to a URL that point to a script file.
RegisterClientScriptResource – specifies Resource name in an assembly. The source attribute is automatically populated with a URL by a call to an HTTP handler that retrieves the named script from the assembly.

Which request is better, Get or Post?

AJAX requests should use an HTTP GET request where the data does not change for a given URL requested.
An HTTP POST should be used when state is updated on the server. This is highly recommended for a consistent web application architecture.


Popular posts from this blog

TOP Agile Testing Interview Questions and Answers

Latest Agile Testing Interview Questions and Answers

Most Asked ADO.NET Interview Questions and Answers