J'utilise Delphi XE2.
Voila mon code est tres simple:
voici l'erreur :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14 uses (...), IdHTTP; procedure TForm1.Button1Click(Sender: TObject); var HTTP : TIdHTTP; Content : string; begin HTTP := TIdHTTP.Create(nil); try Content := HTTP.Get('http://www.djeda.fr'); ShowMessage(Content); except End; HTTP.Free; end;
Exception EIdHTTPProtocolException avec le message 'HTTP/1.1 403 forbidden'
Ce site fonctionne avec un explorateur (www.djeda.fr), alors pourquoi ai-je cette erreur avec mon application ?
Partager