1
I need to make sure that when the administrator registers the user notes typed in the fields Nota1, Nota2, Nota3, Nota4 and Nota5, the values are counted individually, and if one of them exceeds 200 points, a message automatically appears stating that the value exceeded the allowed value (200 points). The list of users is coming from PHP, see:
<?php
....
$visualizar = '<table class="table">
<thead>
<tr>
<td>Aluno</td>
<td>Nota 1</td>
<td>Nota 2</td>
<td>Nota 3</td>
<td>Nota 4</td>
<td>Nota 5</td>
<tr>
<tbody>';
while($pe = mysqli_fetch_object($sql))
{
$visualizar .= '<tr>';
$visualizar .= '<td><input type="text" name="Nome[]" class="form-control" value="'.$pe->NomeUsuario.'" readonly></td>';
$visualizar .= '<td><input type="text" name="Nota1[]" class="form-control"></td>';
$visualizar .= '<td><input type="text" name="Nota2[]" class="form-control"></td>';
$visualizar .= '<td><input type="text" name="Nota3[]" class="form-control"></td>';
$visualizar .= '<td><input type="text" name="Nota4[]" class="form-control"></td>';
$visualizar .= '<td><input type="text" name="Nota5[]" class="form-control"></td>';
}
....
You can do this in Jquery or Javascript?
Have you tried
<input type="number" max="200">
?– fernandosavio
Hello Fernando. It would be a good option, but the notes will be in this format: 5.5, 10.0, 3.2, etc. and I believe that, because it is a number field, do not accept these formats.
– user24136
Just add
step="0.1"
– fernandosavio