Questions tagged [zend-http-client]

Zend_Http_Client provides an easy interface for preforming Hyper-Text Transfer Protocol (HTTP) requests.

Zend_Http_Client provides an easy interface for preforming Hyper-Text Transfer Protocol (HTTP) requests. Zend_Http_Client supports most simple features expected from an HTTP client, as well as some more complex features such as HTTP authentication and file uploads. Successful requests (and most unsuccessful ones too) return a Zend_Http_Response object, which provides access to the response's headers and body.

62 questions
0
votes
1 answer

Zendframework 3 - can't initialized Zend/http

As per subject, how to solve the initilizer problem for the Zend/Http? In my controller: use Zend\Http\Client; class AuthController extends AbstractActionController { /** * Entity manager. * @var Doctrine\ORM\EntityManager */ …
Louis Lee
  • 281
  • 5
  • 15
0
votes
1 answer

Zend_Uri_Http: Invalid URI supplied when using Google Chart URI?

My application uses Google Charts and using HTTPS. I need to display the Google Charts as "secure" images, otherwise Internet Explorer will complain about displaying insecure content. So, I am trying to download them (then link to the local file)…
Andrew
  • 227,796
  • 193
  • 515
  • 708
0
votes
3 answers

Zend Framework 1.10: Cookies aren't stored

I'm trying to with Cookies and Zend Framework 1.10. This is my code: $zendCookie = new Zend_Http_Cookie('foo', 'bar', 'localhost', time() + 60 * 60 * 24 * 30); $client = new Zend_Http_Client(); $client->setCookie($zendCookie); But the cookies…
thomas
  • 11
0
votes
1 answer

How to perform an HTTP request from a Module#onBootstrap(...) in ZF2?

In a Module class of a Zend Framework 2 application I'm sending an HTTP request to a special endpoint to get some information about the user. It works, when I do this within a factory (s. the 1st approach in the code below). It also works within a…
automatix
  • 14,018
  • 26
  • 105
  • 230
0
votes
2 answers

How to do PUT and DELETE with Zend_Http_Client

The Zend_Http_Client docs are confusing and hard to understand. Currently I am using the following code to GET information from the Challonge API: $client = new…
Jason Axelrod
  • 7,155
  • 10
  • 50
  • 78
0
votes
1 answer

ZendService Twitter fails on Client connect()

Having problems connecting with the Twitter API through ZendService/Twitter/Twitter. Error: Fatal error: Call to a member function connect() on a non-object in somepath/vendor/zendframework/zendframework/library/Zend/Http/Client.php on line…
Al-Punk
  • 3,531
  • 6
  • 38
  • 56
0
votes
1 answer

Passing duplicate keys in post request using Zend_Http_Client

I'm using an API using a POST request and Zend_Http_Client. I need the query string to emulate a get request that would look like ?id=5&id=10&fileName=Sample-Document. As you can see, there are two id parameters. Is there a way to do this using…
Nolan Knill
  • 499
  • 5
  • 19
0
votes
2 answers

Zend Http Client : Invalid URI Supplied Error for Urls that redirect

I want to get html of a URL. Basically I am doing this : $client = new Zend_Http_Client($url); $client->setConfig(array('strictredirects' => true, 'timeout'=> 100, 'storeresponse' => true)); $response = $client->request(); $html =…
VishwaKumar
  • 3,433
  • 8
  • 44
  • 72
0
votes
1 answer

Zend_Http_Client SSL Exception

I have Zend Framework 1.12 project, and PHP 5.5.3 and nginx 1.2.7 + php-fpm installed on Ubuntu 10.04 server. I receieved the following exception Message: Unable to Connect to ssl://pftradingnet.com:443. Error #179898264: Unable to find the socket…
zavg
  • 10,351
  • 4
  • 44
  • 67
0
votes
2 answers

zend_http_client browser caching issue

I'm trying to access an https site by passing the username and password into the code, however, the website is denying me access due to 'browser caching issue', can someone help please? here is the code: $client = new…
user2045298
  • 11
  • 1
  • 4
0
votes
2 answers

Too slow Http Client in Zend Framework 1.12

I want to send ~50 requests to different pages on the same domain and then, I'm using DOM object to gain urls to articles. The problem is that this number of requests takes over 30 sec. for ($i = 1; $i < 51; $i++) { $url =…
0
votes
1 answer

How to use zend_http_client or curl in right way

I'm using zend_http_client. What i want is to send a request to transfer(without redirecting) to another site and send number in field that I have and get the answer with info i need to use on my site. That's what i'm doing, but how to send my…
Stopper
  • 411
  • 3
  • 13
0
votes
1 answer

Maximum query length on Zend_Http_Client?

I am using Zend_Http_Client as follows: $client = new Zend_Http_Client($apiURL); if (strpos($restriction, 'c') !== false) { $client->setParameterGet(array( 'channels' => $channels, )); } $client->setParameterGet(array( 'limit'…
Jason Axelrod
  • 7,155
  • 10
  • 50
  • 78
0
votes
1 answer

Zend_Http_Client: How to "do not download large files"

I have PHP script with use of Zend_Http_Client. Script do 2 things: "Expand" shortened urls + get mime-type of URL Get HTML content of text/html urls I use this simple code: $client = new Zend_Http_Client($url); $response =…
noff
  • 115
  • 1
  • 5
0
votes
1 answer

How to retrieve $_POST variable in an action

I am very newbie in zend framework, I send some data to an action with post method by this way: $config = array( 'adapter' => 'Zend_Http_Client_Adapter_Curl', ); $client = new Zend_Http_Client('http://example.com/api/last-news',…
Arash Mousavi
  • 2,110
  • 4
  • 25
  • 47