I have a checkbox JsFiddle When the useR ticks on one of the checkboxes, it opens a new Window, which enables the user to view download a PDF once the checkbox button has been clicked. this then disables the download function so when the user ticks on the checkbox button again it activates the submit button.
The Trouble i am having is when the user clicks on the anything within the terms-blockdiv is downloads the PDF. Initially how i want it when is the user clicks on the text 'terms and conditions' it opens the the PDF, once the PDF is open the text changes to 'i agree with the terms with a tick' that activates the submit button… can this be done
$(function() {
var checkboxes = $("#terms-agreed"),
submitButt = $("input[type='submit']");
enableSub(submitButt );
checkboxes.on("click",function() {
enableSub(submitButt );
if (this.checked) window.open('{site_url}downloads/resellers/Standard_Terms_and_Conditions.pdf');
});
});
Aucun commentaire:
Enregistrer un commentaire