title: How to Extract the Current URL and ID in jQuery?
body: <p>How would I go about getting the current URL using jquery, or more specifically, getting an ID on the end of it?</p>
  
  <p>For example, I have product.php#tab-2. What I want to get from it is just the '#tab-2' part.</p>
  
  <p>I have tried 'window.location.pathname' but that will only return '/product.php'</p>
  
  <p>Thanks</p>