11.3.1 Alternative Format Import Part

11.3.1 Alternative Format Import Part

Content Type:

Any text-based content, support for which is application-defined. [Note: Some examples of formats which might be supported include:

Text = text/plain HTML = text/html WordprocessingML = application/vnd.openxmlformats-officedocument.wordprocessingml.document XHTML = application/xhtml+xml

end note]

Root Namespace:

not applicable

Source Relationship:

http://purl.oclc.org/ooxml/officeDocument/relationships/aFChunk

An alternative format import part allows content specified in an alternate format specified above to be embedded directly in a WordprocessingML document in order to allow that content to be migrated to the WordprocessingML format.

Any document part that permits a p element can also contain an altChunk element, whose id attribute refers to a relationship. That relationship shall target a part within the package, which contains the content to be imported into this WordprocessingML document.

A package is permitted to contain zero or more Alternative Format Import parts, each of which shall have a corresponding alternate format file that is the target of an explicit relationship from a Comments (11.3.2), Endnotes (11.3.4), Footer (11.3.6), Footnotes (11.3.7), Header (11.3.9), or Main Document (11.3.10) part. This relationship shall be explicitly referenced using its relationship ID in the source part using the appropriate XML syntax (i.e.; in the id attribute on the altChunk element), and the presence of this relationship without such a reference shall be considered non-conformant.

ISO/IEC 29500 does not specify how one might create a WordprocessingML package that contains Alternative Format Import relationships and altChunk elements.

The following requirements are applied to applications with respect to this part:

  • An application that is solely a conforming consumer shall not reject documents containing one or more
  • instances of this part
  • An application that is both a conforming consumer and producer shall not reject documents containing
  • instances of this part and shall convert/remove any instances of this part before acting as producer.
  • An application that is solely a conforming producer shall not create a WordprocessingML package that
  • contains Alternative Format Import relationships and elements.

[Note: The Alternative Format Import machinery provides a one-time conversion facility. A producer could have an extension that allows it to generate a package containing these relationships and elements, yet when run in conforming mode, does not do so. end note]

[Example: The following Main Document part-relationship item contains a relationship to an Alternative Format Import part:

<Relationships xmlns="…">
  <Relationship Id="rId5"
    Type="http://…/aFChunk" Target="Demo.html"
    TargetMode="Internal"/>
</Relationships>

The Main Document part contains the following XML fragment:

<w:body>
  <w:p/>
  <w:altChunk r:id="rId5"/>
  <w:p/>
</w:body>

which results in the entire contents of Demo.html being converted and brought into the document at that point (assuming that the content type of Demo.html is supported by the application consuming this WordprocessingML file). end example]

An Alternative Format Import part shall be located within the package containing the relationships part (expressed syntactically, the TargetMode attribute of the Relationship element shall be Internal).

An Alternative Format Import part shall not have any explicit or implicit relationships to parts defined by ISO/IEC 29500.

A producer that wants interoperability should use one of the following standard formats:

  • HTML - application/text/html
  • TEXT - application/text/plain (UTF-16)
Last updated on