Jump to content

primary navbar


sawfly

Recommended Posts

Hi to all. I had a task to migrate old custom page (from 5th version) to 7th version. I have a problem with a primary navbar
I am getting navbar with 6 items in it

count(Menu::primaryNavbar()->getChildren()); // 6 

But on the site in the primary navbar, there are 7 items. I tried to check out in hook the code above and got 7; There is no 'affiliates' item in the navbar. Maybe someone knows how to get full primary navbar as in all pages on the site

Link to comment
Share on other sites

52 minutes ago, brian! said:

is your template based on Six or are you just trying to update an old v5 template for v7 ??

I don't know exactly. I checked out six/header.tpl and custom/header.tpl. They are alike. Earlier this page was on whmcs v5. After updating, the page had been broken, and I was asked to revive it. The page created not as in documentation to v7. For displaying I'm using WHMCS\Smarty->display(), previously setting in it all we need. I call display couple times. I added manually missed child to the menu, but I know that this is a wrong way

Link to comment
Share on other sites

18 hours ago, sawfly said:

I don't know exactly. I checked out six/header.tpl and custom/header.tpl. They are alike.

I assume they both have the navbar includes in them ?

18 hours ago, sawfly said:

The page created not as in documentation to v7.

that might not be helping the situation.... if your theme is based on Six (and if the headers are similar then that might be the case), then making the page using the docs method would be the simpler solution (as the navbar will then be added to all pages).

18 hours ago, sawfly said:

For displaying I'm using WHMCS\Smarty->display(), previously setting in it all we need.

times change. 🙂

18 hours ago, sawfly said:

I added manually missed child to the menu, but I know that this is a wrong way 

if it's only one custom page and you've now got it working, then I wouldn't worry about it... when the time comes for v8 and beyond, then you may have to change it again - but worry about that when the time comes, not now.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated