Translate

Monday 26 October 2015

Advantage to using ASP.Net MVC vs web forms

The main advantages of ASP.net MVC are:
  1. Enables the full control over the rendered HTML.
  2. Provides clean separation of concerns(SoC).
  3. Easy integration with JavaScript frameworks.
  4. Following the design of stateless nature of the web.
  5. RESTful urls that enables SEO.
  6. No ViewState and PostBack events
The main advantage of ASP.net Web Form are:
  1. It provides RAD development
  2. Easy development model for developers those coming from winform development.

Monday 12 October 2015

Set a delay in a jQuery / Ajax function

// set your delay here, 2 seconds as an example...
var my_delay = 2000;

// call your ajax function when the document is ready...
$(function() {
    callAjax();
});

// function that processes your ajax calls...
function callAjax() {
    $.ajax({
        // ajax parameters here...
        // ...
        success: function() {
            setTimeout(callAjax, my_delay);
        }
    });
}