Gett a form data

I have a form


When I submit it, i get

I’m confused cause the alignment name is in the form, heres the markup

						  <select name="alignment" id="alignment" class="form-control" required>
							  <option value="" disabled>Select Width</option>
							  <option value="" disabled>100% Options</option>
							  <option value="0" data-imagesrc="../images/Alignment_0.png">None</option>
							  <option value="" disabled>50% Options</option>
							  <option value="1" data-imagesrc="../images/Alignment_1.png">Left</option>
							  <option value="2" data-imagesrc="../images/Alignment_2.png">Right</option>
							  <option value="" disabled>33% Options</option>
							  <option value="3" data-imagesrc="../images/Alignment_3.png">Left</option>
							  <option value="4" data-imagesrc="../images/Alignment_4.png">Center</option>
							  <option value="5" data-imagesrc="../images/Alignment_5.png">Right</option>
							  <option value="" disabled>25% Options</option>
							  <option value="6" data-imagesrc="../images/Alignment_6.png">Left</option>
							  <option value="7" data-imagesrc="../images/Alignment_7.png">Center-Left</option>
							  <option value="8" data-imagesrc="../images/Alignment_8.png">Center-Right</option>
							  <option value="9" data-imagesrc="../images/Alignment_9.png">Right</option>
						  </select>	

IIf the form element is there, why is it not seen in the POST?

Well #1: Time to learn the power of the <optgroup> tag there :wink:

#2: Gonna need to see the whole form’s HTML.
#3: How’re you checking the $_POST?

sure, heres the page with the form on it


<!DOCTYPE html>
<html lang="en">
<head>
<title>Add Device to a rack</title>
<link rel="stylesheet" type="text/css" href="../css/bootstrap.min.css">
<link rel="stylesheet" href="../css/font-awesome.min.css" type="text/css" />
<link rel="stylesheet" href="../css/style.css" type="text/css" />
<link rel="stylesheet" type="text/css" href="../css/tabs.css">
<script type="text/javascript" src="../scripts/jquery.min.js"></script>
<script type="text/javascript" src="../scripts/jquery.ddslick.min.js"></script>
<style>
.card-body a {
    border-radius: 50%;
	margin-left:15px;
}
.card-body .row {margin-bottom:50px; }
.popup form .row { margin:0 }
.form-group { margin-bottom:1em; }
.dd-option.hide {
    display: none;
 }
 .dd-select {
	 background:white !important;
 }
 .dd-selected-text {
	 font-weight:normal;
	 line-height: normal !important;
	 margin-left:15px;
 }
 a.dd-selected {
	 padding:7px;
	 border-radius:0;
	 margin-left:0;
 }
 .dd-selected-text {
	 margin-bottom:0;
 }
 a.dd-option {
	 border-radius:0;
	 margin-left:0;
 }
 .dd-option-text {
	 font-weight:normal;
	 line-height:15px !important;
	 margin-left:20px;
 }
 
.dd-option-image, .dd-selected-image {
    max-width: 150px !important;
}
 
 </style>
</head>
<body>
<nav class="navbar navbar-expand-lg navbar-dark bg-dark" style="margin-bottom:10px">
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>

  <div class="collapse navbar-collapse" id="navbarSupportedContent">
    <ul class="navbar-nav mr-auto">
      <li class="nav-item">
        <a class="nav-link" href="../index.php">Home <span class="sr-only">(current)</span></a>
      </li>
      <li class="nav-item">
        <a class="nav-link" href="../utilities">Utilities</a>
      </li>      
      <li class="nav-item">
        <a class="nav-link" href="../mdps">MDPs</a>
      </li> 
      <li class="nav-item">
        <a class="nav-link" href="../generators">Generators</a>
      </li>      
      <li class="nav-item">
        <a class="nav-link" href="../upss">UPSs</a>
      </li> 
      <li class="nav-item">
        <a class="nav-link" href="../switches">Switches</a>
      </li>      
      <li class="nav-item">
        <a class="nav-link" href="../pdus">PDUs</a>
      </li> 
      <li class="nav-item">
        <a class="nav-link" href="../power_strips">Power&nbsp;Strips</a>
      </li>      
      <li class="nav-item">
        <a class="nav-link" href="index.php">Devices</a>
      </li> 
      <li class="nav-item">
        <a class="nav-link" href="../racks">Racks</a>
      </li> 
      <li class="nav-item">
        <a class="nav-link" href="../ac_units">A/C&nbsp;Units</a>
      </li>      
      <li class="nav-item">
        <a class="nav-link" href="../furniture">Furniture</a>
      </li> 
	  
	  </ul>
    <span class="navbar-text">
<span class="badge badge-pill badge-light text-dark" style="font-weight:500">You are logged in as lurtnowski@industechnology.com</span>&nbsp;&nbsp;<a class="btn btn-danger btn-sm" href="../logout.php" role="button">Logout</a>	</span>
  </div>
</nav>
<div class="card" style="margin:25px auto; width:85%">
	<div class="card-header">  
      <img src="../images/add_device_icon.png" alt="Remove"><h2>Add Device to a Rack</h2>
	</div>
	<div class="card-body">
			<div class="row">
				<div class="col-4">			  
				  <h5>To Rack:&nbsp;&nbsp;&nbsp;<span class="text-secondary">Rack #1</span></h5>
				  <table class="table table-sm">
				  <thead>
				  <tr><th>Room</th><th>Row</th><th>Bay</th></tr>
				  </thead>
				  <tbody>
				  <tr><td>Comms Room</td><td>A</td><td>1</td></tr>				  
				  </tbody>
				  </table>
				<div class="tabs">
				  <input type="radio" name="tabs" id="tabone" checked>
				  <label for="tabone">Front</label>
					<div class="tab" style="height:765px">
<svg viewBox="0 0 300 1000">
<defs>
  <pattern id="pattern"
           width="8" height="10"
           patternUnits="userSpaceOnUse"
           patternTransform="rotate(45 50 50)">
    <line stroke="#f00" stroke-width="7px" y2="10"/>
  </pattern>
<style>
text { 
font-size:.6em;
font-face:verdana;
}
.move {
      fill:url(#pattern);
      opacity:0.6;
      stroke:#000;
      stroke-width:2px";
}
.device {
	fill:#e3e3e3;
	stroke:#000;
	stroke-width:.5;
}
.device:hover {
	fill: #007bff;
}
.tipthemewhite {margin:3em 0 0 1.1em;}
</style>
</defs> 
  <line x1="35" y1="8" x2="215" y2="8" style="stroke:#212529" />
  <line x1="30" y1="15" x2="35" y2="8" style="stroke:#212529" />
  <line x1="210" y1="15" x2="215" y2="8" style="stroke:#212529" />
  <line x1="210" y1="475" x2="215" y2="465" style="stroke:#212529" />
  <line x1="215" y1="465" x2="215" y2="8" style="stroke:#212529" />
  <rect x="30" y="15" width="180" height="460" style="fill:white;stroke-width:2;stroke:#6c757d" />
  <rect x="35" y="20" width="170" height="450" style="fill:white;stroke-width:1;stroke:#6c757d;stroke-dasharray:5" />
<text x="222" y="465">1</text>
<text x="222" y="455">2</text>
<text x="222" y="445">3</text>
<text x="222" y="435">4</text>
<text x="222" y="425">5</text>
<text x="222" y="415">6</text>
<text x="222" y="405">7</text>
<text x="222" y="395">8</text>
<text x="222" y="385">9</text>
<text x="222" y="375">10</text>
<text x="222" y="365">11</text>
<text x="222" y="355">12</text>
<text x="222" y="345">13</text>
<text x="222" y="335">14</text>
<text x="222" y="325">15</text>
<text x="222" y="315">16</text>
<text x="222" y="305">17</text>
<text x="222" y="295">18</text>
<text x="222" y="285">19</text>
<text x="222" y="275">20</text>
<text x="222" y="265">21</text>
<text x="222" y="255">22</text>
<text x="222" y="245">23</text>
<text x="222" y="235">24</text>
<text x="222" y="225">25</text>
<text x="222" y="215">26</text>
<text x="222" y="205">27</text>
<text x="222" y="195">28</text>
<text x="222" y="185">29</text>
<text x="222" y="175">30</text>
<text x="222" y="165">31</text>
<text x="222" y="155">32</text>
<text x="222" y="145">33</text>
<text x="222" y="135">34</text>
<text x="222" y="125">35</text>
<text x="222" y="115">36</text>
<text x="222" y="105">37</text>
<text x="222" y="95">38</text>
<text x="222" y="85">39</text>
<text x="222" y="75">40</text>
<text x="222" y="65">41</text>
<text x="222" y="55">42</text>
<text x="222" y="45">43</text>
<text x="222" y="35">44</text>
<text x="222" y="25">45</text>

   <rect x="35" y="450" width="170" height="20" class="device jqeasytooltip" data-tiptheme="tipthemewhite"  data-tipcontent="Dog Locator" />
   <rect x="35" y="40" width="42.5" height="20" class="device jqeasytooltip" data-tiptheme="tipthemewhite"  data-tipcontent="Shark Locator" />
   <rect x="35" y="380" width="85" height="20" class="device jqeasytooltip" data-tiptheme="tipthemewhite"  data-tipcontent="Shark Locator" /> 
</svg>
					</div>
				  <input type="radio" name="tabs" id="tabtwo">
				  <label for="tabtwo">Back</label>
					<div class="tab" style="height:765px">
<svg viewBox="0 0 300 1000">
<defs>
<style>
text { 
font-size:.6em;
font-face:verdana;
}
.device {
	fill:#e3e3e3;
	stroke:#000;
	stroke-width:.5;
}
.device:hover {
	fill: #007bff;
}
.tipthemewhite {margin:3em 0 0 1.1em;}
</style>
</defs> 
  <line x1="35" y1="8" x2="215" y2="8" style="stroke:#212529" />
  <line x1="30" y1="15" x2="35" y2="8" style="stroke:#212529" />
  <line x1="210" y1="15" x2="215" y2="8" style="stroke:#212529" />
  <line x1="210" y1="475" x2="215" y2="465" style="stroke:#212529" />
  <line x1="215" y1="465" x2="215" y2="8" style="stroke:#212529" />
  <rect x="30" y="15" width="180" height="460" style="fill:white;stroke-width:2;stroke:#6c757d" />
  <rect x="35" y="20" width="170" height="450" style="fill:white;stroke-width:1;stroke:#6c757d;stroke-dasharray:5" />
<text x="222" y="465">1</text>
<text x="222" y="455">2</text>
<text x="222" y="445">3</text>
<text x="222" y="435">4</text>
<text x="222" y="425">5</text>
<text x="222" y="415">6</text>
<text x="222" y="405">7</text>
<text x="222" y="395">8</text>
<text x="222" y="385">9</text>
<text x="222" y="375">10</text>
<text x="222" y="365">11</text>
<text x="222" y="355">12</text>
<text x="222" y="345">13</text>
<text x="222" y="335">14</text>
<text x="222" y="325">15</text>
<text x="222" y="315">16</text>
<text x="222" y="305">17</text>
<text x="222" y="295">18</text>
<text x="222" y="285">19</text>
<text x="222" y="275">20</text>
<text x="222" y="265">21</text>
<text x="222" y="255">22</text>
<text x="222" y="245">23</text>
<text x="222" y="235">24</text>
<text x="222" y="225">25</text>
<text x="222" y="215">26</text>
<text x="222" y="205">27</text>
<text x="222" y="195">28</text>
<text x="222" y="185">29</text>
<text x="222" y="175">30</text>
<text x="222" y="165">31</text>
<text x="222" y="155">32</text>
<text x="222" y="145">33</text>
<text x="222" y="135">34</text>
<text x="222" y="125">35</text>
<text x="222" y="115">36</text>
<text x="222" y="105">37</text>
<text x="222" y="95">38</text>
<text x="222" y="85">39</text>
<text x="222" y="75">40</text>
<text x="222" y="65">41</text>
<text x="222" y="55">42</text>
<text x="222" y="45">43</text>
<text x="222" y="35">44</text>
<text x="222" y="25">45</text>
0 results 
</svg>
					</div>
				</div>					  
			  
				</div>				
				<div class="col-8">
				  <form method="post" action="add_device_to_rack_engine.php">
					<div class="row">
						<div class="col">
						  <label for="Title">Name</label>
<a class="btn btn-outline-secondary shadow btn-sm" href="#add_name" role="button"><span class="icon-plus"></span></a> 						
<select class="form-control" id="Name" name="Name" required><option disabled selected value="">Select</option><option value="Dog Locator">Dog Locator</option><option value="Shark Locator">Shark Locator</option><option value="test name">test name</option></select>							
						</div>
						<div class="col">
						  <label for="Manufacturer">Manufacturer</label>
<a class="btn btn-outline-secondary shadow btn-sm" href="#add_manufacturer" role="button"><span class="icon-plus"></span></a> 					
<select class="form-control" id="Manufacturer" name="Manufacturer" required><option disabled selected value="">Select</option><option value="Device Emporium.">Device Emporium.</option></select>						
						</div>				  
						<div class="col">
						  <label for="Model">Model</label>
<a class="btn btn-outline-secondary shadow btn-sm" href="#add_model" role="button"><span class="icon-plus"></span></a> 						
<select class="form-control" id="Model" name="Model" required><option disabled selected value="">Select</option><option value="MAGA">MAGA</option><option value="Get Fat">Get Fat</option></select>						
					
								</div>
						<div class="col">
						  <label for="Category">Category</label>
<a class="btn btn-outline-secondary shadow btn-sm" href="#add_category" role="button"><span class="icon-plus"></span></a> 					
<select class="form-control" id="Category" name="Category" required><option disabled selected value="">Select</option><option value="Recreational">Recreational</option><option value="Imperative">Imperative</option></select>						
			
						</div>					
					</div>
					<div class="row">
						<div class="col">
						  <label for="slots">First/Last Slots</label>
							<div class="input-group">
								<div class="input-group-prepend">
								  <span class="input-group-text">#</span>
								</div>						
						      <input type="number" name="beginning_slot" required step="0.1" class="form-control" min="0" max="50" maxlength="2">
						      <input type="number" name="ending_slot" required step="0.1" class="form-control" min="0" max="50" maxlength="2">
							</div>						
						</div>
						<div class="col">
						  <label for="OS">Operating System</label>
						  <input type="text" name="OS" id="OS" class="form-control" maxlength="25">
												
						</div>					
						<div class="col">	
						  <label for="Ports">Ports</label>
							  <select class="form-control" id="Ports" name="Ports">
							  <option value="1">Yes</option>
							  <option value="0">No</option>
						      </select>							
						</div>					
						<div class="col">
						  <label for="Version">Firmware Version</label>
						  <input type="text" name="Version" id="Version" class="form-control">						
						</div>					
					
					</div>
					<div class="row">
						<div class="col">
						  <label for="Orientation">Orientation</label>
							  <select class="form-control" id="Orientation" name="Orientation">
							  <option value="1">Front</option>
							  <option value="0">Back</option>
						      </select>							
						</div>
						<div class="col">
						  <label for="width">Width</label>
							  <select class="form-control" id="width" required name="Width">
							  <option selected disabled value="">Select</option>
							  <option value="100">100%</option>
							  <option value="50">50%</option>
							  <option value="33">33%</option>
							  <option value="25">25%</option>
						      </select>							
						</div>
						<div class="col">
						  <label for="alignment">Alignment</label>
						  <select name="alignment" id="alignment" class="form-control" required>
							  <option value="" disabled>Select Width</option>
							  <option value="" disabled>100% Options</option>
							  <option value="0" data-imagesrc="../images/Alignment_0.png">None</option>
							  <option value="" disabled>50% Options</option>
							  <option value="1" data-imagesrc="../images/Alignment_1.png">Left</option>
							  <option value="2" data-imagesrc="../images/Alignment_2.png">Right</option>
							  <option value="" disabled>33% Options</option>
							  <option value="3" data-imagesrc="../images/Alignment_3.png">Left</option>
							  <option value="4" data-imagesrc="../images/Alignment_4.png">Center</option>
							  <option value="5" data-imagesrc="../images/Alignment_5.png">Right</option>
							  <option value="" disabled>25% Options</option>
							  <option value="6" data-imagesrc="../images/Alignment_6.png">Left</option>
							  <option value="7" data-imagesrc="../images/Alignment_7.png">Center-Left</option>
							  <option value="8" data-imagesrc="../images/Alignment_8.png">Center-Right</option>
							  <option value="9" data-imagesrc="../images/Alignment_9.png">Right</option>
						  </select>							
						</div>
						<div class="col">
						  <label for="Classification">Classification</label>
							  <select class="form-control" id="Classification" name="Classification" required>
							  <option disabled selected>Select</option>
							  <option value="White">White</option>
							  <option value="Yellow">Yellow</option>
							  <option value="Orange">Orange</option>
							  <option value="Red">Red</option>
							  <option value="Black">Black</option>
						      </select>	
						</div>					
					</div>
					<div class="row">
						<div class="col">
						  <label for="Address">IP Address</label>
						  <input type="text" name="Address" id="Address" class="form-control" maxlength="25">
						</div>
						<div class="col">
						  <label for="Software">Hosted Software</label>
						  <input type="text" name="Software" id="Software" class="form-control" maxlength="50">					
						</div>
						<div class="col">
						  <label for="Network">Hosted Network</label>
						  <input type="text" name="Network" id="Network" class="form-control" maxlength="50">						
						</div>
						<div class="col">
						  <label for="System_Name">System</label>
<a class="btn btn-outline-secondary shadow btn-sm" href="#add_system" role="button"><span class="icon-plus"></span></a><select class="form-control" id="System_Name" name="System_Name"><option disabled selected value="">Select</option><option value="Education">Education</option><option value="Government">Government</option><option value="DMV">DMV</option></select>	
					
						</div>
					</div>
					<div class="row">
						<div class="col">
						  <label for="enabled">Enabled</label>
						  <select class="custom-select" id="enabled" name="enabled">
						  <option value="1">Yes</option>
						  <option value="0">No</option>
						  </select>
						</div>						
						<div class="col">
						  <label for="Source">Source</label>
<select class="form-control" id="Source" name="Source" required><option disabled selected value="">Select</option><option value="1">Luke's Power Strip</option><option value="2">Fred's Power Strip</option><option value="3">Wally's Power Strip</option><option value="4">Terry's Power Strip</option><option value="5">Zach's Power Strip</option><option value="6">Ian's Power Strip</option></select>						</div>
						<div class="col">
						  <label for="Purpose">Purpose</label>
						  <input type="text" name="Purpose" id="Purpose" class="form-control" maxlength="127">
						</div>
						<div class="col">
						  <label for="Type">Type</label>
<a class="btn btn-outline-secondary shadow btn-sm" href="#add_type" role="button"><span class="icon-plus"></span></a><select class="form-control" id="Type" name="Type" required><option disabled selected value="">Select</option><option value="GPS Enabled">GPS Enabled</option></select>	
						</div>
					</div>
					<div class="row">
						<div class="col">
						  <label for="Type_Description">Type Description</label>
						  <input type="text" name="Type_Description" id="Type_Description" class="form-control" maxlength="127">
						</div>
					</div>					
					<div class="row">
						<div class="col">
						  <label for="notes">Notes on this addition</label>
						  <textarea name="notes" id="notes" class="form-control" rows="5"></textarea>
						
						</div>
						<div class="col">
					      <label for="Notes">Notes on this device</label>
						  <textarea name="Notes" id="Notes" class="form-control" rows="5"></textarea>
						
						</div>
					</div>
					<div class="row justify-content-center">
					    <div class="col-4">
					      <button type="submit" class="btn btn-primary btn-block btn-lg"><span class="icon-ok"></span>&nbsp;&nbsp;Submit</button>
						</div>
					</div>				
				<input type="hidden" name="rack_id" value="1">
				</form>				
			</div>
		</div>
	</div>
</div>
<div id="add_name" class="overlay"><div class="popup"><a class="close" href="#">&times;</a><div class="content"><h2 class="text-center">Add Device Name</h2><hr><ol><li>Dog Locator</li><li>Shark Locator</li><li>test name</li></ol><form action="add_device_to_rack.php" method="GET" name="Add Name"><div class="justify-content-center row"><div class="col-sm-6"><div class="input-group"><input type="text" class="form-control" name="Name" placeholder="Name to add." required maxlength="25"><div class="input-append"><button class="btn btn-outline-secondary" type="submit"><span class="icon-plus"></span></button></div></div></div></div><input type="hidden" name="rack_id" value="1"></form></div></div></div>
<div id="add_manufacturer" class="overlay"><div class="popup"><a class="close" href="#">&times;</a><div class="content"><h2 class="text-center">Add Device Manufacturer</h2><hr><ol><li>Device Emporium.</li ></ol><form action="add_device_to_rack.php" method="GET"><div class="justify-content-center row"><div class="col-sm-6"><div class="input-group"><input type="text" class="form-control" name="Manufacturer" placeholder="Manufacturer to add." required maxlength="50"><div class="input-append"><button class="btn btn-outline-secondary" type="submit"><span class="icon-plus"></span></button></div></div></div></div><input type="hidden" name="rack_id" value="1"></form></div></div></div>
<div id="add_model" class="overlay"><div class="popup"><a class="close" href="#">&times;</a><div class="content"><h2 class="text-center">Add Device Model</h2><hr><ol><li>MAGA</li><li>Get Fat</li></ol><form action="add_device_to_rack.php" method="GET"><div class="justify-content-center row"><div class="col-sm-6"><div class="input-group"><input type="text" class="form-control" name="Model" placeholder="Model to add." required maxlength="25"><div class="input-append"><button class="btn btn-outline-secondary" type="submit"><span class="icon-plus"></span></button></div></div></div></div><input type="hidden" name="rack_id" value="1"></form></div></div></div><div id="add_category" class="overlay"><div class="popup"><a class="close" href="#">&times;</a><div class="content"><h2 class="text-center">Add Device Category</h2><hr><ol><li>Recreational</li><li>Imperative</li></ol><form action="add_device_to_rack.php" method="GET"><div class="justify-content-center row"><div class="col-sm-6"><div class="input-group"><input type="text" class="form-control" name="Category" placeholder="Category to add." required maxlength="25"><div class="input-append"><button class="btn btn-outline-secondary" type="submit"><span class="icon-plus"></span></button></div></div></div></div><input type="hidden" name="rack_id" value="1"></form></div></div></div>
<div id="add_type" class="overlay"><div class="popup"><a class="close" href="#">&times;</a><div class="content"><h2 class="text-center">Add Device Type</h2><hr><ol><li>GPS Enabled</li></ol><form action="add_device_to_rack.php" method="GET" name="Add Type"><div class="justify-content-center row"><div class="col-sm-6"><div class="input-group"><input type="text" class="form-control" name="Type" placeholder="Type to add." required maxlength="25"><div class="input-append"><button class="btn btn-outline-secondary" type="submit"><span class="icon-plus"></span></button></div></div></div></div><input type="hidden" name="rack_id" value="1"></form></div></div></div>
<div id="add_system" class="overlay"><div class="popup"><a class="close" href="#">&times;</a><div class="content"><h2 class="text-center">Add System</h2><hr><ol><li>Education</li><li>Government</li><li>DMV</li></ol><form action="add_device_to_rack.php" method="GET" name="Add System"><div class="justify-content-center row"><div class="col-sm-6"><div class="input-group"><input type="text" class="form-control" name="System_Name" placeholder="System to add." required maxlength="25"><div class="input-append"><button class="btn btn-outline-secondary" type="submit"><span class="icon-plus"></span></button></div></div></div></div><input type="hidden" name="rack_id" value="1"></form></div></div></div>  
<!--<script type="text/javascript" src="../scripts/jquery.js"></script>
<script type="text/javascript" src="../scripts/jqeasytooltip.v1.3.min.js"></script>-->
<script language="javascript">
$('#alignment').ddslick({
    selectText: "Select your alignment"
});

(function(d) {
    "use strict";
    var widths = d.querySelector("#width");
    var alignments = d.querySelector("#alignment");

    function hideDDSlickOptions(select) {
        var options = alignments.querySelectorAll(".dd-option");
        options.forEach(function (option) {
            option.classList.add("hide");
        });
    }
    function showAlignmentOptions(widthSelect, alignments) {
        hideDDSlickOptions(alignments);
        var widthOption = widthSelect.options[widthSelect.selectedIndex];
        var widthChoice = widthOption.text;
        var options = alignments.querySelectorAll(".dd-option");
        if (widthChoice === "100%") {
            $(alignments).ddslick('select', {index: 1});
            options[2].classList.remove("hide");
        }
        if (widthChoice === "50%") {
            $(alignments).ddslick('select', {index: 3});
            options[4].classList.remove("hide");
            options[5].classList.remove("hide");
        }
        if (widthChoice === "33%") {
            $(alignments).ddslick('select', {index: 6});
            options[7].classList.remove("hide");
            options[8].classList.remove("hide");
            options[9].classList.remove("hide");
        }
        if (widthChoice === "25%") {
            $(alignments).ddslick('select', {index: 10});
            options[11].classList.remove("hide");
            options[12].classList.remove("hide");
            options[13].classList.remove("hide");
            options[14].classList.remove("hide");
        }
    }
    
    function widthChangeHandler(evt) {
        var widthChoice = evt.target;
        showAlignmentOptions(widthChoice, alignments);
    }
    widths.addEventListener("change", widthChangeHandler);

    hideDDSlickOptions(alignments);
    $(alignments).ddslick('select', {index: 0});
}(document));

</script>
<!-- <script src="../scripts/jquery-3.3.1.slim.min.js"></script>
<script src="../scripts/popper.min.js"></script>
<script src="../scripts/bootstrap.min.js"></script> -->
</body>
</html>

The page in the is submitted to

<?php
	
echo '<pre>';print_r($_POST);echo '</pre>';

$Name = addslashes($_POST['Name']);
$Manufacturer = addslashes($_POST['Manufacturer']);
$Model = addslashes($_POST['Model']);
$Category = addslashes($_POST['Category']);
$beginning_slot = (int)$_POST['beginning_slot'];
$ending_slot = (int)$_POST['ending_slot'];
$OS = addslashes($_POST['OS']);
$Ports = $_POST['Ports'];
$Version = addslashes($_POST['Version']);
$Orientation = (int)$_POST['Orientation'];
$Width = (int)$_POST['Width'];
$alignment = addslashes($_POST['alignment']);
$Classification = addslashes($_POST['Classification']);
$Address = addslashes($_POST['Address']);
$Hosted_Software = addslashes($_POST['Software']);
$Hosted_Network = addslashes($_POST['Network']);
$IP_Address = addslashes($_POST['Address']);
$System_Name = addslashes($_POST['System_Name']);
$Enabled = (int)$_POST['enabled'];
$power_strip_id = (int)$_POST['Source'];
$Purpose = addslashes($_POST['Purpose']);
$Type_Description = addslashes($_POST['Type_Description']);
$rack_id = (int)$_POST['rack_id'];
$Type = addslashes($_POST['Type']);
$Notes = addslashes($_POST['Notes']);
$notes = addslashes($_POST['notes']);

switch ($alignment){ 

case 1:
$beginning_x = 0;
break; 
case 2:
$beginning_x = 50;
break; 
case 3:
$beginning_x = 33;
break; 
case 4:
$beginning_x = 66;
break; 
case 5:
$beginning_x = 25;
break; 
case 6:
$beginning_x = 75;
break; 
default: 
$beginning_x = 0;
}
      
$sql = "INSERT INTO devices (power_strip_id,rack_id,name,type,type_description,category,purpose,classification,manufacturer,model,firmware_version,operating_system,
		IP_address,hosted_software,hosted_network,system_name,notes,port,beginning_slot,ending_slot,width,beginning_x,created_by,created_date,enabled
		) VALUES (
		".$power_strip_id.", ".$rack_id.",'".$Name."','".$Type."','".$Type_Description."', '".$Category."','".$Purpose."', '".$Classification."','".$Manufacturer."','".$Model."',
		'".$Version."','".$OS."','".$IP_Address."','".$Hosted_Software."','".$Hosted_Network."','".$System_Name."','".$Notes."',".$Ports.",".$beginning_slot.", ".$ending_slot.", ".$Width.",".$beginning_x.",'".$_SESSION['email']."', CURRENT_TIMESTAMP,".$Enabled.")";
	  
echo $sql;
		
?>

Heres the form before I submit it


the result (no alignment)

then if I comment out the scripts, I see

the result

I think somehow the script that causes the image in the allignment drowdown makes it not submit
id like to use the optgroup if I can use images with it, can I?

Well given that alignment is the only field missing from your post, and it’s also the only field your javascript is messing around with…i’ma put 2 and 2 together and suspect something that “ddslick” is doing is preventing the form from submitting correctly.

What happens if you comment out all your javascript for the moment and process the form field naturally?

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.