Jump to content

Recommended Posts

Можно как-то так:
<div id="categoriesBoxMenu">
{defun name=categories_tree categories=$categories}
{if $categories}
<ul id="CatNavi">
{foreach item=c from=$categories}
{if $category->category_id != $c->category_id}
<li class="CatLevel1"><a href='catalog/{$c->url}' tooltip='category' category_id='{$c->category_id}'>{$c->name}</a></li>
{else}
<li class="CatLevel2"><a href='catalog/{$c->url}' tooltip='category' category_id='{$c->category_id}'>{$c->name}</a></li>
{/if}
{*if in_array($category->category_id, $c->subcats_ids)*}
{if in_array($category->category_id, $c->subcats_ids)}
{fun name=categories_tree categories=$c->subcategories}
{/if}
{*/if*}
{/foreach}
</ul>
{/if}
{/defun}
</div>

Link to post
Share on other sites

Попробовал все под категории прячет но при нажатии на нужную категорию открывается новая страница с под списком категорий а нужно чтоб при нажатии на категорию открывались под категории без перезагрузки страницы

Link to post
Share on other sites
  • 2 weeks later...

Если у вас так как описано выше, тогда дело в стилях. У меня менюха вырисовуется так:
-----------------------------------------------------
#categoriesBoxMenu {
margin:0 0 0;
padding-top:0px;
width:175px;
}

#categoriesBoxMenu #CatNavi,#CatNavi #categoriesBoxMenu #CatNavi,#CatNavi ul,#CatNavi li {
list-style-type:none;
margin:0;
padding:.1em;
}
#categoriesBoxMenu #CatNavi ul {
margin-left:10px;
}

#categoriesBoxMenu #CatNavi li a {
background:url(../images/icon_arrow.gif) no-repeat left center;
color:#3A3A3A;
font-weight:400;
margin:.2em 0 0;
padding:.2em 0 .2em 20px;
text-decoration:none;
text-indent:.8em;

}

#categoriesBoxMenu #CatNavi li a:hover {
background:url(../images/icon_arrow_down.gif) no-repeat left center;
color:#000;
font-weight:400;
}

#categoriesBoxMenu #CatNavi li a,#categoriesBoxMenu #CatNavi .Current li a,#categoriesBoxMenu #CatNavi .CurrentParent li a,#categoriesBoxMenu #CatNavi .CurrentParent .Current li a {
font-weight:400;
text-decoration:none;
}

#categoriesBoxMenu #CatNavi .Current a,#categoriesBoxMenu #CatNavi .CurrentParent .Current a {
text-decoration:underline;
}
#categoriesBoxMenu #CatNavi .CurrentParent a,.bold {
font-weight:600;
}
--------------------------------------------------------------------------
Остальное подправите под себя

Link to post
Share on other sites

Сделать так как на туториалайз, но админкой добавлять в стиль текущей категории еще стиль (в цсс это можно делать) как неактивный, что б текущая категория была открыта :)

Link to post
Share on other sites
  • 5 years later...

Где?

 

Были посты. Их уже удалили. Но Мое сообщение почему то оставили) 

Я думаю их бы тоже можно было удалить. Что бы не смущать людей...

Edited by yr4ik
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...