<?php include("header.php"); ?>
<?php $type= $_POST['type']; ?>
<?php if ($type =='Firearms') { ?>
<div class="office field"><label><?php echo $type; ?></label><select class="equipments" name="equipments"><?php $equipments = mysql_query("SELECT * FROM equipments WHERE type='$type' AND status='available' ") or die(mysql_error());  ?>
		<?php WHILE($equips = mysql_fetch_array($equipments)){
		$id = $equips['equip_id'];
		$serial = $equips['serial'];
		?>
	<option value="<?php echo $serial; ?>"><?php echo $serial; ?></option>
	<input type="text" name="ammos" />
	<?php } ?>
	</select>
	</div>
<?php } else {?>
<div class="office field"><label><?php echo $type; ?></label><select class="equipments" name="equipments"><?php $equipments = mysql_query("SELECT * FROM equipments WHERE type='$type' AND status='available' ") or die(mysql_error());  ?>
		<?php WHILE($equips = mysql_fetch_array($equipments)){
		$id = $equips['equip_id'];
		$serial = $equips['serial'];
		?>
	<option value="<?php echo $serial; ?>"><?php echo $serial; ?></option>
	<?php } ?>
	</select>
	</div>
	
	<?php } ?>