In the application that i’m improving, i would like to implement breadcrumbs so that the user can always go back even more than one page; i used some variables (with session) that i set every time the user opens a view from the previous one and it seems work well.
Some views, however, are in common, so it happens that the path also includes what it don’t need. I would need to reset the variables when the user makes the choice from the menu (navbar), so that the breadcrumbs are correct, but I can’t intercept these commands; i tried from SiteController (in beforeActions()), but the navbar commands don’t go through there; other solution may be duplicate views, but i don’t like.
Any suggestion ?
I also read and try these articles to see if they could help: Breadcrump widget and Auto breadcrumbs but i can’t get them to work; one go in error in view for “$this->widget” and the second for “getTitlePage()”.
Maybe because I’m using Yii2 ?