Forum

Thread tagged as: Question, Problem, Error

Navigation From Pages

I am redesigning a site and somehow I think the database has got confused. I have moved the page that was formerly the index page.

I am using this for the navigation for both the site that resides at the index and a microsite at /photography/index

<?php perch_pages_navigation(array(
        'from-path' => '/services',
        'levels'    => 2,
        'hide_extensions' => true,
        'template'  => array('submenu-level-1.html', 'submenu-level-2.html')
    )); ?>

Both sections have their own layout for the navigation, yet the pages shown in the menus both follow the /photography microsite.

I really don't want to have to delete it all and start again. Is there any way to edit the database to fix the glitch. It seems to be finding the page path from the subdirectory for both.

Nigel Coath

Nigel Coath 1 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

I'm not clear - is it the from-path setting that isn't working?

The paths for index/services/... are showing the paths for photography/services/...

For example there are two pages inside photography/services/ and these are showing for both directories.

So for www.domain.com/ the menu shows the same paths as www.domain.com/photography/

I think my issue might be to do with the navigation code.

How do I achieve this:

'from-path' => '/photography/services' as it does not seem to work, my navigation is a level down

If I try this it displays all urls from the root.

If I try 'from-path' => '/photography' I get a level above where I want to be.

Drew McLellan

Drew McLellan 2638 points
Perch Support

Can you show me what the debug outputs from that?