草庐IT

zend-http-client

全部标签

php - Zend DB 无法模拟 MS SQL 的限制和偏移量

我正在使用ZendFramework1.12访问MSSQL2008服务器。我使用FreeTDS作为数据库驱动程序。我正在使用Zend_Db生成以下查询。$obj_sel=$obj_db->select()->from(array('ps'=>'ProductStock'),array('PLU','stock'=>'SUM(ps.stock)'))->join(array('pc'=>'ProductCatalogue'),'ps.PLU=pc.PLU',NULL)->join(array('gl'=>'Gemini_Location'),'ps.Location=gl.Locatio

php - 在 zend framework 2 中启用 BjyProfiler 模块

我刚刚在我的应用程序中安装了zend开发人员工具模块和BjyProfiler模块。Zend开发人员工具工作正常,zend开发人员工具模块和BjyProfiler模块都显示在工具栏的模块列表中。但是BjyProfiler无法正常工作,当我单击zend开发人员工具栏的数据库按钮时,它显示如下:我浏览了github中的BjyProfiler自述文件。阅读自述文件后,我不确定将此代码放在哪里以启用BjyProfiler进行查询调试。$profiler=$sl->get('Zend\Db\Adapter\Adapter')->getProfiler();$queryProfiles=$profi

php - 如何使用 HTTP 管道通过单个 TCP 套接字发送 PHP cURL 句柄?

我正在尝试使用PHPcURLHTTP管道功能通过单个TCP连接执行多个请求。引用本页http://www.php.net/manual/en/function.curl-multi-setopt.php我通过添加以下内容为curl_multi_exec()启用流水线操作:curl_multi_setopt($mh,CURLMOPT_PIPELINING,1);我不想在这里发布大量源代码list,但您可以在我的github此处轻松查看或checkout完整示例https://github.com/anovikov1984/pipelining-example为了监控TCP连接,我在另一个

php - Symfony 响应对象如何设置 http header ?

我正在使用Sliex框架。我在使用\Silex\Application::redirect方法时遇到重定向问题。我发现当我试图通过http-headers重定向时,而不是symfony“发送”响应似乎调用了__toString方法。这是我的curl输出:bash-4.2$curl-vhttp://127.0.0.1:8082/*Abouttoconnect()to127.0.0.1port8082(#0)*Trying127.0.0.1...*Addinghandle:conn:0x1ea0970*Addinghandle:send:0*Addinghandle:recv:0*Curl

php - Google 云端硬盘服务帐户和 "Unauthorized client or scope in request"

我有3个使用DriveSDK的服务帐户。1,有效,2无效。返回的错误是“ErrorrefreshingtheOAuth2token,message:'{"error":"unauthorized_client","error_description":"Unauthorizedclientorscopeinrequest."}'"所有3个帐户都已在开发者控制台中注册。所有3个都被授权在GoogleApps控制台中进行“ManagedClientAPIaccess”。所有3个都有范围“https://www.googleapis.com/auth/drive.readonly”。所有3个

php - 元素 'foo' : This element is not expected. 预期为 ( {http ://www. example.com}foo )

当尝试使用schemaValidate方法根据模式验证PHPDOMDocument对象时,将生成下一个警告:Warning:DOMDocument::schemaValidate():Element'foo':Thiselementisnotexpected.Expectedis({http://www.example.com}foo).inXonlineY它只发生在附加到DOMDocument的元素上。我准备了下一个代码片段和架构,以便任何人都可以立即进行测试:片段:$template='';$DD=newDOMDocument();$DD->loadXML($template);$

php - Apache 不会加载 Zend Guard Loader

我正在使用具有以下设置的Ubuntu15.04-64位:ApacheServerversion:Apache/2.4.10(Ubuntu),Serverbuilt:Jul24201517:25:18PHPPHP5.6.4-4ubuntu6.2(cli)(built:Jul2201515:29:28)Copyright,(c)1997-2014ThePHPGroupZendEnginev2.6.0,Copyright(c),1998-2014ZendTechnologieswithZendOPcachev7.0.4-dev,Copyright,(c)1999-2014,byZendTec

php - haxe (php) https 调用 : stream_socket_client() Peer certificate CN did not match expected CN

我正在使用haxe的Http类(编译为php)通过https将request()发送到AWS。这是一个使用haxe-aws库(https://github.com/Blank101/haxe-aws)的最小示例:variamconf=newIAMConfig('newbucket.s3-eu-central-1.amazonaws.com',accessKey,secretKey,'eu-central-1','s3');varsig4=newSig4Http('https://newbucket.s3-eu-central-1.amazonaws.com/',iamconf);sig

php - Telegram + PHP (Windows 7) : failed to open stream: HTTP request failed! HTTP/1.1 404 未找到

我正在尝试迈出Telegram的第一步,我也是PHP的新手......我已经在我的Windows7电脑上配置了带有PHP5.6.14和SSL的Apache2.4,它在http和https中运行良好。然后我尝试遵循此TelegramBot教程https://www.youtube.com/watch?v=hJBYojK7DO4.一切正常,直到我不得不创建一个像这样的简单PHP程序时";$website="https://api.telegram.org/bot".$botToken;$update=file_get_contents($website."/getUpates");prin

php - Oauth 2 $client->getAccessToken() 返回空值

我正在使用codeigniterMVC框架使用谷歌客户端库登录我的网站。当谷歌使用代码重定向并且我执行以下代码时,一切都运行良好,期待$client->getAccessToken()。$client->getAccessToken()返回空值。我看了很多教程,但没有得到任何帮助。这是我的Controller功能一的代码。在此函数中,我设置我的凭据以创建authUrl。publicfunctionlogin(){//Includetwofilesfromgoogle-php-clientlibraryincontrollerinclude_onceAPPPATH.'third_part