I'm trying to add a "Click here to edit this page" button in some Wordpress pages.
This button should only appear if the user is admin, this is the code that should appear if the user is admin:
if ( current_user_can( 'manage_options' ) ) {
<div class="action">
<div class="pe-container"><section class="row-fluid">
<div class="span12">
<h5>To edit this page <a href="wp-admin/post.php?post=179&action=edit">CLICK HERE <i class="icon-right-open-mini"></i></a></h5>
</div>
</section></div>
</div>
} else {
return false;
}
This code outputs this: