Delphi-Quellcode:
resp := TMemoryStream.Create;
try
with http
do begin
HandleRedirects := True;
AllowCookies := False;
RedirectMaximum := 10;
end;
http.Get(
url, resp );
resp.Position := 0;
slSource := TStringList.Create;
try
slSource.LoadFromStream(resp);
source := slSource.Text;
finally
FreeAndNil(slSource);
end;
Result := source;
finally
resp.Free;
end;
Wenn ich es wie oben per Stream lade, funktioniert es, anders jedoch nicht.