?
avatar fabelmik
fabelmik
20 Mar 2018

Steps to reproduce the issue

Create a new Joomla article with title: "Test Ø Å" and save.
Now see the alias generated by the system, JFilterOutput::stringURLSafe()

Also try creating a new article with title: "Test ø å".
It gives the same result.

Expected result

Alias should be: "test-oe-aa"

Actual result

Alias becomes: "test-o-a"

System information (as much as possible)

Database Type mysql
Databaseversion 10.1.31-MariaDB-cll-lve
Databasesammenkøring latin1_swedish_ci
Database forbindelse kollation utf8mb4_general_ci
PHP version 7.0.28
Webserver LiteSpeed
WebServer til PHP interface litespeed
Joomla!-version Joomla! 3.8.6 Stable [ Amani ] 13-March-2018 14:00 GMT
Joomla! platformsversion Joomla Platform 13.1.0 Stable [ Curiosity ] 24-Apr-2013 00:00 GMT
Brugeragent Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.186 Safari/537.36

Additional comments

avatar fabelmik fabelmik - open - 20 Mar 2018
avatar joomla-cms-bot joomla-cms-bot - change - 20 Mar 2018
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 20 Mar 2018
avatar fabelmik fabelmik - change - 20 Mar 2018
The description was changed
avatar fabelmik fabelmik - edited - 20 Mar 2018
avatar franz-wohlkoenig franz-wohlkoenig - change - 20 Mar 2018
Category com_content
avatar tonypartridge
tonypartridge - comment - 21 Mar 2018

Did you enable Unicode within the Joomla! SEF config?

avatar franz-wohlkoenig franz-wohlkoenig - change - 21 Mar 2018
Status New Information Required
avatar Bakual
Bakual - comment - 21 Mar 2018

Did you enable Unicode within the Joomla! SEF config?

If so, they wouldn't be replaced at all ?

How the special characters are replaced depends on the item language and thus on the language pack. So first make sure you have the danish language pack installed and set the article to danish.
If that is already the case, you will have to contact the danish language team and see if they want to add a transliterate method to the localise.php file (I think). From what I see on Crowdin, there is currently no specific code for that. @infograf768 likely knows better how that works in detail ?

avatar infograf768
infograf768 - comment - 21 Mar 2018

The default transliteration (when unicode is not chosen in Global config) for Joomla is
'ø' => 'o',
See https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L70

oe is the transliteration of ö
See https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L85

In the French pack we do have a custom transliteration and we use:

'o'		=>	'ò,ó,ô,õ,ø,ō,ŏ,ő,ο,ό,ω,ώ',
'oe'	=>	'œ,ö',
avatar fabelmik
fabelmik - comment - 21 Mar 2018

We don´t want to have unicode characters in URL, so we do not enable unicode alias in Global configuration.

Med venlig hilsen
Mikkel Olsen
Systemudvikler og programmør

Bahnhof Reklame- og webbureau
Østergade 2 - 8370 Hadsten
Tlf.: 71 99 06 99 - www.derbahnhof.dk http://www.derbahnhof.dk/

On 21 Mar 2018, at 08.19, infograf768 notifications@github.com wrote:

The default transliteration (when unicode is not chosen in Global config) for Joomla is
'ø' => 'o',
See https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L70 https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L70
oe is the transliteration of ö
See https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L85 https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L85

You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub #19952 (comment), or mute the thread https://github.com/notifications/unsubscribe-auth/ABV3ig8EO73meaxMLej1nFMbHE9ExTk4ks5tgf7zgaJpZM4Sydkl.

avatar ggppdk
ggppdk - comment - 21 Mar 2018

We don´t want to have unicode characters in URL, so we do not enable unicode alias in Global configuration.

Yes this was understood

I see that the danish language file \language\da-DK\da-DK.localise.php
does not implement (does not have) public static function transliterate($string)

So this code
https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Language.php#L397-L404

	public function transliterate($string)
	{
		// THIS does NOT exist for danish language
		if ($this->transliterator !== null)
		{
			return call_user_func($this->transliterator, $string);
		}
		$string = Transliterate::utf8_latin_to_ascii($string);
		$string = StringHelper::strtolower($string);
		return $string;
	}

will just return the default,
which is Transliterate::utf8_latin_to_ascii(...)
that @infograf768 mentioned above

https://github.com/joomla/joomla-cms/blob/staging/libraries/src/Language/Transliterate.php#L31

This is work for danish translation team to add custom transliteration

avatar infograf768
infograf768 - comment - 21 Mar 2018

Let me add here that you are the first one from Northern Europe to complain about the default transliteration for Latin supplement 1 since we introduced it in 1.6.
You may, if you like, override the localise.php for your language pack to get exactly what you want as the Translation Coordinators for these languages never did it as default was OK for all.

the way to do it is explained here:
https://docs.joomla.org/J3.x:Making_a_Language_Pack_for_Joomla#Example_2_-_Custom_transliteration_implemented

Therefore, just copy the existing da-DK.localise.php
Add the method above and modify it to fit your needs.

Then place the new xx-XX.localise.php in
administrator/language/overrides/ folder
and
language/overrides/ folder

in your case a da-DK.localise.php

avatar infograf768
infograf768 - comment - 21 Mar 2018
avatar infograf768 infograf768 - change - 23 Mar 2018
Status Information Required Closed
Closed_Date 0000-00-00 00:00:00 2018-03-23 14:06:44
Closed_By infograf768
avatar infograf768
infograf768 - comment - 23 Mar 2018

I guess we can close this as this is not a core issue and infos have been given to override.

avatar infograf768 infograf768 - close - 23 Mar 2018

Add a Comment

Login with GitHub to post a comment