Integrating WP users into existing site w/users
-
Hey all,
I need to integrate my wordpress user database with the existing users table in a site that I have developed – or rather, have wordpress use that table instead of its native wp_users table.I have made an attempt at this and so far have been relatively successful – I’ve managed to get my site’s users to be logged into wordpress via cookies I’ve got one one of my scripts set.
So my users are logging in successfully… first step done (I had to edit wp-settings.php and the wp_login(), get_userdatabylogin() and get_userdata() functions in pluggable.php in order to select the correct columns from my site’s users table).
The only challenge now is trying to get my account to work with the admin panel. I log in, but when i try to go onto wp-admin/, I get an error screen saying “You do not have sufficient permissions to access this page.”
So I went to check the permissions in the wp_usermeta table and the rows with my id (1) have wp_user_level set to 10 and wp_capabilities set to “a:1:{s:13:”administrator”;b:1;}” <- obviously serialized, but demonstrates I’m set as an admin user.
My question is, have I missed anything? What do I need to check to fix this problem? As I’ve said, I’ve had to edit files in order to get wordpress to use my “users” table instead of “wp_users”, and for logging in, this works (I think, anyway), but for permissions I don’t seem so lucky.
Its either that or I’m mistaken and I’m not logging in at all. But surely, if I wasn’t logged in, and tried to access wp-admin, I’d be redirected to login screen?
Any suggestions are highly appreciated
- The topic ‘Integrating WP users into existing site w/users’ is closed to new replies.