CHAPTER 8 SIMPLE API FOR XML (SAX)
CHAPTER 8 SIMPLE API FOR XML (SAX) 273 Setting the Parser Options After you have created the parser, you can set the parser options. These options differ from those discussed in Chapter 5, which are used by the DOM and SimpleXML extensions. The xml extension defines only four options that can be used while parsing an XML document. Table 8-1 describes the available options, as well as their default values when not specified for the parser. Table 8-1. Parser Options Option Description XML_OPTION_TARGET_ENCODING Sets the encoding to use when the parser passes the xml information to the function handlers. The available encodings are US-ASCII, ISO-8859-1, and UTF-8, with the default being either the encoding set when the parser was created or UTF-8 when not specified. XML_OPTION_SKIP_WHITE Skips values that are entirely ignorable whitespaces. These values will not be passed to your function handlers. The default value is 0, which means pass whitespace to the functions. XML_OPTION_SKIP_TAGSTART Skips a certain number of characters from the beginning of a start tag. The default value is 0 to not skip any characters. XML_OPTION_CASE_FOLDING Determines whether element tag names are passed as all uppercase or left as is. The default value is 1 to use uppercase for all tag names. The default setting tends to be a bit controversial. XML is case-sensitive, and the default setting is to case fold characters. For
Note: If you are looking for good and high quality web space to host and run your application check Lunarwebhost Cheap Web Hosting services