After a few hours of debugging I figured out the problem.
Here is a diff.
> diff TotalCache.php TotalCache.spf.php
919c919
< add_menu_page('Performance', 'Performance', 'manage_options', 'w3tc_general', '', plugins_url('w3-total-cache/inc/images/logo_small.png'));
---
> add_menu_page('Performance', 'Settings', 'manage_options', 'w3tc_general', '', plugins_url('w3-total-cache/inc/images/logo_small.png'));
The problem is that the plugin is registering pages as
Array
(
[0] => toplevel_page_w3tc_general
[1] => performance_page_w3tc_pgcache
[2] => performance_page_w3tc_minify
[3] => performance_page_w3tc_dbcache
[4] => performance_page_w3tc_objectcache
[5] => performance_page_w3tc_browsercache
[6] => performance_page_w3tc_mobile
[7] => performance_page_w3tc_cdn
[8] => performance_page_w3tc_faq
[9] => performance_page_w3tc_support
[10] => performance_page_w3tc_install
[11] => performance_page_w3tc_about
)
But the plugin has them located at “settings_page…”
since the page it’s looking for doesn’t exist in the method ‘user_can_access_page’, this block fails every time.
if ( !isset($_registered_pages[$hookname]) )
return false;
Not sure why it’s happening and especially why it’s not happening to everyone. I’ll bet there’s a better way of fixing it, but I’m just happy to have something that works.