How to customize the content model in AnQiCMS to achieve diversified content display?

Calendar 👁️ 70

In website operation, the diversity of content is the key to attracting users, improving experience, and optimizing search engine rankings.AnQiCMS provides a highly flexible mechanism that allows users to break free from the constraints of traditional content management systems (CMS) such as 'articles', 'products', etc., and achieve truly diverse content display through custom content models.

Why do you need to customize the content model?

Imagine that you are running not just a blog, but a comprehensive platform that includes recruitment information, real estate rental, online courses, event registration, and a variety of other businesses.If all the content is squeezed into the framework of "article" or "product", then the structure of the content will become chaotic, the display of information will be greatly discounted, it will be extremely difficult for users to find information, and it will also not be conducive to the refined management of content and the crawling of search engines.

The custom content model feature of AnQiCMS is exactly for solving these problems.It allows you to create exclusive 'data blueprints' based on specific business requirements, ensuring that each type of content can be published and displayed in the most appropriate and structured way.For example, you can define position name, salary range, work location, and skill requirements for 'Recruitment Information'; define event name, time, location, and registration limit for 'Event'.This flexibility greatly enhances the adaptability of the system, allowing your website to carry various forms of content.

Create a custom content model: Practice from Zero to One

On the AnQiCMS backend, you will find an option for the 'Content Model' under the 'Content Management' module.This is the core management area of all content models.The system is pre-installed with "Article Model" and "Product Model", which are commonly used content types, but you can create more according to your needs.

Creating a new content model requires attention to several core settings:

  1. Model name:This is a user-friendly identifier, for example, you can name it "Recruitment Information", "Real Estate Lease" or "Event Details".This name will be displayed in the backend management interface, helping you and your team distinguish between different types of content.
  2. Model table name:This is a technical identifier used to store the table name of the model data in the database.For the stability and standardization of the system, it is usually necessary to use English lowercase letters and ensure their uniqueness.
  3. URL alias:This alias will be used for the URL path of the website's front-end content, which is crucial for the SEO-friendliness of the website. It is also recommended to use lowercase English letters, for example, if you created a "Event Details" model, the URL alias could beeventThen the link to the activity content might be/event/活动ID.html.
  4. Title Name:This is a thoughtful design, it defines the prompt text for the "Title" field when you publish the model content.For example, for the "Recruitment Information

Customize deeply: Define exclusive fields for your model

After creating the basic information of the content model, the real flexibility is reflected in the "Content Model Custom Fields" section.You can add any fields you need to your new model to accurately describe this type of content.

  • Single-line text:Suitable for brief text information, such as 'product brand', 'author name', 'event contact', etc.
  • Number: Designed for numeric input, such as "product price
  • Multi-line text:Content suitable for longer descriptions, such as 'Product Detailed Description', 'Event Rule Explanation', 'Job Position Responsibilities', etc.
  • Single choice, multiple choice, dropdown choice:These three types of fields are a boon for structured data.They allow you to preset a series of options, from which the user can select (single) or select multiple (multiple).For example, you can set dropdown selection fields such as 'house type' (one-bedroom, two-bedroom, etc.), 'renovation status' (finishing, rough) for the 'real estate rental' model, and set multiple selection fields such as 'color', 'size' for 'products'.These fields not only standardize the data, but also lay the foundation for subsequent content filtering and display.

Each custom field can be set to 'required' and 'default value', which helps ensure the completeness of the content and reduce the operation threshold.For example, if you want all job information to include salary ranges, you can make that field required.

Seamless connection between content model, classification, and content publishing

The custom content model does not exist in isolation, it is closely connected with AnQiCMS's 'Document Classification' feature.When creating a category, you need to specify the content model to which the category belongs.This means that all content under a category will follow the field structure of its associated content model.

When you publish content, first select a category, AnQiCMS will intelligently display the corresponding custom fields according to the content model of the category.This way, whether you publish ordinary articles, product information, or customized recruitment, event content, you can fill in the required information in the most intuitive way under a unified publishing interface.

Diverse content display: Let the custom model shine in the foreground

It is not enough to define the model only in the background. How to display these carefully organized contents on the website front-end is the key to achieving diversified display. AnQiCMS provides powerful template tags that allow you to easily call and display the data of custom models:

  1. archiveDetailTags:When you need to display detailed information about a single item,archiveDetailIt is your preference. Through this tag, you can directly access any field in the custom model. For example, if you have an 'activity' model that definesactivity_dateandactivity_locationField, you can call it like this in the template:{{archive.activity_date}}and{{archive.activity_location}}.
  2. archiveParamsTags:Sometimes, you may want to list all the custom fields and their values in a unified area (such as the 'specifications and parameters' section on a product details page).archiveParamsTags can help you traverse all custom fields of the content model, which is very suitable for dynamically displaying various product parameters.
  3. archiveListTags:Used for displaying various content in lists. CombinedmoduleIdParameter, you can accurately obtain the list of specific content models. For example, only display the list of 'Recruitment Information' models.
  4. archiveFiltersTags:This is the core to achieve advanced content filtering and diverse display.If you operate a real estate rental website and customize fields such as 'price range', 'house type', 'area', etc., then users can filter through these fields on the front end to find the housing they want.archiveFiltersLabels will automatically generate these filter conditions and their corresponding links, greatly enhancing user experience.

Moreover, AnQiCMS also supports customizing template files based on the table name of the content model. For example, you can createevent/detail.htmlandevent/list.htmlFiles, used to customize the individual content display page and list page of the "Event Details" model, thus achieving a completely personalized visual presentation.

**Practice and Precautions

  • Plan in advance:Before starting to create the model, it is crucial to spend some time planning the content structure.Make clear what types of content are needed, what fields each type contains, what the field types are, and how they may be displayed and interacted with on the front end.
  • Operate cautiously:This content model deletion is an irreversible operation, it will delete all the content and categories under the model at the same time. Be sure to confirm multiple times before performing the deletion.
  • Maintain naming conventions:Choose clear and concise English names for model table names and fields, which will help with template development and subsequent data maintenance.
  • Consider SEO:Custom models and fields provide more opportunities for SEO.For example, by creating custom fields to generate more descriptive URLs, or setting unique TDK (title, description, keywords) for specific content types.

Related articles

How to batch replace keywords or links on AnQiCMS website to quickly update displayed content?

In website content operation, timely update and maintenance of content is crucial.Whether it is the unified adjustment of brand keywords or the link failure caused by external changes, manually modifying the content of the entire station one by one is undoubtedly a time-consuming and labor-intensive project.幸运的是,AnQiCMS provides an efficient and powerful feature that can help us easily cope with such challenges: full-site content replacement.This feature allows us to batch update keywords or links on the website, thus quickly and accurately maintaining the unity and timeliness of the website content.To use this convenient feature, we first need to log in

2025-11-08

How to configure AnQiCMS so that documents of different categories have independent display templates?

In content management, the diversity of presentation methods is the key to enhancing user experience and brand image.A website that can present different design styles and information layouts according to different types of content will undoubtedly make it more attractive and professional.AnQiCMS fully understands this requirement and provides flexible and powerful template configuration capabilities, allowing us to customize exclusive display templates for different categories or even individual documents.Next, we will delve into how to configure this feature in AnQiCMS, allowing your website content to shine with unique charm.

2025-11-08

How can AnQiCMS effectively prevent malicious scraping and display watermarks on the front end?

Today, with the increasing prosperity of content creation, the value of original content is self-evident, but at the same time, malicious collection and plagiarism have also become a major challenge faced by content creators.It is crucial to choose a CMS with strong security protection to effectively protect the originality and copyright of website content.AnQiCMS is a system specially designed for content operators and provides a comprehensive and practical solution in this aspect.AnQiCMS knows the pain points of content creators, and therefore, from the beginning of system design, it has placed content security and anti-crawling in the core position.The built-in 'Anti-crawling and Watermark Management' function

2025-11-08

How to use AnQiCMS template tags to display detailed information of articles or products?

## How to effectively use AnQiCMS template tags to finely present article and product details In website operations, clearly and comprehensively displaying article and product details is crucial for attracting visitors and conveying core values.AnQiCMS as an efficient and flexible content management system provides powerful and easy-to-understand template tag functions, allowing you to easily present various information entered in the background in a natural and smooth manner on the website front-end.This article will take you in-depth to understand how to use these template tags to display detailed information about articles or products.

2025-11-08

How to make AnQiCMS automatically publish content at a specific time and display it?

In website content operation, maintaining a regular update and release rhythm is the key to attracting and retaining users.However, manually releasing content at specific time points is not only time-consuming but also prone to limitations imposed by human factors.AnQiCMS provides a very practical feature that can help you easily achieve scheduled content release and automatic display, making your website operation more efficient and automated.

2025-11-08

How to set and display the navigation menu of the AnQiCMS website, does it support multi-level structure?

The website navigation is an important guide for users when visiting the website, a clear and easy-to-use navigation menu can greatly enhance the user experience.AnQiCMS offers very flexible and powerful functions in terms of website navigation settings and display, allowing us to easily manage and implement multi-level menu structures to meet the needs of various website layouts.In the AnQiCMS backend, all settings related to website navigation are concentrated in the "Navigation Settings" module.Enter this page, you will first see a "navigation category management" area.This feature is very useful

2025-11-08

How to display the TDK (title, description, keywords) information of the website in AnQiCMS template?

AnQiCMS is a content management system that pays great attention to SEO optimization, providing strong support for the search engine performance of website content.Among them, TDK (Title, Description, Keywords, that is, title, description, keywords) is a core element of SEO optimization, and it is crucial to display this information correctly in the website template to enhance the visibility of the website in search engines.This article will introduce how to effectively display these TDK information in the AnQiCMS template.###

2025-11-08

How to display the friend link list in AnQiCMS?

In AnQiCMS, managing and displaying friendship links is very important for improving the website's search engine optimization (SEO) performance, increasing the number of external links, and promoting traffic interflow between websites.AnQiCMS as a fully functional content management system provides an intuitive backend operation and flexible template tags, allowing you to easily display a list of friend links on your website. ### One, manage friend links in AnQiCMS background Firstly, you need to add and manage friend links in the AnQiCMS background.

2025-11-08