Thread overview | |||||
---|---|---|---|---|---|
|
August 27, 2013 [Issue 10911] New: std.net.curl.HTTP: should allow user code to indicate content type of POST data | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=10911 Summary: std.net.curl.HTTP: should allow user code to indicate content type of POST data Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: Phobos AssignedTo: nobody@puremagic.com ReportedBy: hsteoh@quickfur.ath.cx --- Comment #0 from hsteoh@quickfur.ath.cx 2013-08-27 11:06:36 PDT --- Currently, std.net.curl.HTTP.postData hardcodes the content type to application/octet-stream for ubyte[] and text/plain for [unqual,const,immutable](char)[]. The method that lets you specify content type, _postData, is a private function. The workaround is unreasonably complicated: since headers are a singly-linked list, you can't just use addHeader to replace the default Content-Type header; you have to iterate over them and add them back, substituting Content-Type with the desired value. Either that, or use the low-level Curl object directly, which defeats the purpose of having a high-level API. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
October 21, 2013 [Issue 10911] std.net.curl.HTTP: should allow user code to indicate content type of POST data | ||||
---|---|---|---|---|
| ||||
Posted in reply to hsteoh@quickfur.ath.cx | http://d.puremagic.com/issues/show_bug.cgi?id=10911 Sean Kelly <sean@invisibleduck.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED CC| |sean@invisibleduck.org --- Comment #1 from Sean Kelly <sean@invisibleduck.org> 2013-10-21 10:11:21 PDT --- This one has caused me a lot of trouble as well. I'll sort out a pull request. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
October 21, 2013 [Issue 10911] std.net.curl.HTTP: should allow user code to indicate content type of POST data | ||||
---|---|---|---|---|
| ||||
Posted in reply to hsteoh@quickfur.ath.cx | http://d.puremagic.com/issues/show_bug.cgi?id=10911 hsteoh@quickfur.ath.cx changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |pull --- Comment #2 from hsteoh@quickfur.ath.cx 2013-10-21 10:17:52 PDT --- I've already done a pull request, but it's being held up because we're not sure what's the best API for this. See: https://github.com/D-Programming-Language/phobos/pull/1527 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation