title: Match folder name from url using regex
body: <p>I want to match just the folder name that a file is in, </p>
  
  <p>eg:<br>
  pic/<b>2009</b>/cat01.jpg<br>
  pic/2009/<b>01</b>/cat02.jpg  </p>
  
  <p>I want to just match what I put in bold.</p>
  
  <p><b>So far I have this:</b>  </p>
  
  <pre><code>[^/]*/
  </code></pre>
  
  <p>Which will match,<br>
  <b>pic/2009/</b>cat01.jpg  </p>
  
  <p>Any idea?</p>