Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/294.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
从php扩展返回php代码作为返回值_Php_C++_C_Swig_Php Extension - Fatal编程技术网

从php扩展返回php代码作为返回值

从php扩展返回php代码作为返回值,php,c++,c,swig,php-extension,Php,C++,C,Swig,Php Extension,我想返回以下php代码: (include "x.php"); 作为swig开发的php扩展的返回值。我搜索过了,但没有找到具体的答案。此返回值将在php脚本中显示如下 <?php dl("myextension.dll"); my_extension_function(); /*this function call should output the following: (include "x.php"); in this php script*/ ?> 请帮忙

我想返回以下php代码:

(include "x.php");
作为swig开发的php扩展的返回值。我搜索过了,但没有找到具体的答案。此返回值将在php脚本中显示如下

<?php
dl("myextension.dll");

my_extension_function(); /*this function call should output the following:
  (include "x.php"); in this php script*/

?>

请帮忙

问候,


KPM

x.php中有什么?是否要捕获输出?是的,我想在php脚本中显示x.php的输出x.php中有什么?是否要捕获输出?是的,我想在php脚本中显示x.php的输出