Jump to content

Prestashop 1.7 problema en menu superior


tudeporteysalud

Recommended Posts

  • 2 years later...

Hola,  tengo un ploblema con el menú superior  mi version es 1.7.5.2, 

se ha descuadrado o se ha comido dos lugares he mirado el codigo mil veces y logro saber  el motivo os paso una img para que lo veais.

 

os paso el codigo del archivo mainmenu.tpl

{strip}


{assign var=_counter value=0}
{function name="menu" nodes=[] depth=0 parent=null}
    {if $nodes|count}
      <ul class="hrx-header-menu" {if $depth == 0}id="hrx-top-menu"{/if} data-depth="{$depth}">
        {if $depth == 0}
          <li class="{if $page.page_name=='index'}current {/if} hrxmain-menu-wrapper ">
            <div class="hrxmenu-link-wrapper">
              <a href="{$urls.pages.index}" data-depth="{$depth}">
                <span class="hrxmain-menu-text-box">{l s='Home' d='Shop.Theme.Catalog'}</span>
              </a>
            </div>
          </li>
        {/if}
        {foreach from=$nodes item=node}
            <li class="{$node.type}{if $node.current} current {/if} hrxmain-menu-wrapper {if $node.children|count}hrx-has-child{/if}" id="{$node.page_identifier}" {if $node.children|count}{assign var=_expand_id value=10|mt_rand:100000} data-child-dropdown='top_sub_menu_{$_expand_id}'{/if}>
            {assign var=_counter value=$_counter-1}
            <div class="hrxmenu-link-wrapper">
              <a class="{if $depth <= 1} hrxdropdown-submenu{/if} hrxmenu-link" href="{$node.url}" data-depth="{$depth}" {if $node.open_in_new_window} target="_blank" {/if}>                                
                <span class="hrxmain-menu-text-box">
                  {$node.label}
                </span>
              </a>
              {if $node.children|count}
                <span class="hrxmenu-toggle-icon">
                  <i class='material-icons hrxhorizontal-menu-drop-down-icon'>&#xe5c5;</i>
                </span>
              {/if}
              </div>
             
                           <div {if $depth === 0 }  class="hrxmain-menu-dropdown hrxmain-menu-sub-menu hrxmain-menu-mobile-dropdown " {elseif $depth === 1 } class="hrxmain-menu-mobile-dropdown" {else} class="" {/if} >
               
                    {menu nodes=$node.children depth=$node.depth parent=$node }
                      <div  class=""> {if $node.children|count}{if $node.image_urls}{foreach $node.image_urls as $image}
                        <img src="{$image}" alt="{$node.label}">{/foreach} {/if}
                       </div>

                   
              </div>
              {/if}
            </li>
        {/foreach}
      </ul>
    {/if}
{/function}

<div id='hrxcmsdesktop-main-menu'>
  <div class='hrxcmsmain-menu-wrapper' {* id="_desktop_top_menu" *}>
      {menu nodes=$menu.children}
      <div class="clearfix"></div>
      <div class="hrxmenu-button-wrapper">
        <div class="hrxmenu-button">
          <i class='material-icons'>&#xe5d2;</i>
        </div>
      </div>
  </div>
</div>

{/strip}
gracias

descuadre-menu.png

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...