Giter VIP home page Giter VIP logo

Comments (6)

fritzmg avatar fritzmg commented on September 26, 2024

Can you please test if dev-master fixes your issue?

from contao-newslist-extended.

fritzmg avatar fritzmg commented on September 26, 2024

Although for Contao 4.13 I will probably need to make additional adjustments, otherwise you might end up with 2 canonical URLs :)

// edit: done in ddcf4d5

from contao-newslist-extended.

ctwbg avatar ctwbg commented on September 26, 2024

Sadly, it does not work even after installing dev-master.

I have created a blank Contao installation with only newslist-extended installed and I can reproduce the error, so it should not be an issue specific to my main installation.

I have tested with and without generate canonical settings enabled for each page root, no difference.

from contao-newslist-extended.

fritzmg avatar fritzmg commented on September 26, 2024

At the moment I am unable to reproduce your issue. From your description it looks like Contao is generating a news URL that looks like this:

//main.domain.com/news/view/news-item-123

But that should never be the case. It should always either be relative or absolute including the scheme (http: or https:).

from contao-newslist-extended.

ctwbg avatar ctwbg commented on September 26, 2024

Your hint gave me an idea, and it may have something to do with the protocol settings in the page root ("URL-Einstellungen -> Protokoll").

When I switch the page root to "http://" the correct canonical url is used...

Maybe Contao generates protocol-relative urls when using https - and you check for the protocol when building the canonical tag?

from contao-newslist-extended.

fritzmg avatar fritzmg commented on September 26, 2024

Maybe Contao generates protocol-relative urls when using https

That would be a bug in Contao then. It is supposed to always generate either:

  • Absolute URLs including protocol.
  • Path absolute URLs.
  • Relative URLs.

Never protocol relative URLs.

from contao-newslist-extended.

Related Issues (7)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.