How do i web scrape aliexpress from rails (console) or app

56 views
Skip to first unread message

fugee ohu

unread,
Jul 27, 2018, 7:15:37 PM7/27/18
to Ruby on Rails: Talk
how do i webscrape aliexpress? i learned how to get a document object class Nokogiri::HTML containing the full html but there's no tables only ul and li selectors and i'm having trouble with that

Colin Law

unread,
Jul 28, 2018, 2:53:59 AM7/28/18
to Ruby on Rails: Talk
On 28 July 2018 at 00:15, fugee ohu <fuge...@gmail.com> wrote:
how do i webscrape aliexpress? i learned how to get a document object class Nokogiri::HTML containing the full html but there's no tables only ul and li selectors and i'm having trouble with that

Give us an example of a page you are scraping and an element you can't find.

Colin

Message has been deleted

fugee ohu

unread,
Jul 28, 2018, 10:36:56 AM7/28/18
to Ruby on Rails: Talk

Colin Law

unread,
Jul 28, 2018, 10:43:37 AM7/28/18
to Ruby on Rails: Talk
On 28 July 2018 at 15:32, fugee ohu <fuge...@gmail.com> wrote:


On Saturday, July 28, 2018 at 2:53:59 AM UTC-4, Colin Law wrote:
Thanks Colin Made progress so now I have the <ul> list i want in an object I named ul Not sure how I'm gonna proceed My goal is to import to database tables  It's a few related tables instead of just one products table I don't think you still wanna see all that html do you?

If you are now seeing the data then no I don't want to see it.  Your original problem is fixed.

Colin

fugee ohu

unread,
Jul 28, 2018, 10:43:24 PM7/28/18
to Ruby on Rails: Talk
I could read the item description on the page in the browser but couldn't find it searching the source I'm new to using the browser debugging console I never had any reason to use it before So I couldn't find the description I saw on the page in the source so I right clicked on the description and selected inspect This is what I got: 
<li class="property-item" id="product-prop-19204" data-attr="272" data-title="Wireless" data-spm-anchor-id="2114.12010108.0.i4.7c48412aEPVyt2">
                        <span class="propery-title">Cord Length (m):</span>
                        <span class="propery-des" title="Wireless">Wireless</span>
                    </li>
What can I do with this?

Colin Law

unread,
Jul 29, 2018, 4:14:03 AM7/29/18
to Ruby on Rails: Talk
If you can see the description in the browser but not in the source then as a web developer I am sure you can think of at least a couple of ways that might happen.

Colin

Reply all
Reply to author
Forward
Message has been deleted
Message has been deleted
0 new messages