The easiest way to reload current page without losing form data, use the WebStorage where you have -persistent storage (localStorage) or session based (sessionStorage) which remains in memory until your web browser is closed.
Something on these lines:
Try this when the page is about to reload,
window.onbeforeunload = function() {
localStorage.setItem(name, $('#inputName').val());
localStorage.setItem(phone, $('#inputPhone').val());
localStorage.setItem(subject, $('#inputAddress').val());
}