小编Zah*_*Hnn的帖子

<div> 中的 <div> 标签使用 importXML Xpath 查询,在 Google 电子表格中

我在 Google 文档中使用 Xpath 来获取里面的文本<div>。我想将其中的文本保存在<div id="job_description">Google 文档电子表格的一个单元格中,但每个<div>单元格都显示在单独的单元格中。

<div id="job_description">
    <div>
        <strong>
            Basic Purpose:
        </strong>
        <br></br>
    </div>
    <div>
        Work closely with developers, product owners and Q…
        <br></br>
    </div>
    <div>
        The Test Analyst is accountable for the developmen…
        <br></br>
    </div>
    <div>
        <strong>
            Duties and Responsibilities:
        </strong>
    </div>
    <ul>
        <li></li>
        <li></li>
    </ul>
    <div>
        <strong>
            Requirements:
        </strong>
        <br></br>
    </div>
    <ul>
        <li></li>
        <li></li>
    </ul>
</div>
Run Code Online (Sandbox Code Playgroud)

图片:http : //i.stack.imgur.com/K0mAY.png

这是我写的代码:

=IMPORTXML(E4,"//div[@id='job_description']")
Run Code Online (Sandbox Code Playgroud)

你能帮我把所有的文本(包括<div> <ul>......)放在<div id="job_description">一个单元格中吗?

html xpath spreadsheet google-docs

0
推荐指数
1
解决办法
2万
查看次数

标签 统计

google-docs ×1

html ×1

spreadsheet ×1

xpath ×1