Archive for the ‘Twitter’ Category

WordTwit – a great way to tweet posts from WordPress MU

Friday, December 4th, 2009

wordtwitlogo.jpgBack in June, I asked about what people thought the best plugin was for publishing updates to Twitter when there are new blog posts posted here in WordPress MU/WPMU. I was then and have been using Alex King’s excellent Twitter Tools plugin for WordPress, but it was a bit like using a screwdriver to bang in a nail. The Twitter Tools plugin is primarily designed to capture your tweets in a blog post so that you can have occasional posts on your blog site that include all your tweets. The plugin can also publish tweets when you have a new blog post, but it’s real strength seems to be in pulling your tweets into your blog.

All I want to do is publish new tweets… I don’t want to create blog posts with tweets. So I’ve known for quite some time that I’ve been using the wrong plugin for the job… but it’s worked okay, so I continued. I tried a different plugin over on the VoiceObjects Developer Blog, but I haven’t been as happy with it because it tended to shorten the titles of blog posts too much when posting to Twitter.

However, recently my colleague Ron Blaisdell pointed me to WordTwit from BraveNewCode and I have to say that it is outstanding at what I need it to do. Once you install the plugin, there is a very simple configuration screen where you enter your username, password and can change the format of what gets tweeted out:

wordtwit-msg1.jpg

In our case, I chose to edit the message to be “[title] - [link]” so that there is no prefix on any of the tweets.

You then can choose which URL shortener you want to use – I chose bit.ly:

wordtwit-bitly1-1.jpg

After you save the configuration options, you then can go back in and enter your Bit.ly login and API key:

wordtwit-bitly2.jpg

This makes it so that all of your shortened URLs then show up in your bit.ly account where you can see statistics around who has clicked on them, etc.

Because we use Google Analytics, I also checked off an option to add UTM tracking codes to URLs so that I can find any inbound traffic in GA easily.

I’ve been using WordTwit here on blogs.voxeo.com for a bit now and have been very pleased with how well it works. I haven’t yet installed it on the VO Developer Blog but will be doing so soon. Kudos (and thanks!) to the folks at BraveNewCode for developing such a great plugin.

Have you tried WordTwit? Or what plugin do you use for updating Twitter?


If you found this post interesting or helpful, please consider either subscribing via RSS, becoming a fan on Facebook, or following us on Twitter.


What is the best Twitter plugin for WordPress MU?

Monday, June 29th, 2009

twitter.png

What is the best Twitter plugin for WordPress MU for simply publishing tweets when new blog posts are published? Or for WordPress in general?

It’s a question I’ve been mulling over a lot recently as I’ve been looking at:

  1. Reducing the number of tweaks I have to make to WordPress plugins on this site; and

  2. Linking other company WordPress sites into our Voxeo twitter stream.

Back in December 2007, when I first linked this blog site to our Twitter stream, I wound up using Alex King’s great Twitter Tools plugin (see also here). The challenge, though, is this:

I had to hack the plugin code to make it work for us.

THE PROBLEM

Specifically, I went into the code to remove the “New blog post:” that gets added as a prefix to any new message going out to Twitter. This is difficult to do by design, as Alex states in his plugin FAQ:

Is there any way to change the ‘New Blog Post:’ prefix when my new posts get tweeted?

Yes there is, but you have to change the code in the plugin file.

The reason this is done this way, and not as an easily changeable option from the admin screen, is so that the plugin correctly identifies the tweets that originated from previous blog posts when creating the digest posts, displaying the latest tweet, displaying sidebar tweets, and creating blog posts from tweets (you don’t want tweets that are blog post notifications being treated like tweets that originated on Twitter).

Can I remove the ‘New Blog Post:’ prefix entirely?

No, this is not a good idea. Twitter Tools needs to be able to look at the beginning of the tweet and identify if it’s a notification from your blog or not. Otherwise, Twitter Tools and Twitter could keep passing the blog posts and resulting tweets back and forth resulting in the ’spinning fireball of death’ mentioned above.

I have, of course, removed the prefix entirely. And now the problem is that whenever I need to upgrade the plugin, I have to remember to make this modification. Not good.

The issue is that there is a basic fundamental disconnect between the purpose of the Twitter Tools plugin and what I want to do.

The Twitter Tools plugin allows you not only to publish Twitter messages when you have a new blog post, but also perhaps more importantly to publish a blog post aggregating all your Twitter messages. So at some interval you have a new blog post that contains all your recent tweets. While I can see this being tremendously useful in some cases, and is honestly something I’ve been thinking about for my own personal blog, the truth is that for the Voxeo blog portal…

I don’t care!

All I really want out of the Twitter plugin is to publish a tweet whenever we publish a new blog post. I want the one-way push. And that is not where the power lies in the Twitter Tools plugin.

The challenge now in mid-2009 is that it seems like every developer, their brothers, sisters, parents, aunts and uncles have made a Twitter plugin for WordPress – there’s a zillion of them!

A SOLUTION?

So far, in the limited time I’ve had to research this, the plugin that has caught my eye is “Twitter Publisher” by Timan Rebel. It does precisely what it is says… very simply publishes a tweet any time you post a blog post. It does have the ability to add a tweet prefix, but that is blank by default. It also nicely has the ability to use either the bit.ly or awe.sm URL shortening service, which lets me tie the shortened URLs into my bit.ly account for tracking purposes.

I’ve installed this over on the VoiceObjects Developer Portal, which is currently a standalone WordPress (not WPMU) site, and so tweets now appear in our main Twitter stream when blog posts are published there. So far it seems to be working fine, although a couple of times I have been puzzled by how it has abbreviated the blog post title. For instance, here, pointing to this blog post, the post title is:

Adapt-to-me, as I don’t want to adapt to you

yet it was shortened to:

Adapt-to-me, as I don’t want to adap…

which seems strange as it didn’t seem to need to be shortened like that.

Outside of that, it’s been working well so far. I’m intrigued to try out the capability to also send a message to an author’s Twitter account based on including an author’s Twitter name in his/her profile.

MOVING AHEAD

Part of my reason for writing this post is to find out what plugins others have found useful for one-way publishing to Twitter. I have two steps I need to take:

  1. Add a Twitter plugin to blog.imified.com so that posts there automatically appear in our main Twitter stream (Added challenge there: ideally we would like tweets to appear in both @voxeo and @imified)

  2. Replace the Twitter plugin I use here at blogs.voxeo.com in our WordPress MU installation so that I can remove one post-plugin-upgrade tweak I have to make.

The one challenge with Twitter Publisher is that it’s not 100% clear that it will work with WordPress MU, although I’ve generally found most WP plugins to work well with WPMU.

So I throw the question out there… what Twitter plugins for WordPress MU (or WordPress) have you found work the best for updating your Twitter stream whenever you publish a new blog post?

(Thanks in advance)


If you found this post interesting or helpful, please consider either subscribing via RSS, becoming a fan on Facebook or following us on Twitter.


Technorati Tags: , , , ,


If you found this post interesting or helpful, please consider either subscribing via RSS, becoming a fan on Facebook, or following us on Twitter.


Connecting WordPress MU to Twitter to auto-tweet new blog posts

Monday, December 31st, 2007

twitter.pngGiven that over the past year Twitter has emerged as one of the new communication tools within social media, one of my natural reactions was to figure out how to connect this blog site to Twitter so that a post/tweet would appear in twitter.com/voxeo whenever we posted a new article. (If you are not aware of Twitter, my external “The 10 ways I learned to use Twitter in 2007” should give you an overview.) My main reason for wanting to do this was to provide another way for people to stay up on what we post here. For some people, myself included, it’s easier to follow someone on Twitter than even to subscribe to their RSS feeds. So I wanted to make it easy for someone to “follow” the posts we create here on blogs.voxeo.com.

My first instinct was to simply go over to Twitterfeed.com and set up a link between our RSS feed for all posts and our new Twitter account. This undoubtedly would have been the simplest path to go – and one I’d probably recommend for others. There were however, several problems/challenges/concerns:

  1. Twitterfeed.com requires the use of OpenID to login, which, as an OpenID advocate, I delight in. However, I wanted to create the feed using a Voxeo-related OpenID versus one of my own, so first I needed to go and turn this blog site into an OpenID provider.

  2. My second concern was just that Twitterfeed.com seemed somewhat inefficient in that it has to poll to find out if you had new posts to tweet. There’s naturally the potential time delay from posting… and also just the general inefficiency. We are not posting here all that often and don’t need the feeds checked all that much.

  3. My third concern was the issue of introducing yet another site in between this site and Twitter. Given Twitter’s API, it seemed logical that we could connect directly.

  4. By the time I got the site set up to provide OpenID, Twitter was experiencing some performance problems last Friday and the Twitterfeed.com site was also offline.

This last issue caused me to decide I had to solve the problem on our own server so that we aren’t dependent on another site.

A Google search brought me to the “Twitter Updater” plugin for WordPress which, on first glance, seemed to provide exactly what I was seeking. I followed the instructions, activated it for one of the blogs, filled in the credentials, posted a test post and……. nothing. No Twitter post. In further reading down the page, it became clear that the developer stopped further work on this plugin and in fact moved her blog from WordPress over to Drupal and so had no real interest in the plugin anymore. I tried a hack by another user, but it, too did not work.

Meanwhile a friend had recommended that I use Alex King’s great “Twitter Tools” plugin. I actually had it installed, but hadn’t really thought about it for purely posting to Twitter. The strength of the Twitter Tools plugin is really about taking your updates from Twitter and posting it to your blog (which the README clearly shows). However, in our case, we’re not going to be (or don’t expect to be, anyway) posting independently to twitter.com/voxeo. It’s just another publishing medium for us – a one-way publish out to the world of Twitter. So we don’t need to publish our tweets here because there won’t be any.

This is, however, the solution I ultimately used. I activated the plugin for one of the blogs on this site, configured it with our Twitter username and password and then changed the settings so that it was only publishing outbound to Twitter.

There was one change I did make to the PHP code. By default, every new blog post appears in your Twitter stream with the prefix “New blog post: “. However, since our Twitter stream is only new blog posts, this prefix is redundant and wastes some of our precious 140 characters! So I modified line 75 and 76 of “twitter-tools.php” from this:

$this->tweet_prefix = 'New blog post';
$this->tweet_format = $this->tweet_prefix.': %s %s';

to this:

$this->tweet_prefix = '';
$this->tweet_format = $this->tweet_prefix.'%s %s';

You can see the result now over on twitter.com/voxeo.

A couple of notes about this implementation:

  1. The good news is that this posts to Twitter as soon as we publish an article to a blog. No polling. No waiting. No reliance on a site in the middle (Twitterfeed). Just direct from our site to Twitter via the Twitter API.

  2. The good or bad news, depending upon your perspective, is that the plugin needs to be activated separately for each of your WPMU blogs. If you have a lot of WPMU blogs and all you want to do is take all the blog posts and post them to Twitter, you are probably far better off taking the Twitterfeed.com route and simply linking a site-wide RSS feed to a Twitter account. In our case, we don’t have a large number of blogs and while we anticipate adding a few more, we don’t expect to add a huge number. Activating/configuring this plugin is now something I’ll just add to my “provisioning checklist” when rolling out a new blog.

    Note that on the good news side, we do now have a much higher degree of control over precisely which blogs post to the Twitter.com/voxeo account. Because we have to manually configure it, we wind up having the flexibility to not configure certain blogs, so that their postings do not appear in the Twitter.com/voxeo stream. We also have the flexibility to configure a certain blog to post to a different Twitter account. That’s not something I see us doing, but we do now have the option, which we wouldn’t if we simply connected our “all blogs” RSS feed to a Twitter account.

  3. Do note that since we are using WordPress MU, after dropping the Twitter Tools plugin code into the “plugins” directory, I did need to go into the Site Admin page for the site and “allow” the use of the plugin for blogs on the site. After that, I could go into each individual blog, activate the plugin and then configure the settings.

  4. I have the plugin activated currently in four blogs and all are configured to post to the same Twitter account. Everything seems to be working fine.

So there it is… how I linked our WordPress MU blogs to Twitter to publish notifications to the Twitter account when we post new blog entries. Hopefully some of you out there will find this helpful.

Technorati Tags: , , , , , , ,


If you found this post interesting or helpful, please consider either subscribing via RSS, becoming a fan on Facebook, or following us on Twitter.