title: PHP filter_input(INPUT_SERVER, 'REQUEST_METHOD') returns null?
body: <p>Why does this line return <code>null</code> in my live server?</p>
  
  <pre><code>filter_input(INPUT_SERVER, 'REQUEST_METHOD');
  </code></pre>
  
  <p>The live server is <strong>php5.5.9</strong></p>
  
  <p>Have I missed something?</p>
  
  <p>I thought it is used to replace the global method below?</p>
  
  <pre><code>$_SERVER['REQUEST_METHOD'];
  </code></pre>
  
  <p>some of the code,</p>
  
  <pre><code>public function __construct()
      {
          // Construct other generic data.
          $this-&gt;clientRequestMethod = filter_input(INPUT_GET, 'method'); // such as list, add, update, etc
          $this-&gt;clientPostMethod = filter_input(INPUT_POST, 'method'); // such as update
          $this-&gt;serverRequestMethod = filter_input(INPUT_SERVER, 'REQUEST_METHOD'); //such as get or post
      }
  
  
      public function processEntry()
      {
  
          // Determine the $_SERVER['REQUEST_METHOD'] whether it is post or get.
          if ($this-&gt;serverRequestMethod === 'POST' &amp;&amp; $this-&gt;clientPostMethod != null) 
          {
              $this-&gt;processPost();
          }
          else if($this-&gt;serverRequestMethod === 'GET' &amp;&amp; $this-&gt;clientRequestMethod != null) 
          {
              $this-&gt;processRequest();
          }
      }
  </code></pre>