Re: ACTION-1859: Clarify "encode as text" for replace="text"

Hi Steven

I couldn't figure out what you changed based on this message.

Spinning around for a bit, I think maybe you changed this section
http://www.w3.org/MarkUp/Forms/wiki/index.php?title=XForms_2.0#Replacing_Data_with_the_Submission_Response

I think you may have gotten rid of the spec fragment below that contained 
"encoded as text":

If the replace attribute contains the value "text" and the submission 
response conforms to an XML mediatype (as defined by the content type 
specifiers in [RFC 3023]) or a text media type (as defined by a content 
type specifier of text/*), then the response data is encoded as text and 
replaces the content of the replacement target node. 

And that you replaced it with something like this:
 
text: the response data is treated as text, regardless of its media type, 
and used to replace the content of the replacement target node using the 
XForms Action setvalue (The setvalue Element). 

Is this an accurate reflection of the change?

If so, I am not sure the replacement is clearer.  The term "encoded as 
text" is saying that the XML received in response will be encoded so that 
it can become the text content of a node.  In other words, characters like 
< and > will become &lt; and &gt;. 

"Treated as text" and "encoded as text" are not significantly different. 
Saying "using the XForms Action setvalue..." doesn't help because you 
already have to encode the value as text in order to invoke setvalue.

Perhaps it would be better to slightly amend your latter statement to 
replace "treated as text" with "encoded as character data" and then link 
to some definition of that in XML, such as 
http://www.w3.org/TR/REC-xml/#dt-chardata

What do you think?

Thanks,
John M. Boyer, Ph.D.
Distinguished Engineer, IBM Forms and Smarter Web Applications
IBM Canada Software Lab, Victoria
E-Mail: boyerj@ca.ibm.com 

Twitter: http://twitter.com/johnboyerphd
Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer
Blog RSS feed: 
http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw





From:   "Steven Pemberton" <Steven.Pemberton@cwi.nl>
To:     public-forms@w3.org
Date:   18/04/2012 03:26 AM
Subject:        ACTION-1859: Clarify "encode as text" for replace="text"



Done; involved some rewriting, but I think the result is clearer.

http://www.w3.org/MarkUp/Forms/wiki/index.php?title=XForms_2.0#The_xforms-submit_Event


Steven

Received on Wednesday, 18 April 2012 14:40:02 UTC