templates only written to files if text is submitted

Previously, saving the data from a popup window in the multipage
interface, would cause the templates to be written with empty values.
Now they are only written if there is such a value being sent from the
client.
Merge pull request #29 from jegelstaff/Fixing-template-erasure

templates only written to files if text is submitted