CopyCat Category Duplicator Theme Adjustments
To set the categories canonical, you'll need to edit your templates/layouts/base.html page within your theme. You'll need to replace the following which is in the first few lines of your template.
{{{ head.meta_tags }}}
With the following code
{{#if page_type '===' 'category'}} {{ assignVar "currentCanonical" (first (split (last (split head.meta_tags "link rel='canonical' href='")) "' /><meta name='platform'")) }} {{ assignVar "rawCanonical" (first (split (last (split head.meta_tags 'meta name="keywords" content="')) '"><link')) }} {{#contains (getVar "rawCanonical") 'canonical|'}} {{ assignVar "canonical" (last (split (getVar "rawCanonical") 'canonical|')) }} <!-- Only shows canonical --> <link rel='canonical' href='{{{ getVar "canonical" }}}' /> <!-- Replaces the cateogries current canonical with the meta_keyword canonical --> {{#each (split head.meta_tags (getVar "currentCanonical")) ~}} {{#contains this 'canonical' ~}} {{{this}}}{{{ getVar "canonical" }}} {{~else~}} {{{this}}} {{~/contains}} {{~/each}} {{else}} {{{ head.meta_tags }}} {{/contains}} {{/if}}