L
L
lavezzi12015-05-10 08:08:40
Ruby on Rails
lavezzi1, 2015-05-10 08:08:40

How to pull the content of an article from a link?

There is an application on RoR. It is necessary to arrange the pulling of the content of the article (Title, pictures, text, formatting, links). In contact, something very similar can be observed. When the content of the site page in VK opens in a new window. Please tell me what it's called, what queries to look for and if there is a ready-made solution for the rail of such a feature? thank!

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
Askhat Bikmetov, 2015-05-10
@askhat

ruby-toolbox.com/categories/Web_Content_Scrapers

C
caution, 2015-05-10
@caution

gem nokogiri
require 'nokogiri'
require 'open-uri'
# Fetch and parse HTML document
doc = Nokogiri::HTML(open(' www.nokogiri.org/tutorials/installing_nokogiri.html '))

V
vsuhachev, 2015-05-13
@vsuhachev

1) there are modal windows, for example, in bootstrap, jquery-ui and many more where 2) there is jquery-ujs
in rails by default, with which you can ajax call the page loading into the modal window, see below.link_to(..., remote: true)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question