KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Line breaks in XML
PRODUCT: 4D | VERSION: 2004 | PLATFORM: Mac & Win
Published On: June 20, 2007
Your current browser may not allow you to download the asset. We recommend Mozilla Firefox or Google Chrome.
Log In

When 4D parses XML files all carriage returns and carriage return+line feed combinations are treated as single line feeds. This is part of the XML specification:

XML parsed entities are often stored in computer files which, for editing convenience, are organized into lines. These lines are typically separated by some combination of the characters CARRIAGE RETURN (#xD) and LINE FEED (#xA).


To simplify the tasks of applications, the XML processor MUST behave as if it normalized all line breaks in external parsed entities (including the document entity) on input, before parsing, by translating both the two-character sequence #xD #xA and any #xD that is not followed by #xA to a single #xA character.


From here.