IdHttpEx.pas 500 B

1234567891011121314151617181920212223242526272829303132
  1. unit IdHttpEx;
  2. interface
  3. uses
  4. IdHTTP,Classes,SysUtils;
  5. type
  6. // TIdHTTPMethod = (hmHead, hmGet, hmPost, hmOptions, hmTrace, hmPut, hmDelete, hmConnect);
  7. TIdHTTPEx = class(TIdCustomHTTP)
  8. public
  9. procedure Delete(AURL: string);
  10. end;
  11. implementation
  12. {$DEFINE DELPHI2007}
  13. { TIdHTTPEx }
  14. procedure TIdHTTPEx.Delete(AURL: string);
  15. begin
  16. {$IFDEF DELPHI2007}
  17. DoRequest(hmDelete, AURL, nil, nil, []);
  18. {$ELSE}
  19. DoRequest(Id_HTTPMethodDelete, AURL, nil, nil, []);
  20. {$ENDIF}
  21. end;
  22. end.