[lxml-dev] lxml cssselect
Ted Dziuba
ted at milo.com
Tue Jul 14 22:16:02 CEST 2009
I don't think that's a valid CSS selector. Try xpath:
root.xpath("//input[@type = 'image']")
ted
On Tue, Jul 14, 2009 at 1:11 PM, Mary Lei <lei at ipac.caltech.edu> wrote:
> Can I use cssselect to select a set of input tags
> with image
>
> <input name="etsstop" value="1" src="nph-bgExec_files/top.png"
> type="image">
>
> for img in root.cssselect('input'):
> ...
>
>
> works fine but
> for img in root.cssselect('input type="image"'):
> ...
> sends lxml spinnning.
>
> --
> Mary Lei
>
> Software Testing
> IPAC-NExScl
>
> Rm: KS-233
> MS: 220-6
> Phone: 395-1998
>
> _______________________________________________
> lxml-dev mailing list
> lxml-dev at codespeak.net
> http://codespeak.net/mailman/listinfo/lxml-dev
>
--
Ted Dziuba
Co-Founder and Engineer
Milo.com, Inc.
165 University Avenue
Palo Alto, CA, 94301
http://milo.com
Cell: (609)-665-2639
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://codespeak.net/pipermail/lxml-dev/attachments/20090714/9b9e3c43/attachment.htm
More information about the lxml-dev
mailing list