title: PHP extract value from a string that is between <star>t and <end>
body: <p>I want to extract some values from a string (result of a db query).
  An example of such a string is:</p>
  
  <pre><code>$data="tostore1:1 = INTEGER: 10000000
         tostore1:2 = INTEGER: 1000000
         something else something else
         tostore2:1 = STRING: 'test1'
         something else something else
         tostore2:2 = STRING: 'test2'
         tostore3:1 = INTEGER: 1000";
  </code></pre>
  
  <p>I would get two arrays. One containing <code>10000000</code>, <code>'test1'</code> and <code>1000</code> and one containing <code>1000000</code>, <code>'test2'</code>.</p>
  
  <p>In alternative, if I want to extract <code>tostore2:1</code> value, the start could be <code>tostore2:1</code> and the end <code>CR LF</code> @ the end of the line</p>
  
  <p>I'm searching for the most optimized way for do that</p>