/ Published in: PHP

Down & Dirty Wordpress code to show specific links only to admininstrators. Can be refined using WP roles and Capabilities for more specific needs.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<?php if (current_user_can('manage_options')){ ?> <a href="/wp-admin">Dashboard</a> - <?php wp_loginout(); ?> <?php }?>
URL: http://codex.wordpress.org/Roles_and_Capabilities
Comments
