title: How to set and disable headers in php's SoapClient?
body: <p>The SoapClient sends the HTTP header:</p>
  
  <pre><code>POST / HTTP/1.1
  Accept: */*
  Accept-Encoding: deflate, gzip
  SOAPAction: ""
  Content-Type: text/xml; charset=utf-8
  Content-Length: 2085
  Expect: 100-continue
  
  HTTP/1.1 100 Continue
  </code></pre>
  
  <p>I want to disable the <code>Expect: 100-continue</code>. How can I do that?</p>
  
  <p>I found out that I should be able to set a custom header via:</p>
  
  <pre><code>class SoapClient extends \SoapClient implements HttpClientInterface
  
      public function __construct($pathToWSDL, array $options, LoggerInterface $logger){
          ...
          $headers = [
              'stream_context' =&gt; stream_context_create(
                  [
                      'http' =&gt; [
                          'header' =&gt; 'SomeCustomHeader: value',
                      ],
                  ]
              ),
          ];
          parent::__construct($pathToWSDL, array_merge($options, $headers));
   }
  </code></pre>
  
  <p>yet this doesn't work.</p>
  
  <p>How can I set a custom header and disable certain ones?</p>
  
  <p>I am also not using native php, but HipHop VM 3.12.1 (rel).</p>