In database I have this field: "TeST" and I dont know where are the caps lock and I just want to strtolower him and to do somthing like that
SELECT * FROM table WHERE strtolower(field) = strtolower($var)
How can I do that?
Using PDO and assuming MySQL
$stmt = $db->prepare('SELECT * FROM table WHERE LOWER(`field`) = ?');
$stmt->execute(array(strtolower($var)));