I have a database with people's records, the name of my db and Registration and in it I have a table users > with four columns already filled id, age, name and email I am developing a user search system here is the search page
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
</head>
<body>
<form action="" method="GET" >
<input type="text" autocomplete="on" name="q" placeholder="Digite a sua pesquisa" />
<input type="submit" value="Tecle Enter" />
</form>
<?php
$host = 'localhost';
$user = 'devel';
$password = '********';
$database = 'Cadastro';
$connect = mysqli_connect($host, $user, $password, $database) or die("conexao die");
$query = $_GET['q'];
if(isset($query)){
$consult = mysqli_query("SELECT nome FROM 'usuarios' WHERE 'nome' LIKE %q%", $connect);
$result = mysqli_fetch_assoc( $consult );
print_r($result);
}
else {
echo 'nao foi encontrado nada';
}
?>
</body>
</html>
But I'm not getting feedback is there any way to know if the query was successful because I think my error is in the query of $consult
I'm completely lay in MySQL