An administrator must specify in the repository that .svg file extensions are XML documents in order to support importing SVG files as structured documents.
An .svg file that references another image file must be imported as a structured document in order to correctly include the referenced image file.
- On the primary ACS server, run in a command shell:
cd %LSPEED_HOME%\iEngine\python
CALL jython.bat setXMLDocumentExtensions.py
The system response appears:
=======================================================================
== Set XML Document Extensions:
========================================================================
This setting defines the list of file extensions for XML documents
It is a comma-separated list of file extensions (without the period)
The old XML document extensions are "xml,ditamap,dita".
Enter new value (or press ENTER for no change):
Note: Configuration setting is stored in the database, so you only need to run the command on the primary ACS server.
- Enter the new value by copying the old value and adding ,svg
For example:
xml,ditamap,dita,svg
The system response appears:
New "XML Document Extensions" is: "xml,ditamap,dita,svg"
- To verify the change:
- Using the command, import a DITA document that references an .svg file that references an image file, such as a .png.
The referenced .svg and .png files are both imported automatically as references.
- Select the .svg file in the Workbench.
The status bar (bottom left of the Workbench) displays:
<filename>.svg [Structured Document, ...]
- Open the imported DITA file to edit.
The .svg and .png files are displayed in the editor.
- Compose the imported DITA topic (or a map referencing the DITA topic).
In the composed output, both the .svg and .png files are included correctly.