Rechercher une page de manuel
hxselect
Langue: en
Version: 21 Nov 2008 (fedora - 01/12/10)
Section: 1 (Commandes utilisateur)
NAME
hxselect - extract elements that match a (CSS) selectorSYNOPSIS
hxselect [ -i ] [ -c ] [ -l language ] [ -s separator ] selectorDESCRIPTION
hxselect reads a well-formed XML document and outputs elements that match the CSS selector that is given as an argument. For examplehxselect ol li:first-child
selects the first li (list item in XHTML) in an ol (ordered list).
The command operates on the standard input.
Assumes that class selectors (".foo") refer to an attribute called "class".
Assumes that ID selectors ("#foo") refer to an attribute called "id".
OPTIONS
The following options are supported:- -i
- Match case-insensitively. Useful for HTML and some other SGML-based languages.
- -c
- Print content only. Without -c, the start and end tag of the matched element are printed as well; with -c only the contents of the matched element are printed.
- -l language
- Sets the default language, in case the root element doesn't have an xml:lang attribute (default: none). Example: -l en
- -s separator
- A string to print after each match (default: empty). Accepts C-like escapes. Example: -s aq\\n\\naq to print an empty line after each match.
- -?
- Show command usage.
OPERANDS
The following operand is supported:- selector
- A selector. Most selectors from CSS level 3 are supported, with the exception of pseudo-classes, pseudo-elements and selectors with last- in their name.
Contenus ©2006-2024 Benjamin Poulain
Design ©2006-2024 Maxime Vantorre