Skip to content

Instantly share code, notes, and snippets.

@magefix
Created March 25, 2021 08:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save magefix/5c7ffa9fdf4ccc2c62c0a20567d3a36e to your computer and use it in GitHub Desktop.
Save magefix/5c7ffa9fdf4ccc2c62c0a20567d3a36e to your computer and use it in GitHub Desktop.
.htaccess to place inside /wp-content/uploads/
<FilesMatch "\.(php|php\.)$">
Order Allow,Deny
Deny from all
</FilesMatch>
<FilesMatch "\.(php|phtml|php1|php2|php3|php4|php5|pl|py|jsp|asp|html|htm|shtml|sh|cgi|suspected)$">
Order Allow,Deny
deny from all
</FilesMatch>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment