Customizing Oxygen XML Web Author Component Client Side
Client side customization is available through a JavaScript API. Unlike the server side customization, it can be used to modify the application's GUI.
The Oxygen XML Web Author Component is an editing platform, but it is the job of the integrator to provide a way for the user to select which file is going to be edited. Afterwards, the user should be redirected to the Oxygen XML Web Author Component editing page, and the following three URL parameters specified:
url
- An absolute URL of the edited file.ditamap
- (Optional parameter) An absolute URL taken into account only when editing a DITA file. Provides the DITA map context of the edited DITA file.author
- The author name.
Suppose that the Oxygen XML Web Author Component is deployed at the following URL:
http://www.example.com/oxygen-sdk-sample-webapp/
The user (John Doe) wants to edit a file (located at
http://www.test.com/topics/topic.xml
) in the context of a DITA map
(located at http://www.test.com/map.xml
). In this case, the editing URL
should
be:
http://www.example.com/oxygen-sdk-sample-webapp/app/oxygen.html ?url=http%3A%2F%2Fwww.test.com%2Ftopics%2Ftopic.xml &ditamap=http%3A%2F%2Fwww.test.com%2Fmap.xml &author=John%20Doe
Note
Customize Oxygen XML Web Author Component Using JavaScript Code
To extend the client-side functionality provided by Oxygen XML Web Author Component you can use the JavaScript API. To load the your JavaScript customization code, use one of the following methods:
- Create a file called
plugin.js
and copy it in theapp
folder of the Oxygen XML Web Author Component deployment. - Bundle JavaScript code with a Java Plugin.
- Bundle the JavaScript code with a framework. Save your code in the
framework.js
file (located in theweb
folder inside the particular framework folder).