I currently trying to prevent people from deleting files from the root and the upper directories, but have searched everywhere and I can't find how to use the "in" operator.
This my expecting code:
$filename = $_GET['name'];
if("../" in $filename) {die("Error: No Permmission to delete the file.");}
unlink('./uploads/'.$_GET['name']);