Title: CSS hook for current page
Last modified: August 31, 2016

---

# CSS hook for current page

 *  Resolved [eric3d](https://wordpress.org/support/users/eric3d/)
 * (@eric3d)
 * [10 years, 4 months ago](https://wordpress.org/support/topic/css-hook-for-current-page/)
 * When using show_current_page, I would like a CSS hook so I can highlight the 
   current page in the list. The following additions seem to work and I would like
   to see them integrated in the next version.
 * beginning of public static function show_child_pages( $atts ):
 *     ```
       global $post;
       $current_id = $post->ID;
       ```
   
 * in the loop (around line 360):
 *     ```
       if ( $id == $current_id ) {
       	$page_class .= ' cccurrent';
       }
       ```
   
 * Thanks.
 * [https://wordpress.org/plugins/cc-child-pages/](https://wordpress.org/plugins/cc-child-pages/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [caterhamcomputing](https://wordpress.org/support/users/caterhamcomputing/)
 * (@caterhamcomputing)
 * [10 years, 3 months ago](https://wordpress.org/support/topic/css-hook-for-current-page/#post-7047660)
 * Hi Eric … sorry not to have replied sooner but I’ve not been around for a while.
 * This is a great idea and I’ll certainly look at adding this functionality to 
   the next release, and I will look at adding other CSS hooks for parent, sibling,
   etc. while I am at it.
 * Thanks for your input.
 *  Plugin Author [caterhamcomputing](https://wordpress.org/support/users/caterhamcomputing/)
 * (@caterhamcomputing)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/css-hook-for-current-page/#post-8584894)
 * The new version of the plugin has just been released.
 * The classes `active`, `current-page` and `cccurrent` are now added to the `childpage``
   <div>` when displaying the current page.
 * I hope that this helps.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘CSS hook for current page’ is closed to new replies.

 * ![](https://ps.w.org/cc-child-pages/assets/icon-256x256.png?rev=3451096)
 * [CC Child Pages](https://wordpress.org/plugins/cc-child-pages/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/cc-child-pages/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/cc-child-pages/)
 * [Active Topics](https://wordpress.org/support/plugin/cc-child-pages/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/cc-child-pages/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/cc-child-pages/reviews/)

## Tags

 * [current page](https://wordpress.org/support/topic-tag/current-page/)

 * 2 replies
 * 2 participants
 * Last reply from: [caterhamcomputing](https://wordpress.org/support/users/caterhamcomputing/)
 * Last activity: [9 years, 5 months ago](https://wordpress.org/support/topic/css-hook-for-current-page/#post-8584894)
 * Status: resolved