First, I'm not good at writing, but I'll try to explain the problem
I need to print only one cell (number of votes already made) from the result table of the query, but not so I can access the value of the conversion error.
I was having to do the query and the echo directly in the function call in html
The votes need this after the name description
function pegarQtdVotos($conexao,$classificacao){
$query = "select qtd_votos from VOTOS where id={$classificacao}";
$resultado = mysqli_query($conexao, $query);
$qtd = mysqli_fetch_assoc($resultado);
return $qtd;
}
<p class="alert-success"><input type="radio" name="classificacao" id="classificacao" value="1"> Execelente</p>
<p class="alert-info"><input type="radio" name="classificacao" id="classificacao" value="2"> Bom </p>
<p class="alert-warning"><input type="radio" name="classificacao" id="classificacao" value="3"> Regular </p>
<p class="alert-danger"><input type="radio" name="classificacao" id="classificacao" value="4"> Ruim </p>