Class: BlueConductor::HTTP::Song::Response

Inherits:
Object
  • Object
show all
Defined in:
lib/blue_conductor/http/song/response.rb

Class Method Summary collapse

Class Method Details

.album(html) ⇒ Object



11
12
13
14
15
16
17
18
# File 'lib/blue_conductor/http/song/response.rb', line 11

def self.album(html)
  doc = Nokogiri::HTML(html)
  begin
    doc.css('div.pagetitle a')[1].text
  rescue
    'Album Missing'
  end
end

.data(html) ⇒ Object



6
7
8
9
# File 'lib/blue_conductor/http/song/response.rb', line 6

def self.data(html)
  doc = Nokogiri::HTML(html)
  doc.css('p#songLyricsDiv').text
end