public function getNav($handle, $params, $locale = null)
{
$navigation = $this->getNavigationByHandle($handle);
// Check for a missing nav and report the error appropriately
if (!$navigation) {
$e = new Exception(Craft::t('No navigation exists with the handle “{handle}”.', array('handle' => $handle)));
if ($this->_isQuietErrorsEnabled()) {
Craft::log('Error::', $e->getMessage(), LogLevel::Warning);
return $navigation;
} else {
throw $e;
}
}
$this->_navigation = $navigation;
// We want correct URLs now
$this->_parseEnvironment = true;
// Get the params
$this->_setParams($params);
// We want HTML returned
$this->_parseHtml = true;
// Return build HTML
return $this->getNodesByNavigationId($navigation->id, $locale);
}