For this you will want to use a standard socket to port 80 with "GET
yourscript.php?var=foo HTTP/1.0\r\n\r\n" in the send method and the recieve
method will return the results. They have higher level APIs for HTTP but
this is my preference. You should easily be able to find examples on using
sockets in Java. Regards.

-Gregory

-----Original Message-----
From: Matt Palermo [mailto:[EMAIL PROTECTED]
Sent: Friday, October 24, 2003 10:11 AM
To: [EMAIL PROTECTED]
Subject: [PHP] Using PHP with JAVA


I have been searching the web for ways to execute remote PHP files through
the use of JAVA code, but I haven't had any luck.  I have found many ways to
call JAVA functions from a PHP script, but not the other way around.  What
I'm trying to accomplish is I want to build a JAVA application that will be
run from a users local computer after installation and this JAVA program
will connect to a url on my server (a url to a PHP script).  This PHP script
will be used to connect to the server's MySQL database and send some
retrieved information back to the JAVA application on the users machine.  I
have been searching the web for hours trying to find a tutorial, or advice
on how to accomplish this, but so far I have had no luck.  If anyone has any
advice or suggestions please let me know.

Thanks,

Matt

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to