使用Nokogiri获取页面Keywords
require 'rubygems'require 'nokogiri'doc =Nokogiri::HTML("<html><head><meta name=\"Keywords\" content=\"one, two, three\"></head><body></body></html>")doc.xpath("//meta[@name='Keywords']/@content").each do|attr| puts attr.valueend