web/tweet_ajax.php
changeset 708 a7b8011c91dd
parent 707 78ba6e14f159
parent 705 af8b10551286
child 1050 10feb1ce6d17
equal deleted inserted replaced
707:78ba6e14f159 708:a7b8011c91dd
    16      * a preconfigured instance of Zend_Http_Client which automatically
    16      * a preconfigured instance of Zend_Http_Client which automatically
    17      * signs and encodes all our requests without additional work
    17      * signs and encodes all our requests without additional work
    18      */
    18      */
    19     $token = unserialize($_SESSION['TWITTER_ACCESS_TOKEN']);
    19     $token = unserialize($_SESSION['TWITTER_ACCESS_TOKEN']);
    20     $client = $token->getHttpClient($configuration);
    20     $client = $token->getHttpClient($configuration);
    21     $client->setUri('http://api.twitter.com/1/statuses/update.json');
    21     $client->setUri('http://api.twitter.com/1.1/statuses/update.json');
    22     $client->setMethod(Zend_Http_Client::POST);
    22     $client->setMethod(Zend_Http_Client::POST);
    23     $client->setParameterPost('status', $_POST['status']);
    23     $client->setParameterPost('status', $_POST['status']);
    24     $response = $client->request();
    24     $response = $client->request();
    25 
    25 
    26     /**
    26     /**