heimrichhannot / contao-head-bundle

Add <head> tags, like seo meta tags or twitter cards, or open graph meta tags to contao frontend page.
GNU General Public License v3.0
2 stars 1 forks source link

Multi-Language and Organisation Logo #12

Open jochennoack opened 10 months ago

jochennoack commented 10 months ago

Context

Contao version: 4.13 Bundle version: 1.13.1 PHP version: 8.2.

Description

If the starting point of a website is configured in multiple languages and a URL prefix is used, the language prefix is unfortunately also interpreted in the logo URL. In other words, it would make sense to output the complete URL here.

Validator output with incorrect interpretation

Bildschirm­foto 2023-11-23 um 12 51 32

JSON Code:

{
    "@context": "https:\/\/schema.org",
    "@graph": [
        {
            "@type": "WebPage"
        },
        {
            "@type": "Organization",
            "logo": "files\/logo.png",
            "name": "Organisationsname",
            "url": "https:\/\/www.website.de"
        },

    ]
}

JSON code optimised, with complete URL:

{
    "@context": "https:\/\/schema.org",
    "@graph": [
        {
            "@type": "WebPage"
        },
        {
            "@type": "Organization",
            "logo": "https:\/\/www.website.de\/files\/logo.png",
            "name": "Organisationsname",
            "url": "https:\/\/www.website.de"
        },

    ]
}
koertho commented 10 months ago

@jochennoack Good point, can you provide an PR?