I’m trying ‘open-uri’ on Windows XP and my ‘test_uri.rb’ runs OK. But
when I transform ‘test_uri.rb’ in ‘test_uri.rhtml’ and run it on my
localhost I get an error in the last line:
/lib/ruby/1.8/net/http.rb:560:in `initialize’: getaddrinfo:
non-recoverable failure in name resolution.
What is going on?
------------test_uri.rb--------------
require ‘open-uri’
require ‘rexml/document’
include REXML
page = open(“E:/xampp/htdocs/my/MyRuby/rhtml/2360.xml”) #local
file
page=open(‘<![CDATA[BBC News - Home]]>’)
========test_uri.rhtml=============
<%
require ‘open-uri’
require ‘rexml/document’
include REXML