how to pass parameters in breadcrumbs

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

how to pass parameters in breadcrumbs

Coiby
This post has NOT been accepted by the mailing list yet.
This post was updated on .
Hi all,
I have a problem about Zend_Navigation. When visiting {base_url}/site/edit/9, breadcrumbs show nothing. My config file(xml) for Zend_Navigation is as follows:
...
<site-edit>
                <label>Edit a site</label>
                <controller>site</controller>
                <action>edit</action>
                <resetParams>0</resetParams>
                <params>
                <sid>0</sid>
                </params>
</site-edit>
..


If change it to:
...
<site-edit>
                <label>Edit a site</label>
                <controller>site</controller>
                <action>edit</action>
                <resetParams>0</resetParams>
                <params>
                <sid>0</sid>
                </params>
</site-edit>
...


then there's an error:
Uncaught exception 'Zend_Controller_Router_Exception' with message 'sid is not specified' in /var/www/webguide/library/Zend/Controller/Router/Route.php:354 Stack trace: #0 /var/www/webguide/library/Zend/Controller/Router/Rewrite.php

How to solve this problem?

Thanks!
Reply | Threaded
Open this post in threaded view
|

Re: how to pass parameters in breadcrumbs

Marco Pivetta
Well, your rewrite router simply doesn't know where to put the sid parameter... Strip it :)
Marco Pivetta

http://twitter.com/Ocramius     

http://marco-pivetta.com    



On 19 March 2012 13:38, Coiby [via Zend Framework Community] <[hidden email]> wrote:
Hi all,
I have a problem about Zend_Navigation. When visiting {base_url}/site/edit/9, breadcrumbs how nothing. My config file(xml) is as follows:
...
<site-edit>
                <label>Edit a site</label>
                <controller>site</controller>
                <action>edit</action>
                <resetParams>0</resetParams>
                <params>
                <sid>0</sid>
                </params>
</site-edit>
..


If change it to:
...
<site-edit>
                <label>Edit a site</label>
                <controller>site</controller>
                <action>edit</action>
                <resetParams>0</resetParams>
                <params>
                <sid>0</sid>
                </params>
</site-edit>
...


then there's an error:
Uncaught exception 'Zend_Controller_Router_Exception' with message 'sid is not specified' in /var/www/webguide/library/Zend/Controller/Router/Route.php:354 Stack trace: #0 /var/www/webguide/library/Zend/Controller/Router/Rewrite.php

How to solve this problem?

Thanks!



If you reply to this email, your message will be added to the discussion below:
http://zend-framework-community.634137.n4.nabble.com/how-to-pass-parameters-in-breadcrumbs-tp4484617p4484617.html
To unsubscribe from Zend Framework Community, click here.
NAML