Sha256: 0e89d74ef92e5fe94dbf001247924b93ce97d5549f582db718fd5630d0983b8f
Contents?: true
Size: 412 Bytes
Versions: 2
Compression:
Stored size: 412 Bytes
Contents
require "uri" require "open-uri" require "nokogiri" module NnmClub class Torrent def self.find(torrent_id) document = Nokogiri::HTML(open(NnmClub::TorrentURL+torrent_id)) postbody = document.css('.postbody').first info = {:content => postbody.to_html( encoding: "UTF-8" ), :image => postbody.css('var.postImg').first['title'] } return info end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
nnmClub_api-0.1.1 | lib/nnmClub_api/torrent.rb |
nnmClub_api-0.1.0 | lib/nnmClub_api/torrent.rb |