How to configure contact links for social media such as Facebook, Twitter, etc. in the AnQiCMS background?

Calendar 👁️ 97

As an experienced website operations expert, I am well aware of the importance of every detail for website user experience and brand promotion.In the age of popular social media, connecting your website seamlessly with major social platforms can not only broaden the channels for information dissemination, but also enhance user interaction and brand influence.AnQiCMS (AnQiCMS) with its powerful flexibility and ease of use, provides us with an elegant solution.

Today, we will delve into how to configure contact links for social media platforms such as Facebook, Twitter, and others in the AnQiCMS backend, and present them巧妙ly on your website.

Easily connect to the social world: Configure social media contact links such as Facebook, Twitter, etc. in the AnQiCMS backend

Your website is not just an information display platform, it is also the narrator of your brand story and the center of user interaction.Connecting the website with popular social media platforms such as Facebook, Twitter, LinkedIn, and others is a key step to enhancing brand exposure, attracting traffic, and building communities.AnQi CMS is an enterprise-level content management system centered around users, deeply understands this, and provides an intuitive and efficient way to manage these important external links.

Step 1: Manage social media links in the AnQiCMS backend

One of the design philosophies of AnQiCMS is to modularize all functional modules for centralized management and efficient configuration. The setting of social media links is mainly focused on“Backend Settings” -> “Contact Information Settings”area.

  1. Locate "Contact Information Settings"Login to your AnQiCMS admin interface.In the left navigation bar, you will see the option of "background settings".Click it, then find and click "Contact Settings" in the expanded submenu.
  2. Understand Default and Extended FieldsAfter entering the "Contact Information Settings" page, you will see a series of preset contact information fields, such as contact person, phone number, address, email, and WeChat ID. It is worth noting that AnQiCMS has built-in support for some mainstream social media platform links, such asFacebook/Twitter/Tiktok/Pinterest/Linkedin/Instagram/YoutubeThis means that for these platforms, you do not need to create an additional one. You can directly enter your homepage URL in the corresponding field.
  3. Flexible to add custom social linksThe strength of AnQiCMS lies in its high customizability.If you need to add a social media platform that is not on the default list, or if you want to add multiple links for the same social platform (for example, your company has multiple Facebook pages), AnQiCMS provides a 'custom setting parameter' feature.
    • Scroll to the bottom of the page and find the 'Custom Setting Parameters' area.
    • Click the 'Add' button next to it.
    • In the popped-up form:
      • Parameter Name (FieldName)This is the unique identifier used when calling this link in the template. It is recommended to use a concise and clear camelCase naming method, for exampleFacebookPageLink/CompanyTwitterorOurBlogRSS.
      • Parameter Value (Value)Paste the full URL of your social media homepage, for examplehttps://www.facebook.com/yourpageMake sure to includehttps://prefix to ensure the validity and security of the link
      • Remark (Remark)Fill in a brief description, such as 'Company official Facebook page', 'Product line Twitter account', etc. This will help you quickly identify the purpose of these links when managing them in the future.
    • Repeat this step until you have added all the necessary social media links.
  4. Save ChangesAfter completing all social link entries and custom additions, make sure to click the 'Save' button at the bottom of the page to ensure your settings take effect.

Through such centralized management, you can easily update, add, or delete any social media link without touching the frontend code, greatly enhancing the efficiency of website operation.

The second step: Display social links on the website front end

The background configuration is complete, the next step is to let these carefully prepared social links shine on your website.AnQiCMS uses an intuitive template tag system, allowing you to easily call this information in your website template.

  1. UnderstandingcontactTagProvided by AnQiCMS:contactThe label is used to obtain the configuration information of the "Contact Information Settings" configured in the front-end template. Its basic syntax is{% contact with name="字段名称" %}Here is the field name that you entered in the background "Contact Information Settings" (such asFacebook) or a custom "parameter name" (such asFacebookPageLink)

  2. Link called in the templateYou can insert in any HTML template file of the website (such asbash.html/footer.html/contact/index.htmletc)contactLabel to display social links. For example, if you want to display Facebook and Twitter links in the footer, you can write the code like this:

    <div class="social-links">
        {# 调用内置的 Facebook 链接 #}
        {% set facebookLink = contact with name='Facebook' %}
        {% if facebookLink %}
        <a href="{{ facebookLink }}" target="_blank" rel="noopener noreferrer">
            <i class="fab fa-facebook-f"></i> {# 这里通常会配合 Font Awesome 等图标库使用 #}
            <span>Facebook</span>
        </a>
        {% endif %}
    
        {# 调用内置的 Twitter 链接 #}
        {% set twitterLink = contact with name='Twitter' %}
        {% if twitterLink %}
        <a href="{{ twitterLink }}" target="_blank" rel="noopener noreferrer">
            <i class="fab fa-twitter"></i>
            <span>Twitter</span>
        </a>
        {% endif %}
    
        {# 调用自定义的 LinkedIn 链接 (假设后台参数名为 'LinkedInPage') #}
        {% set linkedinLink = contact with name='LinkedInPage' %}
        {% if linkedinLink %}
        <a href="{{ linkedinLink }}" target="_blank" rel="noopener noreferrer">
            <i class="fab fa-linkedin-in"></i>
            <span>LinkedIn</span>
        </a>
        {% endif %}
    </div>
    

    In the code above, we first use{% set variable = contact with name='FieldName' %}The way to assign the obtained link to a variable.The benefit of doing this is that you can first check if the variable exists (i.e., whether the user has configured the link in the background), and only render the corresponding HTML when it exists to avoid empty links or errors.target="_blank" rel="noopener noreferrer"is the standard practice to ensure that the link opens in a new tab and enhances security.

  3. Adapt your template styleAccording to your website design, you can place these links in the header, footer, sidebar, contact us page, or any place you think is appropriate.They are usually combined with exquisite social media icons (such as the Font Awesome icon library) to provide more intuitive and attractive visual effects.

Practical tips and optimization

  • Standard naming conventionsWhen customizing parameter settings in the background "Custom Settings Parameter", try to maintain the uniformity and readability of parameter names. For example, all social link parameters end with "Link", such asFacebookLink/InstagramLink.
  • Link integrity and security: Always use the full URL and withhttps://starting. In the front-end template, add external links totarget="_blank" rel="noopener noreferrer"Properties, not only can it improve user experience (open links in a new window), but also avoid security vulnerabilities (noopenerPrevent the new window from obtaining the reference of the original window, noreferrerPrevent Referrer information from being sent to the target page).
  • Test and verifyAfter completing the configuration and updating the template, be sure to test these social links on different browsers and devices to ensure they can be clicked normally and jump to the correct social media homepage.
  • Icon beautificationAlthough the code example used<i>The label acts as an icon placeholder, but in actual application, you can integrate Font Awesome, SVG sprites, or custom icon fonts to make your social links more visually appealing.

By following these steps, you can efficiently and flexibly configure and display your social media contact links on the AnQiCMS-driven website, making your site a powerful bridge connecting users and brands.


Frequently Asked Questions (FAQ)

Q1: Will it slow down the page load if I put a lot of social media links in the 'Contact Information Settings'?

A1:Will not.All configuration information in AnQiCMS's 'Contact Information Settings' is processed and stored on the server side, and it will not directly slow down the loading speed of the front-end page.

Related articles

Does the contact label support setting links to overseas communication tools such as WhatsApp?

As an experienced website operations expert, I am well aware that in the digital wave, enterprises need to maintain seamless connections with global customers.When it comes to configuring website contact information, especially the integration of overseas communication tools, the flexibility of AnQiCMS (AnQiCMS) always impresses me.Many friends will ask: Does AnQi CMS support setting links to overseas communication tools such as WhatsApp?My answer is: **Fully supported and very convenient to implement!

2025-11-06

What is the actual function of the 'remark' field in AnQiCMS custom contact information?

As an experienced website operations expert, I am well aware that every detail of a CMS system may have a profound impact on the operational efficiency and long-term maintenance of a website.AnQiCMS (AnQiCMS) has become a powerful assistant for many enterprises and self-media in content management, thanks to the efficiency and excellent expansion capabilities brought by the Go language.Today, let's talk about a seemingly insignificant feature in AnQi CMS that plays a huge role in actual operation - the "note" field in the custom contact information.### Flexible Contact Management

2025-11-06

How should the 'parameter value' be filled in for the customized contact information in the AnQiCMS background to be correctly called in the template?

As an experienced website operations expert, I am well aware of how crucial it is to efficiently utilize each feature of a rich platform like AnQiCMS to serve the website content.Today, let's delve deeply into a seemingly simple yet often perplexing issue for many operators: 'How should the 'parameter value' of the customized contact information be filled in the AnQiCMS backend so that it can be correctly called in the template?'}]This is not just a technical detail, it is also about the precise presentation of website information and the smoothness of user experience.

2025-11-06

What are the naming conventions or suggestions when defining a custom contact method field?

In the powerful function ecosystem of Anqi CMS, the flexibility of custom contact information fields is undoubtedly a key factor in improving website operation efficiency.As an experienced website operations expert, I know that every detail can affect the overall performance of the website, and the naming conventions of 'parameter names', although seemingly trivial, are actually related to the maintainability, scalability, and smoothness of team collaboration of the website content.

2025-11-06

Is the AnQiCMS contact information tag integrated with emerging social platforms such as Tiktok, Pinterest, etc?

I am glad to discuss with you the capabilities of Anqi CMS in social media integration.As an experienced website operations expert, I fully understand the importance of keeping up with the times in online touchpoints for corporate brand promotion and user interaction.About whether the AnQiCMS contact information tag has integrated emerging social platforms such as Tiktok, Pinterest, etc.This question, I can give a clear and inspiring answer.

2025-11-06

How can I add LinkedIn or Instagram personal homepage links to the contact information on AnQiCMS?

AnQiCMS, with its high efficiency and flexibility, has become a powerful assistant for many small and medium-sized enterprises and content operation teams.In today's digital marketing era, a website is not only a platform for information release, but also an important window for connecting with users and showcasing the brand image.While social media platforms like LinkedIn and Instagram play a crucial role in professional communication and visual marketing.

2025-11-06

Does AnQiCMS support adding YouTube channel or video link in the contact information?

As an experienced website operations expert, I am happy to give you a detailed explanation of the function of adding a YouTube channel or video link in the contact information of AnQiCMS and the operation strategy behind it. --- ## AnQi CMS: Flexible integration of YouTube content, empowering your multimedia marketing strategy In today's digital age, video content has become an indispensable carrier for brand interaction with users and conveying information.

2025-11-06

How to use the `{% contact %}` tag to accurately call the value after customizing the contact information field?

As an experienced website operations expert, I am well aware of the importance of flexible content display for website operation efficiency and user experience.AnQiCMS (AnQiCMS) offers great customization, making it extremely convenient when handling seemingly simple yet crucial information such as website contact details.Today, let's delve into how to accurately call the values in the contact information field you customized in the Anqi CMS backend through the `{% contact %}` tag in the frontend template.--- ## AnQi CMS Template

2025-11-06