Method: Worldfootball::Page#keywords
- Defined in:
- lib/worldfootball/page.rb
#keywords ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/worldfootball/page.rb', line 27 def keywords # <meta name="keywords" # content="Bundesliga, 2010/2011, Spielplan, KSV Superfund, SC Magna Wiener Neustadt, SV Ried, FC Wacker Innsbruck, Austria Wien, Sturm Graz, SV Mattersburg, LASK Linz, Rapid Wien, RB Salzburg" /> @keywords ||= doc.css( 'meta[name="keywords"]' ).first @keywords[:content] ## get content attribute ## or doc.xpath( '//meta[@name="keywords"]' ).first ## pp keywords # puts " #{keywords[:content]}" # keywords = doc.at( 'meta[@name="Keywords"]' ) # pp keywords ## check for end |