No commit activity in last 3 years
No release in over 3 years
Extract title, meta-description and favicon out of a URL
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 0
>= 0
= 2.0.0.rc1

Runtime

 Project Readme

UrlInfoExtractor

The library helps you extracting some metadata out of HTML URLs.

https://github.com/der-flo/url_info_extractor

Usage

% gem install url_info_extractor

require 'url_info_extractor'
infos = UrlInfoExtractor.new('http://rubygems.org')
puts infos.title
# RubyGems.org | your community gem host
puts infos.favicon_url
# http://rubygems.org/favicon.ico
puts infos.favicon_exists?
# true
puts infos.description
#

Note that the favicon handling determines the URL by link-rel-icon tag and base tag. favicon_exists? does an HTTP HEAD request to check whether the icon is available at the determined path.

Fork me!

If you find this library useful but miss some feature, please drop me a note or - even better - fork the project at GitHub. Along with some specs I'll accept your pull requests.

Author and license

  • Florian Dütsch (mail AT florian-duetsch.de)
  • MIT, see LICENSE file.