Skip to content

Instantly share code, notes, and snippets.

@FraGoTe
Last active May 23, 2018 18:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save FraGoTe/a7e6e319b27ba3055575028d57bdaab2 to your computer and use it in GitHub Desktop.
Save FraGoTe/a7e6e319b27ba3055575028d57bdaab2 to your computer and use it in GitHub Desktop.
<?php
$client = new Zend_Http_Client();
$client->setMethod(Zend_Http_Client::POST);
$client->setUri('http://www.example.com/api/type/');
$client->setParameterPost(array(
'useremail' => '******@*****.***',
'apikey' => 'secretkey',
'description' => 'TEST WEB API',
'amount' => '5000.00'
));
// Agregando headers
$client->setHeaders('Host: www.example.com');
$client->setHeaders('Cookie', array(
'PHPSESSID=1234567890abcdef1234567890abcdef',
'language=es'
));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment