Re: HTMLDocument and Xpath

2006-02-07 Thread swilson
Got the answer - there's a bug in xpath. I think the HTML parser converts all the tags (but not the attributes) to uppercase. Xpath definitely does not like my first string but, these work fine: test = Evaluate('//TD', doc_node.documentElement) test = Evaluate('/HTML/BODY/TABLE/TR/TD',

Re: HTMLDocument and Xpath

2006-02-03 Thread Alan Kennedy
[EMAIL PROTECTED] Hi, I want to use xpath to scrape info from a website using pyXML but I keep getting no results. For example, in the following, I want to return the text Element1 I can't get xpath to return anything at all. What's wrong with this code? Your xpath expression is wrong.

Re: HTMLDocument and Xpath

2006-02-03 Thread swilson
Alan Kennedy wrote: [EMAIL PROTECTED] Hi, I want to use xpath to scrape info from a website using pyXML but I keep getting no results. For example, in the following, I want to return the text Element1 I can't get xpath to return anything at all. What's wrong with this code? Your

HTMLDocument and Xpath

2006-02-02 Thread swilson
Hi, I want to use xpath to scrape info from a website using pyXML but I keep getting no results. For example, in the following, I want to return the text Element1 I can't get xpath to return anything at all. What's wrong with this code? from xml.dom.ext.reader import