Revision: 64659
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at September 4, 2013 08:04 by danielousky
Initial Code
def cargar_pag(enlace) require 'nokogiri' require "net/http" require "uri" url = URI.parse(enlace) req = Net::HTTP::Post.new(url.path) http = Net::HTTP.new(url.host, url.port) http.use_ssl = true http.verify_mode = OpenSSL::SSL::VERIFY_NONE @return = http.request(req) resp = @return.body #.force_encoding("utf-8") # resp = resp.delete "&" return Nokogiri::HTML(resp) end
Initial URL
Initial Description
Ejemplo de Carga de Página con Nokogiri
Initial Title
Load Simple Pag Nokogiri
Initial Tags
load
Initial Language
Ruby