I have a simple problem when picking up a data from a table ..
The error is
Warning: mysqli_fetch_assoc () expects parameter 1 to be mysqli_result, boolean given in
Code:
$sql = mysqli_query($conexao, "SELECT diasvip FROM login WHERE userid = ".$_POST['userid']."");
while($exibe = mysqli_fetch_assoc($sql)){
echo "<div class='alert alert-success' role='alert'>Dias Vip do Usuário: ".$exibe['diasvip']."</div>";
}
mysqli_close($conexao);