title: How to execute php script from the command line?
body: <p>I have a php script by the following address <code>C:\Denwer\home\localhost\www\upload_record_test.php</code>. 
  This script shows some text. But if I try to execute this script from the commmand line by command <code>php C:\Denwer\home\localhost\www\upload_record_test</code>, I get the html response with many errors and the message <code>Call to undefined function curl_init()</code>. The code:</p>
  
  <pre><code>&lt;?php
      $_POST_DATA=array();
      $_POST_DATA['id']='AccountPagesView.a_book/45';
      $_POST_DATA['old_value']='1';
      $_POST_DATA['value']='2';
      $ch=curl_init();
      curl_setopt($ch, CURLOPT_URL, 'http://localhost/index.php/welcome/update_record');
      curl_setopt($ch, CURLOPT_POSTFIELDS, $_POST_DATA);
      curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
      curl_setopt($ch, CURLOPT_VERBOSE, 1);
      $real_result=curl_exec($ch);
      $expected_result=array('result'=&gt;'LOGIN', 'old_value'=&gt;'1');
      $real_result=json_decode($real_result, true);
      if (count(array_intersect($real_result, $expected_result))==2)
      {
          echo "THE TEST HAS BEEN COMPLETED";
      }
      else 
      {
          echo "THE TEST HASN'T BEEN COMPLETED&lt;br/&gt;";
          echo "RESULT:";
          print_r($real_result);
          echo "&lt;br/&gt;EXPECTED RESULT:";
          print_r($expected_result);
      }
  ?&gt;
  </code></pre>
  
  <p>Please, tell me, how can I execute this script from the command line and get only resulted text? Thanks in advance. </p>