Re: PHP connection to external application

From: Date: Thu, 12 Jun 2008 11:30:57 +0000
Subject: Re: PHP connection to external application
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-275265@lists.php.net to get a copy of this message
On 12 Jun 2008, at 12:20, hce wrote:
What is the best way for a PHP web application to connect to an external application written by C in Linux OS? (1) Can PHP directly call external C functions, or similar solution?
No, but you can wrap the C functions in a PHP extension.
(2) Can PHP pass messages to message queue which external C program can access?
Depends on the implementation of the queue, but the answer is almost certainly yes.
(3) Socket connection between the PHP and externam C program.
This would usually be my preferred choice unless there is a particular reason to avoid this in which case I would go down the PHP extension route. A lot will depend on what the C code is doing and how your PHP scripts will interact with it. -Stut -- http://stut.net/

« previous php.general (#275265) next »