Hola gente, necesito su ayuda es que en esta ocasion ando haciendo tags pero n ome sale osea quiero que me digan en que fallo con el codigo WHERE:
Código:
public function b_tags(){
self::set_names();
$tags = "accion, fight";
$tag = explode(", ", $tags);
$sql="SELECT * FROM m_animes WHERE p_tag and '$tag'=?";
$stmt=$this->dbh->prepare($sql);
if($stmt->execute(array($_GET["tag"]))){
while ($row = $stmt->fetch()){
$this->n[]=$row;
}
$this->dbh=null;
return $this->n;
}
}
No me manda, intente con el print_r y no me manda datos, aver si me pueden ayudar