function forena_inner_xml in Forena Reports 6
Same name and namespace in other branches
- 6.2 forena.common.inc \forena_inner_xml()
- 7.5 forena.common.inc \forena_inner_xml()
- 7 forena.common.inc \forena_inner_xml()
- 7.2 forena.common.inc \forena_inner_xml()
- 7.3 forena.common.inc \forena_inner_xml()
- 7.4 forena.common.inc \forena_inner_xml()
Enter description here...
Parameters
simplexml $xml:
string $tag:
Return value
string
1 call to forena_inner_xml()
- forena_data_block_add in ./
forena.admin.inc - submit handler for forena_data_block_form. This adds the datablock to an existing report.
File
- ./
forena.common.inc, line 416 - Common functions used throughout the project but loaded in this file to keep the module file lean.
Code
function forena_inner_xml($xml, $tag) {
if (is_object($xml) && is_object($xml->{$tag})) {
$xml_data = $xml->{$tag}
->asXML();
$xml_data = preg_replace("/<\\/?" . $tag . "(.|\\s)*?>/", "", $xml_data);
}
return $xml_data;
}