WebsiteBaker Support (2.8.x) > Templates, Menus & Design
show_menu2: valid XHTML and CSS selectable menus
brofield:
You are not supplying the SM2_TRIM flag. The default is SM2_ALL. Combine it with the pretty flag with a vertical bar. i.e. SM2_TRIM|SM2_PRETTY
ami:
Wow, really fast answer!
So easy, I just did not see that. And I tried a lot... :|
But whats about the default in <?php show_menu2(0, SM2_ROOT+1, SM2_START); ?>? Why does it work there as I want?
Thank you again!
Axel
brofield:
Sorry, what I said was confusing. Because the SM2_ALL flag uses the value of 0, it is the same as if it isn't specified at all. Therefore, if you supply some flags (like SM2_PRETTY), but don't supply one of the flags like SM2_TRIM, then it will use SM2_ALL. This is different to if you don't supply the flags parameter at all. Because at that time, you get the default value, which is SM2_TRIM.
In summary, always supply all flags.
In the next version I will change it so that if you don't supply one of the required flags then it will generate an error.
B
ami:
Cool!
there are too many features in your module... :roll: :-D
Keep on, its great and really flexible.
Greetings, Axel
brofield:
Version 3.8 now available at http://code.jellycan.com/show_menu2/
* Generate a log error if no group 1 flag was supplied (e.g. ALL, TRIM, etc)
* Fix bug where private pages that were not accessible by the current user were still visible in the menu (thanks to afbelow for the fix).
B
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version