What are the pseudo-static rule modes supported by AnQiCMS, and how to customize the URL structure?

Calendar 👁️ 67

As an experienced CMS website operation personnel of an enterprise, I know that a friendly and efficient URL structure is crucial for the website's SEO and user experience.The Anqi CMS provides a rich selection of rules for pseudo-static, whether it is the ready-to-use preset mode or the highly flexible custom configuration, it can meet the needs of various websites.

Pseudo-static rules supported by AnQiCMS

The static rules can rewrite dynamic parameterized URLs into static file-formatted URLs, which not only makes the URL more readable but also more friendly to search engine crawlers, thus improving the website's SEO performance.AnQi CMS provides several built-in pseudo-static rule modes to adapt to different types of websites and operational strategies.

Numeric pattern

The number pattern is a concise URL structure, mainly based on the content ID (unique identifier) for URL generation.In the document detail page, document list page, single page and tag page, the URL usually contains the numeric ID of the content.This pattern is widely used on websites with Chinese character content because the URL generation of numeric IDs is more stable and direct.

Model naming pattern

The model naming pattern introduces the name of the content model as an identifier in the URL.For example, an article (archive) or a product (product), etc.This pattern is particularly common on English websites, making the URL not only contain the content ID but also clearly indicate the type of content, which helps improve the semanticization of the URL.

Category naming pattern 1 and Category naming pattern 2

These two patterns integrate the category name of the content into the URL structure, but may have a focus on specific implementation.For example, one pattern may be more focused on the hierarchical relationship between parent and child categories, while another may only contain direct categories.The category naming pattern is clear for content organization, and it is beneficial for Chinese websites or multilingual websites that hope the URL reflects the hierarchy of content.They further strengthen the semantics of the URL by embedding the category name in it.

How to customize URL structure

In addition to the above four preset modes, Anqi CMS also provides powerful custom static rule functions, which allow website operators to create unique URL structures according to specific business needs.The custom mode is an advanced feature that requires more detailed configuration to ensure the smooth operation of the website.

The configuration of custom rules is based on six main page types, which are: document detail page, document list page, model home page, single page, tag list page, and tag detail page.Each custom rule follows the format "rule name===rule value" for configuration.

When building rule values, you can flexibly use a series of preset variables to dynamically generate URLs. These variables include:

  • {id}This represents the unique ID of the content.
  • {filename}Represents a custom link alias for content (such as a document, single page, or tag).
  • {catname}Represents a custom link alias for categories.
  • {catid}Represents the unique ID for categories.
  • {module}: Represents the table name or URL alias of the content model.
  • {page}: Represents the page number for pagination, which should be placed within parentheses when used, for example.(/{page}).

By combining these variables, you can create various complex URL structures. For example, a typical set of custom rules might look like this:

archive===/{module}-{id}.html
category===/{module}-{filename}(-{page})
archiveIndex===/{module}.html
page===/{filename}.html
tagIndex===/tags(-{page})
tag===/tag-{id}(-{page})

This example rule demonstrates how to configure unique URLs for different types of pages.For example, the URL of the document detail page will include the model name and document ID;The URL of the category page will include the model name and the custom alias of the category, and optionally pagination information can be added.This high degree of flexibility allows you to design URLs for every important page on the website that are both beneficial for SEO and consistent with the brand image.

In actual operation, the setting of custom URL structure aliases runs through the content creation and management process.

  • DocumentIn the "Add Document" or edit document interface, there will be a "Custom URL" field.The AnqiCMS will automatically generate a pinyin alias based on the title of the document you enter as the default value.You can choose to accept the default value or manually enter a custom alias.It should be noted that each document's custom URL must be unique throughout the entire site.If the manually entered alias is not unique, the system will automatically add a random number after it to ensure uniqueness.

  • CategoryIn the document category management interface, when creating or editing categories, a 'custom URL' field is also provided.It will also automatically generate a pinyin alias based on the category name. Similar to the document, the custom URL of the category also needs to ensure the uniqueness of the entire site.

  • single pageIn the "Page Management" section, each single page (such as "About Us", "Contact Information") has a "Custom URL" field.The principle of its operation is consistent with documents and categories, supports automatic generation of pinyin aliases and manual modification, and requires uniqueness.

  • TagIn the "Document Tag" management, you can set a "custom URL" for each tag.This custom URL also supports automatic pinyin generation and manual modification, and it must be unique across the entire site.In addition, the custom URL of the tag only supports letters, numbers, and underscores, and cannot contain spaces.

By careful planning and configuration, the pseudo-static feature of Anqi CMS can help you build a website that is friendly to search engines and provides a smooth user experience.

Frequently Asked Questions (FAQ)

  1. What problems would I encounter if I configure my custom static rule incorrectly?Incorrect configuration of pseudo-static rules may cause website pages to be inaccessible (for example, a 404 error occurs), or links to incorrect content.Before enabling custom rules, it is recommended to conduct thorough testing in a test environment and ensure that all important page links can be correctly parsed.Once a problem is found, please check and correct the rule configuration immediately.

  2. What is the main difference between 'numeric pattern' and 'model naming pattern', and how should I choose?The numeric pattern primarily uses the unique ID of the content as the main component of the URL, making the URL structure simpler, for example/archive/123.html. The model naming pattern will include the content model name in the URL, for example/article/123.htmlor/product/456.html. For websites mainly aimed at Chinese users, or when a short URL is preferred, a numeric pattern may be a good choice.If your website has a variety of content types and you want the URL to clearly indicate the content type, or you prefer an English URL structure, then the model naming pattern will be more advantageous.

  3. Why does the system automatically add random numbers to the end of my alias when setting a custom URL?The system will check the uniqueness of the custom URL alias you set manually after it is checked within the entire site range.If the alias you enter has been occupied by other documents, categories, single pages, or tags, the system will automatically append a random number to your alias to avoid link conflicts, ensuring that each page's URL is unique.To maintain the cleanliness of the URL, it is recommended to plan ahead when setting a custom alias and try to ensure its uniqueness.

Related articles

How to configure the Baidu and Bing search engine link active push in AnQiCMS?

As an experienced CMS website operator, I know the importance of search engine主动推送 for the rapid inclusion of website content and SEO optimization.AnQiCMS as a platform focusing on efficient content management, built-in convenient link push function, can help operators timely inform Baidu, Bing and other mainstream search engines of the new released or updated content, thus improving the visibility and crawling efficiency of the website.The following will elaborate on how to configure Baidu and Bing search engine link active push in AnQiCMS.

2025-11-06

How to add multi-level menus and custom navigation categories in the AnQiCMS website navigation?

As a long-term practitioner engaged in website operation and having a deep understanding of AnQiCMS (AnQiCMS), I know that a clear and easy-to-use website navigation system is important for user experience and SEO optimization.AnQiCMS provides flexible and powerful navigation management features, allowing operation personnel to easily build multi-level menus and customize navigation categories according to the website structure and user needs.Below, I will elaborate on how to implement these functions in AnQiCMS.--- Build a clear and organized website navigation

2025-11-06

How to set the download, link filtering, and webp format conversion for content images on AnQiCMS?

As an experienced CMS website operation personnel, I am well aware of the core position of content images in website operation.The quality, loading speed, and management methods of images directly affect user experience and search engine optimization effects.AnQiCMS provides us with powerful and flexible image processing capabilities, especially in image downloading, external link filtering, and format conversion, which can help us efficiently optimize the website's image resources.

2025-11-06

What features does the AnQiCMS backend global settings include, and how to customize parameters?

As a senior security CMS website operator, I know the importance of the background global settings.It is not only the 'brain' of the website, determining the overall performance and operational efficiency of the website, but also the foundation for us to achieve refined content management and optimization.With a proficient grasp and flexible application of these settings, we can ensure the stability and efficiency of the website and quickly adjust strategies based on market and user needs.This article will discuss in detail the core functions included in the Anqi CMS background global settings, as well as how to effectively customize parameters to meet the unique needs of our website.

2025-11-06

How to correctly display Markdown content, mathematical formulas, and flowcharts in AnQiCMS templates?

As an experienced AnQiCMS website operator, I know that it is crucial to display a diverse range of information efficiently and accurately in the increasingly rich online content ecosystem.Markdown is a lightweight markup language that is widely popular for its simplicity and efficiency.And mathematical formulas and flowcharts are essential expressions for conveying science, technology, or complex logic.This article will detail how to properly configure the AnQiCMS template to perfectly present these advanced contents.

2025-11-06

How to use the `archiveDetail` tag in AnQiCMS template to get document details and custom fields?

As an experienced CMS website operation personnel, I am well aware of the core position of content in website operations.We must not only create high-quality content, but also ensure that this content can be presented to users in a **way.In this, the flexible use of templates is crucial. Today, we will delve into a powerful and commonly used tag in AnQiCMS templates, `archiveDetail`, which helps us easily obtain detailed information about documents, including those carefully designed custom fields.###

2025-11-06

How to use the `archiveList` tag to call the document list with specified categories and recommended attributes?

AnQi CMS is an efficient enterprise-level content management system, whose powerful content tags are the core of dynamic and personalized content display.For website operators, mastering these tags, especially `archiveList`, can greatly enhance the flexibility and efficiency of content management.This article will elaborate on how to use the `archiveList` tag to accurately call the document list with specified categories and recommended attributes, helping you to better build website pages that meet user needs and optimize content display.###

2025-11-06

How to implement document parameter filtering in AnQiCMS templates, for example, filtering by house type?

As an experienced CMS website operator for a security company, I know how important it is for users to efficiently find the content they need when visiting a website with a large amount of information.The content filtering function can not only greatly improve user experience, but also is a key factor in optimizing website structure and SEO performance.Today, I will elaborate on how to implement document parameter filtering in AnQiCMS templates, taking 'filtering by house type' as an example, to help your website better serve users.

2025-11-06