Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Original way to define the constants
- if (!defined('PLUGIN_URL'))
- define('PLUGIN_URL', WP_CONTENT_URL . '/plugins');
- if (!defined('PLUGIN_PATH'))
- define('PLUGIN_PATH', WP_CONTENT_DIR . '/plugins');
- // Optimal way to define the constants (using plugins_url and plugin_dir_path)
- if (!defined('PLUGIN_URL'))
- define('PLUGIN_URL', plugins_url());
- if (!defined('PLUGIN_PATH'))
- define('PLUGIN_PATH', plugin_dir_path());
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement