= Using XPath in Markup = Markup provides basic [http://www.w3.org/TR/xpath XPath] support for matching and querying event streams. == Limitations == Due to the streaming nature of the processing model, Markup uses only a subset of the [http://www.w3.org/TR/xpath XPath 1.0] language. In particular, only the following axes are supported: * `attribute` * `child` * `descendant` * `descendant-or-self` * `namespace` (not completed yet) * `self` In addition, Markup does not (yet) support numeric types in XPath: everything is treated as text or booleans. For that reason, [http://www.w3.org/TR/xpath#NT-RelationalExpr relational] or [http://www.w3.org/TR/xpath#NT-AdditiveExpr additive] operators such as `>`, `<`, or `<=`. == Querying Streams == {{{ #!python from markup.input import XML doc = XML(''' Foo Bar ''') print doc.select('items/item[@status="closed"]/summary/text()') }}} This would result in the following output: {{{ #!xml Bar }}} == Matching in Templates == See MarkupTemplates#py:match ---- See also: MarkupGuide, MarkupStream