|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2010-04-13 18:46 UTC] ed at atl dot org
Description:
------------
When creating a soap client, I would also like to be able to identify custom HTTP headers.
See attached patch, please include in next release (which will also require the documentation to be included)
Test script:
---------------
$client = new SoapClient('http://london:8180/testing/headerserver.php?wsdl',
array(
"trace"=>true,
"custom_http_header"=>"New: test header"
));
Patchesadd_custom_http_header.patch (last revision 2010-04-13 16:47 UTC by ed at atl dot org)Pull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 16:00:02 2025 UTC |
You can already send HTTP headers through stream context. <?php $opts = array( 'http'=>array( 'header'=>"New: test header\r\n" ) ); $context = stream_context_create($opts); $client = new SoapClient(NULL, array( 'stream_context' => $ctx, 'location' => 'test://', 'uri' => 'test://'));