Friendship links play an important role in website operation, not only helping to increase the number of external links on the website, but also having a positive impact on search engine optimization (SEO), and providing users with more access to related resources. However, not all friendship links are suitable for passing on weight or obtaining search engines' 'recommendations', at this pointrel="nofollow"The attribute is particularly important.
AnQiCMS (AnQiCMS) is a powerful content management system that fully considers the needs of website operators, provides a convenient link management function, and can control flexiblynofollowAttribute, helps the website better manage external link relationships, balancing SEO benefits and compliance.
Management of friendship links in Anqi CMS
On the Anqi CMS backend, you can easily find and manage friend links.Generally, there will be an option for 'Friend Links' under the 'Function Management' menu.Here, you can add new友情链接, edit the information of existing links.
When adding or editing a friendship link, the system will provide several key settings including:
- Link NameThis is the text displayed on the website front end for the friendship link, it should be concise and clear, accurately conveying the content of the link.
- Link AddressThis points to the URL of the target website.
- Link note: Enter some internal remarks information for easy management and identification.
- Link nofollowThis is a very critical option. When you check or enable this option, Anqi CMS will automatically add the friendship link.
rel="nofollow"Property.This means you are telling the search engine not to track this link and not to pass the weight of your website to the target website.This is very useful when dealing with paid links, links of uncertain content quality, or avoiding over-optimization.
Through the friendly interface of the background, you can manage each link in detail, deciding whether it hasnofollowattributes, thereby better controlling the website's SEO strategy.
Display friendship link list in front-end template
Display the friend links set up in the background on the website front end, which requires implementing through the Anqi CMS template tags. Anqi CMS provides speciallinkListLabels, allowing you to easily retrieve and cycle through all friendship links.
First, in your template file (such as the bottom of the website'sfooter.htmlOr a dedicated friendship link page template), you can uselinkListtag to retrieve friendship link data. This tag will treat the friendship link list as an array object (for example, namedfriendLinksPass to the template.
{% linkList friendLinks %}
{% if friendLinks %} {# 判断是否存在友情链接 #}
<div class="friendship-links-section">
<h3>友情链接</h3>
<ul>
{% for item in friendLinks %} {# 循环遍历每一个友情链接 #}
<li>
{# 根据 item.Nofollow 的值来动态添加 rel="nofollow" 属性 #}
<a href="{{item.Link}}" {% if item.Nofollow == 1 %} rel="nofollow"{% endif %} target="_blank" title="{{item.Remark}}">
{{item.Title}}
</a>
</li>
{% endfor %}
</ul>
</div>
{% endif %}
{% endlinkList %}
In the above code example,{% linkList friendLinks %}Gathered all friendship links and stored them infriendLinksthe variable. Then,{% for item in friendLinks %}Traversed this list, eachitemrepresenting a friendship link.
The core lies in{% if item.Nofollow == 1 %} rel="nofollow"{% endif %}This logic.item.NofollowIt will return a boolean value or a 0/1 integer indicating whether the link is set asnofollow. If the value is1(ortrue), the template will be<a>added dynamically in the tag.rel="nofollow"Property. At the same time, in order to provide a better user experience and external link specification, we usually addtarget="_blank"to open the link in a new window, and usetitle="{{item.Remark}}"to display the note information.
This way, you can clearly display友情链接 links on the website front-end and flexibly control according to the settings in the backgroundnofollowattributes to ensure that your SEO strategy is effectively implemented
Optimization and注意事项
When managing and displaying friend links, there are some points worth noting to ensure the healthy development of the website:
- Link location selection: Friend links are usually placed at the bottom (Footer) area of a website or on a separate friend links page.Choosing the right position helps enhance user experience and clarify the nature of these links.
- Link relevanceChoose links that are highly relevant to the content of your website, as this can bring more precise traffic and is also easier to gain the recognition of search engines.
nofollowUse case:- Paid link/ad link: Any link obtained through paid means should be added
nofollow, to avoid being identified as cheating by search engines. - User Generated Content (UGC)In comment sections, forums, and other places where users can freely post links, even if not directly as friend links, it should be considered to add
nofollowor similar properties (such asugcTo prevent spam links and SEO risks. - Websites with low trustworthiness: Add if the quality of the linked website is poor, the content is illegal or unstable.
nofollowCan protect your own website from being involved.
- Paid link/ad link: Any link obtained through paid means should be added
- AnQi CMS automatic
nofollowmechanism: In addition to manually setting the links'nofollowIn addition to the attributes, AnQi CMS also provides the function of 'whether to automatically filter external links' in the 'Content Settings'. If this option is set to 'do not filter external links', the system will automatically add all external links in the article contentrel="nofollow"Property. This is a very practical feature that can prevent content editors from inadvertently passing weight to unnecessary external links, further enhancing the website's SEO control.
Through these functions of AnQi CMS, you can manage and display friend links with precision, enjoying the SEO and traffic benefits brought by friend links while effectively avoiding potential risks to ensure the long-term healthy development of the website.
Frequently Asked Questions (FAQ)
Q1: What is the role of the friendship link attribute?rel="nofollow"What is the role of the attribute?A1: rel="nofollow"The attribute tells the search engine not to follow this link and not to pass the weight of your website or 'link juice' to the target website.It is mainly used to avoid providing SEO recommendations for paid links, untrustworthy content, or external links that do not want to pass on weight.
Q2: Should I add the attribute to all friendship links?nofollowShould I add the attribute?A2: It depends on your specific strategy. If you have pure mutual benefit with the other party, and the content is highly relevant and of good quality, you may consider not addingnofollowPass on the weight. However, it is strongly recommended to add for any form of paid links, advertising links, or links whose content quality and stability you are unsure ofnofollowProperty.
Q3: Besides friend links, what types of links will Anqi CMS automatically add?rel="nofollow"?A3: In the Anqi CMS backend "Content Settings", if the "Auto-filter External Links" feature is enabled and "Do not filter external links" is selected, the system will automatically add all external links in the published content (such as articles, product details, etc.)rel="nofollow"Property. This helps to unify the management of external link behavior in content, preventing unexpected weight loss.