Closing or Hiding the Plugin

Closing the Plugin

The close() method can be used to force the closing of the plugin window. All requests to server and callback functions (except on_close) within the current session will be aborted.

An example of usage:

var session_id = 123;{
  // We transfer the arbitrary meta data, by which we can later identify the session in Oz API
  meta: {
    session_id: session_id 
  // After sending the data, forcibly close the plugin window and independently request the result
  on_submit: function() {

Hiding the Plugin Window without Cancelling the Callbacks

The hide() method can be used to hide the plugin window without cancelling the requests for analysis results and user callback functions. Use this method, for instance, if you want to output your own upload indicator after submitting data.

An example of usage:{
  // When receiving an intermediate result, hide the plugin window and show our own loading indicators
  on_result: function(result) {
    if (result.state === 'processing') {
  on_complete: function() {

Last updated