Home >Backend Development >PHP Tutorial >php使用amf3与flex通信,所有内容都要写在类和类的函数中么,require(/includes/sq_init.php)不支持么?全局变量也不可以用

php使用amf3与flex通信,所有内容都要写在类和类的函数中么,require(/includes/sq_init.php)不支持么?全局变量也不可以用

WBOY
WBOYOriginal
2016-06-13 11:41:411313browse

php使用amf3与flex通讯,所有内容都要写在类和类的函数中么,require(/includes/sq_init.php)不支持么?全局变量也不可以用?

php使用amf3与flex通讯
位置amfphp-2.1.1/Amfphp/Services/HelloWorld.php

<br /><?php<br />require('/includes/init.php');    //这行好像不行<br /><br />class HelloWorld<br />{<br />  public function sayHelloWorld($value)<br /> {<br /> <br />  $GLOBALS['db'] ;     //这行好像也不行啊<br />  echo $value;<br />  return " AMF-RPC for PHP".$value;<br />  }<br />}<br />?>



Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn