Users getting access to Who Sees Ads through widget

Hi, I am a bit confused at the moment. I have added the Who Sees Ads plugin and everything seems to work out just fine, but I can´t figure out why regular users get access to the WSA admin menu and settings by adding a sidebar widget containing a WSA context. Why does WSA contexts appear as widgets at all? And why should regular users be able to add such widgets? I thought WSA could only be administered by site admin? Adding a context widget gives any user the following instruction when he/she clicks to edit the widget: “Configure and set up display rules on the Who Sees Ads administration page”, and “Who Sees Ads” is actually a link leading to admin settings not only for WSA but also other plugins inside the MU-plugins folder. Any ideas on how I can remove the widget-function of WSA? I don’t want regular users possibly messing with the admin settings… :slight_smile:

  • monis
    • New Recruit

    Yes, I have tried logging in with two different user accounts – I’ve been logged out of the admin account while testing with the regular user accounts. Are regular users by default not supposed to see widgets for ads? Or are they just not supposed to get access to the admin menu like they do in my install?

  • Andrew
    • Champion of Loops

    Hiya,

    Open up wp_ozh_whoseesads.php and comment out line 848:

    add_action(‘widgets_init’, ‘wp_ozh_wsa_widgetize’:wink:;

    You can also do this via the options file you can setup for WSA. However, I’ve always found that to be a bit flaky so I just comment that line out.

    Thanks,

    Andrew

  • monis
    • New Recruit

    Thanks Andrew! That did the trick :slight_smile: I tried to remove parts of the widgetcode in the bottom of the file earlier, but received error messages after doing it. Commenting out that exact line worked perfect. Great!