Canonical links to avoid duplicate url:s

Help
Simon
2013-08-20
2013-08-21
  • Simon

    Simon - 2013-08-20

    Each project on our community page has one or more categories via which
    they can be listed and linked to. They are added to the url as a parameter
    like this:

    .../Projekt/Bygga-stug-i-Norrland/?category=30

    or

    /Projekt/Bygga-stug-i-Norrland/?category=33

    But only one catagory is the main one and that is added to the page as a
    canonical link:

    <link rel="canonical" href="/Projekt/Bygga-stug-i-Norrland/?category=30" />
    

    Only the main one should be in the search results of course, to avoid
    duplicates. For this purpose I figured I would use the attribute "Ignore
    non canonical pages" on the HTML Parser. It seems however that it does not,
    as wished, ignore pages where the url does not match the canonical link but
    rather ignores all pages with any canonical link in the header.

    Is there a way to use this setting as I intend?

    /Simon

     
    Last edit: Simon 2013-08-21
  • Naveen A.N

    Naveen A.N - 2013-08-21

    Hello Simon,

    OpenSearchServer first look's for the canonical URL in a webpage and if there is a canonical URL the canonical URL will be added to the URL database and it will be crawled in next crawl session.If the option "Ignore non canonical pages" is set to false. The crawler will ignore the canonical link and crawls the current webpage.

    Naveen.A.N

     
  • Simon

    Simon - 2013-08-21

    Hello, thanks for your reply!

    Can my problem be that the canonical link is relative? I'm thinking it might not match since it is missing the base domain of the url?

     

Log in to post a comment.