Adds an HTML button under a node.
The Add button extraction rule adds an HTML button, that is to say an image element (IMG tag) associated with a link (A tag), in the XHTML content clipped by a Web Clipper extraction rule.
It is part of the set of Web Clipping extraction rules adding content into the XHTML content of a previously executed Web Clipper extraction rule, such as:
• Add link,
• Add text,
• Add image.
Such extraction rules change the XHTML content resulting from the execution of a Web Clipper extraction rule, by adding specific XHTML content based on defined parameters.
Notes:
• The XPath property set for such extraction rules must be valid in the XHTML output resulting from the Web Clipper extraction rule and possibly modified by previous rules.
• If a list of nodes are matching the defined Xpath, the Add button extraction rule will only add one button under the first matching node.
Property | Type | Category | Description |
---|---|---|---|
Comment | String | configuration | Describes the object comment to include in the documentation report. This property generally contains an explanation about the object. |
Href | JS expression | configuration | Defines the content of the href attribute. The href attribute allows to define the link destination, i.e. which web page this link will reach. |
Image URL | String | configuration | Defines the button image URL. The image URL can be either absolute or relative to the project. |
Is active | boolean | configuration | Defines whether the extraction rule is active. |
Target new window | boolean | configuration | Defines whether the link should open in a new window. If set to true, sets the tag target attribute to target="_blank". |
Text | String | configuration | Defines the text content to add. Depending on the extraction rule, it is: • the added text, for Add text rule, • the link displayed text, for Add link rule, • the added image label and alternative text, for Add image and Add button rules. |
XPath | String | selection | Defines the Xpath expression of nodes on which the extraction rule applies. Depending on the extraction rule, the execution of this Xpath on the web page DOM can result in a single Node or a NodeList. |