Restrict access only to admin users
-
Hi, great plugin!
Is there any hook I could use to somehow restrict access to the API docs pages only to administrators? for time reasons I added the following directly on the simple template file:
<?php /* Template Name: Restricted to Admin only */ if ( !current_user_can('administrator')) { get_template_part('error'); exit(0); } ?>
But I know I shouldn’t modify the plugin directly. Is there anything else I could do?
Thank you!
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Restrict access only to admin users’ is closed to new replies.