• Welcome to WebsiteBaker Community Forum. Please log in or sign up.
Welcome, Guest
News
Support WebsiteBaker
Your donations will help to:
PayPal
  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!
You can donate by clicking on the button below.

Mod WBLingual

Started by CodeALot, April 18, 2024, 12:41:45 AM  ( Read 18,466 times )

CodeALot

Two questions:


  • Why is there a readme that tells us to use 'droplet [[iMultiLingual]]' if there is no such droplet?
  • Is there support for hreflang-tags, and if so: how? :-)

    Gast

    Der Hinweis auf das Droplet stammt noch aus früheren Zeiten und ist mittlerweile nicht mehr notwendig, das das frühere Addon zur Sprachumschaltung nun fester Bestandteil von WB ist.
    Beispiele zur Anwendung des hreflang-Tags findest du in der index.php des DefaultTemplates

    Quote<?php
            if (is_callable('LangPageId') && $iMultiLang) {
    ?>
                    <link rel="alternate" hreflang="x-default" href="[wblink<?= LangPageId($sPageLang); ?>]">
                    <link rel="alternate" hreflang="de" href="[wblink<?= LangPageId('DE'); ?>]">
                    <link rel="alternate" hreflang="en" href="[wblink<?= LangPageId('EN'); ?>]">
                    <link rel="alternate" hreflang="fr" href="[wblink<?= LangPageId('FR'); ?>]" />
                    <link rel="alternate" hreflang="nl" href="[wblink<?= LangPageId('NL'); ?>]" />
    <?php
            }

    Beachte, das dies nur funktioniert, wenn du auch die Definitionen von $iMultiLang und LangPageId übernimmst, die sich weiter oben in gleicher Datei befinden

    Google Translation

    The reference to the Droplet dates back to earlier times and is no longer necessary as the previous addon for language switching is now an integral part of WB.
    You can find examples of how to use the hreflang tag in the index.php of the DefaultTemplate

    Quote<?php
            if (is_callable('LangPageId') && $iMultiLang) {
    ?>
                    <link rel="alternate" hreflang="x-default" href="[wblink<?= LangPageId($sPageLang); ?>]">
                    <link rel="alternate" hreflang="de" href="[wblink<?= LangPageId('DE'); ?>]">
                    <link rel="alternate" hreflang="en" href="[wblink<?= LangPageId('EN'); ?>]">
                    <link rel="alternate" hreflang="fr" href="[wblink<?= LangPageId('FR'); ?>]" />
                    <link rel="alternate" hreflang="nl" href="[wblink<?= LangPageId('NL'); ?>]" />
    <?php
            }

    Note that this only works if you also copy the definitions of $iMultiLang and LangPageId, which are in the same file above

      \n\n