Hello!
I need customize layout of some mods.
eg.: members, search, groups...
How to do this in my theme?
I try override search box template, but not success:
/mod/MYTHEMEDIR/mod/search/views/default/search/search_box.php
I modify this file but not work, help.
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by RaĆ¼l Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
- iionly@iionly
iionly - 0 likes
- Per Jensen@gillie
Per Jensen - 0 likes
- Angelo Rocha@angelorocha
Angelo Rocha - 0 likes
- iionly@iionly
iionly - 0 likes
- Angelo Rocha@angelorocha
Angelo Rocha - 0 likes
- Angelo Rocha@angelorocha
Angelo Rocha - 0 likes
- Per Jensen@gillie
Per Jensen - 0 likes
- Angelo Rocha@angelorocha
Angelo Rocha - 0 likes
- Angelo Rocha@angelorocha
Angelo Rocha - 0 likes
You must log in to post replies.Path should be /mod/MYTHEMEDIR/views/default/search/search_box.php.
You should check out Developer guides in the docs. Here's about overriding views.
iionly, i try, but don't work.
Per Jensen, i read this documentation, but this not help me, i did not understand well.
Please, any idea?
If you have simply cache / system cache enabled in the advanced settings of your site, any changes you make won't become visible immediately. Only if you flush the cache (by clicking the corresponding button on the admin dashboard) the cache will be freshly built up. Does the modification show up after flushing the cache? During developing it might be best to keep the caching disabled. Then the changes will show up immediately.
If the change you made in /mod/MYTHEMEDIR/views/default/search/search_box.php still does not show up you should check if any other plugin (that's below your MYTHEMEDIR plugin in the plugin list) also overrides the same view. If this is the case the changed view of your plugin get overridden by it again. In this case place your plugin below this other plugin. If the reason a change does not show up is not due to another plugin: are you sure that you modify the correct view?
I place my theme/plugin for end of list, search custom view works, I did not know the positioning of the plugins influenced. Is there any way to avoid this?
How to position search box in the menu?
Currently my layout is like this:
Is possible?
By default search is added to the header by extending a view. You can add it to another view the same way,
elgg_unextend_view('page/elements/header', 'search/header');
elgg_extend_view('page/elements/mymenu', 'search/header');
How to know the view of the menu?
I tried:
In start.php into the my theme init function, but not work, i'm doing right?
I think i learned ^^
In: mod/MYCOOLTHEME/views/default/navigation/menu
I created a file called: search.php
Finally created a view in: mod/MYCOOLTHEME/views/default/navigation/menu/site.php
Code:
Now it worked, thanks!