This is how we implemented it.
We have a link in all our Marketo pages that asks the visitor to "click here" if the information on the form is not theirs to re-set the information. Once the person clicks on that, a javascript function we created clears the cookie and re-loads the page.
In addition to that, we check for a URL parameter (userID=guest). If any of our pages are called with that URL parameter present, we also clear the Marketo prefill and all the fields prior to rendering the page. We do that with a short JavaScript function. This allows us to link to any of our Marketo lead capture pages forcing not pre-filling the forms even for known leads if we wanted to.
Summary:
-
Create a function that would clear the values, cookie, etc.
-
Place link on your template to call the function to clear and reload the page.
Simple, non-intrusive, and easy to deploy and maintain.
If you wanted to apply the same functionality to the reset button on the form, you can use jQuery to "listen" to a click on the button and fire the same function or have it call the same page with the "magic" URL parameter.
Good luck!
Rafael