title: how to pass multiple url parameters in django
body: <p>I have 2 links in my html templates. First link pass only 1 parameter to URL and second link pass 2 parameters. Like this:</p>
  
  <pre><code>&lt;a href="/products/{{categ_name}}"&gt;{{categ_name}}&lt;/a&gt;
  &lt;a href="/products/{{categ_name}}/{{subcateg_name}}"&gt;{{subcateg_name}}&lt;/a&gt;
  </code></pre>
  
  <p>Now when i click on link with 1 parameter it works fine. I get the parameter value in my django view.<br> But When i click on link with two parameters i only get the first parameter. I get None in the value of second parameter.</p>
  
  <p>My urls.py:</p>
  
  <pre><code>urlpatterns = patterns('',
              url(r'^products/(?P&lt;categ_name&gt;\w+)/', views.products, name='products_category'),
              url(r'^products/(?P&lt;categ_name&gt;\w+)/(?P&lt;subcateg_name&gt;\w+)/', views.products, name='products_subcategory'),
              url(r'^logout/',views.logoutView, name='logout'),)
  </code></pre>
  
  <p>My views.py:</p>
  
  <pre><code>def products(request, categ_name=None, subcateg_name=None):
      print categ_name, subcateg_name
      ...
  </code></pre>
  
  <p>How to get the value of second parametre?</p>