Closed Jimmi08 closed 8 years ago
Do I understand well that you wish to hard-code a plugin theme into the theme's layout?
No. I have f.e. 5 layouts with the same footer where are 3 footer menus. Maybe I do something wrong, but now I need to add this menus 5 times (actually 15 times) . With the visibility option and menu numbering I don't get reason for this change. Don't change anything I am just trying to understand. Why if I put menu in the part of layout what is used for all layouts I still need to add it to all layouts.Thanks.
@Jimmi08 Sorry Jimako, but i don't really understand it.... If you have a menu, and place it on, for instance, menu area 10, via admin interface, and if you have 15 menu areas 10 in your template, you menu placed on menu area 10 will appear in all menu areas 10, so you'll have only to place it once via admin.....
Or i'm seeing the picture wrong????
You might know, i like to think out of the box : would it not be something similar as the feature-menu/jumbotron pieces installed by theme install xml ? Or maybe usefull ? Just thinking...
@CaMer0n yes, it should work that way you described, but I can't get it. From the beginning..
What I do wrong?
But all others layout are empty, I need to add this for each layout.
Examples of hard-coded menus:
{MENU=contact}
for e107_plugins/contact/contact_menu.php
{MENU=contact/other}
for e107_plugins/contact/other_menu.php
@CaMer0n Sorry, I just noticed that answer was from @rica-carv not from you.
This doesn't work for me:
If you have a menu, and place it on, for instance, menu area 10, via admin interface, and if you have 15 menu areas 10 in your template, you menu placed on menu area 10 will appear in all menu areas 10, so you'll have only to place it once via admin.....
I use hard-coded menus (one of the best things in e107 for me) it works, question was about menus in admin area.
If I have 5 menu areas (5 layouts) with the same menu name {MENU=10}, adding menu in first layout (homepage) doesn't mean that menu (f.e. contact) appears in all {MENU=10} in all layouts.
I just need to confirm this behaviour or not. But from @rica-carv answer I got idea that I am doing something wrong.
Thanks for your patience.
If I have 5 menu areas (5 layouts) with the same menu name {MENU=10}, adding menu in first layout (homepage) doesn't mean that menu (f.e. contact) appears in all {MENU=10} in all layouts.
Confirmed, you have to enter the menu's in all your layouts, menu's are not the same in all the layouts..
@Jimmi08 Take a look at the html code for both renders, you migh be breaking something. My layout works dispalyng the footer in all the pages, so it must be a misrender of HTML somewhere.... Can you show all the theme.php file? Or better, if you want, i can give it a try with it...
@rica-carv yes, it works. Your footer has no menu in it. Try to put MENU there and you will need to add it in all layouts separatelly. I would expect different behaviout for common footer, that's all. Question was about menus, not footer layout. But thanks. And yes, I will share that theme.
@Jimmi08 Please test this old style layout: $FOOTER['default'] = "<!-- begin footer --></div><div id='menu'><div id='nav'><ul>{SETSTYLE=menu}{MENU=2}</ul></div></div><div id='footer'><p id='spacer'> </p><center><div id='hnav'>{SITELINKS=menu:4}</div><p class='smalltext' id='clearer'>{SITEDISCLAIMER}</div>";
I've got this on my current v2.0 live site (upgraded from v1.4), and it works....
@rica-carv I would need to rewrite all $layouts and I don't think it's good idea, it's deprecated way.
@Jimmi08 I've tryed with bootstrap3 theme, and assigned three menus to menu areas 101, 102 & 103 (which are on bootstrap3 footer definition), and all works with all layouts (Jumbotron (home), Modern Business: Home page carousel with fixed custom-menus, Jumbotron (full-width), Jumbotron (sidebar-right)) Once more, i seem i can't really understand what you trying to do, or what's not working on your theme....
@rica-carv look at Alex answer above, he has the same experience. Something is different. Ok, Bootstrap 3 theme, menu 101, layout sidebar-right. Added new menu. This menu appeared only on sidebar-right, not on other layouts. What I am trying to do? If this is correct, I can live with it, but you say that you have different behaviour, so I am trying to find reason.
@Jimmi08 Menu placement is layout-specific in v2.x and has been like that for some years now. The alternative is convenient, but limiting.
@Jimmi08 If i could have a look at your theme.php file, maybe i could help.... Anyway, that's a real weird issue, since you can't render menus, and i can.... I'm currently using latest github version.... What i can think more is if there's no server issue, since i've recently have some server issues regarding rendering theme overriden shortcodes....
@rica-carv I am closing this. Look at @CaMer0n answer, my behaviour is correct. Menu is layout specific regardless you put it default footer.
If you want, theme is here: https://github.com/Jimmi08/e107-solid-theme But wait, footer will be in part 11.
@Jimmi08 Sorry to bring this up, but just tested your theme, as it is now (by the way, it has a error on theme_shortcodes.php), and footer is displayed in all layouts...
@rica-carv No problem, question was about footer menus not about footer itself.
I get that now each layout has it's own set of menu areas so that menu=1 for one layout can have different content that in next layout. I am not still sure that this is improvement, but I can live with it. Maybe reason for this change would be helpful.
I just wonder if there is any possibility to add menu area with the same content to all layouts? I don't mean at once, but something like this:
I use words menu area, because if I want the same menu I would use CMENU shortcode in theme.
Thanks