[wp-hackers] Re: CUSTOM_USER_TABLE and CUSTOM_USER_META_TABLE broken

Jeremy Visser jeremy.visser at gmail.com
Sun Mar 9 03:17:50 GMT 2008


As a follow-up to this, it worked fine after deleting all the tables,
and starting from scratch.

Today, I tried to migrate my WordPress MU site to a WordPress which
dynamically changes the $table_prefix depending on the value of
$_SERVER['HTTP_HOST'], and keeps the CUSTOM_USER_TABLE and
CUSTOM_USER_META_TABLE constants...well, constant.

However, I get the "You do not have sufficient permissions to access
this page" error again.

My blog's prefix is wp_2_, and indeed the wp_2_capabilities usermeta is
present, with the value of: a:1:{s:13:"Administrator";b:1;}

Now, I edited wp-admin/menu.php, and changed the wp_die() to, instead of
dumping the error message, to print_r() the contents of $current_user.

Sure enough, it has picked up the capabilities:
        
        [first_name] => Jeremy
        [last_name] => Visser
        [wp_2_capabilities] => Array
        	(
        		[Administrator] => 1
        	)

...so what would cause it to not work? WP capabilities are _way_ too
complicated for me to understand.



More information about the wp-hackers mailing list