How to use AnQiCMS built-in TDK tags to dynamically set page SEO information?

Calendar 👁️ 74

As an experienced website operator, I know the importance of search engine optimization (SEO) for website visibility and traffic growth.In SEO work, the reasonable setting of TDK (Title, Description, Keywords) tags is undoubtedly the cornerstone of the cornerstone.A clear and accurate TDK that can not only help search engines better understand the page content, but also attract users' clicks in search results.AnQiCMS provides very flexible and powerful dynamic setting functions for TDK tags, allowing us to carry out detailed SEO optimization according to the characteristics of different pages.

Understand the importance of TDK tags in AnQiCMS

TDK, which stands for Title, Description, and Keywords of a webpage, is HTML<head>The three key meta tags. They pass the core information of the page to search engines and users.

  • Title (Title)This is the most important display content in the search results, as well as the text displayed in the browser tab. It directly affects the user's willingness to click and the search engine's judgment on the page theme.
  • Description (Description): Although it does not directly affect ranking, a high-quality description can serve as a summary of search results, attract users to click, and improve click-through rate (CTR).
  • Keywords (Keywords): Although modern search engines have significantly reduced their weight, reasonable settings can still help search engines understand the theme of a page, especially in some vertical or niche fields, which still have certain reference value.

The design philosophy of AnQiCMS includes SEO-friendly features, it is built-in with a complete TDK management system, allowing us to finely control these important meta tags from global to local.

Global TDK settings: lay the foundation for the website tone

When you first set up a website or want to set a unified SEO tone for the entire website, you can start with the global TDK settings of AnQiCMS.

In the background management interface, you will usually find the 'Background Settings' area, where there is a special option for 'Homepage TDK Settings'. Here, you can configure the TDK information for the website's homepage:

  • Home titleHere, you usually fill in the core brand name or the most core service/product name of your website, which will serve as the homepage<title>the content of the tag.
  • Home page keywordsEnter core keywords highly relevant to your website theme, separated by English commas,Separated.
  • Home page descriptionWrite a concise and clear description that summarizes the overall content and core value of the website. This text is usually used as the abstract in search results.

These global settings mainly take effect on the homepage of the website, laying the foundation for the SEO optimization of the entire website.

Dynamic TDK: Customized SEO information for each content.

The true strength of AnQiCMS lies in its ability to dynamically set TDK, which means you can set unique and most suitable TDK information for each article, category, and even each independent page on the website.This is like putting the most suitable labels on each product to ensure they stand out in the vast sea of search results.

  1. Article (Document) Page: When you publish or edit an article, you will see fields such as 'SEO Title', 'Document Keywords', and 'Document Summary'.

    • SEO titleHere the title will directly be the page of the article<title>Label content. If left blank, the system may automatically use the article title. You can write a unique and attractive title that includes core keywords based on the article content.
    • Document keywordSelect or input the most relevant keywords for the current article, separated by English commas,Separated.
    • Document IntroductionThis is the article page.<meta name="description" ...>Tag content. If left blank, AnQiCMS will automatically extract the first 150 characters from the article content as a description, but this is usually not as accurate or attractive as writing it manually.In addition, in the article editing interface, you can also set the 'Canonical URL', which is very important for dealing with content duplication issues and concentrating page weight.
  2. Category page: When managing and editing categories, similarly, you can also configure exclusive SEO information for each category.

    • SEO title: As the category page's<title>Tag content.
    • Keywords: Choose or enter keywords for the current category page.
    • Category introductionHere is the text that will be used as the category page<meta name="description" ...>Content.
  3. single pageFor independent single pages such as "About Us" and "Contact Us", AnQiCMS also provides a detailed TDK setting entry.

    • SEO titleSet the single page's<title>.
    • KeywordsAdd keywords to the single page.
    • Single page introductionAs a single page.<meta name="description" ...>Content.

Flexibly call TDK tags in the template.

After setting up the background TDK information, the next step is to correctly reference them in the front-end template, so that browsers and search engines can crawl this information. AnQiCMS provides a powerful "Universal TDK Tag"{% tdk %}making this task very convenient.

You just need to use the template file (usually)head.htmlorbase.htmllocated in the HTML's<head>area) to dynamically output TDK information in the following way:

  • Page Title (Title):

    <title>{% tdk with name="Title" siteName=true sep="-" %}</title>
    

    here,name="Title"Tell the system that you want to get the page title.siteName=trueMeans that the global name of the website is automatically appended to the title,sep="-"It defines the separator between the title and the website name, you can set it to other characters according to your preference, such as_or|. If the current page is a category page and you want to include the name of the parent category in the title, you can also addshowParent=true.

  • Page Keywords (Keywords):

    <meta name="keywords" content="{% tdk with name="Keywords" %}">
    

    This label will output the keywords of the current page.

  • Page Description (Description):

    <meta name="description" content="{% tdk with name="Description" %}">
    

    This label will output the description content of the current page.

  • Standard Link (Canonical URL): To avoid outputting empty tags for the standard link, we usually check if it exists first and then output it:

    {%- tdk canonical with name="CanonicalUrl" %}
    {%- if canonical %}
    <link rel="canonical" href="{{canonical}}" />
    {%- endif %}
    

    here,{%-and-%}Is a special syntax of AnQiCMS template engine, used to remove whitespace on both sides of the tag to ensure that the generated HTML code is cleaner.

In this way, AnQiCMS will automatically call the corresponding TDK settings based on the type of page visited by the user (home page, article page, category page, single page, etc.)If a specific page does not set TDK, the system will also intelligently backtrack to the parent category or global settings to ensure that each page has default SEO information.

Conclusion

The TDK tag dynamic setting feature built-in to AnQi CMS provides great convenience and flexibility for website operators.From global website brand positioning to personalized optimization of each specific content, it can handle it easily.Make good use of these tools, transform technical information into easy-to-understand and practical expressions, and your website's performance in search engines will surely rise, attracting more target users.


Frequently Asked Questions (FAQ)

1. If I have not set the SEO title, keywords, and description for an article or category, how will AnQiCMS handle it?AnQiCMS will adopt an intelligent rollback mechanism. If a specific page does not set this information, the system will try to trace upwards, such as looking for the settings of its category.If the category is not set, the home page TDK information in the global settings of the website will be used eventually.This means that even if you forget to set it, your page will not be completely lacking in TDK information, but it may not be very accurate.

2. What is the role of 'Canonical URL' in TDK tags? When should I use it?The canonical URL is used to tell search engines which URL is the "preferred" or "canonical" version when there are multiple URLs pointing to the same or very similar content on a website. This is mainly used to solve content duplication issues, such as different URL parameters generating

Related articles

How to use the Canonical URL feature of AnQiCMS to avoid content duplication display issues?

In website operations, we often encounter a tricky problem: content duplication.This does not refer to manually copying and pasting the article, but rather to the fact that the same content can be accessed through multiple different URL addresses due to various technical reasons.For search engines, this can cause confusion, as they are not sure which URL is the official version of the content, which may scatter the ranking weight of the page, reduce the efficiency of the crawler, and even affect the overall SEO performance of the website.Luckyly, AnQiCMS provides a powerful and convenient feature——Canonical

2025-11-07

How to configure the page Title, Keywords, Description of AnQiCMS to optimize search engine display?

In website operation, making your content stand out in search engines is a key step to gaining traffic.And the page title (Title), keywords (Keywords), and description (Description), which we often call TDK, are important elements for communicating with search engines.AnQiCMS is a system focused on enterprise content management, fully aware of the value of TDK configuration for SEO, and therefore provides flexible and powerful functions to help us easily optimize the display of our website in search engines.### Why is TDK configuration so important

2025-11-07

How to use AnQiCMS tags to display categories and documents in the navigation menu?

In AnQiCMS, the website's navigation menu is not only an important entry for users to explore content and understand the website structure, but it is also a key for search engines to crawl and understand the website's hierarchical relationships.Using the powerful template tag feature of AnQiCMS, we can easily display categories and documents dynamically in the navigation menu, thus building a beautiful and efficient website navigation. ### One, prepare the background work: build the navigation skeleton Before delving into the template code, we need to make some basic configurations in the AnQiCMS background.In fact, the data that the front-end tags can retrieve and display

2025-11-07

How to control the display sorting and pagination of AnQiCMS comment list?

In AnQi CMS, efficiently managing and displaying website comments is crucial for enhancing user interaction and optimizing content experience.The display order and pagination settings of the comment list directly affect the user's experience when browsing comments.This article will give you a detailed explanation of how to accurately control the sorting and pagination of comments in AnQiCMS. ### Understanding the Comment List Template Structure Firstly, we need to clarify the position of the comment list in AnQiCMS.

2025-11-07

How to correctly configure the pseudo-static rules in AnQiCMS to generate URLs that are friendly to users and search engines?

In website operation, a URL structure that is friendly to both users and search engines is crucial.It not only allows visitors to understand the page content at a glance, but also makes it convenient for search engines to crawl and understand your website, which directly affects the SEO performance and user experience of your website.AnQiCMS (AnQiCMS) knows this well, therefore it is built with powerful pseudo-static features, allowing you to easily customize the URL of your website.Next, we will explore how to correctly configure the pseudo-static rules in AnQiCMS to generate those beautiful and practical URLs.

2025-11-07

How to display the AnQiCMS page's canonical URL?

In website operation, we often encounter the situation where content appears repeatedly under different URLs.For example, a product may have multiple colors, each color generating an independent page, but their core content is the same.Or, in order to track traffic, websites may add various parameters to the URL.This "duplicate" content, although it has little impact on user experience, but it may confuse search engines, not knowing which is the "original version", thus possibly affecting the crawling efficiency and ranking of the website.

2025-11-07

How to perform addition of numbers and strings in AnQiCMS template and display the result?

When building dynamic content in AnQi CMS templates, it is often necessary to perform simple calculations and concatenations of numbers or strings.Whether it is to display the cumulative user points or to combine and display product codes with specific prefixes, Anqi CMS provides a flexible and convenient way to meet these needs.This article will deeply explore how to perform addition operations in the AnQiCMS template, and provide detailed examples and practical suggestions.### Understanding the computational capabilities of AnQi CMS template The AnQi CMS template system is based on syntax similar to the Django template engine

2025-11-07

How to use AnQiCMS filter to display strings centered or aligned to a specified length?

In website content display, we often need to format text to make it more beautiful and tidy in layout, especially in lists, tables, or areas that require a unified visual effect.AnQiCMS (AnQiCMS) powerful template engine provides a variety of practical filters (filters) that can help us easily achieve centered, left-aligned, or right-aligned strings and can be filled to a specified length.

2025-11-07