Showing a Twitter Feed in a Drupal Block

Drupal twitterblock Module

In this tutorial we’ll show you how to place a Twitter feed inside a block. You can then display that Twitter feed anywhere around your theme. There are many different Twitter options out there but most have a couple of limitations:

  • They post tweets as nodes rather than in a block.
  • If they post to a block, they require very complex setups normally involving creating Views.

Thanks to Expedition Post, we’re going to suggest a much simpler way to show tweets in a block on your site. They’ve created a script that is very cleverly called “Twitter Block”.

Installing Twitterblock to Your Drupal Site

  • Step 1: Click here to download the latest version of “Twitter Block”.
  • Step 2: Extract the files into a folder on your desktop. The folder will be called “twitterblock”.
  • Step 3: Login to your site’s files via FTP and navigate to /sites/default/. If there isn’t a folder called /modules/ here, create one.
  • Step 4: Upload the “twitterblock” folder to /sites/default/modules/
  • Step 5: Go to Administer >> Site building >> Modules. Check the box next to “Twitter Block” and click Save Configuration.

Placing Your Twitter Feed in a Block

Now that Twitter Block is set up, we’ll go and place it on our site:

  • Step 6: Go to Administer >> Site building >> Blocks. Scroll down to find Twitter Block.
  • Step 7: Click “Configure” next to the block and enter your Twitter username and password:
  • Drupal twitterblock Module

  • Step 8: Click “Save Block”, publish the block and check to see how it looks on your site:
  • Drupal twitterblock Module

{loadposition drupalnewsletter}

Author

  • Steve Burge

    Steve is the founder of OSTraining. Originally from the UK, he now lives in Sarasota in the USA. Steve's work straddles the line between teaching and web development.

0 0 votes
Article Rating
Subscribe
Notify of
16 Comments
Oldest
Newest
Inline Feedbacks
View all comments
abhitesh
abhitesh
13 years ago

this is gr8 yaar.. it saved me…

thanks a lot..

kh2010
kh2010
13 years ago

I tried this module using these same directions (which are exactly identicle to numerous other articles yet the page i added the block on dissapears! the url i provided is where I added the block. Nothing comes up anymore.

[url=http://www.fpsa.org]http://www.fpsa.org[/url] > I think you can see the spot I’d like to add the feed to.

same here
same here
13 years ago
Reply to  kh2010

Its not working, and I just dont find the pass textbox

kim-zee
kim-zee
13 years ago
Reply to  same here

Exactly the same problem I had – no password box, therefore can’t reach twitter.

John
John
13 years ago

Don’t see password box either? Is this still working?

Would love to try it.

Ari
Ari
13 years ago

Tried to add it myself to our site. Everything works well except for the fact that the module won’t recognize my (or anyone else’s) username. Keeps telling me it doesn’t exist. I’m posting here but I’m guessing I’d have better luck emailing the people behind Expedition Post.

As for the password issue, EP’s site states that the latest version of the module doesn’t require the password, since it works off RSS

pablo23
pablo23
12 years ago

It doesn’t work for me. If someone can help… This is the error showed on my localhost test instalation:

warning: opendir(sites/all/modules/twitterblock) [function.opendir]: failed to open dir: Permission denied in /var/www/[url=http://openremolque.net/includes/file.inc]openremolque.net/includes/f…[/url] on line 934.

Thanks in advance!

pablo23
pablo23
12 years ago

Why is not this module in [url=http://drupal.org?]drupal.org?[/url] It’s really usefull cause the twitter module is too much complicated. Thanks.

An issue: It’s posible to add hashtags instead an account?

Thanks again!

Arghadip
Arghadip
12 years ago

It’s not at all compatible with Drupal 7!! Dammn application!!

Amritendu
Amritendu
12 years ago

is it possible to run the same code in drupal 7, please help me to overcome that issue

Rich
Rich
12 years ago

Received the following error:

warning: file_get_contents(): http:// wrapper is disabled in the server configuration by allow_url_fopen=0 in /var/www/modules/twitterblock/twitterblock.module on line 72.

Please advise

wheresjbob
wheresjbob
12 years ago

I’d suggest looking that this: [url=http://www.drupal.javatomic.com/content/twitter-block-drupal-7#comment-459]http://www.drupal.javatomic…[/url]

It’s an independant (not on [url=http://drupal.org]drupal.org[/url]) “Twitter Block for Drupal 7”. Works with Twitter Pull. Simple and just works. Full CSS control.

squidward
squidward
12 years ago

Twitter Pull: [url=http://drupal.org/project/twitter_pull]http://drupal.org/project/t…[/url]

nodeAche
nodeAche
12 years ago

Must point that this tutorial is for dupal 6.

criscom
criscom
11 years ago

I noticed that when I set the Number of tweets to return to 4, only 3 tweets are returned. Are you aware of a problem in the Twitter API?

16
0
Would love your thoughts, please comment.x
()
x