When creating WordPress plugins, it is always advisable to follow maximum security measures. This makes your plugin more stable and acceptable by other users.
One such security check is to prevent direct access of plugin files by a user. For that add the following code to the top of main plugin php file.
if(!defined('ABSPATH'))
die('Direct access of plugin file not allowed');
One such security check is to prevent direct access of plugin files by a user. For that add the following code to the top of main plugin php file.
if(!defined('ABSPATH'))
die('Direct access of plugin file not allowed');
Labels:
wordpress disable direct access
Previous Article

Responses
0 Respones to "How To Prevent WordPress Plugin Files from Direct Access? "
Post a Comment