Cannot parseWikipedia Atom feed....

A

Arun Kumar

Hi,
I'm using net/http to parse the rss and atom feeds of various sites.
So far I was successful in that process except for wikipedia. When I try
to access the feed url related to a particular topic, a wikipedia eror
page is displayed showing an access denied error. I dont know whether it
is the problem related to my code or whether I need any API to parse the
feeds. My code to parse the feed is:

http = Net::HTTP.start(uri.host, uri.port)
#making a request to the server
if uri.query != nil
response = http.get(uri.path+'?'+uri.query, 'User-Agent' =>
'Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 5.0; Windows XP)')
else
response = http.get(uri.path, 'User-Agent' => 'Mozilla/4.0
(compatible; MSIE 5.5; Windows NT 5.0; Windows XP)')
end

and this is the error :
Request: POST
http://www.wikipedia.com/w/index.php?title=Special:RecentChanges&feed=atom,
from 61.17.18.34 via sq16.wikimedia.org (squid/2.7.STABLE6) to ()
Error: ERR_ACCESS_DENIED, errno [No Error] at Tue, 28 Apr 2009 08:07:28
GMT

Can somebody please give me a suggestion.

Thanks
Arun
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,819
Latest member
masterdaster

Latest Threads

Top