导入到 Google 个工作表 firts/second/third 在网站上出现 class

Importing to Google Sheets firts/second/third occurrence of class on website

我想使用本网站的数据导入 Google Sheet 分开的关注者数量,post 和 ER 用于 Instagram 帐户:https://igstats.net/report/jenniferanistononline/instagram(此帐户仅作为示例)。

包含这些数据的代码片段:

<div class="col-md-12 col-lg-4 d-flex justify-content-around align-items-center mt-4 mt-lg-0 pl-sm-0">
    <div class="col d-flex flex-column justify-content-center">
        Followers <p class="report-header-number">4,319</p>
    </div>
    <div class="col d-flex flex-column justify-content-center">
        Uploads <p class="report-header-number">93</p>
    </div>
    <div class="col d-flex flex-column justify-content-center">
        Engagement <p class="report-header-number">3.78%</p>
    </div>
</div>

我希望收到公式的 xpath,这将为我提供所有指标的分离结果。

有人可以帮我吗?

以下公式对我有用(截至 2019 年 10 月 22 日):

  • 关注者

    =IMPORTXML("https://igstats.net/report/jenniferanistononline/instagram", "/html/body/div/div[1]/div[3]/div[1]/p")
    
  • 上传

    =IMPORTXML("https://igstats.net/report/jenniferanistononline/instagram", "/html/body/div/div[1]/div[3]/div[2]/p")
    
  • EM

    =IMPORTXML("https://igstats.net/report/jenniferanistononline/instagram", "/html/body/div/div[1]/div[3]/div[3]/p")