Could Storify be implemented in Drupal?

; Date: Tue Mar 29 2011

Tags: Node.js »»»» Drupal

I've been exploring Node.js recently (long story, which will see a book come out of it reasonably soon) and one site I've come across is Storify. It first caught my eye because it's supposedly implemented using Node.js, but once I got there some of the functionality really caught my eye. The site appears to still be in a private "beta" but they have some examples published that shows fantastic integration with social networking sites.

For example.. if you want to refer to a specific in your article, the simple ways are

  • to paste in the URL making your visitor go to (twitter.com) twitter.com to read the tweet,
  • copy/paste the text of the tweet, attaching the URL,
  • taking a screen shot and embedding the image.

But, on the Storify site an embedded tweet is a useful widget that supports directly retweeting or sending @ replies to the author of the embedded tweet. It's not just tweets, the examples I see on the site are Twitpic images, and YouTube videos.

After a couple days of this rumbling in my head I was struck that it's feasible to implement this in Drupal, and further there is an existing module which could be a useful starting point:

(drupal.org) http://drupal.org/project/googtube

The question is.. why was that link presented by Drupal as a bare link? What if the link filter were to recognize it as a link to a Drupal project and render a useful widget about the Drupal project in question? What about a link to, say, (www.youtube.com) http://www.youtube.com/user/TheCivilWars ... a youtube channel page, why can't that be a little video player showing videos from that channel. Or a link to a youtube video, why not render it as a youtube video player? Or a link to a flikr or other photosharing site, why not render a thumbnail of the image?

Go to this page ... (storify.com) http://storify.com/ajestream/miyagi ... play with some of the objects.

Now.. look at the googtube module source: (drupalcode.org) http://drupalcode.org/project/googtube.git/blob/HEAD:/googtube.module

Don't you see that the googtube_youtube and googtube_google functions serve as a pattern, and that a googtube_twitter function could take twitter links and render them with some javascript code which implements a widget like the one on the (storify.com) storify.com page referenced above? And that to support fancy widgets for links to various services is "just" a matter of adding a preg_replace_callback matching the link pattern for each service, and a googtube_xyzzy function to match?

This is quite possible.

(drupal.org) http://drupal.org/node/1108528 is the place to add some opinions.

UPDATE: Some comments were made when this post lived on (davidherron.com) davidherron.com.  Those comments are important enough to replicate here ...

(www.oembed.com) http://www.oembed.com/ - https://github.com/embedly - (drupal.org) http://drupal.org/project/oembed

(embed.ly) http://embed.ly/

(github.com) https://github.com/embedly/embedly-node

About the Author(s)

(davidherron.com) David Herron : David Herron is a writer and software engineer focusing on the wise use of technology. He is especially interested in clean energy technologies like solar power, wind power, and electric cars. David worked for nearly 30 years in Silicon Valley on software ranging from electronic mail systems, to video streaming, to the Java programming language, and has published several books on Node.js programming and electric vehicles.