function wsclient_tester_prettify_xml in Web service client 7
Indent and format XML for display.
1 call to wsclient_tester_prettify_xml()
- wsclient_tester_prepare_request_callback in wsclient_tester/
wsclient_tester.inc - Callback for the test from 'prepare' button.
File
- wsclient_tester/
wsclient_tester.inc, line 175 - Utility functions for running the tester UI for web services.
Code
function wsclient_tester_prettify_xml($xml) {
$dom = new DOMDocument();
$dom->preserveWhiteSpace = FALSE;
$dom
->loadXML($xml);
$dom->formatOutput = TRUE;
return $dom
->saveXml();
}