xml.DomDocument.load
Loads a XML Document into a DomDocument object from a file or an URL.
Syntax
load(
filename STRING )
- filename defines a valid URL or the name of the file.
Usage
This method loads a XML Document into a DomDocument
object from a file or an
URL, where filename is a valid URL or the name of the file.
Only the following types of URLs are supported: http:// , https:// , tcp:// , tcps:// , file:/// and alias://. See Web Services FGLPROFILE configuration for more details about URL mapping with aliases, and for proxy and security configuration.
Use setFeature()
to
specify how the document can be loaded. HTML parsing is possible when enable-html-compliancy is
enabled.
See getErrorsCount()
and getErrorDescription()
to retrieve error messages related to XML document.
In case of error, the method throws an exception and sets the
STATUS
variable. Depending on the error, a human-readable description of the
problem is available in the SQLCA.SQLERRM
register. See Error handling in GWS calls (STATUS).
CALL
doc.setFeature("enable-html-compliancy",TRUE)
, loading an HTML document with
xml.DomDocument.load()
may produce additional blank TEXT nodes, because the
libxml library loads some ignorable white-space nodes from the HTML document.
Starting with Mac OS X 10.9, the
libxml library of the system has fixed this bug.