I'm very new to programming php and html. I've got a form I'm using to update info to a SQL DB.
I can get the form to send information into the SQL, but once I add a space to my inputs or they get too long it stops working.
I've gotten to the point where all I'm trying to do is send the $test variable in. I've also tried sending spaces into the SQL using the SP directly itself and it works just fine. Any advice is appreciated.
<div class="form-popup" id="myForm">
<form action="../processors/unload.php" method = "POST" class="form-container" >
<h1>EDIT BOX</h1>
<label for="part-id"><B>PART ID</B></label>
<input type="text" placeholder="enter part ID" name="partID" required>
<label for="part-id"><B>BOW</B></label>
<input type="text" placeholder="BOW" name="bow" >
<label for="partid"><B>TUBE HEIGHT</B></label>
<input type="text" placeholder="TUBE HEIGHT" name="tube">
<label for="notes"><B>NOTES</B></label>
<input type="text" placeholder="notes" name="notes">
<br>
<label for="quality"><B>QUALITY</B></label>
<select name='quality' class='defectDrop'>
<option value='ok'>OK</option>
<option value='NOK'>NOK</option>
<option value='online'>ONLINE</option>
</select>
<label for="defect"><b>DEFECT</b></label>
<button type="submit" class="submit-button" id ="boo" >SUBMIT</button>
<button type="button" class="cancel-button" onclick=hideIt();>CLOSE</button>
</form>
</div>
<?php
include('../connect.php');
$partID = $_POST['partID'];
$quality = $_POST['quality'];
$notes = $_POST['notes'];
$bow = $_POST['bow'];
$tube = $_POST['tube'];
$test = "what up";
$sql = "EXEC dbo.php_test
@part_ID = " .$partID. "
, @notes = " .$test. " ";
echo $sql;
sqlsrv_query($conn, $sql);
sqlsrv_close($conn);
header("location: ../html/test.html");