No IsPostBack, using the AcceptVerbsAttribute


There is no IsPostBack -- everything is either a POST or GET (or other HTTP verb). You can limit the HTTP verbs that your action allows, i.e., you'll never see a request from a disallowed verb, using the AcceptVerbsAttribute. For example, the following only allows POSTs.
  [AcceptVerbs( HttpVerbs.Post )] 
 
[ValidateAntiForgeryToken] 
 
public ActionResult Update( int id ) 
 
{ 
 
} 

If you need to have the same action name do both GET/POST and they actually do different things, you can either give them separate signatures or use the ActionNameAttribute to alias one of the actions so the methods can have different names.
  [AcceptVerbs( HttpVerbs.Get)] 
 
public ActionResult List() 
 
{ 
 
} 
 
 
[AcceptVerbs( HttpVerbs.Post )] 
 
[ValidateAntiForgeryToken] 
 
public ActionResult List( string filter, int page, int limit ) 
 
{ 
 
} 

OR
  [ActionName( "List" )] 
 
[AcceptVerbs( HttpVerbs.Get)] 
 
public ActionResult ListDisplay() 
 
{ 
 
} 
 
 
[AcceptVerbs( HttpVerbs.Post )] 
 
[ValidateAntiForgeryToken] 
 
public ActionResult List() 
 
{ 
 
}