Twitter button to reply to a tweet - twitter

I am looking for a way to create a Twitter button which would automatically post a reply to an existing tweet, without the API.
Clicking the button would open a pop up window with a Twitter status form. Tweeting from the window would create a reply, which would have the tweet_id replied to in its metadata.
Any help appreciated.

Use Twitter's Web Intents for this. You can setup the tweet intent to take a in_reply_to parameter indicating the tweet that is being replied to. It's pretty much as simple as creating an HREF pointing to https://twitter.com/intent/tweet?in_reply_to=12345
If you incude Twitter's optional Javascript, the HREF will become a pop-up automatically and you can further track the events.

Related

Making a link that generates a tweet on Twitter

I've just looked online but couldn't find the answer:
Is it possible to include a link in an HTML e-mail, so that when a user clicks it, it takes them to post a pre-defined text on their Twitter account, e.g. "#username #hashtagterm This text comes up automatically for me to tweet"?
I guess that if a user isn't logged in, they'll have to go past the login screen and then arrive at the page where they can send the tweet, right?
As I said, it needs to work reliably in an email, so I guess it shouldn't have any javascript associated with it.
Thanks for any help.
Try this, replacing the text with what you want:
https://twitter.com/intent/tweet?text=this+is+a+test
See intents

Link on published action with opengraph

I've a trouble with my link on published action.
When my action is published, the link appear like that:
http://www.facebook.com/l.php?u=http%3A%2F%myDomain.com%2F%3Ffb_action_ids%3D3085543269620%26fb_action_types%3Dvideo.watches%26fb_source%3Drecent_activity&h=dAQF21zjX&enc=AZP6SPsPIfAKMoNKqLKjTEig1nsAERVmwUcrfURxEHA34JS11i5ofB29bXKBaOrkm0cOv-Lyg5IVTth3Kr308Qar
And I see on another app who used the same action, the link appear like that:
http://www.facebook.com/connect/uiserver.php?app_id=XXXXXXX&method=permissions.request&redirect_uri=http%3A%2F%2FTheDomain.com%3Ffb_action_ids%3D3056990355815%26fb_action_types%3Dvideo.watches%26fb_source%3Drecent_activity&response_type=token&display=page&auth_referral=1
Did you know why we haven't not the same publish link type ?
I want to publish with an URL like that: http://www.facebook.com/connect/uiserver.php?app_id=XXXXXXX&m.....
Best regards, sorry for my poor english :/
The link of the first type appears when a users click on a link which will take them to an external site.
The link of the 2nd type appears if the app has enabled Authenticated Referrals in the app's settings. When a user click a link of this type, Facebook links into the Authentication Dialog to generate an access token or OAuth code, the user is then redirected to the Action URL.

Post with Twitter API and PHP

I am new to Twitter API and in twitter in general so I have some questions. I have a web site and I want to add a button for sharing a message (for example "Hello World", taken from my site) to a user's twitter page.
First of all I have created an application in twitter, call myTwitterApp and I want to post through this. When the user clicks the button I want to see the authentication page, for login, and then after login I want to see my message inside the editable input, being able to be changed my the user. And finally I want the user to post it by clicking the tweet button, but continue saying that the post was "via myTwitterApp".
Does anyone have an idea how to do it or how to search about it?
Thanks in advance.
I have some experience with the twitter api lately, but not comprehensively. so I can only give you some kind of direction, and hopefully this will help you. So the idea is that you should understand how the Oauth protocol works, steps like requestToken->accessToken->api calls. there is a tutorial for beginners here http://oauth.net/documentation/getting-started/, you shold take a look. if you have manage to go through the oauth authentication, then you should be able to call the POST method which you can post contents to Twitter. you can search for Twitter oauth api, there are a bunch of them online. grab one and use it.

Can I post on page's wall with an iOS application?

How to post to a page's wall using FaceBook Graph API for iPhone?
Should I need to prompt for any permission for that?
Is it possible or not?
Thanks in advance.
You can using the Post method. It requires the publish_stream permission. The user needs to have "liked" the page in question.
To publish a wall post, POST the
message and optional attachment to the
feed/wall of the user, page or group,
i.e.,
http://graph.facebook.com/PROFILE_ID/feed.
Annoyingly, the one thing that Graph API will not allow, is to let the user "like" a page through it. The user must already have "liked" the page. (catch-22)
Graph API Page documentation

Twitter oauth authorization in a pop-up instead of in main browser window

I feel incredibly stupid for even asking this since the answer might already be under my nose but here it goes:
TweetMeme has a Re-tweet twitter widget that publishers can place on their blogs. When a user clicks on the widget, it pops open a window which allows the user to authenticate themselves with twitter and then re-tweet.
This seems to use some special Twitter oauth popup form factor - unless there is something fancier happening under the surface to authenticate the user.
The pop-up window looks like this:
http://twitpic.com/1kepcr
I'd rather handle an authentication via a pop-up rather than send the user to a brand new page (for the app I'm working on) and they seem to have the most graceful solution. Thoughts on how they did this?
I think that the process is something like this (I assume that they have used php on server-side):
First it opens a jQuery-like popup, but it's not strictly related to twitter sign in functions.
The real sign-in process begin when you confirm that popup, so it open new popup, with some php inside, that # hold a session.
Those scripts ask to twitter the request tokens, using site's application params, and save them into $_SESSION array.
If it's all-right, twitter send you to twitter authenticate page (https://twitter.com/oauth/authenticate), and after you have inserted your login params, twitter send you to the callback page defiend by that site. Here there is another php page that request access tokens, and save them into $_SESSION array. If it's all-right now the site has params that he needs for querying your profile, so last scripts inside popup refresh opener window (main site) and close himself.
Now main window has all the interesting params inside $_SESSION array.
Check this useful library for all the server-side work.
All they're doing is opening a page http://api.tweetmeme.com/share?url=someURL&source=tweetmeme in a new window (using target _blank), then starting the process from there.
EDIT: I was looking at the wrong retweet button. For your specific example, clicking the retweet button first opens Tweetmeme page http://tweetmeme.com/ajax/partial?... in a new window. Clicking yes then initiates the OAuth process by sending you (still in that window) to https://twitter.com/oauth/authenticate (with appropriate parameters).

Resources