title: How do i push a new key value pair to an array php?
body: <p>I know there is a lot of documentation around this but this one line of code took me ages to find in a 4000 line file, and I would like to get it right the first try.</p>
  
  <pre><code>file_put_contents($myFile,serialize(array($email_number,$email_address))) or die("can't open file");
      if ($address != "email@domain.com") {
          $email['headers'] = array('CC' =&gt; 'email@domain.com');
      }
  }
  </code></pre>
  
  <p>After this if statement I basically want to add on</p>
  
  <p><code>'BCC' =&gt; 'another_email@domain.com'</code></p>
  
  <p>into the <code>$email['headers']</code> array (so it adds it whether the if evaluates to true or not)</p>