Overwriting autonav view.php in a package
Permalink
I am trying to overwrite view.php found in the directory.
It was my understanding that in my package I could add my own tweak of view.php file in but this does not seem to be the case.
I just want to overwrite the "selected" class from "nav-selected" to "active".
I don't want to edit the file in the concrete directory as some blog posts have suggested as this would break the site on updates and render my "theme" useless.
I am trying to change this as I am working with the "Header Nav" area.
This seems like it should be very trivial.
Thanks in advance.
concrete/blocks/autonav/view.php
It was my understanding that in my package I could add my own tweak of view.php file in
packages/my_package/blocks/autonav/view.php
I just want to overwrite the "selected" class from "nav-selected" to "active".
I don't want to edit the file in the concrete directory as some blog posts have suggested as this would break the site on updates and render my "theme" useless.
I am trying to change this as I am working with the "Header Nav" area.
This seems like it should be very trivial.
Thanks in advance.
Thanks for reply.
Is this not possible?
Is this not possible?
From the lack of response I guess what I wanted to do is not possible. For newbies with a similar problem I had to use a custom template, calling it with the following code:
<?php $bt_nav = BlockType::getByHandle('autonav'); $bt_nav->controller->displayPages = 'top'; $bt_nav->controller->orderBy = 'display_asc'; $bt_nav->controller->displaySubPages = 'none'; $bt_nav->render('templates/navbar'); ?>
blocks/autonav
This does not help you though if you are trying to create a package. I would be interested to know the answer to this one as well.