title: Route in Rails: bad URL
body: <p>The problem is that when I click on the link, the URL looks like:</p>
  
  <pre><code>/show?id=1&amp;slug=aasdasd
  </code></pre>
  
  <p>But should be:</p>
  
  <pre><code>/strona/1/aasdasd
  </code></pre>
  
  <p>In routes.rb</p>
  
  <pre><code>match "strona/:id/:slug", :controller =&gt; "subpages", :action =&gt; "show", :via =&gt; :get  
  </code></pre>
  
  <p>In application_controller.rb:</p>
  
  <pre><code>def subpages
   Subpage.all
  end
  </code></pre>
  
  <p>In application.html.erb:</p>
  
  <pre><code>&lt;% subpages.each do |subpage| %&gt;
    &lt;%= link_to subpage.title, {:controller =&gt; 'subpages', :action =&gt; 'show', :id =&gt; subpage.id, :slug =&gt; subpage.title.parameterize} %&gt;
  &lt;% end %&gt;
  </code></pre>
  
  <p>Any ideas?</p>