Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Netzwerke (https://www.delphipraxis.net/14-netzwerke/)
-   -   Delphi Delphi ServerSocket und PHP (https://www.delphipraxis.net/17858-delphi-serversocket-und-php.html)

Andreas_Seidel 10. Mär 2004 17:43


Delphi ServerSocket und PHP
 
Hi,

ich habe mal versiucht, ob ich mit PHP socket auf Delphi zugreifen kann.
Das geht fast, aber leider nicht ganz

Server ind Delphi :

Delphi-Quellcode:
procedure TForm1.SSConnect(AThread: TIdPeerThread);
begin     LB.Items.Clear;
LB.Items.Add('Connect');
end;


procedure TForm1.SSExecute(AThread: TIdPeerThread);
VAR
MSG:string;
begin
Msg := AThread.Connection.ReadLn;
LB.Items.Add(MSG);
end;

procedure TForm1.SSDisconnect(AThread: TIdPeerThread);
begin
LB.Items.Add('DisConnect');

end;

PHP Code :
Delphi-Quellcode:
$fp = fsockopen ("192.168.2.9", 9999, $errno, $errstr, 30);
fputs ($fp, "TEST");
fwrite($fp,"TEST");
fclose($fp);
Das Connect kommt, und das Disconnect auch. Leider kommt nicht der "TEST"

Was habe ich da falsch ?

Geht das überhaupt ?

Danke

Andreas

AnTiPrimaTe 11. Mär 2004 09:20

Re: Delphi ServerSocket und PHP
 
Hallo,
verwendest Du blocked Sockets oder non-blocked Sockets?


Alle Zeitangaben in WEZ +1. Es ist jetzt 22:50 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz