summaryrefslogtreecommitdiff
path: root/Examples/CallPhpFunctions/callphpfunction.php
diff options
context:
space:
mode:
authorJasperVanEck <jaspergkurtz@gmail.com>2013-12-02 11:54:02 +0100
committerJasperVanEck <jaspergkurtz@gmail.com>2013-12-02 11:54:02 +0100
commitc97224558d022b5698fb000018f910f2499df1b4 (patch)
tree6c11c83990a0aa12b56c8baa59ecaff46b3f3b6c /Examples/CallPhpFunctions/callphpfunction.php
parentafa7694bcdb14e7a1d4b1acaf63a8f8eac2b9c05 (diff)
Added example of a php function call, but isCallable() doesnt work
Diffstat (limited to 'Examples/CallPhpFunctions/callphpfunction.php')
-rw-r--r--Examples/CallPhpFunctions/callphpfunction.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/Examples/CallPhpFunctions/callphpfunction.php b/Examples/CallPhpFunctions/callphpfunction.php
new file mode 100644
index 0000000..26f161c
--- /dev/null
+++ b/Examples/CallPhpFunctions/callphpfunction.php
@@ -0,0 +1,16 @@
+<?php
+/**
+ * callphpfunction.php
+ * @author Jasper van Eck<jasper.vaneck@copernica.com>
+ *
+ * An example file to show the working of a php function call in C++.
+ */
+
+/*
+ * Run the function with the given name. As you can see, the given name
+ * can be different from the actual function name.
+ */
+$result = call_php_function(function($a, $b, $c){
+ return $a + $b + $c;
+ });
+echo $result;