PHP code example of cube-agency / arbory-menu

1. Go to this page and download the library: Download cube-agency/arbory-menu 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/ */

    

cube-agency / arbory-menu example snippets

  
Admin::modules()->register(\CubeAgency\ArboryMenu\Http\Controllers\Admin\MenuController::class);
sh
$ php artisan migrate
sh
    public function mainMenu(): BelongsTo
    {
        return $this->belongsTo(\CubeAgency\ArboryMenu\Menu\Menu::class);
    }
    
sh
    public function compose(View $view): void
    {
        ...
        $view->with([
            ...
           'mainMenuItems' => $languageNode->content->mainMenu->getPreparedItems()
        ]);
    }