This is an old revision of the document!
Make your plugin compatible to Admidio 4
New menu calls
In Admidio 4 we have changed the way the menu is structured. For this you have to change your plugin if you have worked with $page→getMenu(); before.
Now you don't have to create an instance of the menu to add the single entries there. Also there is now a simple function to add a back button to the page.
So far you had to do the following steps for the back button:
$page = new HtmlPage('My Headline'); $myMenu = $page->getMenu(); $myMenu->addItem('menu_item_back', $gNavigation->getPreviousUrl(), $gL10n->get('SYS_BACK'), 'fa-arrow-circle-left');
Now it's only necessary to call the following function:
$page = new HtmlPage('My Headline'); $page->setUrlPreviousPage($gNavigation->getPreviousUrl());