我用 Composer 安装了 PHRETS,并且能够使用 CMD 终端并按照文档打印信息。我尝试将所有文件上传到我的 Web 服务器,但页面超时。
我的错误日志显示以下内容:
PHP Fatal error: Uncaught exception 'GuzzleHttp\Ring\Exception\ConnectException' with message 'cURL error 7: Failed to connect to rets-rald.realtyserver.com port 6103: Connection timed out' in /public_html/phrets/vendor/guzzlehttp/ringphp/src/Client/CurlFactory.php:126
Stack trace:
#0 /public_html/phrets/vendor/guzzlehttp/ringphp/src/Client/CurlFactory.php(91): GuzzleHttp\Ring\Client\CurlFactory::createErrorResponse(Array, Array, Array)
#1 /public_html/phrets/vendor/guzzlehttp/ringphp/src/Client/CurlHandler.php(96): GuzzleHttp\Ring\Client\CurlFactory::createResponse(Array, Array, Array, Array, Resource id #69)
#2 /public_html/phrets/vendor/guzzlehttp/ringphp/src/Client/CurlHandler.php(68): GuzzleHttp\Ring\Client\CurlHandler->_invokeAsArray(Array)
#3 /public_html/phrets/vendor/guzzlehttp/ringphp/src/Client/Middleware.php(54): GuzzleHttp\Ring\Client\CurlHandler->__invoke(Array)
#4 /public_html/phrets/vendor/guzzlehttp/ringphp/src/Client/Middlewa in /public_html/phrets/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php on line 49
我怎样才能让它在网络服务器上工作?下面是我的配置。
$config = new \PHRETS\Configuration;
$config->setLoginUrl('http://rets-rald.realtyserver.com:6103/saskatchewan/rets/login');
$config->setUsername('username');
$config->setPassword('password');
$config->setRetsVersion('1.5');
$config->setUserAgent('PHRETS/2.0');
$config->setHttpAuthenticationMethod('digest');
$config->setOption('use_post_method', false);
$config->setOption('disable_follow_location', false);