title: how do I redirect a folder name as url param using htaccess?
body: <p>I need to 301 redirect in .htaccess from old site with folder structure to new page that uses the ending folder name as a url param.</p>
  
  <p>like this:</p>
  
  <p><a href="http://example.com/artists/artist-name" rel="nofollow">http://example.com/artists/artist-name</a></p>
  
  <p>to</p>
  
  <p><a href="http://example.com/search-works.php?searchArtist=artist-name" rel="nofollow">http://example.com/search-works.php?searchArtist=artist-name</a></p>