On Mon, 9 Nov 2020 at 09:33, [email protected] <[email protected]> wrote: > > Hi all, > > I'm doing a site and I'm trying to understand how navigation links works > between pages and output. I just try to link agenda pages with, for the index > : > > .. title: AGENDA > .. slug: agenda_index > > to my menu : > > NAVIGATION_LINKS = { > DEFAULT_LANG: ( > ("/index.html", "ACCUEIL"), > (( > ('/index', 'Index'), > ('/now', 'A présent'), > ('/older', 'Archives')), > 'AGENDA'), > ("/categories/", "Étiquettes"), > ), > } > > How do I declare the hierarchy in my pages ? In my folders ? > Is it the title, or the slug of page that has to be declared in my conf.py ? > What's the order I have to follow ? first create directly the folder "agenda" > ? > > I'm a great neophyte, but I really do my best, reading over and over the > handbook, but I'm really bad for this...
If you want /agenda/ and /agenda/now/ in output: 1. mkdir pages/agenda 2. Put the agenda index in pages/agenda/index.rst, use `index` for the slug 3. Also create pages/agenda/now.rst, use `now` for the slug 4. Make sure that your PAGES config will lead to agenda being placed in the site root (and not in a pages/ subdirectory) NAVIGATION_LINKS hierarchies are independent of any paths, so you need to specify '/agenda/' and '/agenda/now/' as the destinations. -- Chris Warrick <https://chriswarrick.com/> PGP: 5EAAEA16 -- You received this message because you are subscribed to the Google Groups "nikola-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/nikola-discuss/CAMw%2Bj7Kdr7jsjN%2BoX1DMam8rbTr_xm4iHkQjnphau2DodX-QvQ%40mail.gmail.com.
