jublo / codebird-php

Easy access to the Twitter REST API, Direct Messages API, Account Activity API, TON (Object Nest) API and Twitter Ads API — all from one PHP library.
https://www.jublo.net/projects/codebird/php
GNU General Public License v3.0
775 stars 237 forks source link

Do not get the url of the third part website , when a post is shared from it. #241

Open Majid-ali37 opened 5 years ago

Majid-ali37 commented 5 years ago

I shared a post from a third party blog website to my twitter account and it didn't returned the link to that actual post on its website, in the response. I needed it to pull meta from that website's page from which the post has been shared, just like twitter do.

Majid-ali37 commented 5 years ago

Please resolve my issue ASAP

mynetx commented 5 years ago

@Majid-ali37 Thanks for your question – please share the relevant part of your code and we may take a closer look.

Majid-ali37 commented 5 years ago

Ok I'm using this code to retrieve my tweets, everything is working perfect except for the third party url from which I shared a post. For example , I shared a post from quora.com website to my twitter handle, it was shared to my twitter tweets , but the url ( I need to extract the meta of website from which the blog was shared i.e quora as twitter do ) of that website (quora.com) was found no where in the response. here is my code. ` require_once (path_to_codebird_lib/codebird-php-develop/src/codebird.php'); function tweets(){

\Codebird\Codebird::setConsumerKey(CONSUMER_KEY, API_SECRET); // static, see README

$cb = \Codebird\Codebird::getInstance();

$cb->setToken(ACCESS_TOKEN,ACCESS_TOKEN_SECRET); // see above

$reply = (array) $cb->statuses_userTimeline(); echo "

";
print_r($reply);
echo "

";`

mynetx commented 5 years ago

@joshuaatkins I would like you to take a look at this one, please.

bobbykjack commented 5 years ago

FWIW, I'm using 3.1.0 and I am getting the 'source' attribute of a tweet as expected, when using the statuses_userTimeline() method.