All threads / How to access a webpage and get its content

Ask A Question

Notifications

You’re not receiving notifications from this thread.

How to access a webpage and get its content

Kelvin Firmino asked in Rails

Hi, good afternoon.

Chirs, I would like to access a website and get its content from its page to create a database with this information.

It is about a game so, it is a common information that I would like to do website about in a better way. So, instead of copy by hand the content, I would like to do this in a more efeccienty way, accessing its multiple pages and catch the data that I need.

Do you know a way that I can do that?

Thanks in advance for your help.

Hey Kelvin,

I've never done it, but the keyword you're looking for is "web scraping"

Check out: https://www.google.com/search?q=web+scraping

Have a look at the Nokogiri gem

Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 39,376+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Ruby on Rails tutorials, guides, and screencasts for web developers learning Ruby, Rails, Javascript, Turbolinks, Stimulus.js, Vue.js, and more. Icons by Icons8

    © 2020 GoRails, LLC. All rights reserved.