Does WP identify plugin by plugin name or plugin_basename?

I see from the activation link, wordpress is using the plugin’s dir. Also, when many plugins use add_action to hook on activation, they use

add_action('activate_' . plugin_basename(), 'name_activation');

If the plugin dir is word/ , the plugin name is Press, then, this will be:

Read More
add_action('activate_word', 'press_activation'');

So, WP identify the plugin as “word” or “press” ?
I know that by using ‘activate_word’, WP gets to know which file to activate. I also tested that the “Press” got activated and running. But, is there any potential trouble to consider?

Related posts

Leave a Reply

1 comment