title: Using regex in javascript to cut out substring
body: <p>There are some strings</p>
  
  <pre><code>"string numbe1 fdsf gfdgfdgf (value1)"
  "string numbe2 fdsf gfdgfdgf (value2)"
  "string numbe3 fdsf gfdgfdgf (value3)"
  "string numbe5 fdsf gfdgfdgf (value1)"
  "string numbe5 fdsf gfdgfdgf (value2)"
  </code></pre>
  
  <p><code>(valueN)</code> can be either <code>(value1)</code> or <code>(value2)</code> or <code>(value3)</code>. I need to cut it from the original string by using javascript regex. So the newString must be kind of <code>string numbe1 fdsf gfdgfdgf</code></p>
  
  <p>Here is what I did (and which is not working as I want)</p>
  
  <pre><code>var newString = originalString.replace(/(value1)|(value2)|(value3)/g,"") ;
  </code></pre>
  
  <p>It returns <code>"1 ()"</code>.</p>
  
  <p>How can I solve it?</p>