I'm trying to make a contact form where users are supposed to toggle different checkboxes (within checkbox groups), which i've made to buttons with a combination of Bootstrap Button Groups (http://getbootstrap.com/components/#btn-groups) and Bootstrap Toggle (http://www.bootstraptoggle.com), enter their email address and submit. The results of the user input should be sent to a specified recipient email, with following body
- Email address
- Values of checked checkboxes/toggled buttons
Selection of at least one checkbox within each group is required, and users should be able to check all checkboxes if the choose to.
I'm fairly comfortable with HTML/Bootstrap, but not at all with PHP - I can barely decipher PHP codes and I've stared at 100+ questions and tutorials about PHP forms, only to get more confused, which is why i have no PHP code to show (email.php i just a empty doc waiting to be filled the correct PHP code).
I have no idea where to begin, and absolutely zero idea of how to manage the multiple checkboxes/buttons with PHP.
FYI: Don't mind some of the HTML is in Danish.
This is my HTML:
<form action="assets/helpers/email.php" method="post">
iPhone model<br><br>
<div class="btn-group" data-toggle="buttons" >
<button type="button" class="btn btn-primary"> <input type="checkbox" value="5" name"5" id="5">iPhone 5/5S</button>
<button type="button" class="btn btn-primary"> <input type="checkbox" value="6" name"6" id="6">iPhone 6</button>
<button type="button" class="btn btn-primary"> <input type="checkbox" value="6p" name"6p" id="6p">iPhone 6 Plus</button>
</div>
<br> <br>
<br>
Bumper model<br><br>
<div class="btn-group" data-toggle="buttons" >
<button type="button" class="btn btn-primary"><input type="checkbox" value="FK" name"FK">Firkantet</button>
<button type="button" class="btn btn-primary"><input type="checkbox" value="RU" name"RU">Rund</button>
</div>
<br>
<br>
<br>
Lås<br><br>
<div class="btn-group" data-toggle="buttons">
<button type="button" class="btn btn-primary"><input type="checkbox" value="US" name"FL">Flet</button>
<button type="button" class="btn btn-primary"><input type="checkbox" value="MS" name"SK">Skruer</button>
</div>
<br> <br> <br>
Farve<br><br>
<div class="btn-group" data-toggle="buttons">
<button type="button" class="btn btn-primary"><input type="checkbox" value="BA" name"BA">Sort</button>
<button type="button" class="btn btn-primary"><input type="checkbox" value="SI" name"SI">Sølv</button>
<button type="button" class="btn btn-primary"><input type="checkbox" value="GR" name"GR">Grå</button>
<button type="button" class="btn btn-primary"><input type="checkbox" value="CH" name"CH">Champagne</button>
</div>
<br> <br>
<br/>
<input type='text' name='email' placeholder="Din email" />
</p>
<input type='submit' name='submit' value='Skriv mig op' />
</form>