-
-
Save codepedia/edf0eac107904f46e22b5840a7a0f2c4 to your computer and use it in GitHub Desktop.
submetendo um form para o google spreadsheet sem redirect
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
var submitted = false; | |
function submit(){ | |
if(submitted) { | |
alert('Obrigado por cadastrar seu e-mail!'); | |
document.getElementById('entry_0').value = ''; | |
} | |
</script> | |
<iframe name="hidden_iframe" id="hidden_iframe" style="display: none;" onload="submit();"></iframe> | |
<form action="SPREADSHEET_URL" method="POST" id="ss-form" onsubmit="submitted=true;" target="hidden_iframe"> | |
<!-- RESTO DO FORM --> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment