How to set and display the pseudo-static URL structure of the AnQiCMS website?

Calendar 👁️ 70

AnQiCMS provides a flexible and powerful pseudostatic URL structure setting function in website operation, which is crucial for the SEO performance and user experience of the website.Static URL, as the name implies, makes the links of dynamically generated pages look like simple and regular file paths, thereby making it easier for search engines to crawl and for users to understand.

Why is the pseudo-static URL so important?

Before delving into how AnQiCMS sets up URL rewriting, let's briefly review why it occupies such an important position in website operation:

  1. Improve search engine optimization (SEO): Search engine spiders prefer URLs that are structured clearly and semantically explicit.Static URLs usually contain meaningful keywords, rather than a string of unordered parameters, which helps search engines better understand the content of the page and thus improve the inclusion and ranking of the website.
  2. optimize user experienceA concise and readable URL is not only convenient for users to remember and share, but can also increase users' trust in the website to some extent.When a user sees a clean URL, they are more likely to click and browse.
  3. Enhance link stability: The dynamic URL may become invalid due to parameter changes.Once a static URL is set, it usually remains relatively stable, reducing the occurrence of dead links, which is particularly beneficial for long-term operation of websites.

AnQiCMS fully understands these advantages, therefore, in the system design, it takes pseudo-static as a core feature, providing users with a variety of settings from convenient selection to in-depth customization.

The core implementation mechanism of AnQiCMS static aliasing

AnQiCMS combines backend routing rules with frontend page rendering to achieve pseudo-static.In simple terms, when a user accesses a pseudo-static URL, the website server (such as Nginx, Apache) will forward the request to the AnQiCMS application.AnQiCMS again parses the content that the user actually wants to access according to the internal static rule configuration (for example, article ID, category ID), then retrieves the corresponding data from the database and renders the page, and finally returns it to the user.

Two modes of settings: quick start and deep customization

AnQiCMS provides two kinds of static settings for users to meet different needs:

1. Built-in static rules: a convenient choice

For most users, the four built-in static rules provided by AnQiCMS are sufficient to meet daily needs, covering common URL structures for Chinese and English websites, allowing you to have SEO-friendly links without complex configuration:

  • Numeric pattern: Use the content ID as the unique identifier for the URL. For example:/article/123.html.
  • Model naming pattern: Include the alias of the content model (such as article, product) in the URL for better semantics. For example:/article/seo-guide.html.
  • Classification naming pattern 1: Include category alias in the URL, which is commonly used on Chinese websites. For example:/news/industry-trends-123.html.
  • Classification naming pattern 2: It also includes category aliases, but may use different delimiters or structures, more suitable for English sites. For example:/category/news/article-title.html.

These built-in rules can be directly selected and enabled in the 'Function Management' -> 'URL Rewrite Rule' section of the AnQiCMS backend, which is very suitable for users who want to quickly build a website.

2. Customize the pseudo-static rules: have everything under control

If you have a specific SEO strategy, brand needs, or need to maintain consistency with the old website's URL structure, AnQiCMS's custom static rule feature will provide ultimate flexibility.This belongs to the advanced mode, it needs to be particularly meticulous in configuration to avoid the page from being inaccessible.

Customize the pseudo-static rules can be set for the following six types of pages:

  • Document details page (archive): such as articles, product detail pages.
  • Document list page (category): such as category list pages.
  • Model homepage (archiveIndex): Such as article homepage, product homepage.
  • Single page (page): Such as 'About Us', 'Contact Us' and other independent pages.
  • Tag list page (tagIndex): Display page for all tags.
  • Tag detail page (tag): Display page for contents under a specific tag.

Each custom rule follows规则名===规则值format. For example,archive===/{module}-{filename}.html.

In规则值In Chinese, you can flexibly use the variables provided by AnQiCMS to construct your URL:

  • {id}: The unique ID of the content (such as article ID, category ID).
  • {filename}: The custom URL alias for content.
  • {catname}Custom URL alias for a category.
  • {catid}Unique ID of the category.
  • {module}The content model (such as)article/productURL alias for ).
  • {page}Page number.Please note: Page number variable.{page}Must be in parentheses.()Wrapped in, for example.(-{page})It indicates that pagination is optional and is displayed only when pagination is present.

Custom rule example:

`conf

Document details page: Model alias/Content alias.html

archive===/{module}/{filename}.html

Document list page: category alias/(optional pagination)

Related articles

How to format and display the article's publish timestamp in AnQiCMS templates?

In Anqi CMS, we all hope that visitors can clearly see the publication or update time of the articles.A clear and beautiful time format not only enhances the professionalism of the page but also optimizes the user experience.AnQi CMS with its flexible template engine makes it very simple to customize the display format of timestamps.Next, we will explore how to present the publishing time of articles accurately and elegantly in the AnQiCMS template.Understanding time data in AnQiCMS templates

2025-11-07

How to automatically add the `rel="nofollow"` attribute to hyperlinks in the page to optimize SEO?

In website content operation, hyperlinks play a vital role, they are not only the bridge for users to browse and obtain information, but also the key for search engines to understand the structure of the website and pass on page authority (PageRank).However, not all links should pass weight, especially links to external websites.At this point, the `rel="nofollow"` attribute comes into play, which can tell the search engine "Do not follow this link, nor pass the weight of this page to the link target".Use `rel="nofollow"` appropriately

2025-11-07

How does AnQiCMS handle and display image resources, including thumbnails and original images?

The charm of website content largely comes from images.They not only beautify the page, but also convey information directly, catching the reader's eye.Therefore, how a content management system (CMS) efficiently and intelligently handles and displays image resources is crucial for the overall performance of a website.AnQiCMS (AnQiCMS) provides a comprehensive and flexible solution in this regard, whether it is for the automatic generation of thumbnails or the optimization and presentation of the original images, it can help us easily manage the visual content of the website.

2025-11-07

How to display the subcategory list under a specified category in AnQiCMS template?

When using AnQiCMS to build a website, clearly organizing content and conveniently displaying it on the page is the key to improving user experience.Especially for content with multi-level classification structures, how to flexibly display the subcategory list under a specified category in the template is a need many users will encounter.A powerful template tag system of AnQiCMS, especially the `categoryList` tag, provides us with an elegant and efficient solution.### Understanding AnQiCMS Classification Structure Before delving into templates, it is important to understand how AnQiCMS manages classifications

2025-11-07

How to display the current page's TDK (Title, Description, Keywords) information in AnQiCMS template?

In website operation, the TDK (Title, Description, Keywords) information of the website plays a vital role.They are not only the key for search engines to understand the content of the page, but also a critical factor for users to decide whether to click on your website in the search results.A well-optimized TDK can significantly improve a website's ranking in search engines and attract more target users.AnQiCMS (AnQiCMS) is a content management system designed for SEO optimization, naturally providing strong and flexible support for TDK management

2025-11-07

How to enable Markdown editor in AnQiCMS and ensure that mathematical formulas and flowcharts are displayed correctly on the webpage?

AnQiCMS provides a flexible and diverse editing experience for content creators, and the introduction of the Markdown editor has made it even more convenient for many users who are familiar with this concise markup language.However, simply enabling the Markdown editor is not enough for content that requires special rendering, such as mathematical formulas and flowcharts.This article will provide a detailed guide on how to enable Markdown editor in AnQiCMS and ensure that your web page can correctly and beautifully display complex mathematical formulas and flowcharts.### One, Enable

2025-11-07

How to implement lazy loading (lazyload) feature in AnQiCMS article content?

On your AnQiCMS website, optimizing image loading is a key step to improving user experience and website performance, especially for pages with a large number of image content.The Lazy Load (Lazy Load) technology is an efficient solution that allows the page to only load images within the user's viewport, while deferring the loading of images outside the viewport until the user scrolls near them.This can significantly reduce the initial page loading time, save bandwidth, and improve the overall website response speed.

2025-11-07

How to display single page content in AnQiCMS, such as the "About Us" or "Contact Us" page?

Displaying single-page content such as 'About Us' or 'Contact Us' in AnQiCMS is a very intuitive and flexible process.The system is designed to meet the needs of such static information display, through simple backend management and powerful template rendering capabilities, allowing you to easily create and beautify these important web pages. ### Create and Manage Single Page in the Back-end Firstly, all the content of single pages needs to be created and managed in the AnQiCMS back-end.

2025-11-07