KIO HTTP: Post-Content type bug in http.c and SOAPAction header

Dawit A. adawit at
Tue Oct 1 13:00:54 BST 2002

On Monday 30 September 2002 03:41, Tim Jansen wrote:
> On Monday 30 September 2002 00:05, Simon Hausmann wrote:
> > I think a cleaner solution would be something along the lines of
> >
> > QString customHeader = metaData( "customHTTPHeader" );
> > if ( !customHeader.isEmpty() ) {
> >     header += customHeader;
> >     header += "\r\n";
> > }
> > and on the other side:
> > job->addMetaData( "customHTTPHeader", "SOAPAction: foobar" );
> > You get the idea :)
> Yes. Actually it would be even nicer if it was possible to add more than
> one header per request, I just dont have any idea of how to do this... at
> least not in a pretty way.

Well it is actually simple.  All you have to do is build your headers in say a 
QStringList and simply join them at the end using the HTTP header delimiter, 
"\r\n".  This is of course untested and the above patch is accepted.  I think 
I like the generic customHTTPHeader that Simon came up with for now.  In the 
future perhaps this can be expanded a bit more...

Dawit A.

More information about the kde-core-devel mailing list