Some people, upon upgrading from WordPress 1.5.x to 2.0.x have been experiencing this error:
You do not have sufficient permissions to access this page
The most common cause of this error is an upgrade that didn’t complete. The database number has been incremented, so WordPress thinks it is up to date, but it hasn’t yet written the permissions that you will need to access the WordPress admin interface.
I have written a script to force the 1.5.x to 2.0.x upgrade.
Download
Instructions
- Click “Download” and save as
force-upgrade.php
- Upload
force-upgrade.php
to your WordPress root directory (the directory withwp-config.php
) - Access the file in your browser (e.g.
http://example.com/wordpress/force-upgrade.php
) - Delete
force-upgrade.php
from your server
I won’t promise you that this will solve all your problems, but it has helped several people who have tried it. Let me know how you fare.
Hey, It Worked For Me!
wp-admin/admin.php?page=intensedebate
can’t access dis page. I click on my comments page n i get dis
You do not have sufficient permissions to access this page
HELP!
Excellent job. Thanks so much for the assist.
This is the sequence of events when I run your script. Thoughts? Thanks much!
WordPress loaded…
Upgrade functions loaded…
Object cache flushed…
Database made current…
Fatal error: Call to undefined function: upgrade_160() in /home/vatulnet/public_html/blog/force-upgrade.php on line 35
I guess I need a new upgrade-functions.php file with a definition for upgrade_160.
Yeah, you’ll need the latest version of WordPress with upgrade_160();
Hi Mark,
Thanks for the script – gave it a spin but no joy. I am only encountering this issue with users who sign up to post comments. Admin is fine.
Still hunting for a cure!
All the best,
Tom
Tom,
Possible problem:
Maybe your default role (subscriber?) doesn’t have any capabilities. Try the Role Manager plugin (Google it) and make sure the Subscriber role looks correct.
test
Hey Mark,
Thanks for that – installed the Red Alt version, and upped the permissions to allow a subscriber to “Edit Post” (closest thing to post comment I could see).
Clicked on the “logged in” URL and it allowed me to login – yeah, unfortunately thrown straight back to the original post with no option to add anything.
Curiouser and curiouser.
Appreciate the heads up on the role manager – didn’t have a clue it was required.
“Everyone is ignorant – only on different subjects…”
All the best,
Tom
man.. I LOVE YOU!THANKS I Resolved my problem!
You’re a genius! Thanks!
seems to be working, thanks for making my day easier!
Mark! THANK YOU!! OMG, I was freaking out. I’m finally going to start blogging on scripty again, upgraded to the latest version of WP, it failed, couldn’t access anything… this did the trick. THANK YOU THANK YOU THANK YOU!!!
Thanks mark! It worked.
when i upgrade 2.0.5 to 2.1, i met the same problem, unfortunely, it doesnt work any more, can you write a new one to solve “to 2.1″problem?
did this… then i could log in.. but do not have admin-rights now
WKR AveN
please help
i moved my db, i added prefix to it, i went and manually changed wp-config.php and added my prefix there, but now it takes my username and password for wp-admin, but i get following error
You do not have sufficient permissions to access this page.
and i haven’t changed word press itself, i’m on same version
From 1.5 to WordPress 2.1.3 it works! Useful script, thanks.
I tried using this software as I have had problems since attempting to upgrade from 1.5 to 2.1.3.
Unfortunately, the problems still remain. My DB tables seem to be a mixture of 1.5 and 2.1
When running force-upgrade.php, I got:
WordPress loaded…
Upgrade functions loaded…
Object cache flushed…
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_categories’]
ALTER TABLE wp_categories ADD COLUMN link_count bigint(20) NOT NULL default ‘0’
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_categories’]
ALTER TABLE wp_categories ADD COLUMN posts_private tinyint(1) NOT NULL default ‘0’
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_categories’]
ALTER TABLE wp_categories ADD COLUMN links_private tinyint(1) NOT NULL default ‘0’
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_posts’]
ALTER TABLE wp_posts CHANGE COLUMN post_status post_status enum(‘publish’,’draft’,’private’,’static’,’object’,’attachment’,’inherit’,’future’) NOT NULL default ‘publish’
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_posts’]
ALTER TABLE wp_posts CHANGE COLUMN post_type post_type varchar(20) NOT NULL default ‘post’
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_posts’]
ALTER TABLE wp_posts ALTER COLUMN post_type SET DEFAULT ‘post’
WordPress database error: [ALTER command denied to user ‘smargolisbl’@’localhost’ for table ‘wp_posts’]
ALTER TABLE wp_posts ADD KEY type_status_date (post_type,post_status,post_date,ID)
1. Added column wp_categories.link_count
2. Added column wp_categories.posts_private
3. Added column wp_categories.links_private
4. Changed type of wp_posts.post_status from enum(‘publish’,’draft’,’private’,’static’,’object’,’attachment’) to enum(‘publish’,’draft’,’private’,’static’,’object’,’attachment’,’inherit’,’future’)
5. Changed default value of wp_posts.post_type from to post
6. Added index wp_posts KEY type_status_date (post_type,post_status,post_date,ID)
Database made current…
Data upgraded…
Rewrite rules flushed…
Object cache flushed…
Hopefully that did it! DELETE THIS FILE FROM YOUR SERVER NOW!
And then, try to access your /wp-admin/
Any suggestions?
Thanks
Update:
I finally managed to fix this by clearing the database and starting with WordPress’ own ‘wp-content’ folder. Problem solved.
Thanks! worked for me in 2.2.
don’t know what really worked for me, but I deleted a “mailing-list.php” plugin file from the plugins folder because it was including the “upgrade-functions.php”, in which some function (don’t remeber which) was redeclared.,..
Hell of a mess, I know. If anyone has mailing-list plugin and the same problem “not have sufficient permissions to access this page”, delete it!
For those who get this error randomly, without having upgraded WordPress recently, it’s caused by a database table being corrupted. Log in to MySQL and perform a repair using the syntax
repair table tablename
This fixed mine the first time I tried it.
Thanks. It worked fine with me.
A clarification for the not-so-fast: The force-upgrade.php is to be run AFTER uploading the files of the new version to the server.
Regards
Mortenoc
Thanks heaps for this 🙂
Fix my upgrade to 2.2.1
worked well, thanks
I have filed a bug to remove the $table_prefix in the column names which causes this problem in the first place.
http://trac.wordpress.org/ticket/4780
Ciao!
It’s not clear to me that this script does the edits that are noted as required in the ticket (and accounts for other entries that may have been added in the three years since the ticket’s been updated. [I’ve got an installation with “xxx_” as the table prefix and the xxx_options table *does* have an entry with option_name equal “wp_optimize” (not xxx_optimize). But the xxx_usermeta table had an entry with meta_key equal to xxx_dashboard_quick_press_last_post_id.] I’m under a deadline at the moment, but will try to verify this — by running the script on the problematic install — next week. In the meantime, if anyone knows if “table_prefix_options.wp_optimize” should *stay* “wp_optimize” no matter what the value of $table_prefix, I’d appreciate knowing about it – and maybe the trac ticket should be updated with a reference to “table_prefix_usermeta.table_prefix_dashboard_quick_press_last_post_id” ?
i hadn’t upgraded anything WordPress on my site in a couple years and yesterday i started getting the error after logging in to my admin page and trying to go to my profile (none of the usual menu items were there):
“You do not have sufficient permissions to access this page”
I tried the script and now i can’t even get in to the admin page…
urgh… any ideas would be GREATLY appreciated.
thanks,
ryder
THANKS !!! YOU ARE A GENIOUS
I used your upgrade script – and this got me further, but my admin account seemed to have no admin privs. All I could do was edit my profile – not post, nothing. I think the reason was that in the process of upgrading I also changed my blog prefix name. And this does bad things to wp_usermeta
Here’s what I did to fix:
Go into wp_usermeta in mysql and change all the meta_keys that proceed with the old blog prefix table name to the new blog prefix table name.
Bryan your solution is brilliant, easy and did not require any other scripts. excellent man
I had the same problem, and this fixed it, THANX!
can logged into the dashboard but dunno wat happened now, i can see only the dashboard and profile links there
the download link is not working!
http://txfx.net/files/wordpress/force-upgrade.phps
Thank you so Much this is an awesome and clean fix.! My site http://www.caffination.com would not be up and running right now without you. Works for botched installs from wordpress 2.2.X – 2.3.1. Many thanks!
Awesome, thanks
what the hell! it worked! you are awesome man… 😀 cheers! 🙂
Thanx!
good work, i’m not use it yet, but download it just in case i need it in near future
Bryan – October 11, 2007 at 10:43 pm :I used your upgrade script – and this got me further, but my admin account seemed to have no admin privs. All I could do was edit my profile – not post, nothing. I think the reason was that in the process of upgrading I also changed my blog prefix name. And this does bad things to wp_usermeta
Here’s what I did to fix:
Go into wp_usermeta in mysql and change all the meta_keys that proceed with the old blog prefix table name to the new blog prefix table name.
I have the same prob. The upgrade script worked, I also change the meta_keys of the old prefix table name.. I still don’t have the admin priviledges in admin account. I can’t edit posts. pls help!
Hi,
Well done.
It actually worked in fixing my WP 2.2 admin login problem. Before running the script, it keep complaining I have no permission to access the admin’s profile despite I am already using admin profile.
FYI. I am using free hosting from http://www.freehostia.com.
I had same problem as paul loke and primas.
after ran the scripts i got the error as primas. but progressed to admin page. but can’t see write , manage , etc option. Only dashboard and profile. Any solution ?
Nowadays free us polyphonic ringtone croupier fold slow basic bank back free polyphonic ringtone for alltel circle railroad weak 100 gratis klingeltne speek kicker pocket symbols.
Jugar poker regeln zum download Kugel paar gekommen overplay kostenloses online poker spiel Überbrücker Zweien rain Klaps Diamanten Banknotenrolle poker spiel lernen paigow steif Neutrales!
this topic is not used and moderated anymore? … i also have some problems..but as i can see..nobody is here anymore 😦
yikes
it came in as a quicktime file.php
granted i dont understand any of this but that seems weird.
will you call me
213-435-3665
thanks,
marion
Did the job for me! Perfect! Thanks a lot!
OBRIGADO!
thankx a lot!
você salvou minha vida =DD
o/
I am trying to install a new theme in word press 2.o but any theme i chose it comes up with an error “Broken Theme” and “style.css is unreadable”.
Any comments much appreciated.
Works for me!!Thanks
Funciono barbaro gracias por la info!!
ohh maaan thx!!!!!!
I’ve upgraded to WP 2.5 but I’m still unable to get rid of this error message and am still locked out of the admin module. I’ve tried all the fixes suggested on this page 😦
What else can be done? Is the WP crew unaware of this problem that seems to be affecting so many people and are they not working on a fix for it?
Hopefully, they are, otherwise I’ll have to replace my blog script with another, more stable platform.
Thank, it worked.
worked for me! Thank you for taking the time to help us out. It is much appreciated.
-J
Not only did it not work but it completely wiped clean all of the content from my website. You’re shitty little piece of code may help some people but the damage it does to others is greater.
Thank You very much for saving me another big headache! Thank You!
FIXED!!!!
OK gang – if you run the script and can then LOGIN but only get the Dashboard and Profile, you must do 2 things
1) In you wp_usermeta table make sure your meta_key entries are correct (e.g. wp_capabilities and wp_userlevel on a default configuration.
2) delete the extra wp_capabilities entries the script has added to the end of your table. by default if will add a:1:{s:13:”subscriber”;b:1;} to your wp_capabilities – which makes your admin account a subscriber only.
Thanks man !!!
It worked for me (from 2.1.3 to 2.5.1)
you made my day 🙂
Thanks a lot, You did it, it works
The plugin wordphonic 1.02 was causing the problem in my site, try deactivating it.
I had SERIOUS doubts this would work since I had a working version of 2.5.1 but after changing table names and moving some files around I got this error. This php file totally fixed it! THANK YOU!!!
ACK! I can get to the dashboard but NOTHING else!!!
It worked!
Thanks!!!
Excellent! Thanks. I had this problem after using WP-Security-Scan plug in on a WP 2.5.1 installation and this fixed it right up.
thx
I used it a couple of minutes ago on v2.5.1, and everything works fine now.
g;)
Hi Mark,
I had a crash in the middle of an upgrade and your fix helped me get into the dashboard, but I can’t navigate past that point. Can you think of any other files that might need to be “upgraded” so that we can access all of the admin panel?
If you think of something, please use small words as I am not a programmer.
no me funcionó 😦
Thank you Mark. Worked in v2.5.1. Awesome!
For those of you who encountered this error, and are in the process of moving WP to another spot… and changed the base table names in the process (e.g. the old tables had the prefix “wp_” and you chose to change it to “XX_wp_” in the new spot) then please take a look at this link:
http://www.lildude.co.uk/howto-change-wordpress-table-prefix/
It turns out that THAT was the reason we couldn’t log into the admin, and the solution presented here just ended up putting garbage information into the database that we had to delete.
Thanks! worked nicely
Worked for me too, great job 🙂
Worked a treat – thanks a bunch! And this was applied to a 2.5 db, through a hosting company, they must have run the upgrade en masse and not noticed it not working.
Three cheers for the genius!!! Thanks!! I’m back at work again.
Nice! Thanks!!!
Zx93fcdmlkEqo09
ou gc ih
ju ds ta
did not worked for me. i’m using wp 2.7
Did not work for my 3.0 install.
Any updates for 3.0?
Thanks
Thanks a lot for the fix.
It worked like a charm.
Happy coding
worked perfect for me after upgrading from 1.5 to 2.7.1 and getting locked out of my admin. thanks.
i tired force express, it made the site run — but unfortunatley i can post or edit
Thanks Mark for your force-upgrade script. For al those that are having trouble with this as I have this is what I did to fix my problem. I am a novice on databases so I first did the one-click install that my hosting provider (Media Temple) provided to create the tables.
1) One Click Install (version 2.0)
2) Went to login into WP and it accepted my login information
3) Got message: You do not have sufficient permissions to access this page error
4) Downloaded and ran Mark’s force-upgrade.php file
Force Upgrade for WordPress
4) Opened up Plesk – used Database WebAdmin to bring up PHPMyAdmin
5) Click on the User_Meta Table
6) Made sure table prefixes were consistent and correct
7) Saw that I now had an extra line in user_meta named ‘capabilities’ instead of ‘wp_capabilites’ and the value was “subscriber”
8) Copied long string of information with wp_capabilities that WP put there on the initial instal to the meta_value for the line listed ‘capabilities’ and this changed the permissions from subscriber to administrator.
10) After all this was complete. Everything showed up in working order in my admin panel.
Hope this helps somebody. 🙂
Thanks for great post. It worked. But user admin can’t add new user, delete post, delete page… what error ?
Please help me !
I just want to say that I was getting what I thought was this error, and it turned out to be something very silly–I was copying my urls from my FTP, and so they all started with ftp rather than http.
I imagine everyone else is a little more savvy than that, but just in case anyone else is that silly…
Why I always login to admin profile, the others menu disappear, any help?
Yeah!
I’ve been at this ALL day. I’m a complete web amateur, but great tips here helped sort it out!
Thanks!
Sweeet! Worked like a charm!
Thanx a bunch!!!
Worked with no probs…
Saved so much research time.
cheers,
Chippa
Thanks man, you saved my day.
Bottom line: the force-upgrade worked. Thanks, Mark!
A little more info about my unique situation might shed light on what’s really going on — I include my guesses; feel free to enlighten me.
I have two blogs at two different websites. I installed a WP 2.7 instance from scratch a few weeks ago at one of the sites, and have been playing with all the plug-ins, templates, etc. to determine how much of a website (beyond the blog) is possible with WP. Templates with menus and other pages make this environment rich — I imagine many people build their entire website in WP.
I then tried to install WP on the other website. Unlike the first one, this site only had WP 2.0, the 3 year old version. I installed it, and then expected to do an upgrade to 2.7. The upgrade from wordpress.org downloaded 2.7 to my home computer, leaving me with the need to FTP it up to the website.
Since there was no script to do this, I created a completely parallel instance. But since this 2.7 was completely vanilla, I had to copy the wp-config file over so it would know where the data base was. It found that OK, noted that it was out of date, and upgraded it (or at least said it did). That’s when I tried
to login thru the browser as admin, and when I hit the ‘you don’t have permssion…’ . So going to Google with the error message, I found your site, downloaded your force-upgrade.php, and finally got to the 2.7 dashboard.
Now I am working on the next problem — 2.7 downloaded from wordpress.org doesn’t have anywhere near the dashboard controls of the other 2.7 — just Profile and Tools; no Appearance, Plug-ins, etc. I am assuming that there are more php files I need to activate, and if I look at the directory structure at the two sites, there are differences beyond the theme I downloaded. I still wonder about how various downloads differ at this basic level. Certainly I would expect to have to download plug-ins one by one, but the general dashboard access points ought to be common for the same version. Right?
Thanks very much. This worked on 2.7.1
Thank You! Worked for me.
Thanks a lot for the script, seems to work all the way to wp 2.8.
By the way, this was caused by WP-Security Scan, damn that plugin!
it didnt work for me.
i am unable to acesss my admin an after that i tries your script.
it didnt work..
Awesome. W0rked for me! Thanx
Thanks a lot my friend!!!!!!!!!!!!!!!!!!!!!!!!!!
Work perfect with 2.8
Worked like a champ after an update from WordPress 2.7 to 2.8.1. Thanks a ton!
Hey this worked! I just fixed this error on a 2.8.0 installation with it. Good stuff.
Muchas gracias hermano,
si funciona exelente
Hi it works for me too.. nice job!
Thanks a lot
I owe you one…. it worked on 2.8.2
Thank you Sir…
A life-saver, thank you.
Its working… wow!!!
WOHO awesome, it fixed it 😀
Hi,
I get the same error message, but only for the plugin “pn-counter”.
I use WP 2.8.4, and it’s running well for the rest!
I have tried several solutions, but the same error message is popping up every time I will give pn-counter a try!
Thanks,
Eno
Thanks a lot.
That has able to access my admin side.
Thank you so much !!
You save me.
Thanks
But it didn’t help my problem with pn-counter. . . .
What else to try ?
??
May i know why i post comment on someone blog but the comment never show up?Can u help?Thanks
well, I’m having the pb with the NowReading plugin .. I’ve tried your fix but it seemes it doesn’t work for me .. I’m still having the problem ..
It didn’t work for me with version 2.8, not sure what it could be, but several plugins gave me the same error.
you helped me a lot! Thanks!
OH thank You can make me easy
perfect it works for wp 2.8
Thank you thank you thank you,
Wow, it turns out it was erroring. I had a lot of trepidation over downloading a php script from txfx.net when a link was on this site markjaquith.wordpress.com, but damn that worked. I thought this blog was wrecked.
Thanks!
Thanks. That worked a treat. I thought it was a file permission problem with the Thesis theme which I was trying out on a spare domain.
Hey it works. Great Thanks to you! I’ve problems with my plugins before but it’s all fixed now.
You rule!
I couldn’t get into any admin page after installing WP 2.0 from Plesk.
I’ve used your file – it said that there was some error but anyway now i have admin privileges
i fucking love you man
i tryed editing my user in the data base – failed
i reseted my password a couple of time – failed
i searched in the scripts for a pass mix up – failed
used force-upgrade.php : WORKED
thank you for the script
ALL BEGAN TO WORK!!!! THANK YOU FRIEND!!! Let God bless you!
How can I Solve this problem. That when I leave a comment on the blog. It shown me this Web. This is the url can help me check it out thanks .
URL:http://www.ttfatloss.com/wp-comments-post.php
It show some WordPres> Error
worked like a charm! thanks for making the process so easy.
Your the shit… worked for me like a charm 😀
Hi Mark
Thanks VERY much for the script.
It didn’t work the first time so I had a little look-see and the following comments are for anyone who is not getting the page to display correctly so that the script can actually be run:
—-
You might be having an issue due to the frames the script comes wrapped in.
I opened the file that I’d downloaded with my text editor, copied out the code, saved it as a fresh “force-upgrade.php” file (containing JUST the code I needed — without the frames), uploaded that to my server, and navigated to the page… voila! I could see the message saying “Please click here to force the upgrade”
I did, it worked, I deleted the file, yay!
Thanks a LOT, Mark. I was COMPLETELY stumped as to how to get around it. Nice one and a lot of people, me included, are very grateful to you.
All the best,
TheNightOwl
I tried this on 2.8.4 site… it allowed me into the admin area, but now all I see is Profile and Tools, I can not access Posts, Pages, Media Library, Plug-ins, etc. I just upgraded to 2.8.5 but still all I see under admin is Profile and Tools. Any ideas out there!????
hi check and see if you can at least see the plugins themes pages, i can but get
you do not have sufficient permissions to access this page.
which seems to point to us having only subscriber level access , anyone???
Tried the steps above and still no go. I also tried copying/pasting the text and saving as .php file (just in case frames were causing an issue) and still no go.
I have looked at my table names (not sure exactly what I’m looking for) and everything seems ok.
I STILL cannot access any plugins after upgraded to 2.8.5.
I’ve looked all over the internet for answers and there’s no real solution. I’ve read hundreds of posts in the worpdress forums and this is the most common solution (using the force-upgrade.php script). Nothing else I’ve tried has worked.
Is there seriously no answer for this?
Its working Now Thank you very much.
Jagat
I register one user in my root WP DB before run that script. I opend this script then it worked fine, after using that script I added one more user in my WP DB but again I faced “you do not have sufficient permissions to access this page.” error. I dont want to run this script manually after every 5 min. Anyother solution?
Worked great. Register.com seems to have this problem by default on their software install widget. Glad to have a solution.
Hello,
I had similar problem and I was getting same message.
“you do not have sufficient permissions to access this page.”
After running the force-upgrade.php script, i could login and see the subscriber level dashboard – I can only see Tools and Profile. It shows me user as “admin”, but nothing other than that.
I can browse the site fine,but not the admin dashboard.
Can somebody help?
Cheers
thanks, it works on 2.5.8
Hello,
Ok.I changed all the entries in the database with the correct _*names.
I could now get in as administrator. The only bit (probably the most important) that is missing is “Add New” under PLUGINS section, so I can’t upgrade anything without ftp’g the file manually. I am sure this may affect my future WP upgrades.
Anybody here to help?
Cheers
Excellent work, saved me lots of time:) Thank you
I spoke too soon and have the same prob as a few above
After running the force-upgrade.php script, i could login and see the subscriber level dashboard – I can only see Tools and Profile. It shows me user as “admin”, but nothing other than that.
I can browse the site fine,but not the admin dashboard.
any one found a solution yet???
I solved my prob, i reuploaded an older config file which had more info in it, after that WP redirected me to an install page, it then reconnected to db and told me admin un and pw , logged in and it worked fine, weirrrrrrrd , hope this convoluted response helps
It really worked for me! Thank you dude, you saved a lot of my time and efforts 🙂
Thanks for the fix. It worked!
OMG , thank you so much , it worked so nice for me and i have wordpress 2.8.5 !!!!! I MUST BUY YOU SOMETHING !!!
OMG its not working
i always get the error
hmmm
Wow!! this was amazing and fast!! This just shows the power of wordpress and its community!! thank you very much…
-nic
WOW! Problem Solved!
After hunting and pecking for a solution to what seemed like an obvious problem that the author’s of the plugin should have resolved, I found your site and ran your suggested fix.
Thank for your help
GREAT! It works for me!
thanx a bunch!
i’ve had this issue for aaages now, and i was starting to just live with it, but there are so many admin pages i can’t see now that it needs sorting…
tried this fix after the 2.7 upgrade but i couldn’t even make it work as it said it would..
this time (2.9) it worked as described but still no fix, dag nabbit…
cheers anyway dawg
Awesome post and I definitely like the guides as well.
I LOVE YOU ……….. its saved my great jani
I think you are nice, I want to make friends with you, can you pm me?
.
i had this particular issue and tried numerous things to resolve none of which worked until i took my head out of my ass and disabled all my plugins and re-enabled them one by one, starting with firestats and tagally, which were the two that were giving the insufficient permissions error, eventually i re-enabled WORDPHONIC by Tracy Fu and the issue had returned, i’ve tried to contact Tracy to no avail but i thought i’d let ya’ll know what i found, anyone hears of a fix, let me know, eddbot
well done mate! it worked a charm
Hey, You are the bestest i tell ya.
I don’t know when this was originally posted, but this still worked for me. I switched from my own host to a Freehostia account and I had this error.
Thank you.
Hi it work for me but no longer administrator….
Ah, I spoke too soon. Same thing as Pera; no longer an admin.
Found it. In the [your_prefix]usermeta table there are keys that link to tables. If you’ve changed your table prefixes these will now be broken. Just change the keys to match your prefixes. Webbhotell gave me the hint but he’s still using the wp_ prefix, so that threw me off.
OK my solution I added feild in wp_usermeta
like this
4 1 wp_capabilities a:1:{s:13:”administrator”;b:1;}
The first “4” umeta_id must be unique..
Worked for me in 2.9.2. Thanks so much!
Hey, that worked for me! I was changing the WP_ prefixes manually, and went to log in, and I had no access. Found this online, gave it a shot, and now Im back! THANK YOU!
Excellent. Thanks so much 🙂
You make my work it easy and not loose my page.
you are very helpful.Code work very good.
Awesome it’s Work for me with WordPress 3.0 Beta THX!
Hey Mark,
It only worked kind of.
I can now login but even though I’m administrator it doesn’t seem to think I am the administrator.
Is there anyway I can force my user account to get administrator privileges?
MARK! YOU ARE A ROCK STAR!!
This worked perfectly for me and allowed me into my dashboard.
For anyone still reading this far down that found they could get into dashboard but no longer had admin priviledges – you will have to go through your host to administer your wordpress database – my host uses phpMyAdmin.
“Browse” the wp_usermeta table and if it has more than one entry for wp_capabilities, delete the extras, keeping one.
THEN, edit the remaining wp_capabilities – it will probably say ‘subscriber’ but change to exactly this:
a:1:{s:13:”administrator”;b:1;}
Save your changes and try logging into your dashboard again. Good luck, all!
Hey Julie,
I tried to do what you said but it just went back to the same page as at the start, “You do not have sufficient privileges to access this page.
Anyone have any ideas?
Jordan
omg…thank you so much!
I was literally pulling my hair out
this fixed whatever the problem was
thanks again
This is the problem with open source scripts: too many changes, upgrades, etc. lead too all kinds of incapatibilities, and the guys doing the programming don’t seem to care.
it resolved my problem for WORDPRESS 2.9.2 too!
thank you very much!
thanks a lot man!! you saved me!!!
thanks you very i much…for you tips help for fix my blog 😀
Sadly it didnt work for me 😦 . and i cant mess with DP stuff . HELP!!!!
Thank you so much… I tried it with my fresh wp 3.0 (that was broken because of the “wp_” to “wp_xxx” renaming) installation and it worked!
Thank’s again 🙂
Alex
It didn’t work 100% for wp 3.0, the admin account had after executing the force-update.php no privileges to see Plugins & the Widget Panel. Finally I had to modify the mysql db directly …
But anyway, thanks for sharing 🙂
Alex
Unbelievable. It works for wp 3. Thank you very much.
If you have problems with plugins, go to cpanel and change the name of the plugins folder to anything and create a new folder called plugins. Then go to admin of your blog and click on plugins. All the plugins will then be deactivated. Go back to cpanel and delete the empty plugins folder. Rename the original plugins folder back to plugins.
It worked for me. Thank you Mark.
hey!! I did what you said and it works, now I can login and see everything, now I have to activate all plugins and check which was causing the error.. thanks so much! 😉
Thanks sooo much. This happened a few times to me…just renaming the folder…cherry!
Antonio
😦 it did not work for me … thanks anyway
in one word, THANKS!
any idea if it also works for the upgrade to 3.x?
The problem formed after going back from the automatic upgrade to 3.0. I could not access the parts to edit the themes stuff, so i tried going back to 2.9, and that caused the problem.
Anyway, with not going to 3.x, at least i can now work on my site again, GREAT !!!
My website still doesnt work, this error still there. I tried many ways. Before the error I activated “Contact Commenter” Plugin and I am not solving this problem. Please Help me
Suddenly… nothing happened. Oh well, thanks anyway.
mani thanks ! xD
Check to see if you have Publish 2 ping.fm installed. If so, deactivate it and then try initiating a campaign. Chances are, this will fix the problem.
Best of luck.
BMU
great solution it worked for me
I have used it for my site.. but all in vain..
u can check it by logig in …
user name >> abrahamciwolski
password >> abrahamciwolski
Please provide me solution..
You little ripper, thank you so much. Many hours wasted on this issue, though I believe you have saved me many more….
Best Software Downloads and Reviews. the most comprehensive source for free-to-trysoftware downloads on the WebBEST 4 DOWNLOADS
Best you could make changes to the webpage name WordPress Error: You do not have sufficient permissions to access this page Mark on WordPress to more generic for your blog post you create. I enjoyed the blog post yet.
I cant get it to work anyway..
Such a amazing script. Its work for me. Thanks so much for the assist.
Thanks Buddy.. really great script.
Thanks again Mark. Seems when I went to manually update the prefix on all my tables and then change a few common database fields that there are still things left out.
Wish that WP would just include an easy option to change the prefix of the tables from the Admin CP.
Its really great script. Now my site was live. Thanks my friend.
Ummm.. well I guess I was lucky; the Apture plug-in caused this problem for me.
Hey, guys i have created a plugin that displays some tabular data and has some pagination on it. When i click to navigate throught the data via the pagination i get the following message You dont have sufficient permission to access this page. Any suggestion will be more than appreciated.
Thanks in advance.
thanks guys,nice information
thanks for sharing. i’ve problem during installation plugin. and solved after force upgrade.
Cole haan kindle cover
Yehey!!! this really work!!!
i do not usually post thanks but this php upgrade worked first time. you are a fucking genius thanks you so much :D:D:
Your instruction rocks! It fixed the problem in Admin right away. Awesome! can’t be happier. Thank you so much for helping the community.
This worked for me. I had this issue after updating to 3.0.4. I tried several things. I even tried re-triggering the install, changing the prefix to prompt install.. none of that worked.
This script worked perfectly.
I am to believe in my case, the automatic upgrade featured failed and did not finish the upgrade. Either due to a system timeout or as simple as a network connection failure.
THANK YOU!!!! I have been reading various posts/forums for hours and the script you wrote is what finally fixed the problem. I was getting the “you don’t have sufficient permissions” error when clicking on “overview” in the nextGen Gallery plugin. This error also resulted in not being able to dictate the gallery layout. ie the number of image columns.
Thank you again!
Hello there! This is my first visit to your blog! We are a team of volunteers and starting a new project in a community in the same niche. Your blog provided us beneficial information to work on. You have done a outstanding job!
Fantastic, thank you for sharing! J
OMG
Help guys. I have 3 blogs, 2 are OK.
However on my most important one: First wouldn’t accept password. Got new password via email. Entered it with User name.
Received “dot not have sufficient . . . etc. message.
I’m not at all techie, and don’t understand most of the stuff above.
Sorry for being a dum dum, but I really ned a step-by-step fools guide. Can anyone help – please?
Alan
thanks a million. you’re a star. I had copied my website to the live server and was getting ‘you do not have sufficient permissions to access this page’ error when trying to access wordpress admin. Ran the force-upgrade and all is good now
thx 4 sharing,,, sometimes that’s occur on my blog,,
thank you so much for sharing this. it’s really helpful… ^_^
Brilliant! Worked like a charm, despite having been made five years ago! Thanks. 😀
Excellent job! Thanks / Tissy
Brilliant! Worked like a charm, despite having been made five years ago! Thanks. kopas news
Worked for me, Thanks a ton.
oha
Faild 😦
Warning: require(wp-config.php) [function.require]: failed to open stream: No such file or directory in /home2/depietri/public_html/temiwordpress/wp-content/plugins/force-upgrade.php on line 27
Fatal error: require() [function.require]: Failed opening required ‘wp-config.php’ (include_path=’.:/usr/lib64/php:/usr/lib/php:/usr/share/pear’) in /home2/depietri/public_html/temiwordpress/wp-content/plugins/force-upgrade.php on line 27
http://www.temiwordpress.net/wp-content/plugins/force-upgrade.php?step=1
Look at the instructions again. It’s not a plugin. It needs to be uploaded to the WordPress root directory, the one that contains wp-config.php.
hooray!
it even worked for wp 3.2.1. however my role had been reset to ‘subscriber’ afterwards … (still better than not being able to access the admin-area at all – set your ‘capabilities’ in ‘usermeta’ in your db to ‘a:1:{s:13:”administrator”;s:1:”1″;}’ if the same happens to you)
OH MY GOD!!!!!!!!! THANK YOU SO MUCH, BROTHER. I JUST ABOUT HAD A HEART ATTACK!
Awesome! Genius! Thankssss!!!!!
Thanks so much for the assist
Thank you very much for helping me clear up this error. I can see by the amount of replies it’s helped a lot of others as well!
Wow, thank you! Amazing how this post if from 2006 yet the solution still works for WordPress 3.2.1
Correction, it seemed to remove permissions so despite not seeing the “You do not have sufficient permissions to access this page.” message I couldn’t actually access any functionality through the admin panel… Is there any other solution available?
Your blog provided us beneficial information to work on. Thank You for sharing
there probably is a better way to solve this, see http://wpml.org/2010/06/fixing-you-do-not-have-sufficient-permissions-to-access-this-page/
Thank you!!!!!!!
I cannot thank you enough, been working on this for like 8 hours now. I think this was the last of all the potential solutions on the entire internet.
Thanks!
Man, LOVE you for this, saved my day. Thank you, thank you.
hi,
it’s not working for me…
can you help me……
i want to create a plugin for users&admin to view a form & submit values to database……….
plz help me…….
Oh god! You saved my day. Hey. Mark thank you so much The trick worked for me 🙂
exactly what I was searching for! thx
Thank you… this is wat i was searching for..
i did as it was shown , but still im having the same problem …You do not have sufficient permissions to access this page.
actually im creating a simple plugin , but when im clicking from the admin pannel , its showing that error