This WordPress hack lets you use CSS codes to create a sliding door in navigation for your WordPress website. By default, WordPress core functions: wp_list_pages() and wp_list_categories() do not allow you to use the required span tag for this technique to work successfully. This hack will let you bypass this restriction and use sliding doors in your WordPress theme.
This hack will not let you modify WordPress core to apply this technique. Cores aren’t made to be modified and can cause a lot of headaches if you do it especially during WP update. The technique is done by using PHP. The php preg_replace() function is the trick to make this hack work in your WordPress theme.
Read full article here: http://wphacks.com/sliding-doors-wordpress-navigation-css-technique/