rob006 Meant on our side, changing the extension to allow for selection of different transliteration implementations. We could have the transliteration packages be suggested when installing, and also show which one is needed when selecting through the settings modal.

    0.2.0

    • !! Removed non-English locales
    • Added two different vanilla PHP transliterator methods
      • They both require the intl PHP extension
      • They use different rules, I won't attempt to explain them because I don't know what they mean 😂
        • #1 - Any-Latin; Latin-ASCII; [\u0100-\u7fff] remove;
        • #2 - Any-Latin; NFD; [:Nonspacing Mark:] Remove; NFC; [:Punctuation:] Remove; Lower();
    • Added dropdown to settings modal to choose transliterator method
    • Added extender for developers/forum owners to add their own methods
      return [
          (new \FoF\Transliterator\Extend())
              ->add('test', function (string $str) {
                  // transliterate/slugify
                  return $str;
              })
      ];

    Updating

    composer require fof/transliterator
    2 months later

    Thanks for extension..
    Found it over my old 200,000 discussions. 🙂

    4 months later

    hi. i need to instal this, but comand failed. i have composer at server, but in flarum directory i havent composer.json file. Please help

      Crypto77777 If you don't have a composer.json file in the Flarum directory, you may want to open a support dioscussion as that's not related to this extension.

      2 months later

      Every once in a while there are users in this community asking for the possibility to remove the discussion title from the slug alltogether, e.g. here.

      This could be easily achieved by adding one more "transliteration" option in /src/Transliterator.php. What do you think @datitisev?

        Pollux That can actually be achieved very easily through extend.php

        <?php return [
            (new \FoF\Transliterator\Extend())
                ->add('blank', function (string $str) {
                    return '';
                })
        ];

          Great, didn't expect it to be that easy without forking your extension.

          6 days later

          Littlegolden there's a missing translation

          You added that blank option yourself in your extend.php file, how can there be a translation provided by others?

          If you want to see a translation there, you need to provide it yourself. I use my own custom language pack, so it was quite easy for me to add a translation. If I hadn't one already I would probably do without a translation.

            6 months later

            Is it compatible with beta 14?

            0.2.1

            • beta 14 ready 🥳
            Updating
            composer require fof/transliterator:^0.2.1
            php flarum cache:clear
            a month later

            0.3.0

            • Flarum beta 15 support
            a month later

            When you enable the extension, the admin panel breaks:
            flarum.ERROR: Error: Class 'FoF\Transliterator\Transliterator' not found in /.../vendor/fof/transliterator/extend.php:22

              Lolu how did you install the extension? Can you share the output of php flarum info ?

              • Lolu replied to this.
                3 months later

                Extiverse Helper shows this is not compatible with beta 16?