summaryrefslogtreecommitdiff
path: root/tutorial
diff options
context:
space:
mode:
Diffstat (limited to 'tutorial')
-rwxr-xr-xtutorial/php/PhpClient.php6
-rwxr-xr-xtutorial/php/PhpServer.php6
2 files changed, 6 insertions, 6 deletions
diff --git a/tutorial/php/PhpClient.php b/tutorial/php/PhpClient.php
index 92dc3cbac..eb2c2e5ee 100755
--- a/tutorial/php/PhpClient.php
+++ b/tutorial/php/PhpClient.php
@@ -5,7 +5,7 @@ namespace tutorial\php;
error_reporting(E_ALL);
-require_once __DIR__.'/../../lib/php/lib/ClassLoader/ThriftClassLoader.php';
+require_once __DIR__.'/../../vendor/autoload.php';
use Thrift\ClassLoader\ThriftClassLoader;
@@ -13,8 +13,8 @@ $GEN_DIR = realpath(dirname(__FILE__).'/..').'/gen-php';
$loader = new ThriftClassLoader();
$loader->registerNamespace('Thrift', __DIR__ . '/../../lib/php/lib');
-$loader->registerDefinition('shared', $GEN_DIR);
-$loader->registerDefinition('tutorial', $GEN_DIR);
+$loader->registerNamespace('shared', $GEN_DIR);
+$loader->registerNamespace('tutorial', $GEN_DIR);
$loader->register();
/*
diff --git a/tutorial/php/PhpServer.php b/tutorial/php/PhpServer.php
index 5a9b49bde..749da3a0b 100755
--- a/tutorial/php/PhpServer.php
+++ b/tutorial/php/PhpServer.php
@@ -5,7 +5,7 @@ namespace tutorial\php;
error_reporting(E_ALL);
-require_once __DIR__.'/../../lib/php/lib/ClassLoader/ThriftClassLoader.php';
+require_once __DIR__.'/../../vendor/autoload.php';
use Thrift\ClassLoader\ThriftClassLoader;
@@ -13,8 +13,8 @@ $GEN_DIR = realpath(dirname(__FILE__).'/..').'/gen-php';
$loader = new ThriftClassLoader();
$loader->registerNamespace('Thrift', __DIR__ . '/../../lib/php/lib');
-$loader->registerDefinition('shared', $GEN_DIR);
-$loader->registerDefinition('tutorial', $GEN_DIR);
+$loader->registerNamespace('shared', $GEN_DIR);
+$loader->registerNamespace('tutorial', $GEN_DIR);
$loader->register();
/*