Web Author loading/caching issue
Posted: Wed May 06, 2020 6:17 pm
Hello,
We are using Web Author 22.0 inside a client's firewall. We have been able to successfully load XML files into the editor using the following setup:
However, if the user then refreshes the page, the document loads OK, so it also appears to be related to the browser cache.
In the browser debugger, this error does not show until we call window.editor.load(editorOptions), which looks something like this:
We are using a dummy URL because we are not resolving any references and the XML is stored in a relational database.
We hope you can help shed some light as to what's going on. Thank you!
We are using Web Author 22.0 inside a client's firewall. We have been able to successfully load XML files into the editor using the following setup:
- embed Web Author inside iFrame with url parameter pointing to a dummy document
- in plugin.js, stop loading dummy document with event.preventDefault() in BEFORE_EDITOR_LOADED
- send message to parent window that editor is ready in BEFORE_EDITOR_LOADED
- send editorOptions object via postMessage() to iFrame that contains dummy url and XML to be loaded
Code: Select all
TypeError: Cannot read property 'substring' of undefined
at sync.support.AuthorEditingSupport.load (workspace-bf5835e8c0.js:3449)
at sync.Editor.init (workspace-bf5835e8c0.js:3793)
at sync.Editor.<anonymous> (workspace-bf5835e8c0.js:3787)
at d.onFulfilled (workspace-bf5835e8c0.js:737)
at Function.goog.Promise.invokeCallback_ (workspace-bf5835e8c0.js:745)
at goog.Promise.executeCallback_ (workspace-bf5835e8c0.js:744)
at goog.Promise.executeCallbacks_ (workspace-bf5835e8c0.js:743)
at goog.async.run.processWorkQueue (workspace-bf5835e8c0.js:723) "Message: Cannot read property 'substring' of undefined<br>Url: <a href="view-source:https://domainA/oxygen-web-author/app/oxygen.html?url=https://domainB:4787/app/editor/Loading" target="_new">https://domainA/oxygen-web-author/app/oxygen.html?url=https://domainB:4787/app/editor/Loading</a><br>Line: Not available<br>
In the browser debugger, this error does not show until we call window.editor.load(editorOptions), which looks something like this:
Code: Select all
autoSaveInterval: 0
content: "<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE Section PUBLIC "--REMOVED--" "client.dtd">↵<Section PartNumber="00" ChapterNumber="030" SubchapterNumber="01" SectionNumber="999">↵<Title><?oxy_insert_start author="Anonymous" timestamp="20200505T175013-0400"?>Ron is Testing↵<?oxy_insert_end?><?oxy_delete author="Anonymous" timestamp="20200505T175016-0400" content="TEST"?></Title>↵<Para><?oxy_insert_start author="Anonymous" timestamp="20200430T165015-0400"?>Test save↵function<?oxy_insert_end?></Para>↵</Section>↵<?oxy_options track_changes="on"?>"
trackChanges: "enabled"
url: "https://domainB:4787/app/editor/Loading"
userName: ""
We hope you can help shed some light as to what's going on. Thank you!