Kieran Menor Posted January 1, 2010 Share Posted January 1, 2010 Is $_FILES[...]['name'] affected by magic_quotes_gpc? Quote Link to comment https://forums.phpfreaks.com/topic/186867-is-_filesname-affected-by-magic_quotes_gpc/ Share on other sites More sharing options...
Mchl Posted January 1, 2010 Share Posted January 1, 2010 gpc stands for GET, POST, COOKIE http://www.php.net/manual/en/security.magicquotes.what.php Apparently it isn't a very good response. $_FILES come through POST request, so it's affected. Quote Link to comment https://forums.phpfreaks.com/topic/186867-is-_filesname-affected-by-magic_quotes_gpc/#findComment-986846 Share on other sites More sharing options...
PFMaBiSmAd Posted January 1, 2010 Share Posted January 1, 2010 Boy is it affected, badly. Under the latest php5.3.x on Windows (this could be a php/Apache under Windows problem, again), magic_quotes_gpc being ON truncates everything up to and including the single quote in an uploaded filename. With magic_quotes_gpc OFF, the same file name is passed correctly. Confirmed using var_dump($_FILES[...]['name']); Quote Link to comment https://forums.phpfreaks.com/topic/186867-is-_filesname-affected-by-magic_quotes_gpc/#findComment-986895 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.