Archived topic
Navigation Menu Inside a Section
3 replies · Started by Mosche on September 3, 2015
I would like to know how I could get the Main Navigation Menu inside a container.
Working with sections is one of the greatest features of GeneratePress.
Is there a code I could use to get the navigation bar to show up inside a container?
You could try creating a shortcode (not 100% sure it will work).
function generate_navigation_shortcode() {
return generate_navigation_position();
}
add_shortcode( 'generate_navigation', 'generate_navigation_shortcode' );
Adding PHP: https://generatepress.com/knowledgebase/adding-php-functions/
Then you might be able to use the [generate_navigation] shortcode in your Sections.
Dear Tom,
Thank you for your quick response.
I was able to get the navigation inside of a section.
Although it didn't look good.
But as it turns out, the solution to the real problem I'm working on should be sought in the header.
But that should be in another topic.
I'll consider this question resolved.
I figured it might look a little weird - might be useful for others to know how to use it in a shortcode though.
Will be on the lookout for your other topic :)