XF 2.1 custom canonical link

gouwepeer.nl

Well-known member
I have content on my forum from another site (with permission), for which I want to link back to that site in exchange.
Now I want to avoid duplicate content by editing the canonical url (node id 85, 1286,1296 and 1285).
Template Metadata_Macros:
In it I added the following lines before <xf:if is="$siteName is not empty">
HTML:
    <xf:if is="in_array({$forum.node_id}, [85,1286,1296,1285])">
        <xf:macro name="canonical_url" arg-canonicalUrl="https://www.horoscoop-hoekje.nl/" />
</xf:if>
Unfortunately this does not work. What am I doing wrong?
 
Just found this, it might help.

 
Back
Top Bottom