Title: Custom code not working
Last modified: January 20, 2018

---

# Custom code not working

 *  [vickigarside](https://wordpress.org/support/users/vickigarside/)
 * (@vickigarside)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/custom-code-not-working-2/)
 * Hi team
 * I have a menu item (sitemap) that I need to hide from the navigation bar. I have
   asked about this previously and was provided with a little bit of custom code
   to add into the CSS and that solution worked on the homepage ([https://wordpress.org/support/topic/remove-page-from-navigation-bar/](https://wordpress.org/support/topic/remove-page-from-navigation-bar/))
 * But I’ve noticed it doesn’t work for newly created posts – the page in the example
   is new and when I load it it shows the ‘Sitemap’ option as the second menu item.
   
   Is there any way I can remove this for all posts as well as pages?
 * Thank you
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fcustom-code-not-working-2%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 1 replies (of 1 total)

 *  [sacredpath](https://wordpress.org/support/users/sacredpath/)
 * (@sacredpath)
 * Automattic Happiness Engineer
 * [8 years, 4 months ago](https://wordpress.org/support/topic/custom-code-not-working-2/#post-9907197)
 * Hi there, let’s change the CSS selector on the CSS you previously received a 
   bit. Replace what you have with the following.
 *     ```
       #site-navigation .page-item-7294 {
           display: none;
       }
       ```
   

Viewing 1 replies (of 1 total)

The topic ‘Custom code not working’ is closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/sela/1.0.17/screenshot.png)
 * Sela
 * [Support Threads](https://wordpress.org/support/theme/sela/)
 * [Active Topics](https://wordpress.org/support/theme/sela/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/sela/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/sela/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [sacredpath](https://wordpress.org/support/users/sacredpath/)
 * Last activity: [8 years, 4 months ago](https://wordpress.org/support/topic/custom-code-not-working-2/#post-9907197)
 * Status: not resolved