xml_content - Read the value of a node, this can be either the text carried directly by this node if it’s a TEXT node or the aggregate string of the values carried by this node child’s (TEXT and ENTITY_REF). Entity references are substituted.
xml_content(xml:string, [error:variable]);
Read the value of a node, this can be either the text carried directly by this node if it’s a TEXT node or the aggregate string of the values carried by this node child’s (TEXT and ENTITY_REF). Entity references are substituted.
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"
}
res=<{
xml=xml_new(error:t,file:"/html/test.xml");
%include "/includes/xml.sn";
xml_content(xml);
xml_free(xml);
}>. return res=
laplante
bilodeau
.
the file test.xml:
laplante
bilodeau
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