mirror of
https://github.com/moparisthebest/xeps
synced 2025-02-07 02:40:22 -05:00
example 3 should have type=error. also use message ids.
git-svn-id: file:///home/ksmith/gitmigration/svn/xmpp/trunk@2309 4b5297f7-1745-476d-ba37-a9c6900126ab
This commit is contained in:
parent
2bca22090a
commit
6747f54710
@ -49,7 +49,7 @@
|
||||
<p>The definition of XMPP stanzas in &xmppcore; and &xmppim; allows a &MESSAGE; stanza to include any number of child elements that define extended content. The fact that a message stanza may contain multiple instances of extended content can make it difficult for sending entities to know what is appropriate for inclusion in a message stanza and for receiving entities to know exactly how to process a message stanza.</p>
|
||||
<p>Consider the following hypothetical example:</p>
|
||||
<example caption='A confusing message'><![CDATA[
|
||||
<message from='romeo@montague.lit' to='juliet@capulet.com'>
|
||||
<message from='romeo@montague.lit' to='juliet@capulet.com' id='msg_1'>
|
||||
<body>Shall we meet?</body
|
||||
<html xmlns='http://jabber.org/protocol/xhtml-im'>
|
||||
<body xmlns='http://www.w3.org/1999/xhtml'>
|
||||
@ -105,7 +105,7 @@
|
||||
<p>Elements used in a message stanza are either profile elements (for example, <body> or <data xmlns='http://jabber.org/protocol/ibb'>) or metadata elements (for example, <error> or <amp xmlns='http://jabber.org/protocol/amp'>). A message stanza SHOULD only contain profile elements that are part of the same profile. A message stanza MAY contain as many metadata elements as desired.</p>
|
||||
<p>A sender MAY mix elements of different profiles only for the purposes of fallback. For example, it may be useful to include a <body> element in a message that is not intended to be displayed as a text message, in case the recipient does not support the primary profile of the message.</p>
|
||||
<example caption='Mixing profile elements'><![CDATA[
|
||||
<message from='romeo@montague.lit' to='juliet@capulet.com'>
|
||||
<message from='romeo@montague.lit' to='juliet@capulet.com' id='msg_1'>
|
||||
<body>If you read this message then you don't support IBB.</body
|
||||
<data xmlns='http://jabber.org/protocol/ibb' sid='ft_session_2' seq='84'>
|
||||
qANQR1DBwU4DX7jmYZnncmUQB/9KuKBddzQH+tZ1ZywKK0yHKnq57kWq+RFtQdCJ
|
||||
@ -129,7 +129,7 @@
|
||||
</ol>
|
||||
<p>If a message stanza is received that combines multiple profiles, or the profile cannot be determined, the receiving client MAY return a stanza error, which SHOULD be ¬acceptable;.</p>
|
||||
<example caption='Message not acceptable'><![CDATA[
|
||||
<message from='juliet@capulet.com' to='romeo@montague.lit'>
|
||||
<message from='juliet@capulet.com' to='romeo@montague.lit' type='error' id='msg_1'>
|
||||
<error code='406' type='cancel'>
|
||||
<not-acceptable xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
|
||||
</error>
|
||||
|
Loading…
Reference in New Issue
Block a user