If you are updating numbers in your table why you have put the variables in quotes?
$update = "update invoice set reg_no = '$reg_no', cost = '$cost' where i_id = '$update_i_id'";
If you are updating numbers in your table why you have put the variables in quotes?
$update = "update invoice set reg_no = '$reg_no', cost = '$cost' where i_id = '$update_i_id'";
Did you tried to turn it off and back on?