TwitterTweets: My First Plugin For the ColdFusion-Powered Mura CMS

This is my first attempt at building a Mura CMS plugin, so as you can imagine, this is going to be pretty darn simple. This plugin was actually inspired by a blog post I wrote back in March 2009 about using ColdFusion's CFFeed to display twitter tweets. If you like it ... great! If not, sorry I disappointed you.

The plugin will allow you to display the most recent tweets on your site(s). No knowledge of ColdFusion or programming should be required! However, if you are comfortable with .css, etc.then you'll be happy to know the tweets are displayed within a div id of "twitterTweets" and the tweets themselves are output in an unordered list, so you can style to your heart's content.

If there are tweets available via the twitter search interface, then you should be able to see output. If not, or if the tweets are more than a few weeks old, then you will see a message stating that there are no tweets available.

Installation

  1. Login to your Mura CMS admin
  2. Go to "Site Settings" (upper-right on the yellow bar)
  3. Select the "Plugins" tab
  4. Browse to the location of the TwitterTweets.zip file (don't unzip the files! Mura will do this for you. Unless, of course, you want to poke around the code.)
  5. Click "Deploy"
  6. You need to enter you twitter username. For example, if you visit http://twitter.com/stevewithington, then "stevewithington" is your username.
  7. Under "Site Assignment" be sure you select which site(s) you wish to apply this plugin to
  8. Go to the "Site Manager" of the site you wish to display this on
  9. Select a page to edit
  10. Select the "Content Objects" tab
  11. From the "Available Content Objects" dropdown, select "Plugins"
  12. Then select "TwitterTweets" and choose which area to display on by clicking the ">>" button
  13. Click "Publish"

Optional settings at this point are merely how many recent tweets to display and whether or not you want to show a title above the tweets.

Need help?

Catch me on the Mura CMS forums or contact me through my site.

Cheers!

Edit

I was asked about using more than one twitter username and how to handle the plugin for multiple sites. The answer is actually quite simple. All you would have to do is install and deploy TwitterTweets again. This would allow you to have multiple installs, each with their own username, etc. This also gives you control over which install goes to which site(s).

I am considering including the ability to have multiple usernames for one install though.

Any other suggestions?

Comments

guess i should also mention the plugin is FREE! just click the "Download" link at the end of the article.
# Posted By Stephen Withington | 8/28/09 8:22 AM
Great addition Steve. Thanks for the work and all of your involvement on the forums.
# Posted By David Morgan | 8/28/09 8:50 AM
@David, thank you too man!
# Posted By Stephen Withington | 8/28/09 9:00 AM
Cool stuff, Steve! Mura plugins are just plain fun to build, aren't they?

I can't wait to try this out.
# Posted By Grant | 8/28/09 1:19 PM
@Grant, yeah, this was my first stab at it and i just wanted to understand how a very simple plugin worked. trust me though, it's nowhere near the complexity of your plugins ... so don't get too excited.
# Posted By Stephen Withington | 8/28/09 1:26 PM
Thanks for building this Steve. Installed easy as pie!

If you are open to a few suggestions, some href control options would be a good addition to the setup. Adding a rel for nofollows and a target for new windows would be sweet.

Again, great job. Looking forward to more plugins

- Lou Lynch
AutoInsurancePlans.com
# Posted By Lou Lynch | 9/8/09 10:05 AM
Gotta love little Mura Plugins that work right out of the box with such simplicity - many thanks for sharing!
# Posted By Jonas | 1/11/10 11:20 AM
Steve - This is great but I am wondering if you could tell me how to make a small change. The twitter feed I am pulling from isnt real active and when I go to show the last 3 it says "account" hasn't twittered in awhile. Anyway I can grab the last 3 regardless of time?
# Posted By Dan Vega | 12/31/12 2:35 PM
Just curious if anyone has been able to get this working on a page with a secure connection. I updated the script source in the tweetWeidget.cfm to use https when loading https://widgets.twimg.com/j/2/widget.js, but I'm still getting an error in my console that insecure content from http://platform.twitter.com/widgets.js is being blocked?
# Posted By John Sieber | 3/7/13 12:42 PM
Ignore my previous post, we were loading the widget.js in another location as well. This plugin does work under SSL once the call to widget.js is modified.
# Posted By John Sieber | 3/7/13 1:11 PM

© 2024, Stephen J. Withington, Jr.  |  Hosted by Hostek.com

Creative Commons License   |   This work is licensed under a Creative Commons Attribution 3.0 Unported License.