Cannot find text by xpath (scrapy)
<p>I try to use xpath to get the date from the example listed below. </p>

<pre><code>&lt;node&gt;
    &lt;table&gt;
        &lt;td&gt;
            &lt;font style="font-size:14px"&gt;http://www.aaa.com&lt;/font&gt;

             &amp;nbsp;&amp;nbsp;2016-10-11 17:14:11

        &lt;/td&gt;
    &lt;/table&gt;
&lt;/node&gt;
</code></pre>

<p>I used code looks like: </p>

<pre><code>response.xpath('/node/table/td/text()[2]').extract()
</code></pre>

<p>However it does not work. I expect it will return u'[&nbsp;&nbsp;2016-10-11 17:14:11], but it return []. Can anyone help me?</p>

<p>you can try following xpath</p>

<pre><code>response.xpath('/node/table/td/font/following-sibling::text()[1]').extract()
</code></pre>

python html xpath scrapy