Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get tweets with hash tags #8

Open
mohitathwani opened this issue Sep 16, 2013 · 1 comment
Open

Get tweets with hash tags #8

mohitathwani opened this issue Sep 16, 2013 · 1 comment

Comments

@mohitathwani
Copy link

How can I use this script to get tweets with a particular hashtag instead of just tweets from my timeline ..??

I tried changing
$get_tweets = $connection->get("https://api.twitter.com/1.1/statuses/user_timeline.json?screen_name=".$twitter_user_id."&count=".$tweets_to_display."&include_rts=".$include_rts."&exclude_replies=".$ignore_replies);

to
$get_tweets = $connection->get("https://api.twitter.com/1.1/search/tweets.json?q=%40psatgames13");

but it doesnt work.

Please advise on how to proceed.

@andrewbiggart
Copy link
Owner

Hi mohitathwani,

Unfortunately I don't have time to look at this at the moment.

I'll try and get the functionality added asap.

You are along the right lines. However the formatting of the returned data will be slightly different for hastags, so you'll have to change the text and created on variables to match the change.

You can read more about this here. (https://dev.twitter.com/docs/api/1/get/search)

Hope this helps.

Andrew

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants