Auto Expanding an accordian section based on the directory of the page you're on - accordion

So I have an expandable accordion, the represents different directories on my site. For example...
rootdomain.com/directory1
rootdomain.com/directory2
I have corresponding accordion sections on my site, so in the example above I have an accordion with 2 sections, directory1 and directory2
I would like to "expand" the accordion for directory2 if I'm already on a page that resides within the directory2 directory (for example, rootdomain.com/directory2/page1). The accordion for directory1 would stay closed, however if I changed pages to a page within directory1 that accordion would show expanded while directory2 accordion would be closed. If I am on a page not within any of these directories, all accordions would stay closed.
Is this do-able?

Related

Magento 2 remove the unwanted sidebar div displaying something I don't know where come from

the image attached shows the sidebar in a category page that lists all its products with this sidebar that shows search block and compare block then this div that shows that error. I don't know how this been generated but I want to remove this error info div
additional sidebar div
Turn on path hints
Get file template
Copy template to your theme and remove your div.

Remove subcategories form Vanilla Forum sidebar

I wish to display root categories in the Vanilla sidebar, however both categories and subcategories are displayed. The admin panel only gives the option of removing the sidebar all together or display root categories as headings.
I've narrowed down the PHP file responsible for this section of the sidebar it's located at: applications/vanilla/views/modules/categories.php
How would I modify this to prevent subcategories being displayed?
You can use CSS, for example if you are using the Bootstrap theme, you can do this with:
li.ClearFix.Depth2{
display:none;
}

How to insert different text with different format on each page in Libre Office Writer?

How can I add a different text to each header and footer of each page in LibreOffice Writer? If I edit the header of a page, the text automatically changes on the others. I want them to behave independently.
EDIT: What I would like to achieve is this: let's say I have 7 pages, the first one doesn't have neither a header or a footer, it's just a simple page with an image.
The second page should have an "INDEX" header and a footer at the bottom of the page with the page number "2" on the right. The third page should have another header, or better a header with a different text, different text-size and with italic style, and the footer should have the page number "3", and so on.
If I click Insert->Fields->Number of pages I get the total of the pages of my document and this is not what I am looking for. But also clicking on Insert->Fields->Number of page doesn't help cause if I have e.g. the "INDEX" page and I click on Insert->Fields->Number of page, I get the number "3" instead of the number "2". Also I have noticed that my footer style is different on some pages, how can I make it the same for every page?
For different page numbering, you will have to use page styles. If your document contains a front page, one or more index pages, and the main content pages, you could create three different page styles (frontmatter, index, maincontent). To change from one page style to the next one, you need to set manual page breaks, telling LibreOffice which page style to use after the page break: Menu Insert -> Manual Break:
Using the "Style" ComboBox, you can select the page style to use for the pages following the break.
For each page style, you can set different headers / footers, e.g. to hide page numbering on the front page. Also, you can set the page numbering to start with 1 instead of the "physical" page number (for example, if the front page doesn't count as page 1, you could set the following page style to start with 1 instead 2).
The most important point is diving the document in logical units using page styles. After this is done, you can set different paragraph styles for each page element (header, footer), allowing to set a different text size only for the header of the "index" part of your document.

Is it possible to not show \xrefitem pages in the top level treeview?

I'm using ALIAS and \xrefitem to gather a specific list of comments into a separate page for reference. This is working fine, however, each of these specific pages appear in the top level treeview. For other page/subpage hierarchies I've built a MarkDown index page that shows in the top level, and then references the others, thus keeping my treeview neat. I've done the same for the xrefitem pages, and the index page works fine, but the xrefitem pages still appear in the top level treeview.
Is there any way I can stop this, to keep my treeview clean?
Cheers
Paul
Try this in a markdown file (or work it into your existing mainpage):
Scratch {#mainpage}
==================================
\subpage custom
\xrefitem xrefitem_subpage "xrefitem Heading" "xrefitem Title" Item to document
\page custom My Custom Pages
\subpage xrefitem_subpage
\page xrefitem_subpage Key Three Page
Some Text

Use the sitemap content element to load content of the referenced pages

I use the sitemap content element so that the editor can explicitly reference to individual pages in my page tree. Of course those pages do contain content elements (Textpic, Media, all the good stuff...) in their "normal" section. I need advice on how to modify the sitemap content element that it will output the content of the referenced pages.
I know there is already a plugin called "kb_sitemap" which basicaley does this job... but it does not handle the output of images or media (flash-, quicktime movies..) elements which is absolute necessary. The rendering relevant stuff is handled by Css Styled Content (CSC) which is necassary for me because it renders the media content element.
Do you use templavoila ?
Ok, go to page properties -> General tab (bottom part of the tab) and then you'll find all containers that possibly contain CEs, click to the lil folder icon and you may select content elements from any other page.
EDIT: added screenshot, page properties...
Note, showcase, maincontent, right content are just my names for my TV elements, could of course be name differently.