Posted By

gd6d on 11/03/09


Tagged

menu wordpress


Versions (?)

Add privates pages in navigation menus


 / Published in: PHP
 

URL: http://www.wprecipes.com/how-to-add-privates-pages-in-navigation-menus

  1. <ul>
  2. <?php
  3. wp_list_pages('depth=1&title_li=0&sort_column=menu_order');
  4. if(current_user_can('read_private_pages')) :
  5. ?>
  6. <li><a href="<?php echo get_permalink(10); ?>">For Authors only</a></li>
  7. <?php endif; ?>
  8. </ul>

Report this snippet  

You need to login to post a comment.