RE: xpath questions...

2008-08-23 Thread bruce
tt =",t1[0].toString() sys.exit() thanks!! -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Fredrik Lundh Sent: Saturday, August 23, 2008 5:58 AM To: python-list@python.org Subject: Re: xpath questions... bruce wrote: > Regarding the xpath q

RE: xpath questions...

2008-08-23 Thread bruce
parent::*/attribute::href" q="//[EMAIL PROTECTED]'cos_search1']/@action" t1=d.xpath(q) print "href = ",t1 print "hnode =",t1[0].nodeValue print "htest =",t1[0].textContent print "htesttt =",

Re: xpath questions...

2008-08-23 Thread Fredrik Lundh
bruce wrote: Regarding the xpath question I've posed, some have said that it shouldn't be here on the mailing list. Give that I'm writing the test scripts/apps in python, using the python libs, where else should it be posted? I mean, I could post the entire sample script so you can see that it'

RE: xpath questions...

2008-08-23 Thread bruce
n see that it's using python, but I simplified the issue. So, please tell me, just where should the question be posted? Thanks -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Fredrik Lundh Sent: Saturday, August 23, 2008 4:44 AM To: python-list@python.or

Re: xpath questions...

2008-08-23 Thread Stefan Behnel
Hi, this is totally not Python related, so this is the wrong list. bruce wrote: > form action='foo' name='cat' > > i'm curious, is there a way to select an attribute, only if another > attribute in the element is set to a given value?? > > something like > //form/[EMAIL PROTECTED]'foo'[EMAI

Re: xpath questions...

2008-08-23 Thread Fredrik Lundh
bruce wrote: playing around with xpath and the html dom... are you sure this question belongs on a Python forum? -- http://mail.python.org/mailman/listinfo/python-list