This displays all data ...
public function getProdutosHome($limit = false){
if($limit == false){
$query = "SELECT * FROM 'fretes' ORDER BY id_frete DESC";
}else{
$query = "SELECT * FROM 'fretes' ORDER BY id_frete DESC LIMIT $limit";
}
return self::conn()->query($query);
}
How can I filter using checkbox ? with each click going filtering the data of the database?
Thank you and sorry for the question.