Support » Plugin: Content Aware Sidebars - Unlimited Widget Areas » Add New Sidebar -> “Sorry, you are not allowed to access this page.”

  • Resolved Larry Daniele

    (@larrydaniele)


    I’m on an up-to-date system with WordPress 5.0.3, PHP 7.2.6, Content Aware Sidebars 3.7.7.

    When I go to Appearance > Widgets and click “Add New Sidebar”, I am redirected to the URL:

    https://www.holycowonlinemarketing.com/wp-admin/admin.php?page=wpcas-edit

    where I get the message:

    Sorry, you are not allowed to access this page.

    I have no problem access anything else in the Admin menus, so I don’t believe there’s a general problem.

    I don’t see any rule in .htaccess that would be a problem.

    I don’t see any messages in the debug.log file that are relevant.

    There is no PHP error log (but PHP error logging is on).

    I have tried deleting and re-installing the CAS plugin. That did not help.

    What should I check/do next?

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author Joachim Jensen

    (@intoxstudio)

    Thank you for reporting this and for all the details.

    I have seen this issue reported a few times before, but have not been able to find the cause.

    Do you by any chance use any role manager or capability plugins?
    Do you use WordPress multisite?

    Content Aware Sidebars requires the admin to have the edit_theme_options capability to manage widget areas. This is a core capability that ought to be available to admins by default.

    Larry Daniele

    (@larrydaniele)

    Thanks for looking into this again.

    The site is NOT a multisite installation.

    We are using the Avada theme. I have tried switching to the WordPress Twenty-Nineteen theme and that doesn’t help.

    We’re using the following potentially capability-related plugins:
    * Restrict User Access v1.0.1
    * Toolset Access v2.6
    * WordPress Access Control v4.0.13
    * WPFront User Role Editor v2.14.2

    Even with all these plugins deactivated, the problem persists.

    I deactivated all plugins except CAS and the problem still occurs. So it appears to be something fundamental in the plugin / WordPress itself.

    I looked again in debug.log and php-errors.log. Nothing relevant (or recent / repeated).

    I looked at the code in sidebar-edit.php and don’t see anything obviously wrong there. Also, the “Sorry, you are not allowed to access this page.” does not appear to belong to CAS, so I’m not sure we’re even getting to the sidebar-edit code. That seems like a clue.

    Any further debugging advice would be appreciated. Also, I could clone the site if you wanted to try debugging it on a non-live site.

    Larry Daniele

    (@larrydaniele)

    I’ve also tried using a different (rarely used) administrator account and that didn’t resolve the problem either.

    Plugin Author Joachim Jensen

    (@intoxstudio)

    Thank you for the info. I see a plugin to edit user roles, is it possible that the admin role is either missing
    1) edit_theme_options, or
    2) capabilities such as add_sidebar, edit_sidebar etc?

    The error message is provided by WP itself when users are missing a specific capability.

    Usually deactivating user role editor plugins will not “reset” roles back to default, which might explain why deactivating the plugins don’t solve the problem.

    Our Administrator role has “edit_theme_options” checked.

    There are no capabilities such as “add_sidebar” or “edit_sidebar” listed. And I searched all the PHP files within the installation (i.e. WordPress and all plugins) and there are no occurrences of “add_sidebar” or “edit_sidebar” used for capabilities (i.e. no “current_user_can( ‘add_sidebar’…)”. As expected, there are many occurrences of “current_user_can( ‘edit_theme_options’…)”.

    Adding the “add_sidebar” or “edit_sidebar” capabilities did not resolve the problem (so I removed them again).

    Since this appears to be a fundamental (WordPress?) problem getting to the URL “/wp-admin/admin.php?page=wpcas-edit”, I’m wondering what conditions could cause the error within WordPress. I looked on the disk and as expected, all the permissions for the PHP files seem correct and the same as for any other plugin files.

    Same problem, using none of the plugins mentioned above.

    Did you manage to find a solution to this?

    When I allowed the plugin to share data with freemius – it worked. And I was not able to get past that notice WITHOUT accepting. This is not good!

    Plugin Author Joachim Jensen

    (@intoxstudio)

    @ellegaarddk

    Thank you for reporting this.

    Did the permission problem happen after update, or did you install the plugin on a new site? What is your wp version?

    For the Skip issue, see: https://wordpress.org/support/topic/cannot-skip-shread-infos-with-frremius/

    formerfatguy

    (@formerfatguy)

    Thanks @joachim. The link you provided solved my issue as well. I had to accept that thing first before plugin “truly” activated. Now I have permissions to create sidebars.

    Same resolution (and sentiment) as @ellegaarddk

    OK, so I believe my original problem was because I got to the Freemius screen and did not opt in and could not press Skip. So I left it at this screen. It is this state that causes the “Sorry, you are not allowed to access this page.” error when trying to add a new sidebar.

    The work-around is to:

    1. Opt-in to Freemius (temporarily). (Click on “Content Aware” in the admin sidebar if you’re not at that screen.)
    2. Go to the Plugins page.
    3. On the “Content Aware Sidebars” item, click on the “Opt Out” link.

    Hopefully the fix would be to get the “Skip” feature to work correctly so we don’t have to opt in in the first place.

    Thanks to all for finding a path through this!

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Add New Sidebar -> “Sorry, you are not allowed to access this page.”’ is closed to new replies.