Verzeichnisstruktur phpBB-3.2.0
- Veröffentlicht
- 06.01.2017
So funktioniert es
|
Auf das letzte Element klicken. Dies geht jeweils ein Schritt zurück |
Auf das Icon klicken, dies öffnet das Verzeichnis. Nochmal klicken schließt das Verzeichnis. |
|
(Beispiel Datei-Icons)
|
Auf das Icon klicken um den Quellcode anzuzeigen |
remote-proxy.php
01 <?php
02
03 require_once __DIR__ . '/../vendor/autoload.php';
04
05 use ProxyManager\Factory\RemoteObject\Adapter\XmlRpc;
06 use ProxyManager\Factory\RemoteObjectFactory;
07 use Zend\XmlRpc\Client;
08
09 if (! class_exists('Zend\XmlRpc\Client')) {
10 echo "This example needs Zend\\XmlRpc\\Client to run. \n In order to install it, "
11 . "please run following:\n\n"
12 . "\$ php composer.phar require zendframework/zend-xmlrpc:2.*\n\n";
13
14 exit(2);
15 }
16
17 class Foo
18 {
19 public function bar()
20 {
21 return 'bar local!';
22 }
23 }
24
25 $factory = new RemoteObjectFactory(
26 new XmlRpc(new Client('http://localhost:9876/remote-proxy/remote-proxy-server.php'))
27 );
28 $proxy = $factory->createProxy('Foo');
29
30 try {
31 var_dump($proxy->bar()); // bar remote !
32 } catch (\Zend\Http\Client\Adapter\Exception\RuntimeException $error) {
33 echo "To run this example, please following before:\n\n\$ php -S localhost:9876 -t \"" . __DIR__ . "\"\n";
34
35 exit(2);
36 }
37