When operating a website, some seemingly simple single-page pages, such as 'About Us', 'Contact Us', or 'Terms of Service', carry the brand image, trust endorsement, and user conversion entry of the website.Carefully designed independent visual styles for these pages, optimized search engine (SEO) information, and flexible content display are crucial for improving user experience and website professionalism.AnQiCMS provides powerful and flexible features, allowing you to easily meet these needs.
Core Function: Customize Exclusive Experience for Single Page
First, let's learn how to manage and customize these single-page in AnQiCMS. All of this revolves around the 'Page Management' feature.
When you enter the "Page Resources" module in the background and select "Page Management", you will see a list of all single pages created.In here, you can add a new single page or edit an existing page.When creating or editing a single page, you will find that AnQiCMS provides comprehensive configuration options to ensure that each page has its unique identification.
Content and visual independence
- Page Content Management:Each single page has an independent "page name," "single page introduction," and "single page content" editing area.Through the rich text editor, you can easily format text, insert images, videos, and even quote code snippets, ensuring the richness and attractiveness of the content presentation.For example, on the "About Us" page, you can thoroughly introduce the company's history, team members, and accompany it with exquisite pictures;On the "Contact Us" page, you can embed a map and provide multiple contact methods.
- Custom URL:To make the link of a single page more semantic and identifiable, AnQiCMS allows you to set a "custom URL". The system will automatically generate a pinyin alias based on the name of the page you enter, but you can also manually modify it, create such as
/about-us.htmlor/contact.htmlThis concise and friendly link. It not only helps users remember and share, but is also an important part of search engine optimization (SEO). - Independent SEO information:Each single page can have its own SEO information, including "SEO Title", "Keywords", and "Single Page Summary". These fields directly correspond to the page's
titletags,meta keywordsandmeta descriptionIt is crucial for improving the visibility and click-through rate of a page in search engine results.Carefully crafting this information can help search engines better understand the page topic and attract target users. - The canonical URL:For pages that may have duplicate content or to specify the preferred version, you can set the 'standard link'.This is especially useful when doing foreign trade website or having multiple similar pages, it can tell search engines which is the authoritative version of the content, to avoid weight dispersion.
Configuration of exclusive template
The strength of AnQiCMS lies in its flexible template mechanism. By default, all single pages will usepage/detail.htmlAs a display template. If you want the "About Us" page to have a unique layout, and the "Contact Us" page to use a different style, you can completely achieve this through a custom template.
First, in your template file directory (usually/template/{您的模板文件夹}/page/In this case, you can create a new HTML file, for exampleabout.html.
Next, when editing the 'About Us' single page in the AnQiCMS backend, find the 'Single Page Template' field. Here, simply enter the name of the template file you just createdabout.htmlAfter saving, when the user visits the "About Us" page, the system will automatically load and renderabout.htmlThis dedicated template, rather than the default onepage/detail.htmlIn this way, you can design a unique visual style for each single page of the website, perfectly matching its content theme and brand character.
Content display in practice and SEO optimization
After you have created a dedicated template for a single page, how can you call and display content as well as SEO information in the template?AnQiCMS provides intuitive template tags, making data calls simple.
You will mainly usepageDetailandtdkThese tags.
Call page content:In
about.htmlIn such a custom template, to display the title, content, and introduction of the "About Us" page, you can use it like thispageDetailTags:<h1>{% pageDetail with name="Title" %}</h1> <div> {% pageDetail pageContent with name="Content" %} {{ pageContent|safe }} </div> <p>{% pageDetail with name="Description" %}</p>here,
{{ pageContent|safe }}of|safeThe filter is necessary, it indicates that the system should parse the content in HTML format instead of simply outputting it as plain text, ensuring that the rich text editor's formatting is displayed properly.Set SEO information:The page's SEO information is usually placed in
<head>tags. UsetdkLabel, you can easily call the SEO title, keywords, and description set in the single-page background:<head> <title>{% tdk with name="Title" siteName=true %}</title> <meta name="keywords" content="{% tdk with name="Keywords" %}"> <meta name="description" content="{% tdk with name="Description" %}"> {%- tdk canonical with name="CanonicalUrl" %} {%- if canonical %} <link rel="canonical" href="{{canonical}}" /> {%- endif %} </head>siteName=trueThe website name will be automatically appended to the end of the page title, for example “About Us - AnQi CMS”. andCanonicalUrlIt will render only when the specification link is set in the background, to avoid unnecessary code.
URL structure and pseudo-static
Custom URL alias ({filename}) Combined with the pseudo-static rules provided by AnQiCMS, it can further optimize the URL structure of a single page. In the "Function Management" under "Pseudo-static Rules", you can select or customize a URL pattern that conforms to SEO **practices, such as setting a single page to/{filename}.htmlThe form is such that the link to the "About Us" page can be/about-us.htmlIt is concise and有利于搜索引擎抓取和理解。
Summary: Flexible empowerment, enhance value
Through AnQiCMS' page management feature, you can not only configure independent templates for each single page of the website to achieve a differentiated visual experience, but also finely tune the SEO information and content display methods.This high degree of flexibility ensures that each single page can maximize its role in brand promotion, information delivery, and search engine optimization, thereby enhancing the professionalism and user experience of the entire website.
Frequently Asked Questions (FAQ)
1. My custom single page template has been uploaded and selected in the background, why is the default template content still displayed on the front end?
Please check several aspects:
- Is the template file path and name correct?Make sure that the template file you uploaded is located at
template/{您的模板文件夹}/page/Under the directory, and the filename (including the suffix .html) must be exactly consistent with the content filled in the "Single Page Template" field in the background. For example, if you fill in the backgroundabout.htmlThen the file should betemplate/{您的模板文件夹}/page/about.html. - Is the cache cleared?In the AnQiCMS backend, sometimes you need to click the "Update Cache" feature to ensure that the new template configuration takes effect.
- Does the template code contain any syntax errors?Even if the file path and name are correct, if there are syntax errors in the Django template engine within the template file, it may also cause the rendering to fail correctly.You can try to check the server logs to troubleshoot the specific error.
2. Will the 'custom URL' and 'SEO Title' of the single page be automatically generated? Do I need to modify them manually?
Yes, AnQiCMS will automatically generate a pinyin alias for the 'Custom URL' after you enter the 'Page Name', and use the 'Page Name' as the default for the 'SEO Title'.These automatically generated contents usually meet basic needs.
However, in order to achieve better SEO results and brand consistency, we strongly recommend that you manually optimize these fields:
- **Custom URL:**