How to use the `showParent=true` attribute in AnQi CMS to display more hierarchical information in the Title?

Calendar 👁️ 73

Anqi CMS, as an enterprise-level content management system that deeply understands the way of content operation, its powerful functional design reflects a profound understanding of user needs and search engine optimization.The importance of the page title (Title) in website operation is self-evident. It is not only the first entry for users to click but also the core basis for search engines to judge the relevance of page content.Today, we will delve into how Anqi CMS cleverly utilizestdkin the labelshowParent=trueThe attribute, enriches the page title with more rich, hierarchical information, thereby effectively improving the website's SEO performance and user experience.

The deep value of the page title: more than just a few words

In the practice of content operation, an excellent page title is far more than a simple summary of the content.It needs to accurately convey the page theme, attract user clicks, and include keywords friendly to search engines, as well as clearly show the position of the page within the website structure.Imagine when a user finds your product through a search engine, a page with a title that only displays 'Product Details' is compared to a page that displays 'Product A - Digital Product - Electronic Products | Your Brand Name'. The latter clearly has more information, not only making it clear to the user the category of the product, but also subtly building the professional image of the brand.

Anqi CMS knows this and therefore in itstdkThe design of the label provides a high degree of flexibility and intelligent hierarchical display capabilities for generating page titles.

tdkwith the tag andTitleThe core function of the attribute

In the AnQi CMS template system,tdk(Title, Description, Keywords) tags are the core tools for setting page meta information.By this tag, we can dynamically generate SEO-compliant titles, keywords, and descriptions for each page of the website. Among them,name="Title"The attribute is specifically used to control the main title of the page.

In most cases, we may only use{% tdk with name="Title" %}To display the current page title. For example, for an article named 'AnQi CMS Quick Start', the page title may be 'AnQi CMS Quick Start'.This is sufficient in some scenarios, but in complex website structures, especially when content has clear hierarchical relationships, such a title may be a bit thin.

Deep understandingshowParent=true: to add hierarchy to the title

Anqi CMS is to solve the above problems, intdklabel'sname="Title"introduced in the propertiesshowParent=trueThis powerful and practical parameter. This seemingly simple attribute, hidden behind it, is the wisdom to inject depth and breadth into the page title.

When we willshowParentis set totrueAt that time, AnQi CMS will intelligently identify the category level of the current page and add the titles of these parent categories hierarchically to the page title.The mechanism of its operation is as follows: For a document (such as an article or product), it will first obtain the title of the direct category to which the document belongs. If the category has a parent category, it will continue to trace up until the top-level category, and integrate all the titles of the parent categories in the order of the hierarchy into the page title.

For example, suppose your website structure is as follows:

  • Electronics(Top Category)
    • Digital Equipment(Subcategory)
      • Smartphone(Subcategory)
        • Article/Product: Review of the latest smartphone

If the article "Review of the latest smartphone" used{% tdk with name="Title" showParent=true %}And you also want to include the website name and a custom separator, then the final page title may be:

<title>最新款智能手机评测 - 智能手机 - 数码设备 - 电子产品 | 您的网站名称</title>

You can see that the title is no longer isolated as a review of the "latest model smartphone", but clearly shows its position in the hierarchy of "Electronic products > Digital devices > Smartphones."}This rich hierarchical information is crucial for search engines to understand the relevance of page content, website structure, and for users to quickly identify your page among many search results.

To better control the display of the title, you can combinesepThe attribute comes from the separator between custom hierarchical titles, for examplesep=" > ", as well assiteName=trueAdd the website name at the end of the title. These detailed settings collectively build a flexible and powerful title generation mechanism.

Actual application scenarios and strategies

showParent=trueProperties can play a huge role in many complex websites, especially suitable for the following scenarios:

  1. Product detail pages on e-commerce websites:Users usually want to know which major category and series a product belongs to.The hierarchical title can clearly show the product classification path, such as "iPhone 15 Pro Max - Smartphone - Mobile Device - Digital Products | Apple Official Store".
  2. Knowledge bases or blogs with deep content:When an article belongs to a series or a sub-branch of a theme, hierarchical titles can help readers better understand the context of the article, such as "Introduction to Deep Learning: Neural Network Basics - Machine Learning - Artificial Intelligence | Technical Blog".
  3. Information portal with multi-level directories:Ensure that each news or special report reflects its channel and column in the title, enhancing the sense of information ownership and navigation.

When using this attribute, website operators should weigh the length and readability of the title.The title is too long and may be truncated in search results, affecting user experience.Therefore, combining the actual classification depth and keyword strategy of the website, use it reasonablyshowParent=true,and cooperatesepOptimizing the attribute is the key to achieving **effect.

Summary

Of Security CMSshowParent=trueThe attribute provides a powerful and convenient tool for website operators to build page titles that are more informative, more in line with user browsing habits, and more favored by search engines.By accurately displaying the hierarchical information of the page title, we can not only effectively improve the website's SEO performance, but also optimize the user's in-site navigation experience, thus standing out in the fierce online competition.


Frequently Asked Questions (FAQ)

1.showParent=trueIs the attribute only effective for document (article/product) pages?Yes,showParent=trueThe attribute is mainly used for generating titles on document detail pages (such as articles, product pages) and category list pages. It depends on the hierarchical structure of the content or category (i.e., havingParentIdThe classification relationship). For independent pages that do not belong to any category (such as "About Us" single pages), this attribute will not generate parent title information.

2.showParent=trueWill it recursively display the titles of all parent categories?Yes, whenshowParent=trueWhen activated, the AnQi CMS will trace back from the current content or category, recursively obtaining the titles of all hierarchical parent categories and integrating them in order of hierarchy into the final page title, until the top-level category.This ensures that the title fully presents all levels of the content path.

3. How to customizeshowParent=trueThe separator between the hierarchical titles generated?You can use it totdklabel'ssepProperties to specify the separator between title levels. For example, if you want to use “>” as the separator, you can set it like this:<title>{% tdk with name="Title" showParent=true sep=" > " %}</title>This will display the title as: "Subcategory Title > Parent Category Title > Top Level Category Title".

Related articles

How to customize the separator of the `sep` attribute for the AnQi CMS page title?

In today's digital world, every detail of a website can affect its performance in search engines and the first impression of users.The page title (Title) serves as the 'face' of the website content, its importance is self-evident.It is not only a key clue for search engines to understand the theme of a web page, but also a direct factor for users to decide whether to click in the search results.AnQiCMS (AnQiCMS) knows this and is committed to providing users with efficient and customizable content management solutions, including fine-grained control over page titles.As an experienced website operations expert

2025-11-07

What is the difference between `siteName=true` and `siteName=false` in the Title tag of AnQi CMS?

The secret of the Title tag in AnQi CMS: Deep analysis of `siteName=true` and `siteName=false`The title tag acts as the 'face' of a webpage, its importance is self-evident.It is not only a key signal for search engines to understand the theme of a page, but also the primary information that users determine at a glance in search results.

2025-11-07

What parameters should be noted when using the `tdk` tag of AnQi CMS?

As an experienced website operations expert, I know that TDK (Title, Description, Keywords) are crucial for the performance of a website in search engines.AnQi CMS provides us with powerful and flexible TDK management capabilities with its SEO-friendly design philosophy.Today, let's delve into the various parameters that need to be paid attention to when using the `tdk` tag in Anqi CMS, to help everyone better master this core SEO element.

2025-11-07

How to customize the display logic of Title, Description, and Keywords in AnQi CMS template?

As an old soldier who has been deeply involved in website operations for many years, I know that every detail can affect the performance of a website in search engines.Among them, Title (title), Description (description), and Keywords (keywords) - commonly referred to as TDK, are also the foundation of website SEO optimization.They are like the 'front door' and 'map' of a website, directly telling search engines and users what your page is about.

2025-11-07

What is the correct way to call `CanonicalUrl` in the `tdk` tag of AnQi CMS?

As an experienced website operations expert, I know that search engine optimization (SEO) plays a key role in the success of a website, and one often overlooked but crucial detail is the correct use of `Canonical Url`. In such a powerful content management system as AnQiCMS, we also need to master the practice of calling `CanonicalUrl` with the `tdk` tag to ensure the uniqueness and authority of the website content, thereby achieving better performance in search engines.

2025-11-07

What is the role of the variable name of the `tdk` tag in the AnQi CMS template?

## The `tdk` tag in Anqi CMS template: The key to mastering SEO and building high-performance websites As an experienced website operations expert, I deeply understand the core status of TDK (Title, Description, Keywords) in website SEO.They are not only key signals for search engines to understand web content, but also the first line of defense to attract users and increase website traffic.In daily content operations, how to efficiently and flexibly manage TDK is an important factor in enhancing website competitiveness. Today

2025-11-07

How can AnQi CMS automatically generate Sitemap to help search engines crawl TDK information?

In today's highly competitive online environment, it is the goal of every website operator to efficiently have their website content discovered, crawled, and accurately displayed by search engines.Among these, the TDK (Title, Description, Keywords) information of the website, is like the "business card" of your website presented on the search engine results page (SERP), and its quality directly affects the click-through rate and user access.However, how can we ensure that these carefully prepared TDK information can be effectively read by search engine spiders and presented to users?AnQi CMS knows this pain point

2025-11-07

How does the Robots.txt configuration of Anqi CMS affect the crawling of TDK tags by search engines?

As an experienced website operations expert, I am well aware of the importance of Search Engine Optimization (SEO) for website visibility.Among many SEO strategies, the title (Title), description (Description), and keywords (Keywords) of a web page, which we usually call TDK tags, are the core elements that attract the attention of search engines and users.And the Robots.txt file, this seemingly simple text file, acts like a director behind the scenes, subtly influencing how search engine spiders interact with our website content, including TDK tags.

2025-11-07