> XML is designed to be used in practically any environment. In some
> environments, whitespace has significance. In others, it doesn't.
Should a
> haiku be written on one line?

I'm not necessarily saying you're wrong, but show me one example where
the white space between tags of an xml document would be as significant
as any brother node and would need to be used by an application.  I
mean, XML presents data in the form of nested tags which contain
appropriately escaped data in their attributes and optionally in the
contents of each tag.  

Given the following examples:

<root><book title="test"><author name="bob" /></book></root>

<root>
        <book title="test">
                <author name="bob" />
        </book>
</root>

Have I changed the actual data being transferred one iota?  Give me a
SINGLE example of an application which should act differently based on
the second xml string as opposed to the first.  Maybe that example
exists, and I am more than willing to accept it, but I haven't seen it
yet.

By your own omission, if Mozilla is properly parsing XML, then
ColdFusion's xml parser itself does not properly handle XML.  If I were
to parse both of those strings above they would result in the same XML
object.  
If I were to cfdump the second object there would be no references at
all to the "significant" white space.  If I were to iterate over the
child nodes of the "book" tag there would be ONE child and that makes
perfect sense.  (NOTE: if you were to tostring the documents, CF
remembers the white space, but I will point out that the interaction and
behavior of the object is changed in no way that I can tell.)

As far as a haiku, your statement is true, but I don't believe there is
any corollary from that which can be applied to XML.  You have simply
provided an example of a string of text which includes line breaks as
significant data.  That example does prove or disprove the significance
of white space in another type of string.  

Anyway, I know I am arguing against a brick wall, since the standard for
XML is already defined, but I guess my main points are:
1) I would love to see a real-life example which proves this theory of
significant white space between xml tags.
2) If Mozilla is right, then is ColdFusion wrong?  

~Brad

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
ColdFusion MX7 by AdobeĀ®
Dyncamically transform webcontent into Adobe PDF with new ColdFusion MX7. 
Free Trial. http://www.adobe.com/products/coldfusion?sdid=RVJV

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:281289
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to