Bitballoon’s (POST) form handler normally responds with a generic Bitballoon-branded “thanks” page.  If you have a reseller platform, you can customize this across your customer sites to brand it on your own. 

But individual sites, and in fact individual forms, can customize their own “thanks” page.  To set up a custom “thanks” page:

  • Build a page in your site tree called “thanks.html” (or anything else — but it must have the .html suffix)
  • In your <form> HTML, set the form’s @action to point to the thanks page, with the .html suffix.  

So, for example: <form action=”/thanks.html”>

Bitballoon will strip out the .html suffix on the page itself and in the form action attribute, so the deployed site will have <form action=”/thanks”> instead.  The form submission will be captured in the Bitballoon database and the user will see your “thanks” page as the response (including seeing the URL /thanks in the address bar).

Using this technique you can point all of the forms on a Bitballoon site to the same thanks page, or to a distinct page per form.  In fact (though I haven’t tested this) you could even point a form to submit back to the same page that the form is on.

When Bitballoon responds to a form POST, it will also inject a special Javascript snippet into the page head.  This javascript will set a global variable called “FormSubmission”, which will be an object containing all the submitted form data (in and some metadata like the submission’s unique non-sequential id, the timestamp of the submission, and the name of the form that was submitted.

You can use this to place conditional content on your page: with Javascript, check for the existence of the FormSubmission variable.  If it’s set, then you know that this is the response to a POST request that submitted a particular form, and you can display a “thanks” message, or fill in the data on the form if you’re submitting back to the same page, etc.

Filed December 21st, 2013 under bitballoon

On a Bitballoon site, you can customize the 404 page by including a file called “404.html” in the root of your website tree.

Bitballoon will strip out the “.html” suffix so the page will be served at /404, and will also be served whenever a request is made to a nonexistent page.

Note that (at least currently) this feature does not work with the following variations:

  • The file you upload cannot be called “/404″ — it must be “/404.html” with the suffix.
  • The file you upload cannot be called “/404/index.html” (even though this trick works for “regular” pages) — it really must be exactly “/404.html”.


Filed December 21st, 2013 under bitballoon