title: Custom Model Binder for ASP.NET MVC on GET request
body: <p>I've created a custom MVC Model Binder which gets called for every <code>HttpPost</code> that comes into the server. But does not get called for <code>HttpGet</code> requests.</p>
  <ul>
  <li><strong>Should my custom model binder get called during a <code>GET</code>? If so, what did I miss?</strong></li>
  <li><strong>If not, How can I write custom code handling the <code>QueryString</code> from a <code>GET</code> Request?</strong></li>
  </ul>
  <p>Here's my implementation...</p>
  <pre><code>public class CustomModelBinder : DefaultModelBinder
  {
     public override object BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext)
     {
        // This only gets called for POST requests. But I need this code for GET requests.
     }
  }
  </code></pre>
  <p>Global.asax</p>
  <pre><code>protected void Application_Start()
  {
     ModelBinders.Binders.DefaultBinder = new CustomModelBinder();
     //...
  }
  </code></pre>
  <p>I've looked into these solutions, but they don't quite work for what I'm looking for:</p>
  <ul>
  <li>Persisting complex types via <code>TempData</code></li>
  <li>Using the default binder to build up complex types (<code>?Name=John&amp;Surname=Doe</code>)</li>
  </ul>
  <h1>Remark on answer</h1>
  <p>Thanks to @Felipe for the help. Just in case someone struggles with the same, I learnt:</p>
  <ul>
  <li>The custom model binder <strong>CAN</strong> be used for <code>GET</code> requests</li>
  <li>You <strong>CAN</strong> use <code>DefaultModelBinder</code> class</li>
  <li>My snag was that the <strong>action method MUST have a parameter</strong> (otherwise the model binder is skipped for <code>GET</code> Requests, which makes sense when you think about it)</li>
  </ul>