0

We need to build a help page similar to Wordpress Developer Resources (see the screenshot below). We're problably looking for a developer solution as we haven't found any plugin that would fit our needs but we're open for suggestions.

We're using Twenty-sixteen theme with some customisations.

On the help pages we need to have sidebar menu/list of help articles. We need to be able to manage the order of the list. When a user clicks on one of the links we would display the article and mark the link in the sidebar menu.

We thought about using ACF to create a list of links so it's easily maangeable by our admin but how do we mark currently clicked position on the list?

Also, should we use custom post type for that and a template?

enter image description here

2
  • the dev hub handbook theme is opensource, as are all the plugins that were used to set it up ( they're all hand made specific for the dev hub ), keep in mind though that there's currently extensive redesign and reworking going on. As this isn't a forum though you need a specific question, something I could write an answer for that could be marked as factually correct if it answers it, and it need to be a single question not a collection of questions. Can you edit this to fit the sites format? If you're asking how to create an ordered list of pages though wouldn't a standard nav menu work?
    – Tom J Nowell
    Commented May 7 at 11:56
  • Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer.
    – Community Bot
    Commented May 13 at 17:35

2 Answers 2

0

Looks like it can be fairly trivially achieved with a hierarchical custom post type and a menu widget in the sidebar. Menus come with current page CSS classes out of the box that can be styled as you require.

0

We figured it out by simply using calling Wordpress menu functions

First we need to register menu in functions.php

function wpb_custom_help_page_menu() {
    register_nav_menu('help-page-menu',__( 'Help Page Menu' ));
}
add_action( 'init', 'wpb_custom_help_page_menu' );

Then call the registered menu in page template

<?php
    wp_nav_menu( array( 'theme_location'=>'help-page-menu', 'menu_class'=>"help-page-menu" ) );
?>

Remaining part is simply configuring the menu via the Wordpress UI (Appearance -> Menus). We had to create a menu with the same name as we used in the code. No custom Post Type was needed. It's nice because Wordpress applies classes to the current menu item so you just need to style it with css

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.