Title: Quick php-based question&#8230;
Last modified: August 19, 2016

---

# Quick php-based question…

 *  [rnmproductions](https://wordpress.org/support/users/rnmproductions/)
 * (@rnmproductions)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/quick-php-based-question/)
 * I’m currently using a code that goes like this…
 *     ```
       <?php
       global $user_login;
       get_currentuserinfo();
       if ($user_login && current_user_can('manage_options')){
       ?>
       (Insert whatever here)
       <?php } ?>
       ```
   
 * to hide a widget from public view/use. I currently use “manage options” as the
   qualifier on whether or not the user can see the widget, is there a way I can
   use whether or not the user has access to a certain page? I’m hoping to use this
   in conjunction with Wishlist Member plugin that I use that allows me to restrict
   certain pages for users.

The topic ‘Quick php-based question…’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [rnmproductions](https://wordpress.org/support/users/rnmproductions/)
 * Last activity: [16 years, 10 months ago](https://wordpress.org/support/topic/quick-php-based-question/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
