Skip to main content

scoped-Filterung

[en] Scoped filtering is a special type of filtering that's designed for this scenario:

  • [en] You reuse the same topic in multiple places in your publication

  • [en] You want each instance of the topic to be filtered differently, depending on its position in the publication.

[en] For example, you might have an "installation" topic that appears in a "Windows" section of your publication and also in a "macOS" section. You want to filter out macOS content when the topic appears in the "Windows" section, and then filter out "Windows" content when the topic appears in the "macOS" section. To make this possible, you need scoped filtering.

[en] Scoped filtering works by using the hierarchical structure of your content to define which filters to apply. You position the topic you want to use in several places so that it is always a child of another topic. Paligo uses the filters applied to the parent topic to determine which filters to apply to the child.

[en] To use scoped filtering:

scoped-Filterung aktivieren

In der Layout-Editor ist es möglich, scoped-Filterung sowohl für HTML5- als auch für die PDF-Ausgabe zu aktivieren. Stellen Sie sicher, dass die Option auf Ja oder Standard eingestellt ist.

Anmerkung

Für die PDF-Ausgabe finden Sie diese Einstellung unter Allgemein/Filterung und Taxonomien/scoped-Profiling/-Filterung aktivieren.

Anmerkung

[en] For PDF Layouts, the option is in a different location:

  1. Wählen Sie auf der Seitenleiste Allgemein aus.

  2. [en] Select Filtering and taxonomies.

  3. [en] Look for the Enable scoped profiling/filtering setting.

  1. Wählen Sie im oberen Menü Layout aus.

    Paligo editor. The Layout option in the header menu is highlighted.

    Paligo zeigt eine Liste von Layouts an. Die Liste ist leer, wenn keine benutzerdefinierten Layouts in Ihrer Paligo-Instanz vorhanden sind.

  2. Wählen Sie das Layout, das Sie aktualisieren möchten, oder Ein Layout erstellen aus.

    Tipp

    Sie können die URL des Layout-Editors kopieren und in eine neue Registerkarte in Ihrem Browser einfügen. Dies kann nützlich sein, wenn Sie häufig zwischen Ihren Paligo-Inhalten und den Layout-Einstellungen wechseln.

  3. Wählen Sie auf der Seitenleiste Klassen und Attribute aus.

    Classes_and_Attributes.png
  4. Wählen Sie Ja, um scoped-Profiling/-Filtering zu aktivieren.

    • [en] Yes to turn scoped filtering on.

    • [en] No to turn scoped filtering off.

    • Standard – um den Wert für diese Einstellung aus dem Basislayout zu übernehmen. Das Basislayout kann ein von Paligo bereitgestelltes integriertes Layout oder ein anderes kundenspezifisches Layout ein. Weitere Informationen finden Sie unter Layoutbeziehungen – Basis, Neu, Duplizieren.

    Enable_Scoped_Filtering.png
  5. Drücken Sie Speichern.

[en] Set Up Scoped Filtering

[en] To set up scoped filtering, you need to create a publication your content arranged as parent topics and child topics. The topic you want to reuse in different places has to be a child topic. For example, in the following publication, the same "Specifications" topic is reused three times. In each case, it appears as a child of a different parent topic. You will then need to apply your choice of filter attributes and filter values to the parent topics as well as the child topic.

reusing_the_same_topic_several_times.webp

[en] To show you how this is set up, we will give you step-by-step instructions. It is easier to follow with an example, so we will include one that filters based on the operating system being macOS or Windows.

Anmerkung

[en] The instructions use filter attributes and filter values set in the Element attributes panel in each topic. But if you prefer, you could set up taxonomy filters for filters at the topic-level. You would need a taxonomy tag to represent the filter attribute (type) and child taxonomy tags to represent the filter values. For details on using taxonomy tags for filtering, see Taxonomie-Filter.

[en] We assume that you already know how to create and organize publications and topics. You should also have already enabled scoped filtering in your Layout, see scoped-Filterung aktivieren.

  1. [en] Topics erstellen that will serve as a parent topic.

    [en] For these instructions, we will use two example parent topics: "Installing on MacOS" and "Installing on Windows".

  2. [en] Create a topic that will serve as a child topic. This is the topic that is going to be reused in more than one place in your publication.

    [en] For our example, we will use a child topic named "Operating system".

  3. [en] Create a publication and add the parent topic(s) and child topic to it. You can add the child topic many times, but it must always be a child of one of your parent topics.

    A publication structure. At the top is the publication icon labelled 1. At the next level down is an Installing on macos topic labelled 2. Also at this level is an Installing on Windows topic. These are the parent topics. The parent topics both have the same child topic at the next level down. The child topic is called Operating system and is labelled 3 in both places.

    [en] (1) is the publication, (2) is the first parent topic, (3) is the child topic, reused in two different places, and (4) is the other parent topic.

  4. [en] Edit your child topic and apply filter attributes and filter values to the parts you want to filter in or out.

    [en] In our example child topic, we have two itemized lists, one for macOS content and one for Windows content. We have applied the os filter attribute to the itemizedlist elements. We have set the filter value to macOS or Windows respectively.

    A topic with two itemized lists. Each list has a filter applied to the itemizedlist element. The top list has an os filter attribute with a macOS filter value.

    [en] First itemizedlist element has os filter attribute and macOS filter value.

    A topic with two itemized lists. Each list has a filter applied to the itemizedlist element. The lower list has an os filter attribute with a windows filter value.

    [en] Second itemizedlist element has os filter attribute and Windows filter value.

  5. Drücken Sie Speichern. Save icon.

  6. [en] Open one of your parent topics in the editor. Select its section element and use the Element attributes panel to give it:

    • [en] The same filter attribute you used on your child topic, for example, os

    • [en] The relevant filter value for that topic.

    [en] Select Save when you have done that.

    [en] With our example, we give:

    • [en] "Installing on macOS" - its section element has the os filter attribute and macOS as the filter value. When we publish, we want Paligo to filter it so that it only includes the content that's relevant for macOS.

      Installing on macOS topic. Its section element is highlighted. In the Element attributes side panel, we can see that the section element has the os filter attribute with a macOS filter value.
    • [en] "Installing on Windows" - its section element has the os filter attribute and Windows as the filter value. When we publish, we want Paligo to filter it so that it only includes the content that's relevant for Windows.

      Installing on Windows topic. Its section element is highlighted. In the Element attributes side panel, we can see that the section element has the os filter attribute with a windows filter value.
  7. [en] Repeat the previous step for your other parent topics that have the same reused child topic.

    [en] Your parent topics and child topic are now set up to use scoped filtering.

  8. [en] Publish your publication and choose your Layout. You must use a Layout that has scoped filtering enabled.

    [en] In the publishing settings, use the Profiling attributes section to include:

    • [en] The filter attribute that you gave to your parent topics and the child topic

    • [en] The filter values for all of the versions you want to include.

    [en] For our example, this means we choose:

    • [en] Filter attribute: os

    • [en] Filter values: macOS and Windows.

    [en] Note that we include all of the values that are needed for the publication. In this case, the first instance of the operating systems topic uses a macOS value and the second uses a Windows value. So we need to include both values.

    profiling-os-windows-mac.webp

    Wichtig

    [en] The parent-child relationship between topics is important for scoped filtering. When a topic appears in a publication many times, Paligo uses the filter attributes and filter values on the parent topics to figure out which filters to apply to the child topics.

[en] The published output should:

  • [en] Show the child topic multiple times in the table of contents

  • [en] Filter the content in the child topic differently, depending on where the child topic appears.

op-system-mac.webp

[en] Scoped filtering on an "Operating system" topic. The first instance of the topic appears as a child of a "Installing on macOS" topic. The "Operating system" topic is filtered so that it only contains information relevant to macOS.

op-system-windows.webp

[en] Scoped filtering on the same "Operating system" topic, but reused later in the publication. It is reused as a child of a "Installing on Windows" topic and is filtered so that it only contains information relevant to Windows.