Hello, its been a while since I use mysql and I breaking my head with this syntax:
SELECT * FROM `Botones` WHERE `aprove` = 1
AND `descripcion` LIKE '%$search%'
OR `nombre` LIKE '%$search%'
ORDER BY `likes` DESC
LIMIT 0,20
Its working great only problem is that it returns colums even if aprove
is equal to 0, and I want it to return only colums that aprove
= 1
aprove
type is INT (1)
EDIT: nvm solve it by :
SELECT * FROM `Botones` WHERE `aprove` = 1
AND `descripcion` LIKE '%$search%'
OR `aprove` = 1 AND `nombre` LIKE '%$search%'
ORDER BY `likes` DESC
LIMIT 0,20
Silly me :P