使用 import.io,给出以下代码片段,在成功提取name
和time
列之后,如何.heading
使用 XPath 提取最近的前面元素作为第三列?
...
<div class="row-fluid">
<div class="heading">HBO</div>
</div>
<div class="row-fluid">
<div class="name">Silicon Valley</div>
<div class="time">9pm</div>
</div>
<div class="row-fluid">
<div class="name">The Wire</div>
<div class="time">10pm</div>
</div>
...
<hr>
<div class="row-fluid">
<div class="heading">ABC</div>
</div>
<div class="row-fluid">
<div class="name">Lost</div>
<div class="time">9pm</div>
</div>
<div class="row-fluid">
<div class="name">Heroes</div>
<div class="time">10pm</div>
</div>
...
<hr>
...