title: PHP parsing external site
body: <p>I do not have any experience in parsing external url's to grab some data from, but today i've try some experiments: </p>
  
  <pre><code>$str1 = file_get_contents('http://www.indiegogo.com/projects/ubuntu-edge');
  $test1 = strstr($str1, "amount medium clearfix");
  $parts = explode("&gt;",$test1);
  $parts2 = vsprintf("%s", $parts[1]);
  
  $str2 = file_get_contents('http://www.indiegogo.com/projects/ubuntu-edge');
  $test2 = strstr($str2, "money-raised goal");
  $test3 = str_ireplace("money-raised goal", "", "$test2");
  $test4 = str_ireplace("\"", "", "$test3");
  $test5 = str_ireplace("&gt;", "", "$test4");
  $test6 = substr($test5, 0, 29);
  $test7 = explode("Raised of", $test6);
  $test8 = vsprintf("%s", $test7[1]);
  </code></pre>
  
  <p>try the code with:</p>
  
  <p><code>print_r($parts2);</code>  then with <code>print_r($test8);</code> and then with <code>echo "$parts2 - $test8";</code></p>
  
  <p>Because it's so popular this days the Ubuntu Edge campaign i have try to get the two fields from site (only as a experiment), but without success. 
  Well it grabs the two fields, but i could not put both in the same variable. The output is or the $parts2, or the $parts2 contain the value of test8, or only the $test8.</p>
  
  <p>What i'm doing wrong, and why? Also is there a simpler method to do what i want, without so much code?</p>