PHP code example of cmatosbc / oopress-menus
1. Go to this page and download the library: Download cmatosbc/oopress-menus library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
cmatosbc / oopress-menus example snippets
// Create the instance for "menu-1" menu
$menuData = (new \Oopress\Menus\Fetcher('testing'))
->fetch()
->getItems(true); // Fetches menu data and returns the data in JSON (or array if not TRUE)