title: ASP.NET MVC controller parameter optional (i.e Index(int? id))
body: <p>I have the following scenario: my website displays articles (inputted by an admin. like a blog).</p>
  
  <p>So to view an article, the user is referred to Home/Articles/{article ID}.</p>
  
  <p>However, the user selects which article to view from within the Articles.aspx view itself, using a jsTree list.</p>
  
  <p>So I what I need to do is to be able to differentiate between two cases: the user is accessing a specific article, or he is simply trying to access the "main" articles page. I tried setting the "Articles" controller parameter as optional (int? id), but then I am having problems "using" the id value inside the controller.</p>
  
  <p>What is the optimal manner to handle this scenario? Perhaps I simply need a better logic for checking whether or not an id parameter was supplied in the "url"?</p>
  
  <p>I am trying to avoid using two views/controllers, simply out of code-duplication reasons.</p>