diff --git a/www/search.php b/www/search.php index 04a1e9b..0115c04 100644 --- a/www/search.php +++ b/www/search.php @@ -31,8 +31,8 @@ if(isset($_GET["q"])) } - - $stmt = $pdo->prepare("select * from SavedVideo where Title like '%$search%' LIMIT ".strval($offset*20).", 20"); + $mySearch = $pdo->quote("%".$search."%"); + $stmt = $pdo->prepare("select * from SavedVideo where Title like $mySearch LIMIT ".strval($offset*20).", 20"); $stmt->execute(); $videos = $stmt->fetchAll();