You are using the concats inside the string incorrectly:
UPDATE Orders
SET status='".$_POST['order_status'][$i]."'
WHERE ID='".$_POST['order_no'][$i]."';
The reason being you are already splitting the string and you want to use the value of inside the array.
What you have is a string:
UPDATE Orders SET status='
and you are concat'ing a variable to it:
$_POST['order_status'][$i]
and so on...
You use the concat between strings, and don't need to use it inside the array you are including.
On that note, using $_POST
data inside a query is dangerous. You really should use a prepared statement - which means you can them bind the variable safetly.