Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Asger 25 posts 171 karma points
    Jun 23, 2016 @ 12:32
    Asger
    1

    Hi umbraco forum.

    I have created a template that i am using in my content. It appears that i can find the template twice;

    1. by accessing www.mydomain.dk/findVej
    2. by accessing www.mydomain.dk/find-vej

    The 1st one is direct access to the template

    The 2nd one is access to the content

    What is wrong here? If it is like this, i will get dublicate content for every single page.

  • Dennis Aaen 4499 posts 18254 karma points admin hq c-trib
    Jun 23, 2016 @ 17:31
    Dennis Aaen
    100

    Hi Asger,

    The reason why you can find the content twice is because of something that we call AltTemplate, you can see more about it here in this video below.

    https://umbraco.tv/videos/umbraco-v7/implementor/fundamentals/templating/alt-template/

    The good thing is that you can turn this off if you want to.

    So assuming you haven't changed anything in the content finders setup, you just want to remove that legacy handler. This would be in ~/config/404handlers.config, where you need to remove the line that contains

    <notFound assembly="umbraco" type="SearchForTemplate" />
    

    Hope this helps,

    /Dennis

  • Asger 25 posts 171 karma points
    Jun 24, 2016 @ 07:34
    Asger
    0

    Hi Dennis.

    I just tried implementing your solution. The content is no longer loaded, but i can still access the template.

    Any idea how to fix this?

    Best regards.

Please Sign in or register to post replies

Write your reply to:

Draft