Menu in Accordion example

This is an accordion element with a series of buttons that open and close related content panels.

Funding Navigation

[menu name=”Funding”]

CESP Navigation

[menu name=”CESP”]

This pages uses a custom function that allows us to insert a menu into a editing field via a shortcode. This is one way to provide navigation menus in sections of content, without having a dramatic impact on the page layout, as happens when a very long column block is rendered next to a shorter neighboring column.

Because the accordion renders in a collapsed state by default, the vertical length of the menu is apparent only when it is expanded.

There are probably some usability ramifications, and possibly accessibility as well.

The required code is in functions.php and was cribbed from an online source.  It’s only 15 lines.