In website operation, the URL is not only the entrance for users to access content, but also an important basis for search engines to understand and extract website content.A clear and semantic-friendly URL that can significantly improve user experience and website performance in search engines.One of the keys to achieving this goal is to cleverly use pseudo-static technology.
AnQiCMS is an efficient and customizable content management system that fully considers the needs of SEO optimization, providing powerful and flexible pseudo-static rule configuration functions.Today, let's delve into how to use the pseudo-static rules of AnQiCMS to optimize the display structure of article URLs, thereby effectively improving the SEO performance of the website.
What are the things about website structure and SEO?
When we browse the web in our daily lives, we may come across two types of URLs. One is a dynamic URL, which usually contains question marks, equals signs, and a series of seemingly random numbers or letters, for exampleyourdomain.com/article.php?id=123&category=techThis kind of URL can be accessed normally, but it is not friendly to search engines and users.
And another one is a pseudo-static URL, which looks like a static HTML file, concise and meaningful, for exampleyourdomain.com/tech/anqicms-seo-tips.htmlThis kind of URL is not only easier to remember and share, but also allows search engines to clearly understand the theme and hierarchy of the page content, thereby improving the efficiency of crawling and the potential for ranking.
The pseudo-static feature of AnQiCMS is exactly what helps us convert complex dynamic parameters into this concise and friendly pseudo-static URL.
Overview of AnQiCMS pseudo-static feature
The built-in pseudo-static feature of AnQiCMS is located in the "Function Management" backend, click "Pseudo-static Rule" to enter the configuration page.Here are various preset rules and highly customizable options, allowing us to flexibly adjust the URL structure according to the specific needs of the website.
The system provides four default rule options that can meet the initial needs of most websites, saving the trouble of manually writing complex rules:
Numeric mode:This is the most common pattern, document details, lists, single pages and tab pages are all used
{id}It is used as the basis for generating URLs. For example, articles may be/article/123.htmlThis pattern is concise and clear, suitable for Chinese websites with a large amount of content and the need to quickly index by ID.Model naming pattern:It is usually used for English websites. It will include the content model in the URL, such as
articleorproductThe alias, followed by the custom link name or ID of the content. For example,/article-anqicms-seo-tips.htmlThis helps users and search engines understand the type of content.Category naming pattern 1:It is commonly used on Chinese websites. It incorporates the category custom link name or ID into the URL, followed by the custom link name or ID of the content. For example,
/tech/anqicms-seo-tips.htmlThis pattern can well display the hierarchical structure of the website.Category naming pattern 2:Similar to the model naming pattern, but more focused on the classification level, commonly used in English websites. For example,
/technology/anqicms-seo-tips.html.
Choose the appropriate preset mode to get started quickly, but when pursuing the ultimate SEO effect, we often need more precise control.
Customize the static rules to create a unique URL structure
AnQiCMS's "Custom Mode" gives us the greatest flexibility, allowing us to design unique URL structures based on content types (documents, categories, single pages, tags, etc.).This is like customizing a set of address numbers for each content module of the website.
Configure using custom rules规则名===规则值Format. The system has predefined six main rule names corresponding to different page types on the website:
archive: Document detail page (articles, products, etc.)category: Document category list pagearchiveIndex: Home page of content model (such as list page of all articles)page: Single page detail pagetagIndex: List page of all tagstag: Document list page under a specific tag
In the corresponding rule names规则值In it, we can skillfully combine multiple variables to build meaningful URLs. AnQiCMS provides the following core variables:
{id}: The unique ID of the content, such as article ID, category ID.{filename}Custom link name for content. While editing documents, categories, single pages, and tags, you can enter this value in the 'Custom URL' field. The system will default to generating pinyin based on the title, but you can manually modify it to better fit SEO and brand image in English or pinyin.{catname}: The custom link name of the category. It is also set when editing the category.{catid}Unique ID of the category.{module}: The URL alias of the content model. Set in the content model management, usually the English name of the model, such asarticle/product.{page}: The page number of pagination. This variable usually needs to be enclosed in parentheses, such as(/{page})to display in the URL/page/2or/2such as this form, and it only appears when actual pagination is used.
Let's take a few examples of custom rules to see how these variables can be combined:
A concise and clear document URL (recommended for English sites):
archive===/{module}/{filename}.htmlThis will generate such/article/anqicms-seo-tips.htmlURL, directly displaying the model type and article topic, very clear.Document URL with a classified hierarchy:
archive===/{catname}/{filename}.htmlIf your website hierarchy is important, this rule can make the URL more structured, for example/tech/anqicms-seo-tips.html.Optimize pagination list URL:
category===/{catname}(-{page})This will generate such category list pages as/tech/(Page 1) and/tech-2/(Page 2) URL, beautiful and easy for search engines to understand pagination relationships.Create a concise and robust URL for a single page:
page===/{filename}.htmlLike the "About Us" page, its URL can be/about.html, concise and forceful.
In the setting{filename}and{catname}Remember to edit the document, category, single page, and tag interface in the background, and find the 'Custom URL' field to fill in.A well-crafted custom URL should include core keywords and be short and easy to read, which is very beneficial for search engine keyword recognition and user memory.
Apply and manage the rules of pseudo-static in practice.
Configure the pseudo-static rules is a process that requires careful planning.Once the rules are determined, you can select the "Custom Mode" on the "Function Management" -> "Static Rule" page of the AnQiCMS backend, and then fill in your rules one by one.
The key steps are:
- Establish rules:Plan the ideal URL structure for each page type meticulously, ensuring they have good readability, contain keywords, and reflect the hierarchy of the website.
- Input system: In the custom mode in the background, fill in the rules you have designed.
- Save and observe:After saving the rules, visit the website's front end and check if the URL is generated as expected.
- Use 301 redirect:If your website has already been launched and you are changing the existing URL structure, thenMake sureCooperate with the AnQiCMS '301 Redirect Management' feature.Redirect the old URL precisely to the new URL, which can effectively avoid 404 errors and losses of traffic and SEO weight caused by URL changes.AnQiCMS provides a convenient 301 redirect setting, which is an important tool to ensure a smooth transition of the website.
Key considerations for improving SEO
Optimizing URL structure is not just about technical configuration, it is also a content operation strategy. When using the pseudo-static rules of AnQiCMS, it is recommended that you:
- Integrate keywords:Embed core keywords related to the content topic within the URL, which helps enhance the search engine's understanding of the page topic.
- Maintain conciseness:The shorter the URL, the better. It avoids redundant information. A long URL is not only unattractive but may also reduce the willingness of users to click.
- Ensure readability:Even if it contains keywords, the URL should look natural and easy to understand, as if a sentence can describe the content.
- Reflect the hierarchical structure:The URL path should as far as possible reflect the actual content hierarchy of the website, helping search engines build the website map.
- Maintain consistency:Once the URL structure is determined, try to maintain consistency throughout the entire site and avoid frequent changes. If a change is indeed necessary, please be sure to set up 301 redirect.
By using AnQiCMS's flexible pseudo-static rules, we can make the optimization work of seemingly complex URLs accessible.A reasonable plan and careful configuration will help our website stand out in search engines and attract more target users.
Frequently Asked Questions (FAQ)
1. After modifying the static rules, will the old URL become invalid? What should I do?
Yes, after modifying the static rule, the website's URL will be generated according to the new rule, and the old URL will no longer be directly accessible. Visiting the old URL may result in a 404 error.To avoid traffic and SEO weight loss, you need to immediately use the "301 Redirect Management" function in the AnQiCMS backend.Redirect all important old URLs one-to-one or in bulk to their corresponding new URLs, informing search engines that the page has been permanently migrated to maintain SEO rankings and user experience.
2. How can I set a custom URL alias for my articles or categories (i.e.{filename}and{catname})?
In AnQiCMS backend, when you edit articles, categories, single pages, or tags, there will be a field named "Custom URL" in the corresponding editing interface.The system usually generates a pinyin alias automatically based on the title you enter, but you can manually modify this field and enter a personalized, meaningful English or pinyin alias that you want to display in the URL.Make sure this alias is unique across the entire site, concise, and contains keywords for SEO optimization.
3. What are the differences and usage scenarios of pseudo-static rules?{filename}/{catname}and{module}What are the differences and usage scenarios of variables?
{filename}It refers to the custom link name of a single content item (such as an article, a single page, a tag), which is set for you in the corresponding 'Custom URL' field.It focuses on describing the theme of a single page.{catname}It refers to the custom link name of the category, set in the 'Custom URL' field on the category editing page. It is used to represent the category hierarchy of the content.{module}It refers to the URL alias of the content model (such as “article”, “product”) set in the content model management. It represents the macro type of the content.
In terms of use cases,{filename}Used for document details and single pages, directly reflecting the content theme;{catname}Used for category lists and document details, to show the content category level; while{module}It is more commonly used on the model homepage or as a general prefix for URLs to distinguish different types of content.According to your website structure and SEO strategy, you can flexibly combine these variables to build the most appropriate URL.