MCPcopy Create free account
hub / github.com/gawel/pyquery / xpath_image_pseudo

Method xpath_image_pseudo

pyquery/cssselectpatch.py:300–311  ·  view source on GitHub ↗

Matches all image input elements:: >>> from pyquery import PyQuery >>> d = PyQuery(' ') >>> d('input:image') [ ] ..

(self, xpath)

Source from the content-addressed store, hash-verified

298 return xpath
299
300 def xpath_image_pseudo(self, xpath):
301 """Matches all image input elements::
302
303 >>> from pyquery import PyQuery
304 >>> d = PyQuery('<div><input type="image"/></div>')
305 >>> d('input:image')
306 [<input>]
307
308 ..
309 """
310 xpath.add_condition("@type = 'image' and name(.) = 'input'")
311 return xpath
312
313 def xpath_reset_pseudo(self, xpath):
314 """Matches all reset input elements::

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected