title: Extract substring from string using javascript regular expressions
body: <p>I am new to regular expressions in Javascript.</p>
  
  <p>The string looks something like </p>
  
  <pre><code>Password=6)8+Ea:4n+DMtJc:W+*0&gt;(-Y517;Persist Security Info=False;User ID=AppleTurnover;Initial Catalog=ProductDB;Data Source=Sydney
  </code></pre>
  
  <p>and I am trying to extract from this just the bit </p>
  
  <pre><code>Password=6)8+Ea:4n+DMtJc:W+*0&gt;(-Y517
  </code></pre>
  
  <p>from ths string.</p>
  
  <p>So, I have:</p>
  
  <pre><code>string="`Password=6)8+Ea:4n+DMtJc:W+*0&gt;(-Y517;Persist Security Info=False;User ID=AppleTurnover;Initial Catalog=ProductDB;Data Source=Sydney"
  substring=string.match('/Password=(.*);/g');
  </code></pre>
  
  <p>It returns back the entire string again. What is going wrong here?</p>