Thank you Paul ... thanks a lot for the help

Warm Regards,

Sharad

----- Original Message -----
From: "Paul Maine" <[EMAIL PROTECTED]>
Date: Wednesday, October 9, 2002 9:00 am
Subject: RE: [PHP] Calling C functions

> I am including a code snippet that will aid you.
> 
> # Location of your binary.
> $yourbinary = "/usr/bin/yourprogram";
> 
> # Location of the libs for your c program if needed
> $yourlib = YOUR_LIB . ":" . getenv("LD_LIBRARY_PATH");
> putenv("LD_LIBRARY_PATH=$yourlib");
> 
> # The args to call the binary with
> # For example:               
> $arg1 = 10;
> $arg2 = 15;
> 
> # Put together the command string
> $command = "$yourbinary $arg1 $arg2";
> 
> $result = `$command`;
>                
> Be sure to check the return result from your program.
> 
> Hope this helps
> Paul
> -----Original Message-----
> From: Sharad Tiwari [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, October 08, 2002 10:07 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Calling C functions
> 
> 
> hi all,
> 
> I have just started working on PHP ... (just a couple of days back)
> I had posted a question yesterday and could not get any rep from 
> anyone....
> 
> My problem is this ... I have to take inputs from a web-based 
> interfaceand pass them as parameters to a C function (or an 
> executable program)
> Could anyone of you kindly let me know how can I invoke such C library
> functions or executables from php.
> 
> thanks for the help in advance.
> 
> Warm Regards,
> 
> Sharad
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 

**************************Disclaimer************************************************** 
   
 
 Information contained in this E-MAIL being proprietary to Wipro Limited is 
'privileged' 
and 'confidential' and intended for use only by the individual or entity to which it 
is 
addressed. You are notified that any use, copying or dissemination of the information 
contained in the E-MAIL in any manner whatsoever is strictly prohibited.

****************************************************************************************

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

Reply via email to