ThemeForest

You do not have sufficient permissions to access this page.

47 posts
  • Has been a member for 2-3 years
  • Bought between 1 and 9 items
virgild says

Has anyone stumbled across this issue in Wordpress?

I followed this tutorial

http://wpshout.com/create-an-awesome-wordpress-theme-options-page-part-1/

to add a background color option to my theme options. It registered the new arrays but now when I click “save changes” in my theme options I get the “You do not have sufficient permissions to access this page.” message..

The new options are saved in the theme, but I get that message each time. I tried deleting the new theme arrays and I still get the error. Then I tried the theme on a new database and I have the same issue.

I haven’t tried deleting the new arrays and then uploading the theme on a new database. I’m really not sure what is causing this.. I;d really appreciate any kind of help!

2 years ago
53 posts
  • Has been a member for 3-4 years
  • Exclusive Author
  • Sold between 50 000 and 100 000 dollars
  • Bought between 50 and 99 items
  • New Zealand
  • Referred between 1 and 9 users
templateup says

you should have a line similar to this

add_theme_page("", "Theme Options", 'edit_themes', basename(__FILE__), 'themeopt_admin');

the “edit_themes” parameter has to match your role, so if it’s edit_themes your role MUST be administrator.

You can find all the roles and capabilities here http://codex.wordpress.org/Roles_and_Capabilities

2 years ago
47 posts
  • Has been a member for 2-3 years
  • Bought between 1 and 9 items
virgild says

Yup I have that line and it matches yours. The options worked before.

I deleted the new theme options and uploaded to a new database and.. I still get the error. At this point I have no idea what could have caused it..

The last things I added to my theme was @font-face and before that some multiple loops on my homepage.. this is weird :-(

2 years ago
47 posts
  • Has been a member for 2-3 years
  • Bought between 1 and 9 items
virgild says

Ok, I fixed it! :-) Mid developmet I decided to revise my functions.php into this:

<?php include (TEMPLATEPATH . '/theme_base.php'); include (TEMPLATEPATH . '/sidebar_widgets.php'); ?>

My idea was to keep everything organized and I haven’t tinkered the options since..

Apparently that restricts admin permission when you try to edit the options. I guess I have to keep my arrays on my functions.php.

sorry for the double post!

2 years ago
by
by
by
by
by