I will preface my question by stating that I know it’s a strange request but it cannot however be done otherwise for this particular project.
I have a list of a few hundred checkboxes as part of a form. Outside of the form, I have a link going to a separate page that I would like to append the list of checked checkboxes to. example:
<form name="sampleForm" method="POST" action="process.php">
<input type="checkbox" name="checkbox_1" />
<input type="checkbox" name="checkbox_2" />
<input type="checkbox" name="checkbox_3" />
</form>
<a href="otherPage.php>Alternate Page</a>
What I need is for when someone clicks on the Alternate Page link, the checkboxes are appended like a GET statement:
otherpage.php?checkbox_1=1&checkbox_2=1
Or something along these lines, any suggestions that would solve a problem like this would be great. I am not interested in rewriting large portions of code or replacig this with a submit button.
You can do it like this by attaching javascript to the link. Change the HTML to this:
Add this javascript:
This works as follows: