Skip to content

Instantly share code, notes, and snippets.

@ChrisFrench
Created December 10, 2014 15:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ChrisFrench/5b648b22b6ab2d1da4ed to your computer and use it in GitHub Desktop.
Save ChrisFrench/5b648b22b6ab2d1da4ed to your computer and use it in GitHub Desktop.
<?php
namespace Api\Site\Controllers;
class Menu extends Auth {
public function getMenu() {
$array = $this->getInputs();
$user = $this->app->get ( 'user');
$results = $this->app->get('results');
//do some ACL LOGIN etc to build a menu based on this user and the optional event
$menu = array();
$menu[] = array('title' => 'Profile', 'http://ryst.cc/user');
$menu[] = array('title' => 'Wristbands', 'http://ryst.cc/user/wristbands');
$results['result'] = $menu;
$this->app->set('results', $results);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment