xml_child - Return child for current node.
xml_child(xml:string, [error:variable]);
This function return child of current node.
To use this module, you must specify the following in /usr/local/website/site.conf:
Module xml { Library : "/usr/local/lib/libsnxml.so" Init : "snxml_init" }
t = xml_traverse(cur_node.xml_child()); child = xml_child(xml); %include "/includes/xml.sn"; child = skip_text_node(child); The function skip_text_node is define in the include file: // // Description: Skip text node // // Input: xml node // // Output: xml node where type is not XML_TEXT_NODE // // Author: 2013-10-10 21:30:48 laplante@sednove.com // function skip_text_node(node) type = xml_type(node); while type == XML_TEXT_NODE do node = xml_next(node); type = xml_type(node); endw return node; endf
Written by Pierre Laplante, <laplante@sednove.com>
Cras sit amet nibh libero, in gravida nulla. Nulla vel metus scelerisque ante sollicitudin commodo. Cras purus odio, vestibulum in vulputate at, tempus viverra turpis.
1.0 2014-09-09 21:24:14 laplante@sednove.com