I am making a registration form that posts the values to a php file, but upon inspection of the post variable in netbeans, I saw that the radio button is not included in the array yet all the other input are.
Heres the code:
<form id="register" action="php/register.php" method="post">
<h1>Please fill out as much as possible</h1>
<h2>Would you like to register as a bulk buyer or a retail buyer?</h2>
<div id="container">
<div class="regForm left">
<input type="radio" name="custType" value="Bulk"><label>Bulk buyer</label><br>
<input id="bEmail" type="email" name="bEmail"><label>Email address</label><br>
<input id="bPass" type="password" name="bPass"><label>Password</label><br>
<input id="bComp" type="text" name="bCompany"><label>Company name</label><br>
<input id="bContact" type="text" name="bContact"><label>Contact person</label><br>
<input id="bOffice" type="tel" name="bOffice"><label>Office number</label><br>
<input id="bMobile" type="tel" name="bMobile"><label>Mobile number</label><br>
<input id="bVAT" type="text" name="bVat"><label>VAT number</label><br>
<textarea id="bAddress" cols="17" rows="4"></textarea><label>Address</label>
</div>
<div class="regForm right">
<input type="radio" name="custType" value="Retail"><label>Retail buyer</label><br>
<input id="rEmail" type="email" name="rEmail"><label>Email address</label><br>
<input id="rPass" type="password" name="rPass"><label>Password</label><br>
<input id="rMobile" type="tel" name="rMobile"><label>Mobile number</label>
</div>
<div class="regForm right">
<label>Do you wish to receive additional email marketing from us? <input id="marketingCheck" type="checkbox" name="market"></label><br>
<input id="regSubmit" type="submit" name="submit" value="Register"><a href="" id="cancelReg">Cancel</a>
</div>
<div class="clear"></div>
</div>
</form>
At the moment I am doing nothing with the post in the php file.
I could post a screenshot of the post var in netbeans, but the site will not allow me.
Heres the result of print_r($_POST);
Array ( [bEmail] => [bPass] => [bCompany] => [bContact] => [bOffice] => [bMobile] => [bVat] => [rEmail] => [rPass] => [rMobile] => [submit] => Register )
I looked at the other post, but they seem to have just a typo in the code or the sort.
Thanks