Mr. XML Publisher's user interface is implemented with HTML generated from JSP pages, JavaScript, a few small plain HTML pages, and Java applets. The interface components depend on each other and communicate according to details of the specifications for HTML, JavaScript, and LiveConnect.[4]
JSP
Nearly all visual elements in the user interface are created by HTML generated from a JSP file named "entry.jsp." The entry.jsp file is the main entry point to Mr. XML Publisher and is defined as such in the default Mr. XML Publisher web.xml file in a <welcome-file> element value. Mr. XML Publisher uses a few additional JSP files to handle server messages and error conditions. JSP files are discussed in JSP.
JavaScript
The HTML generated from entry.jsp includes a small amount of embedded JavaScript, but most of the JavaScript it uses is imported in the generated HTML's <head> tag via a <script> element. The imported JavaScript file is named XMLP.js. Each function and each variable contained in XMLP.js is described in JavaScript.
Plain HTML Files
Several plain HTML files are used to present popups, forms, instructions, etc. Each is described in Plain HTML Files.
Java Applets
Mr. XML Publisher uses four Java applets. Three of them are DocBook XSL Configurator applets used to create XSL customization layers. The remaining applet is named "XMLP_JavaUtils." It provides a wide variety of services, such as creating zipped project archives and XML parsing. Applets are discussed in Java Applets.
Supported browsers include:
FireFox
2.0.x
3.0.x
3.1b2
Internet Explorer
6
7
8 Beta
Additional supported browsers include any using version 1.8.1, 1.9, or 1.9.1 of the Mozilla Corporation's Gecko layout engine. Such browsers include Netscape 9.0, SeaMonkey 1.1, SeaMonkey 2.0, and many others. Through user interface customizations, Mr. XML Publisher can be made to work with virtually any browser.
Some user interface elements are optional. For example, you may have no need to provide output archives compressed as tar+gzip. Thus, the option to choose a compression type for returned archives can be removed. The default is "ZIP."
Another example, you may not need the Create Customization Layer button. That would be the case if you wanted to discourage users from writing their own XSL customization layers. Depending on the currently selected style, the Create Customization Layer button activates an appropriate DocBook XSL Configurator applet. You would still have the option of allowing the formatting of uploaded XML according to the rules specified in uploaded XSL. You could also still use DocBook XSL Configurator to create customization layers by installing it locally in application form. And, you could still use customization layers not part of a user's project by specifying the use of customization layers in XSLT processor commands within <context-param> element command arrays.
All default user interface elements and their actions are customizable, but not all are optional. The various user interface elements depend on triggers, variables, and method calls. Thus, barring customizations nearing a complete re-write of the default user interface, the following user interface elements are required:
The drop-down menu providing format choices
Formatting choices provided to your users are defined in command arrays inside <context-param> elements in the Mr. XML Publisher web.xml file. Mr. XML Publisher automatically generates the list of choices in the drop-down menu from the command arrays. For a brief discussion of command arrays, see Command Arrays: Special web.xml <context-param> Elements. For a more extensive discussion of command arrays, see COMMAND Arrays .
The Select Project XML File button
The Select Project XML File button activates the XMLP_JavaUtils applet, which presents a navigation dialog used to select an XML project's main XML file. The XML file selected must contain the project's XML root element and may use XInclude elements and external entities to include additional XML. The XMLP_JavaUtils applet parses the project's XML and any XSL, looking for error conditions and possible security threats. It then creates a zipped project archive of everything in the parent directory of the selected XML file. The user uploads the zipped archive.
The XMLP_JavaUtils applet performs a few security checks on XInclude elements and external entities. In some cases it prevents the upload of a project. The XMLP_JavaUtils applet's security checks are the first line of defense against security violations, but you should consider them as just a convenience. Protection for your server should depend mostly on the server's own security mechanisms. For a discussion of the Select Project XML File button, see Buttons. For a discussion of security with Mr. XML Publisher, see Security.
The Browse button
The Browse button activates an HTML-generated file navigation dialog used to select the zipped project archive created by the XMLP_JavaUtils applet. HTML security restrictions prevent combining the functions of the Select Project XML File button with those of the Browse button. Users must manually select the zipped project archive created by the XMLP_JavaUtils applet.
The Upload and Format button
The Upload and Format button initiates an upload of the selected zipped project archive, preceded by several checks performed by JavaScript contained in the XMLP.js file. For a discussion of the Upload and Format button and the checks performed before the project archive is uploaded, see Buttons.
[4] LiveConnect is an API used to provide JavaScript communication with Java and vice-versa. More information on LiveConnect is at: http://developer.mozilla.org/En/Core_JavaScript_1.5_Guide:LiveConnect_Overview and https://jdk6.dev.java.net/plugin2/liveconnect/.