One box for old non-migrated vB posts

By saving a file sitepoint_forums_onebox.rb in the lib/onebox/engine folder

module Onebox
  module Engine
    class SitepointForumsOnebox
      include Engine
 
      matches_regexp /^http:\/\/www\.sitepoint\.com\/forums\/.*/
 
      def to_html
        "<iframe src='#{@url}' style='border-width:0' frameborder='0' scrolling='no' width='100%'></iframe>"
      end
    end
  end
end

Needs some Design Love

2 Likes