PHP类文件内方法如何调用另一个文件夹内不含类的php文件里的方法/www/controller/Message.php 里面有个class 其中有个public function a(){...}
该方法内想调用/www/webservice/Client.php 内的方法 但是Client.php内不含类
只是实例化了另外一个对象 并写了很多方法在里面。请问怎么才能调用到啊
该方法内想调用/www/webservice/Client.php 内的方法 但是Client.php内不含类
只是实例化了另外一个对象 并写了很多方法在里面。请问怎么才能调用到啊
include("test6.php");
class Test{
function usefun(){
fun();
}
}
$obj = new Test();
$fun = $obj->usefun();
echo $fun;
?>test6.php<?php
function fun(){
echo "This is function";
}
?>
This is function