Skip to content

Latest commit

 

History

History
41 lines (25 loc) · 848 Bytes

File metadata and controls

41 lines (25 loc) · 848 Bytes

StraightDope is a gem for getting the URLs of media content from sites such as yfrog and Twitpic. Currently supported services:

  • yfrog

  • TwitPic

  • Lockerz

  • Twitgoo

  • img.ly

  • Mobypicture

Coming soon:

  • Posterous

Add this to your Gemfile and run the bundle command.

gem "straight_dope"

To use it, simply call extract_media on a string.

StraightDope.extract_media("put your urls here")

StraightDope will return you an array of URL strings, that you can use directly in your HTML tags.

  • oEmbed support

  • API keys

  • Video support

  • Different sizes

Straight Dope was inspired from these blog posts.

jasonneylon.wordpress.com/2011/02/01/twitter-picture-previews-with-ruby

railstips.org/blog/archives/2009/03/04/following-redirects-with-nethttp