zend-navigation

Inline Zend Navigation links in view content saved to db

I'm storing the page content in the database (both as markup and HTML code) and displaying this content in the view (let's say it's CMS or forum post). The this data have also some links to internal pages existing in sitemap (Zend_Navigation object). It's easy to insert the link in page body just by using <a> tag. But the contents of th...

Zend_Navigation with hidden pages

Hi, I have my Zend_Navigation loaded from a PHP array (but that's irrelevant...) and I'm using the navigation menu helper to generate a menu based on the loaded navigation. Some menu items must not appear in the outputted menu, so I simply set "'visible' => false" in my array for that page and there you go! But if the URL of an 'hidden' ...

Zend Navigation: current page

There is a method isActive() in Zend_Navigation. But it returns true for all the elements in the current path (parent li is active and all the children too, even when the current is parent li). Is there any method like isCurrent(), to determine whether the current menu item is the current page? I just like to add custom class attribute...

Zend Framework - how to apply icon in xml file and retriev it

When it load the xml file, the icon cause failure inside the label tags. How to fix it? // horizontal top menu <?xml version="1.0" encoding="UTF-8"?> <root> <nav> <page1> <label><img src='icon.icon' /> Page 1</label> <controller>index</controller> </page1> <home> <label>Home</label> <controller>...

Zend Navigation - Best Practices?

I would like to know how people use Zend_Navigation, what are the best practices to employ to get the most out of it? My company has built our last 2 major projects using Zend Framework, we have used a combination or Zend_Navigation the url view helper. Using the url view helper has caused lots over extra work when having to refactor c...

Zend Framework: Hide navigation item in menu by show in breadcrumbs

i am using Zend_Navigation i want to show the nav item in the breadcrumbs but hide it in my menu, how can i do that? ...

Zend Framework: Zend_Navigation menu links rendering bug?

i am having this scenario where when i goto a url like /posts/add, my menu items will all render posts/add. when i goto /posts its all right my nav config ...

Rendering Active Branch of Zend Navigation Without Top Level

I am rendering the top-level elements of a Zend Navigation object in one place like this: echo $this->navigation()->menu()->setMaxDepth(0); How do I render the navigation tree from the second level on down for the active branch? I've tried creating a partial that loops the $this->container object, but I don't know how to determine if...

How do i pass the PHP Dynamic variables in to the XML File

Iam trying to generate the menu and For that iam using navigation.xml (Zend Framework) Contents of navigation.xml(file) <?xml version="1.0" encoding="UTF-8"?> <config> <nav> <page1> <pages> <label>test</label> <uri>abc.php</uri> </pages><page1></nav></config> and in the controller iam reading the config.xml file as follows $con...

Zend Navigation and Zend Router problem - not finding correct active page

Okay. I'm building a CMS with Zend. It isn't as simple as it looked but still — the best solution for me. I have a tree system with ID and PARENT, PARENT marks under which page the child resides. Anyway. Simple stuff. Every time a page is created or sorted Nav & Routes are regenerated. I'll copy the whole Admin_Pages_Model code for cre...

Zend Naviation Menu View Helper - All links are the same??

heres my setup: http://www.example.com/&lt;module&gt;/&lt;controller&gt;/&lt;action&gt; I have this route defined: $router->addRoute( 'editUser', new Zend_Controller_Router_Route('admin/users/edit/:id', array( 'module' => 'admin', 'controller' => 'users', ...

Zend_Navigation add class to active link

How can I add a class to the active navigation link? If a link points to URI /index/index and the request URI is also /index/index, I would like the link to have class, for example: <li class="active"> <a href="/index/index">Index</a> </li> This is how I am initializing navigation in the bootstrap: protected function _initNavigat...

How to add a page inside some levels using Zend_Navigation?

I'm using a XML (click here to see) with Zend_Navigation to render this: which Menu Principal is the first level, then Home and Quem Somos, then the dropdown is the third and last level. I want this last list to be dynamic (querying from the database). I found out that I can use the method addPages($array) in order to dynamically rend...

zend headtitle using zend_navigation

I am using zend_navigation for creating menu. Which works fine. Now i m looking if i can take current page and set it as page title using headTitle. Is there is any way to do that? or how can i use config files (.ini) for creating Pagetitle and meta data ? ...

Zend Framework Navigation - dynamically adding parameters

Hello.. I am experimenting with Zend_Navigation to build breadcrumb for a web site. I created an XML file which lists the hierarchy of pages. Things are working fine for the most part except for pages that have dynamic parameters. For example, there is a group page which has the URL " www.../groups/gid/1001". The id 1001 is dynamic so i...

Zend Navigation - various navigation blocks

Hi, I have a navigation.xml file: <?xml version="1.0" encoding="UTF-8"?> <config> <nav> <programm_nav> <label></label> <uri>#</uri> <pages> <all> <label>test1</label> <resource>default:programme</resource> <module...

Zend Navigation - Url config problem

Hi, I store my navigation content in a navigation.xml file in the configs folder of my project. Basically I have two modules, the default module that deals with e.g. authentication and basic page usage and the admin module to admininstrate the website. When I sign in as admin a special admin navigation appears according to my acl and...

How does one register a non menu page with Zend_Navigation?

I have an access denied page, which should not be shown in menus. However, it's possible for the user to be redirected to the access denied page. I also have a breadcrumbs section on the page, and if you go to the access denied page, it shows as blank, which is extremely ugly. I would therefore like to register the page, but not have t...

Where do I create custom Navigation Containers?

In Zend's Documentation they write about creating Navigation Containers. But they don't explain where I should create them. Does anyone know that? I'm also wondering if a custom Navigation Container extends or overwrites the navigation.xml file which contains the static links. (I want to make a custom Navigation Container to add dyna...