This has been annoying me for ages as im not used to WordPress and not being able to specify what menu a page shows in and where.
So if you want a page to not show in your main menu but as a footer link or something you can use this code.
- Make your page and preview it to get the page id number, then publish it for now.
- Go to your editor and find the php file with the navigation code, usually header.php
- Find this bit of code or something similar –
- Where I’ve put the x is where you put the page id that you don’t want to show in your main WordPress menu.
- If you have a few pages that you don’t want in the main menu you can do this –
li=&exclude=34,96,100'where 34, 96 and 100 are the page id’s.
Perfect for Terms & Conditions, Privacy Statements and Help links in site footers.