title: Regex for number
body: <p>I'm fairly new to reg expressions and I'm struggling to come up with a regex for a price field.</p>
  
  <p>I want to use</p>
  
  <pre><code>var price = $('#new_price').val().replace(/*regex*/, '');
  </code></pre>
  
  <p>to strip out any unwanted characters.</p>
  
  <p>The price can be an int ie 10
  or a decimal to 2dp ie 9.99</p>
  
  <p>basically I want anything that doesn't match a standard monetary format to be removed.</p>
  
  <p>OR</p>
  
  <p>I'd like a regex to check (using <code>.match(regex)</code>) that the field is in the desired format.</p>
  
  <p>If someone could quickly write either of those regex's for me and explain it to me so i know for the future I would be very grateful.</p>