On 29 May 2015 at 18:44, [email protected] <[email protected]> wrote: > I would like to fetch some database info. I have to construct a url with > arguments, send it then parse the returned XML. > > I quick example would be nice, but if someone could point out how to do the > following tasks, I could probable figure it out. > > 1) Performng a http 'fetch'
Is this to run as a background task or from the command line or from a user request to a rails app? > > 2) Parking XML. There must me a library or gem for this... I assume you mean parsing :) Have a look at nokigiri. In fact I believe that will fetch it from a url for you. The answer to question 1 is still important as it is not advisable to run code fetching from a url in a request from a user. No doubt when you googled for ruby xml parsers you found others, they may well be perfectly acceptable but I have not tried any of them. Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAL%3D0gLuLcEfQKdKq3GHpH%3DJGcim%3DoBBzd2Chr0xyDqk1cU7%2BJg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.

