Autor Beitrag
bruce185
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 283

winXP
D7 Ent
BeitragVerfasst: Mo 10.09.07 00:44 
Abend zusammen,

wenn ich eine URL öffnen möchte mit idHTTP1.GET,
dann bekomme ich eine fehlermeldung zurückgeliefert:

ausblenden Delphi-Quelltext
1:
HTTP/1.1 302 Found.					


bei meinem anderen provider ging alles sehr gut, bis ich zu einem anderen provider gewechselt habe, erhalte ich nun diesen fehlermeldung.

Kann es sein, das ich bei den provider nicht von meinem Delphi Programm aus eine URL öffnen kann?

Hier ist mal der Code:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
try
  eintraege := idHTTP2.Get(Edit2.Text+'?action=count');
  Label3.Caption := 'Einträge in der Datenbank: '+eintraege;
except
  Label3.Caption := 'Fehler beim laden der URL!';
end;


Ich danke euch schonmal für die Hilfe.

MfG
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Mo 10.09.07 09:44 
Stell mal die Eigenschaft "FollowRedirects" oder "AllowRedirect" auf true.
Das müsste dir helfen.
Es hätte aber auch gereicht, wenn du diese Fehlermeldung mal in der Forensuche gesucht hättest.

_________________
In the beginning was the word.
And the word was content-type: text/plain.
bruce185 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 283

winXP
D7 Ent
BeitragVerfasst: Mo 10.09.07 18:33 
Achso, Danke Dir.

Jetzt bekomme ich keine fehlermeldung mehr sondern bekomme das hier zurückgeliefert:

ausblenden XML-Daten
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
<?xml version="1.0" encoding="iso-8859-2"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="cs" lang="cs">
 <head>
  <meta name="generator" content="" />
  <meta http-equiv="content-type" content="text/html; charset=utf-8" />
  <meta http-equiv=REFRESH content="3;URL=http://extra.hu">

  <title>Extra.hu | 404</title>
   </head>
 <body bgcolor="#e6e6e6">
        <center><img src="error-404.gif" border="0" alt="error-404"/></center>
 </body>
</html>


wenn ich das bei meinem vorherigen anbieter teste, dann geht es, aber bei extra.hu geht das nicht.
Kann man das vieleicht noch anders lösen?

MfG
Timosch
ontopic starontopic starontopic starontopic starontopic starofftopic starofftopic starofftopic star
Beiträge: 1314

Debian Squeeze, Win 7 Prof.
D7 Pers
BeitragVerfasst: Mo 10.09.07 18:44 
Das ist anscheinend ein 404er. Sicher, dass die Datei, auf die du zugreifst, existiert?

_________________
If liberty means anything at all, it means the right to tell people what they do not want to hear. - George Orwell
bruce185 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 283

winXP
D7 Ent
BeitragVerfasst: Mo 10.09.07 18:56 
Ja, wenn ich die URL in die Adresszeile im Internet Explorer einfüge, dann geht es, nur bei meinem Programm geht das nicht.

MfG
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Di 11.09.07 10:00 
vielleicht hast du kein Session Cookie, das du brauchst um auf die Daten zuzugreifen...
Es gibt da viele Möglichkeiten.

Ein Lösungsansatz wäre mal den Datenstrom vom IE und von deinem Programm via Etherreal aufzuzeichnen und zu vergleichen.

_________________
In the beginning was the word.
And the word was content-type: text/plain.
bruce185 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 283

winXP
D7 Ent
BeitragVerfasst: Do 13.09.07 18:06 
Danke.
Also ich hab das mal mit MySQLDirekt versucht, aber welche Port muss ich für die MySQL Verbindung angeben?
Ich hab das mal mit dem Port 80 versucht, aber irgendwie kommt fehler bei der verbindung.

Vielen Dank schonmal.

MfG
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Fr 14.09.07 09:26 
das wird nicht klappen, weil der Port für mySQL 3306 ist. Dieser ist aber bei den meisten Internetprovidern gesperrt...

_________________
In the beginning was the word.
And the word was content-type: text/plain.