title: Replace part of URL with JavaScript
body: <p>I want to replace part of the URL with JavaScript but stupid regex is giving me headaches. I want to switch from this:</p>
  
  <pre><code>http://website.com/test.html/post/something-else/
  </code></pre>
  
  <p>to this:</p>
  
  <pre><code>http://website.com/post/something-else/
  </code></pre>
  
  <p>Any ideas? Thanks!</p>