Version Description
- Removed quotes from table which added extra dashes
Download this release
Release Info
Developer | webvitaly |
Plugin | Cyr to Lat enhanced |
Version | 3.5 |
Comparing to | |
See all releases |
Code changes from version 3.4 to 3.5
- cyr-to-lat.php +14 -16
- readme.txt +6 -3
cyr-to-lat.php
CHANGED
@@ -5,31 +5,31 @@ Plugin URI: http://wordpress.org/plugins/cyr3lat/
|
|
5 |
Description: Converts Cyrillic, European and Georgian characters in post, term slugs and media file names to Latin characters. Useful for creating human-readable URLs. Based on the original plugin by Anton Skorobogatov.
|
6 |
Author: Sol, Sergey Biryukov, Nikolay Karev, Dmitri Gogelia
|
7 |
Author URI: http://karevn.com/
|
8 |
-
Version: 3.
|
9 |
*/
|
10 |
|
11 |
function ctl_sanitize_title($title) {
|
12 |
global $wpdb;
|
13 |
|
14 |
$iso9_table = array(
|
15 |
-
'А' => 'A', 'Б' => 'B', 'В' => 'V', 'Г' => 'G', 'Ѓ' => 'G
|
16 |
-
'Ґ' => 'G
|
17 |
'Ж' => 'ZH', 'З' => 'Z', 'Ѕ' => 'Z', 'И' => 'I', 'Й' => 'J',
|
18 |
-
'Ј' => 'J', 'І' => 'I', 'Ї' => 'YI', 'К' => 'K', 'Ќ' => 'K
|
19 |
-
'Л' => 'L', 'Љ' => 'L', 'М' => 'M', 'Н' => 'N', 'Њ' => 'N
|
20 |
'О' => 'O', 'П' => 'P', 'Р' => 'R', 'С' => 'S', 'Т' => 'T',
|
21 |
-
'У' => 'U', 'Ў' => 'U
|
22 |
-
'Ч' => 'CH', 'Џ' => 'DH', 'Ш' => 'SH', 'Щ' => 'SHH', 'Ъ' => '
|
23 |
-
'Ы' => 'Y
|
24 |
'а' => 'a', 'б' => 'b', 'в' => 'v', 'г' => 'g', 'ѓ' => 'g',
|
25 |
'ґ' => 'g', 'д' => 'd', 'е' => 'e', 'ё' => 'yo', 'є' => 'ye',
|
26 |
'ж' => 'zh', 'з' => 'z', 'ѕ' => 'z', 'и' => 'i', 'й' => 'j',
|
27 |
-
'ј' => 'j', 'і' => 'i', 'ї' => 'yi', 'к' => 'k', 'ќ' => 'k
|
28 |
-
'л' => 'l', 'љ' => 'l', 'м' => 'm', 'н' => 'n', 'њ' => 'n
|
29 |
'о' => 'o', 'п' => 'p', 'р' => 'r', 'с' => 's', 'т' => 't',
|
30 |
-
'у' => 'u', 'ў' => 'u
|
31 |
-
'ч' => 'ch', 'џ' => 'dh', 'ш' => 'sh', 'щ' => 'shh', 'ъ' => '
|
32 |
-
'ы' => 'y
|
33 |
);
|
34 |
$geo2lat = array(
|
35 |
'ა' => 'a', 'ბ' => 'b', 'გ' => 'g', 'დ' => 'd', 'ე' => 'e', 'ვ' => 'v',
|
@@ -50,10 +50,8 @@ function ctl_sanitize_title($title) {
|
|
50 |
$iso9_table['ъ'] = 'a';
|
51 |
break;
|
52 |
case 'uk':
|
53 |
-
$iso9_table['И'] = 'Y';
|
54 |
-
$iso9_table['и'] = 'y';
|
55 |
-
break;
|
56 |
case 'uk_ua':
|
|
|
57 |
$iso9_table['И'] = 'Y';
|
58 |
$iso9_table['и'] = 'y';
|
59 |
break;
|
5 |
Description: Converts Cyrillic, European and Georgian characters in post, term slugs and media file names to Latin characters. Useful for creating human-readable URLs. Based on the original plugin by Anton Skorobogatov.
|
6 |
Author: Sol, Sergey Biryukov, Nikolay Karev, Dmitri Gogelia
|
7 |
Author URI: http://karevn.com/
|
8 |
+
Version: 3.5
|
9 |
*/
|
10 |
|
11 |
function ctl_sanitize_title($title) {
|
12 |
global $wpdb;
|
13 |
|
14 |
$iso9_table = array(
|
15 |
+
'А' => 'A', 'Б' => 'B', 'В' => 'V', 'Г' => 'G', 'Ѓ' => 'G',
|
16 |
+
'Ґ' => 'G', 'Д' => 'D', 'Е' => 'E', 'Ё' => 'YO', 'Є' => 'YE',
|
17 |
'Ж' => 'ZH', 'З' => 'Z', 'Ѕ' => 'Z', 'И' => 'I', 'Й' => 'J',
|
18 |
+
'Ј' => 'J', 'І' => 'I', 'Ї' => 'YI', 'К' => 'K', 'Ќ' => 'K',
|
19 |
+
'Л' => 'L', 'Љ' => 'L', 'М' => 'M', 'Н' => 'N', 'Њ' => 'N',
|
20 |
'О' => 'O', 'П' => 'P', 'Р' => 'R', 'С' => 'S', 'Т' => 'T',
|
21 |
+
'У' => 'U', 'Ў' => 'U', 'Ф' => 'F', 'Х' => 'H', 'Ц' => 'TS',
|
22 |
+
'Ч' => 'CH', 'Џ' => 'DH', 'Ш' => 'SH', 'Щ' => 'SHH', 'Ъ' => '',
|
23 |
+
'Ы' => 'Y', 'Ь' => '', 'Э' => 'E', 'Ю' => 'YU', 'Я' => 'YA',
|
24 |
'а' => 'a', 'б' => 'b', 'в' => 'v', 'г' => 'g', 'ѓ' => 'g',
|
25 |
'ґ' => 'g', 'д' => 'd', 'е' => 'e', 'ё' => 'yo', 'є' => 'ye',
|
26 |
'ж' => 'zh', 'з' => 'z', 'ѕ' => 'z', 'и' => 'i', 'й' => 'j',
|
27 |
+
'ј' => 'j', 'і' => 'i', 'ї' => 'yi', 'к' => 'k', 'ќ' => 'k',
|
28 |
+
'л' => 'l', 'љ' => 'l', 'м' => 'm', 'н' => 'n', 'њ' => 'n',
|
29 |
'о' => 'o', 'п' => 'p', 'р' => 'r', 'с' => 's', 'т' => 't',
|
30 |
+
'у' => 'u', 'ў' => 'u', 'ф' => 'f', 'х' => 'h', 'ц' => 'ts',
|
31 |
+
'ч' => 'ch', 'џ' => 'dh', 'ш' => 'sh', 'щ' => 'shh', 'ъ' => '',
|
32 |
+
'ы' => 'y', 'ь' => '', 'э' => 'e', 'ю' => 'yu', 'я' => 'ya'
|
33 |
);
|
34 |
$geo2lat = array(
|
35 |
'ა' => 'a', 'ბ' => 'b', 'გ' => 'g', 'დ' => 'd', 'ე' => 'e', 'ვ' => 'v',
|
50 |
$iso9_table['ъ'] = 'a';
|
51 |
break;
|
52 |
case 'uk':
|
|
|
|
|
|
|
53 |
case 'uk_ua':
|
54 |
+
case 'uk_UA':
|
55 |
$iso9_table['И'] = 'Y';
|
56 |
$iso9_table['и'] = 'y';
|
57 |
break;
|
readme.txt
CHANGED
@@ -2,8 +2,8 @@
|
|
2 |
Contributors: Atrax, SergeyBiryukov, karevn, webvitaly
|
3 |
Tags: cyrillic, latin, l10n, russian, rustolat, slugs, translations, transliteration, media, georgian, european, diacritics, ukrainian
|
4 |
Requires at least: 2.3
|
5 |
-
Tested up to:
|
6 |
-
Stable tag: 3.
|
7 |
|
8 |
Converts Cyrillic, European and Georgian characters in post, page and term slugs to Latin characters.
|
9 |
|
@@ -25,7 +25,7 @@ Based on the original Rus-To-Lat plugin by Anton Skorobogatov.
|
|
25 |
|
26 |
== Installation ==
|
27 |
|
28 |
-
1. Upload `
|
29 |
2. Activate the plugin through the 'Plugins' menu in WordPress.
|
30 |
3. Make sure your system has iconv set up right, or iconv is not installed at all. If you have any problems (trimmed slugs, strange characters, question marks) - please ask for support.
|
31 |
== Frequently Asked Questions ==
|
@@ -44,6 +44,9 @@ add_filter('ctl_table', 'my_cyr_to_lat_table');
|
|
44 |
|
45 |
== Changelog ==
|
46 |
|
|
|
|
|
|
|
47 |
= 3.4 =
|
48 |
* Fixes for Ukrainian characters
|
49 |
|
2 |
Contributors: Atrax, SergeyBiryukov, karevn, webvitaly
|
3 |
Tags: cyrillic, latin, l10n, russian, rustolat, slugs, translations, transliteration, media, georgian, european, diacritics, ukrainian
|
4 |
Requires at least: 2.3
|
5 |
+
Tested up to: 4.1
|
6 |
+
Stable tag: 3.5
|
7 |
|
8 |
Converts Cyrillic, European and Georgian characters in post, page and term slugs to Latin characters.
|
9 |
|
25 |
|
26 |
== Installation ==
|
27 |
|
28 |
+
1. Upload `cyr3lat` folder to the `/wp-content/plugins/` directory.
|
29 |
2. Activate the plugin through the 'Plugins' menu in WordPress.
|
30 |
3. Make sure your system has iconv set up right, or iconv is not installed at all. If you have any problems (trimmed slugs, strange characters, question marks) - please ask for support.
|
31 |
== Frequently Asked Questions ==
|
44 |
|
45 |
== Changelog ==
|
46 |
|
47 |
+
= 3.5 =
|
48 |
+
* Removed quotes from table which added extra dashes
|
49 |
+
|
50 |
= 3.4 =
|
51 |
* Fixes for Ukrainian characters
|
52 |
|