title: Undefined indexes in PHP. Generic solution required
body: <p>I have been searching Stack Overflow and the rest of the web, and I am starting to believe that there is no generic solution for undefined indexes. </p>
  
  <p>I have a massive PHP application with several form and at the end of the script I call all the form's inputs and put them together to display a summary of all the inputs.</p>
  
  <pre><code>echo $_POST['FirstName'];
  echo $_POST['MiddleName'];
  echo $_POST['LastName'];
  </code></pre>
  
  <p>I know how to check each occurence like</p>
  
  <pre><code>if ( !isset($_POST['MiddleName']) ) { $_POST['MiddleName'] = '' }
  </code></pre>
  
  <p>Is there a way to automatically capture all undefined indexes and then set them to 0 or null?</p>