Twitter Connect (sort of)

March 24, 2009117 Comments

Note:  Learn about the latest version and see additional instructions on this post.

 

If you take a look at my comment form on this blog, you’ll notice the addition of a little blue button.  Click on the button and you can claim your comments using your Twitter credentials.  This process tells my blog who you are, but I never have to ask for a password.  I’m using a WordPress plugin called Twit Connect.  I wrote it today, based on the work done by Adam Hupp of Facebook.  Although this plugin is nowhere near as complex as the Facebook Connect code, it provides the basic login into WordPress and will display avatars with each comment.

I’ll probably release this plugin in a few days after I try it out and get more feedback.  Give it a try yourself and leave me a comment on this post.

Update:  Download The Plugin From WordPress.org

Update 2: Adding the code to your Comments.php File:

Each theme will be slightly different, but you should place the code right about the Name field.  look for code like this in your comments file:

<?php else : ?>

<?php twit_connect() ?>

<p> <strong><?php _e(‘Name:’); ?> <?php if ($req) _e(‘(Required)’); ?></strong><br/>

<input type="text" name="author" id="author" value=" <?php echo $comment_author; ?>" tabindex="1" />

 

Share

99 Responses to “Twitter Connect (sort of)”

  1. deanpowers says:

    Let’s see if this Twitter Plugin for WordPress works. If it does, we’ll start on developers on doing the same thing for our Zope3 social collaboration software (Zojax)

    Pretty interesting this plugin knows your Twitter name and doesn’t even ask for your twitter password.

  2. Twitter Comment


    I just left a comment on Twitter Connect (sort of) at Shannon Whitley – [link to post]

    Posted using Chat Catcher

  3. twitter says:

    Good wordpress plugin

  4. Kasun says:

    Hi I’m developing blog for a client . I want to palce the twitter connect button some where other than diractly above the name field.

    I have two div elements , one in the left side with the comment form and the one in the right side with the twitter button.(Like techcrunch’s facebook button) I tried the placing the “” code, but for no success.

    If I tried to place it above the form it appears at correct place. But when I try to load it in the div on the right side it appears above the name field. Please help

  5. [...] So I think I might try Twit Connect, that in the spirit of all good things, does one thing and (hopefully) one thing well (for the record, I found out about this here, which led me to here). [...]

  6. Shannon Whitley says:

    @Kasun

    <?php if(function_exists(‘twit_connect’)){twit_connect();} ?>

    If you insert this code in your template, that is where the button should appear. If you changed the template on the Settings page, the “twc_connect” div is required.

    There is one other possibility. I wonder if the code in your comment section is being executed before your sidebar.

  7. Chris Perabo says:

    Oh, I am sad. I see this great “Sign in with Twitter” here below and I want it too. I never had this plugin before, but I just upgraded to WordPress 2.9.2 and then found this plugin.

    It did warn me that this plugin has not yet been tested with 2.9.2, but I installed anyway. I inserted the php code into the comments section, but when I go to install, I get the message,
    “Plugin could not be activated because it triggered a fatal error.”
    …and I am sad.

    I have PHP5, so that’s not the issue. Well, I hope I’ll get some support to get this running!

  8. @Chris Perabo – I’ve just verified that Twit Connect does work with 2.9.2. It may conflict with another plugin that you have installed. If you deactivate all of your plugins, activate Twit Connect, and then reactivate each one, you can tell which one is the culprit.

  9. Ljudbildspel says:

    Hi!

    I have problems with the author link. I want it to point to the author´s twitter profile (http://twitter.com/{username}).
    But it points to: http://mydomain.com/wp-admin/profile.php

    I have checked the author link tickbox.
    I´m pretty sure that it has been working before I updated to 2.08.

    Do you have any ideas?
    Have you heard this before or have I messed something up?

    I´m using the FB connect aswell and the author link works fine.

    eivind

  10. Shannon says:

    @Ljudbildspel – I just tested the author link. It works fine here. Have you tried it with a new user who has never logged in?

  11. Hi just testing to see how this works

  12. divya says:

    nice app, can u give the code?

  13. Ni co says:

    Hi Shannon,

    Your plugin works fine until I try to put my own consumer keys.

    I first tested it without, no problem. Then I check the box and put my keys, and I receive an error like : Twit Connect can’t retreive the username. It does it with alredy used twitter account and new ones.

    I got the feeling Twit Connect is still expecting “your” keys.

    I made many tests, reinstall plugin, get new keys, changing OS, browser, deleted first created users, etc.

    Any idea? or just badluck…

    Nico

  14. Simon Young says:

    Is there a way to use this without creating new users automatically in the WordPress back end? I’d like to just allow users to comment via Twitter or standard WP but not add new accounts for each commenter.

    Thanks

    Simon

  15. That of a wonderful post! Statements are the essential for virtually every little thing fundamentally

Leave a Reply

Twitter Tweet This

18 Trackbacks

  1. swhitley (Shannon Whitley)

    Twitter Comment


    Twitter Connect (sort of) – New WordPress Plugin – Claim blog comments w/ your Twitter login – [link to post]

    – Posted using Chat Catcher

  2. TwitLinksRSS (TwitLinksRSS)

    Twitter Comment


    Twitter Connect (sort of) | Shannon Whitley: If you take a look at my comment form on this blog, you’ll notice t.. [link to post]

    – Posted using Chat Catcher

  3. lyf108 (Larissa Fair)

    Twitter Comment


    RT @swhitley Holding my breath until someone tries this. Please comment on the Twit Connect WP plugin before I pass out – [link to post]

    – Posted using Chat Catcher

  4. swhitley (Shannon Whitley)

    Twitter Comment


    Also showing Twitter avatars with Twit Connect on my blog. Should release the plugin tomorrow – [link to post]

    – Posted using Chat Catcher

  5. swhitley (Shannon Whitley)

    Twitter Comment


    For late owls (I’m off to bed), Twit Connect WordPress Plugin. Claim comments w/ your Twitter id – [link to post]

    – Posted using Chat Catcher

  6. jasonwryan (Jason Ryan)

    Twitter Comment


    RT @swhitley: Twit Connect WordPress Plugin. Claim comments w/ your Twitter id – [link to post] < Very nice...

    – Posted using Chat Catcher

  7. DaveMora (Dave Mora)

    Twitter Comment


    [link to post] is it just me or is twitter new OAuth and Facebook connect going to a close version of “OpenID” ?

    – Posted using Chat Catcher

  8. { Suzanne Ahjira }

    Twitter Connect Adds Comment Functionality…

    I got a nice lead on another Twitter plug-in for WordPress today, Twitter Connect. I’m trying to understand the value-add here (versus the cost of running the plug-in) (and that’s “cost” as in the extra bandwidth it adds to your…

  9. barneyc (Barney Craggs)

    Twitter Comment


    Twitter Connect (sort of) | Shannon Whitley [link to post]

    – Posted using Chat Catcher

  10. tonys (Tony Scott)

    Twitter Comment


    RT @barneyc: Twitter Connect (sort of) | Shannon Whitley [link to post]

    – Posted using Chat Catcher

  11. cidermaker (cidermaker)

    Twitter Comment


    RT @Twitter_Tips USE TWITTER FOR Blog comments with this new plugin [link to post] –Share: http://bit.ly/SqEVh

    – Posted using Chat Catcher

  12. michaelmaass (michaelmaass)

    Twitter Comment


    @sacrion check this out. definitiv cool : [link to post]

    – Posted using Chat Catcher

  13. ipad (Ivor)

    Twitter Comment


    @huguito @webjac es fácil de integrar Twitter Connect [link to post] #twitterconnect

    – Posted using Chat Catcher

  14. rickdog (rick shide)

    Twitter Comment


    tTwit> Twitter Connect (sort of) | Shannon Whitley [link to post]

    – Posted using Chat Catcher

  15. swhitley (Shannon Whitley)

    Twitter Comment


    This Mashable/DISQUS login looks vaguely familiar – http://bit.ly/noXCS;) ([link to post])

    – Posted using Chat Catcher

  16. Most popular social media (cloud tools « Neaga Oleg)

    [...] [...]

  17. deanpowers (deanpowers)

    Twitter Comment


    I just left a comment on Twitter Connect (sort of) at Shannon Whitley – [link to post]

    Posted using Chat Catcher

  18. Using Twitter IDs for comments « dantwining.com

    [...] So I think I might try Twit Connect, that in the spirit of all good things, does one thing and (hopefully) one thing well (for the record, I found out about this here, which led me to here). [...]