title: URL rewrite with pipes and comma
body: <p>How can I rewrite urls from query that looks like</p>
  
  <pre><code>http://localhost/index.php?c=vga&amp;av=France|originaly,540-MHZ|freq
  
  http://localhost/index.php?c=fructe-congelate&amp;gramaj=1+Kg&amp;av=Romania|Tara%20de%20origine,-18%20grade|Temperatura%20de%20pastrare&amp;brand=Royal
  </code></pre>
  
  <p>In something like :  </p>
  
  <pre><code>http://localhost/fructe-congelate/gramaj-1+Kg/brand-royal/filtre/Romania|Tara-de-origine,-18|Temperature
  </code></pre>
  
  <p>I'm doing this for a filtering system on a shopping cart.<br>
  This is what I have for the moment in .htaccess:</p>
  
  <pre><code>RewriteEngine On 
  Options -Indexes 
  Options +FollowSymLinks
  &lt;Files .htaccess&gt;
  deny from all
  &lt;/Files&gt;
  
  RewriteRule ^([A-Za-z0-9_?-]+)/?$ index.php?c=$1 [NC,L]
  RewriteRule ^([A-Za-z0-9_?-]+)/filtre/([A-Za-z0-9_?-]+)/?$ index.php?c=$1&amp;av=$2 [NC,L]
  </code></pre>
  
  <p>All the product filters (attributes) are stored in $av, but I have predefined parameters like gramaj, brand, inoffer, page with values appended to sql query and added to the url.</p>