title: jquery - get url path?
body: <p>I know I can use window.location.pathname to return a url, but how do I parse the url?</p>
  
  <p>I have a url like this: <a href="http://localhost/messages/mine/9889" rel="noreferrer">http://localhost/messages/mine/9889</a> and I'm trying to check to see if "mine" exists in that url?  </p>
  
  <p>So, if "mine" is the second piece in that url, I want to write an if statement based on that... </p>
  
  <pre><code>if(second argument == 'mine') { do something }
  </code></pre>