e107sk.com

Content Category Page/Menus

Page/Menus

Stuff related to core page/menu system

BOOK_CHAPTERS shortcode on 14 Jul 2020

Render All visible Chapters from a specific Book.

Uses "listChapter" template key. ie. $CHAPTER_TEMPLATE[---TEMPLATE --]['listChapters']

{BOOK_CHAPTERS: name=book-sef-url}
{BOOK_CHAPTERS: name=book-sef-url&template=xxxxx&limit=3}

$parm['name']
$parm['template'] - $tmplKey = varset($parm['template'],'panel');
$parm['class']
 

CHAPTER_MENUS shortcode on 14 Jul 2020

Render All visible Menus from a specific chapter. Very often used for portfolio on homepage.

{CHAPTER_MENUS: name=chapter-sef-url}
{CHAPTER_MENUS: name=chapter-sef-url&template=xxxxx}

$parm['name']
$parm['template'] - overrides value ['menu_template']
$parm['class']
$parm['active']
$parm['limit']

Example for 2 cycles:

{CHAPTER_MENUS: name=portfolio&template=portfolio}
{CHAPTER_MENUS: name=portfolio&template=portfolio-modal}

CMENU shortcode on 14 Jul 2020

 {CMENU=feature-1}

Renders a menu called 'feature-1' as found in the e107_page table

 Templating:  template key "nav" +  'showPage' in chapter_template.php

 Using:

- in Menu Manager: the only caption can be set, it always displayed all chapters + pages  (template nav is used), but shortcode is used for rendering (good)

- as a shortcode: - 

{PAGE_NAVIGATION: template=navdoc&auto=1}
{PAGE_NAVIGATION: chapter=4}
{PAGE_NAVIGATION: book=3&pages=true}

 

this shortcode uses e_sitelinks addon 

Chapter Menu on 14 Jul 2020

 Templating:  template key "panel" in chapter_template.php

 Using:

- in Menu Manager: the only caption can be set, it always displayed all chapters with template panel

- as a shortcode: - parameter book is available, so you can display only chapters/pages from one book, but again, chapters have to have template "panel" 

It has no logic...  not mention you need to know book ID . And there is hardcoded 24 items limit.

Example:

{MENU: path=page/chapter&book=7}

You can display only chapter shortcodes. No page/menus list. 

Next notice: as soon as you use panel template for book, this menu will fail.

 The menu is not working, see the issue

Other links

Follow us