July 07th, 2024

How to disable PHP Execution in WordPress

Like (1) Comments (1)

1 Comments Add Your Comment

Akshat Gupta
3 years ago Selected
Simply create a .htaccess file and upload it to your site's /wp-includes/ and /wp-content/uploads/ folders.

You can create an .htaccess file using Notepad (TextEdit on Mac). All you need to do is paste the below code in your .htaccess file.

deny from all

After creating your .htaccess file, upload it to the /wp-includes/ and /wp-content/uploads/ folders. You can upload it through FTP client or File Manager (cPanel dashboard).

After uploading the .htaccess file with this code, it will disable PHP execution from these directories.
Like (0) Reply

Post a Comment

To leave a comment, please Login or Register