I'm stuck on how to sanitize the code below for SQL injections.
Line 3 is where I'm stuck and put ??? for the value I'm not sure of. I'd also appreciate if someone can review the entire thing to check if I made other mistakes.
$path will look something like /1/A/2/B/3/C/
1 $path = parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH);
2 $stmt = $db->prepare("SELECT * FROM table WHERE path = :path");
3 $path = filter_input(???, 'path', FILTER_SANITIZE_STRING);
4 $post->bindParam(':path', $path, PDO::PARAM_STR);
5 $post->execute();