Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

URL for a link to Twitter for a specific tweet

Tags:

twitter

I have some Javascript that uses Twitter API to get tweets. I parse the data and use jQuery to generate HTML for the DOM.

An aspect of what I want to display is a "View this tweet" link -- yeah, sorta sounds silly, but it allows a user to get a URL for a specific tweet.

I am generating an a tag with an href. The URL is of the form:

http://twitter.com/{twitter-user-id}/status/{tweet-status-id} 

where the content in curly braces is actual data extracted from the tweet (no, I am not including the curly braces). For example:

http://twitter.com/Atechtrader/status/57432099984130050 

What happens in operation is that this works for some tweets, but not others. For the ones that fails, the Twitter server responds with content that says the requested page does not exist.

Am I doing something wrong?

like image 700
Zhami Avatar asked Apr 13 '11 15:04

Zhami


People also ask

How do I make a short URL for Twitter?

Creating a link is simple. Copy the link from the address bar of page you want to post. Paste it into the space provided on short.ie or bit.ly. Click the 'shorten' button and it will provide you with a tweet sized link.


1 Answers

https://twitter.com/statuses/ID should work.
it will redirect to the needed status.

like image 165
Sagiv Ofek Avatar answered Oct 02 '22 08:10

Sagiv Ofek