Added query information API to plugin server

Change-Id: Ib4120ca18d1153fd454aa4354d7854a5685fb092
diff --git a/dev/js/src/plugin/server.js b/dev/js/src/plugin/server.js
index e5578be..7a2d305 100644
--- a/dev/js/src/plugin/server.js
+++ b/dev/js/src/plugin/server.js
@@ -407,10 +407,29 @@
 
       // Get information from the embedding platform
       case 'get':
+
+        // Get KoralQuery
         if (d.key == 'KQ') {
           if (KorAP.koralQuery !== undefined) {    
             d["value"] = KorAP.koralQuery;
           };
+        }
+
+        // Get Query form information
+        else if (d.key == 'QueryForm') {
+          let doc = document;
+          let v = d["value"] = {};
+
+          var el;
+          if (el = doc.getElementById('q-field')) {
+            v["q"] = el.value;
+          };
+          if (el = doc.getElementById('ql-field')) {
+            v["ql"] = el.value;
+          };
+          if (el = KorAP.vc) {
+            v["cq"] = el.toQuery();
+          };
         };
       };