How to combine the "Keyword Library" feature of AnQi CMS to provide richer filtering vocabulary for `archiveFilters`?

Calendar 👁️ 54

As an experienced website operations expert, I am well aware that in this era of content explosion, how to efficiently organize and display content so that users can quickly find the information they need is the key to improving user experience and SEO performance.AnQiCMS (AnQiCMS) with its powerful feature set provides us with many operational tools.Today, let's delve into a seemingly simple yet potentially powerful combination application: how to cleverly combine the 'keyword library' and 'content model' of AnQi CMS toarchiveFiltersFunction injection introduces richer filtering vocabulary, thus building a more intelligent and user-friendly content filtering system.

Skillfully utilize the 'Keyword Library' and 'Content Model' of AnQi CMS: constructarchiveFiltersPractical guide to a rich filtering system

In a content management system, the content filtering function is like the navigation system of a website, directly affecting the efficiency and satisfaction of users in discovering information. Anqi CMS providesarchiveFiltersThe label is the core tool for building this 'navigation system'.However, relying solely on the default settings is far from enough to make this tool operate at its best.We need to deeply explore the 'keyword library' and 'content model' functions of Anqi CMS, providing more accurate and rich filtering dimensions for the filter.

1. Deep understandingarchiveFiltersThe foundation of content filtering

First, let us clearly understandarchiveFilters. According to the Anqi CMS template tag document,archiveFiltersis specifically designed fortemplate for the document home page or document categoryDesign, intended to perform list combination filtering based on the various parameters of the document.It allows us to flexibly display various filtering conditions such as 'House Type', 'Area', 'Price Range' on the front-end page, significantly improving user experience, and providing an excellent opportunity for long-tail keyword SEO optimization.

The key here is:archiveFiltersThe "document parameters" relied on do not directly come from the "keyword library" of the background, but rathercustom fields defined in the content model. This means that to enricharchiveFiltersThe filtering dimension, we need to start from the content model rather than directly adding vocabulary to the keyword library.

2. The real positioning and indirect value of the "keyword library".

So, what role does the 'keyword library' of Anqi CMS play in this process? It does not directly providearchiveFiltersProvide front-end filtering options. Conversely, the core value of the keyword library is reflected in the following aspects:

  • Centralized management and standardization:The keyword library provides a unified place to manage the important keywords of the website, ensuring that content creators can use standardized, highly relevant vocabulary to the website theme when publishing documents.It is crucial for maintaining the overall professionalism and consistency of the website.
  • Content creation efficiency:On the "Publish Document" interface, content creators can directly select keywords from the keyword library to avoid manual input and spelling errors, greatly improving work efficiency.
  • SEO optimization foundation:The keywords in the library are an important basis for SEO optimization.They can be used for article meta keywords, anchor text settings in content, and even through the "site-wide content replacement" feature to batch implement keyword internal link deployment, thereby improving the relevance and weight of the page.
  • Auxiliary content strategy:By analyzing the keyword library, operators can more clearly understand the key direction of website content and the focus of user concerns, providing data support for future content planning.

Although the keyword library does not provide direct filtering options, it ensures that the content's keyword annotations are standardized and consistent.This consistency lays a good foundation for subsequent filtering through custom fields, because users may base their filtering on their understanding of these keywords.

3. Build richarchiveFiltersFiltering system: The core lies in the customization of content model fields

To truly bearchiveFiltersProvide rich and practical filtering vocabulary, our focus is on the powerful AnQi CMS.Custom fields for content modelFunction. AnQi CMS allows us to add any number of custom fields for different content models (such as articles, products, real estate information, etc.). These fields arearchiveFiltersParameters that can be recognized and utilized.

The detailed steps to build this system are as follows:

  1. Define the screening dimensions and business requirements:Before starting the hands-on operation, we should first clarify what filtering conditions the website users may need.For example, for an e-commerce website, users may need to filter by 'brand', 'color', 'size', 'material', and so on;For a real estate website, it may be necessary to filter by 'area', 'house type', 'rental/sale type', 'renovation status', and so on.In-depth user research and market analysis is the key to this step's success.

  2. Create custom fields in the content model:Log in to the AnQi CMS backend, go to 'Content Management' -> 'Content Model', select the target model you need to add the filtering function (such as 'Product Model' or create a new 'Real Estate Model').Click "Content model custom field" under "Add field", create a custom field for each confirmed filtering dimension.Here are some key points:

    • Parameter name:User-friendly, easy-to-understand Chinese name (such as "brand", "house type").
    • Call field:English lowercase letters, which will be used in the template to identify the field.FieldNamefor examplebrand/house_type)
    • Field type:This is the most important step. In order to supportarchiveFiltersdropdown or multi-select filtering, we should prioritize:
      • Single selection (Radio):options that are mutually exclusive, such as "Type of Tenancy" (rental/sale).
      • Multiple selection (Checkbox):Suitable for multi-selectable filters, such as “facilities” (parking spaces, gardens, terraces).
      • Select (Select):Suitable for filters with many options but single selection, such as “brand”, “region”.
    • Default:Here, we need to preset all possible filter options.For example, if the field is "house type", the default values can be entered one per line: "one bedroom one living room", "two bedrooms one living room", "three bedrooms two living rooms".These default values will becomearchiveFiltersinItemsofLabel.
  3. Fill normalized data for the document content:After the custom field is created, these custom fields will appear in the "Other Parameters" collapse box when publishing or editing the document under the corresponding model.Ensure that content editors strictly fill in data according to the preset options (or standardized format).This is the foundation for the normal operation of the filter function, any irregular data may cause the filter to fail or the results to be inaccurate.

  4. Call in the front-end templatearchiveFiltersTags:Now, we can use it in the list page or category page template that requires a filter function,archiveFiltersLabel to display these custom filter conditions. “`twig {# Example: Call the filter on the product list page #}

    <h3>商品筛选</h3>
    {% archiveFilters productFilters with moduleId="2" allText="不限" %} {# moduleId为产品模型的ID #}
        {% for item in productFilters %}
            <div class="filter-group">
                <span class="filter-name">{{ item.Name }}:</span> {# 显示“品牌”、“颜色”等参数名 #}
                <ul class="filter-options">
                    {% for option in item.Items %}
                        <li class="{% if option.IsCurrent %}active{% endif %}">
    

Related articles

Does the `archiveFilters` tag support secondary or multi-level cascading selection, for example, selecting provinces first and then cities?

As an experienced website operations expert, I am well aware that the filtering function plays a crucial role in content management and user experience.Especially when faced with massive amounts of information, an efficient and intuitive filtering system can greatly enhance the efficiency of users in finding the content they need.AnQiCMS (AnQiCMS) has won a lot of praise in the content operation field with its flexible functions and powerful extensibility.

2025-11-06

How to avoid duplicate content or empty list situations on the `archiveFilters` filter results page?

As an experienced website operations expert, I am well aware of the core role of the content management system (CMS) in website operations.AnQiCMS with its efficient and flexible features, provides many conveniences for us to build personalized content display.The `archiveFilters` tag is undoubtedly a powerful tool for enhancing the user's content search experience and implementing multi-dimensional content filtering.

2025-11-06

How to keep the `archiveFilters` tag parameters concise and readable when passed in the URL?

As an experienced website operations expert, I am well aware of the importance of URL structure for the SEO performance, user experience, and even brand image of a website.In a flexible and efficient content management system like AnqiCMS, the `archiveFilters` tag provides us with powerful dynamic filtering capabilities, but how to ensure that these filtering parameters in the URL are concise and readable to avoid long and disordered URLs is a problem that every operator needs to consider carefully. Today

2025-11-06

Does the `archiveFilters` tag support filtering based on Tag tags, in addition to custom parameters?

AnQi CMS is an efficient enterprise-level content management system that provides many flexible tags and features for content display and management.Among them, the `archiveFilters` tag is often used by website operators to build complex document filtering interfaces due to its powerful filtering capabilities.HoweverToday, let's delve deeply into this issue. ###

2025-11-06

What are the specific application scenarios of the `IsCurrent` field in the `archiveFilters` tag in front-end development?

Good, as an experienced website operations expert, I am very willing to delve into the specific application scenarios of the `archiveFilters` tag's `IsCurrent` field in front-end development in AnQi CMS.We will integrate technical details into practical applications in a natural and fluent manner, hoping to bring you some practical inspiration.--- ## Deep Analysis of Anqi CMS Front-end Development: The Magic of `IsCurrent` Field in `archiveFilters` Tag In the Anqi CMS ecosystem

2025-11-06

How to use CSS/JavaScript to beautify the `archiveFilters` tag generated filter interface to enhance user experience?

As an experienced website operations expert, I am well aware of the importance of user experience for the success of a website, especially in complex filtering functions.The `archiveFilters` tag provided by AnQiCMS greatly facilitates the rapid construction of the document parameter filtering interface.However, relying solely on default styles often fails to meet the high requirements of modern websites for aesthetics and interactivity.

2025-11-06

How will the `archiveFilters` tag handle if the document does not have a value for a certain filter parameter?

As an experienced website operations expert, I often deal with content management systems in my daily work and understand the importance of flexible use of template tags for website performance and user experience.AnQiCMS (AnQiCMS) with its powerful features and high performance brought by the Go language has become the preferred choice for many enterprises and operation teams.Today, let's delve into a detail issue that may be encountered in template development and content operation: **What will happen when a filter parameter dependent on the `archiveFilters` tag does not have a corresponding value?

2025-11-06

`archiveFilters` tag supports dropdown menu or checkbox form of filtering interface?

AnQiCMS provides a highly flexible solution in content management and display, especially in handling dynamic content filtering, where its `archiveFilters` tag plays a core role.Does the `archiveFilters` tag support a dropdown menu or checkbox form of the filter interface?This question can be understood as: The `archiveFilters` tag itself does not directly generate visible UI elements, such as dropdown menus or checkboxes

2025-11-06