diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -7,6 +7,9 @@ function furkotTrip() {
   var form, stops;
 
   function plan(data) {
+    if (!form) {
+      form = createForm();
+    }
     stops.value = JSON.stringify(data);
     return form.submit();
   }
@@ -16,13 +19,19 @@ function furkotTrip() {
     return hidden ? '_blank' : '_top';
   }
 
-  form = document.createElement('form');
-  form.action = 'https://trips.furkot.com/trip';
-  form.method = 'post';
-  form.target = target();
-  stops = document.createElement('input');
-  stops.name = 'stops';
-  form.appendChild(stops);
+  function createForm() {
+    var form = document.createElement('form');
+    form.style.display = 'none';
+    form.action = 'https://trips.furkot.com/trip';
+    form.method = 'post';
+    form.target = target();
+    stops = document.createElement('input');
+    stops.name = 'stops';
+    form.appendChild(stops);
+    // Firefox needs form in DOM
+    document.body.appendChild(form);
+    return form;
+  }
 
   return {
     plan: plan
fix form submission on Firefox

Firefox does not submit forms unless they are added to document body