Latest Inquiries - Data Extraction Software

Oddsportal javascript extract

Submitted: 8/31/2018
Hello,


I am trying to scrape some data from oddsportal.com but the site using javascript is very complex.
For example at this webpage:

http://www.oddsportal.com/soccer/belgium/jupiler-league/genk-waasland-beveren-SEYWRCU3/

Almost every tab "1x2" , "O/U", "Both teams to score" has 3 sub-tabs above them: "full time" , "1st half" , "2nd half"
After very research i tried to navigate through the tabs and its sub-tabs.

1.  However using xpath command "//DIV[@id='bettype-tabs-scope']/UL[2]/LI//SPAN[.='2nd Half']" for navigation, sometimes UL[2] uses a different number inside the brackets. ie UL[3] or UL[1]. so the script doesn't work always. is there any solution?

2.  In O/U tab, for every 3 of its sub-tabs, "full time", 1st half", "2nd half", there are a lot of other data in different categories:  Over/Under 1.5
Over/Under 2.5
Over/Under 3.5   etc
How can i navigate- "click"  at these categories in order to rip some data?

thank you.
oddsportal_java.rip

Replied: 9/6/2018 10:31:59 AM

Hi,

For your first question, The sequence of UL determines which is the first tab table load. For example, you will say that the 3 subtabs (FullTime, 1st Half, 2nd half) of "1x2" should be the UL[1], this is because they are the first one that loads. If you load this, http://www.oddsportal.com/soccer/belgium/jupiler-league/kortrijk-genk-rkV7TP58/#over-under;2 you will notice that it is also a UL[1] and if you click the 1x2, the subtabs of 1x2 become UL[2] and whatever tab you click again, it became the UL[3] and so on. And you have to coordinate your action. 

For your second question, you just need to create a list template and you may use this XPath: //div[@id="odds-data-table"]/div[contains(@class, "table-container")]/div[1]/strong/a

Best regards,

Replied: 9/6/2018 1:35:01 AM
I want to capture "Match name", "date", "score", average odds from O/U tab separate for every "full time" , "1st half" , "2nd half" for the following sections:

Over/Under 1.5
Over/Under 2.5
Over/Under 3.5

All these data needs to be columns in excel file.

The templates of the project attaches are correct. The problem is at the navigation of the O/U tab, how to open the categories
Over/Under 1.5
Over/Under 2.5
Over/Under 3.5

using javascript in order to rip the data displayed.
Replied: 9/3/2018 8:23:48 AM

Hi,

What data you want to capture and how you want it to display in excel? If you can give screenshots or sample excel file on how you want to see the output data, that would be helpful.

Best regards,