http://bugs.winehq.org/show_bug.cgi?id=27891
Summary: Winhttprequest POST doesn't work Product: Wine Version: 1.3.25 Platform: x86 URL: http://netikka.net/dev/posttest.exe OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: winhttp AssignedTo: wine-bugs@winehq.org ReportedBy: ocean04@suomi24.fi
http://netikka.net/dev/posttest.exe
SetRequestHeader implementation is needed first. Maybe not enough to make this work, interesting to see. I use this kind of code to send formdata/photographs to server.
procedure TForm1.Button1Click(Sender: TObject);
var fhttp, postdata: variant;
i: integer;
s: string;
begin
s:='test=12345';
postData := VarArrayCreate([0, Length(s) - 1], varByte);
for i := 1 to Length(s) do postData[i-1] := Ord(s[i]); fhttp:=createoleobject('WinHttp.WinHttpRequest.5.1');
fhttp.open('POST', 'http://netikka.net/dev/posttest.php', true); fhttp.setRequestHeader('Content-Type','application/x-www-form-urlencoded'); fhttp.send(postdata);
if Not fhttp.WaitForResponse(30) then
begin
fhttp.Abort;
fhttp:=unassigned;
showmessage('Timeout!');
exit; end;
if fhttp.responsetext='12345' then
showmessage('Success!') else showmessage('Failed!');
fhttp:=unassigned;
end;
http://bugs.winehq.org/show_bug.cgi?id=27891
ocean04@suomi24.fi changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download, source
http://bugs.winehq.org/show_bug.cgi?id=27891
Hans Leidekker hans@meelstraat.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |FIXED
--- Comment #1 from Hans Leidekker hans@meelstraat.net 2011-07-26 12:15:22 CDT --- Fixed by 6191469bc2fe1e2995127349236fbf1950c04532.
http://bugs.winehq.org/show_bug.cgi?id=27891
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #2 from Alexandre Julliard julliard@winehq.org 2011-08-05 12:37:52 CDT --- Closing bugs fixed in 1.3.26.