Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
submenu
#3
Use I18N plugin + custom  rendering(to assign classes to elements <ul>, <li>, etc.) + HTML, CSS (for position and menu design)
You can read the details:
http://mvlcek.bplaced.net/get-simple/i18n
http://mvlcek.bplaced.net/get-simple/mul...navigation
http://mvlcek.bplaced.net/get-simple/mul...-rendering

This will help if you want to display in the sidebar the child pages:
http://mvlcek.bplaced.net/get-simple/mul...v-children


Insert it in the template and get a simple menu as there http://mvlcek.bplaced.net/:
(This is the easiest option - the output only without rendering menu)
Code:
<ul>                    
   <?php get_i18n_navigation(return_page_slug(),0,99,I18N_SHOW_NORMAL); ?>
</ul>

Example menu rendering for Bootstrap:
(a component - to create in the admin panel, )
PHP Code:
<?php
$s 
= array('current''activepath''currentpath''open');
$r = array('active''active''active''dropdown');
$c str_replace($s$r$item->classes);
?>
<li class="<?php echo $c?>">
  <?php if ($item->isOpen) { ?>
  <a href="<?php echo htmlspecialchars($item->link); ?>" class="dropdown-toggle" data-toggle="dropdown">
    <?php echo htmlspecialchars($item->text); ?>
    <b class="caret"></b>
  </a>
  <ul class="dropdown-menu">
    <?php $item->outputChildren(); ?>
  </ul>    
  <?php } else { ?>
  <a href="<?php echo htmlspecialchars($item->link); ?>">
    <?php echo htmlspecialchars($item->text); ?>
  </a>    
  <?php ?>
</li> 
In the template use the following code:
PHP Code:
<?php get_i18n_navigation(get_page_slug(FALSE),0,1,I18N_SHOW_MENU'here-component-name'); ?>
I use machine translation. Forgive me my errors.
Reply


Messages In This Thread
submenu - by andylorenz - 2017-02-17, 05:57:07
RE: submenu - by andylorenz - 2017-02-17, 07:49:06
RE: submenu - by AleksK - 2017-02-18, 05:18:54
RE: submenu - by andylorenz - 2017-02-21, 00:09:20
RE: submenu - by Carlos - 2017-02-21, 01:36:38
RE: submenu - by andylorenz - 2017-02-21, 23:41:05
RE: submenu - by Timbow - 2017-02-22, 04:02:51
RE: submenu - by andylorenz - 2017-02-25, 00:01:46
RE: submenu - by AleksK - 2017-02-25, 01:18:35



Users browsing this thread: 1 Guest(s)