title: How to get the directory from an URL using JS?
body: <p>I have one URL which is </p>
  
  <pre><code>https://hpscrmdev.honeywell.com/service_enu_dv2_oui/start.swe?SWECmd=GotoView&amp;SWEView=Home+Page+View+(WCC)&amp;SWERF=1&amp;SWEHo=hpscrmdev.honeywell.com&amp;SWEBU=1
  </code></pre>
  
  <p>I want this 'service_enu_dv2_oui' part using regex. How can I get that?
  Please suggest.</p>
  
  <p>Thanks.</p>