title: Handling post requests in ASP.NET MVC
body: <p>Recently I started working with MVC, before that I used "classic" ASP.NET.</p>
  
  <p>After using Ruby on Rails (RoR), I wonder how to implement POST request handling in MVC similar to how RoR operates. In RoR you use the <code>Post</code> method, so you need only one function for a view.</p>
  
  <p>In ASP.NET MVC I need to use 2 separate functions for <code>GET</code> and for <code>POST</code>, so I need to initialize the same data twice, and I don't like to repeat something in my code.</p>
  
  <p>How can I check if the request is <code>POST</code> in one method?</p>
  
  <p><strong>Update:</strong></p>
  
  <p>Solution is found: I have to use Request.HttpMethod.</p>
  
  <p>Thank you!</p>