Re: Resume of my problem
| From: | Zak Greant | Date: | Mon, 25 Mar 2002 00:42:07 +0000 |
| Subject: | Re: Resume of my problem | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-89953@lists.php.net to get a copy of this message | ||
On March 25, 2002 01:50, you wrote:
> HI,
>
> I have a functino write in c, like as:
>
> void addvalue ( int a, int b, int *c )
> {
> *c = a + b;
> }
>
> in php
>
> <?
>
> phpinclude ("alexlib");
> addvalue ( 1, 2, c );
> print ( "Value c = $c ");
>
> ?>
>
> what the procedure to make this ?
To briefly answer your question:
You could write code like this:
function av ($a, $b, &$c) {
$c = $a + $b;
}
For more information, review the section on References
and Functions in the PHP manual.
--zak