Weglot Translate – Translate your WP website - Version 1.10

Version Description

  • Add new languages + add Oman flag
  • Can potentially translate email sent from admin
  • Add tags to inline elements to ignore when parsing
Download this release

Release Info

Developer remyb92
Plugin Icon 128x128 Weglot Translate – Translate your WP website
Version 1.10
Comparing to
See all releases

Code changes from version 1.9.3 to 1.10

WGUtils.php CHANGED
@@ -4,146 +4,218 @@ class WGUtils {
4
 
5
  public static function getLangNameFromCode( $code, $english ) {
6
  switch ( $code ) {
7
- case 'sq':
8
- return $english ? 'Albanian' : 'Shqip';
9
- case 'en':
10
- return $english ? 'English' : 'English';
11
- case 'ar':
12
- return $english ? 'Arabic' : '‏العربية‏';
13
- case 'hy':
14
- return $english ? 'Armenian' : 'հայերեն';
15
- case 'az':
16
- return $english ? 'Azerbaijani' : 'Azərbaycan dili';
17
- case 'af':
18
- return $english ? 'Afrikaans' : 'Afrikaans';
19
- case 'eu':
20
- return $english ? 'Basque' : 'Euskara';
21
- case 'be':
22
- return $english ? 'Belarusian' : 'Беларуская';
23
- case 'bg':
24
- return $english ? 'Bulgarian' : 'български';
25
- case 'bs':
26
- return $english ? 'Bosnian' : 'Bosanski';
27
- case 'vi':
28
- return $english ? 'Vietnamese' : 'Tiếng Việt';
29
- case 'hu':
30
- return $english ? 'Hungarian' : 'Magyar';
31
- case 'ht':
32
- return $english ? 'Haitian' : 'Kreyòl ayisyen';
33
- case 'gl':
34
- return $english ? 'Galician' : 'Galego';
35
- case 'nl':
36
- return $english ? 'Dutch' : 'Nederlands';
37
- case 'el':
38
- return $english ? 'Greek' : 'Ελληνικά';
39
- case 'ka':
40
- return $english ? 'Georgian' : 'ქართული';
41
- case 'da':
42
- return $english ? 'Danish' : 'Dansk';
43
- case 'he':
44
- return $english ? 'Hebrew' : 'עברית';
45
- case 'id':
46
- return $english ? 'Indonesian' : 'Bahasa Indonesia';
47
- case 'ga':
48
- return $english ? 'Irish' : 'Gaeilge';
49
- case 'it':
50
- return $english ? 'Italian' : 'Italiano';
51
- case 'is':
52
- return $english ? 'Icelandic' : 'Íslenska';
53
- case 'es':
54
- return $english ? 'Spanish' : 'Español';
55
- case 'kk':
56
- return $english ? 'Kazakh' : 'Қазақша';
57
- case 'ca':
58
- return $english ? 'Catalan' : 'Català';
59
- case 'ky':
60
- return $english ? 'Kyrgyz' : 'кыргызча';
61
- case 'zh':
62
- return $english ? 'Simplified Chinese' : '中文 (简体)';
63
- case 'tw':
64
- return $english ? 'Traditional Chinese' : '中文 (繁體)';
65
- case 'ko':
66
- return $english ? 'Korean' : '한국어';
67
- case 'lv':
68
- return $english ? 'Latvian' : 'Latviešu';
69
- case 'lt':
70
- return $english ? 'Lithuanian' : 'Lietuvių';
71
- case 'mg':
72
- return $english ? 'Malagasy' : 'Malagasy';
73
- case 'ms':
74
- return $english ? 'Malay' : 'Bahasa Melayu';
75
- case 'mt':
76
- return $english ? 'Maltese' : 'Malti';
77
- case 'mk':
78
- return $english ? 'Macedonian' : 'Македонски';
79
- case 'mn':
80
- return $english ? 'Mongolian' : 'Монгол';
81
- case 'de':
82
- return $english ? 'German' : 'Deutsch';
83
- case 'no':
84
- return $english ? 'Norwegian' : 'Norsk';
85
- case 'fa':
86
- return $english ? 'Persian' : 'فارسی';
87
- case 'pl':
88
- return $english ? 'Polish' : 'Polski';
89
- case 'pt':
90
- return $english ? 'Portuguese' : 'Português';
91
- case 'ro':
92
- return $english ? 'Romanian' : 'Română';
93
- case 'ru':
94
- return $english ? 'Russian' : 'Русский';
95
- case 'sr':
96
- return $english ? 'Serbian' : 'Српски';
97
- case 'sk':
98
- return $english ? 'Slovak' : 'Slovenčina';
99
- case 'sl':
100
- return $english ? 'Slovenian' : 'Slovenščina';
101
- case 'sw':
102
- return $english ? 'Swahili' : 'Kiswahili';
103
- case 'tg':
104
- return $english ? 'Tajik' : 'Тоҷикӣ';
105
- case 'th':
106
- return $english ? 'Thai' : 'ภาษาไทย';
107
- case 'tl':
108
- return $english ? 'Tagalog' : 'Tagalog';
109
- case 'tt':
110
- return $english ? 'Tatar' : 'Tatar';
111
- case 'tr':
112
- return $english ? 'Turkish' : 'Türkçe';
113
- case 'uz':
114
- return $english ? 'Uzbek' : "O'zbek";
115
- case 'uk':
116
- return $english ? 'Ukrainian' : 'Українська';
117
- case 'fi':
118
- return $english ? 'Finnish' : 'Suomi';
119
- case 'fr':
120
- return $english ? 'French' : 'Français';
121
- case 'hr':
122
- return $english ? 'Croatian' : 'Hrvatski';
123
- case 'cs':
124
- return $english ? 'Czech' : 'Čeština';
125
- case 'sv':
126
- return $english ? 'Swedish' : 'Svenska';
127
- case 'et':
128
- return $english ? 'Estonian' : 'Eesti';
129
- case 'ja':
130
- return $english ? 'Japanese' : '日本語';
131
- case 'hi':
132
- return $english ? 'Hindi' : 'हिंदी';
133
- case 'ur':
134
- return $english ? 'Urdu' : 'اردو';
135
  case "bn":
136
  return $english ? "Bengali" : "বাংলা";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
137
  case "fj":
138
  return $english ? "Fijian" : "Fidžin";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
139
  case "sm":
140
  return $english ? "Samoan" : "Samoa";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
141
  case "ty":
142
  return $english ? "Tahitian" : "Tahitian";
 
 
 
 
 
 
 
 
 
 
143
  case "to":
144
  return $english ? "Tongan" : "Tonga";
 
 
 
 
 
 
 
 
 
 
145
  case "cy":
146
  return $english ? "Welsh" : "Cymraeg";
 
 
 
 
 
 
 
 
 
 
147
  }
148
  }
149
 
4
 
5
  public static function getLangNameFromCode( $code, $english ) {
6
  switch ( $code ) {
7
+ case "af":
8
+ return $english ? "Afrikaans" : "Afrikaans";
9
+ case "sq":
10
+ return $english ? "Albanian" : "Shqip";
11
+ case "am":
12
+ return $english ? "Amharic" : "አማርኛ";
13
+ case "ar":
14
+ return $english ? "Arabic" : "‏العربية‏";
15
+ case "hy":
16
+ return $english ? "Armenian" : "հայերեն";
17
+ case "az":
18
+ return $english ? "Azerbaijani" : "Azərbaycan dili";
19
+ case "ba":
20
+ return $english ? "Bashkir" : "башҡорт теле";
21
+ case "eu":
22
+ return $english ? "Basque" : "Euskara";
23
+ case "be":
24
+ return $english ? "Belarusian" : "Беларуская";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
25
  case "bn":
26
  return $english ? "Bengali" : "বাংলা";
27
+ case "bs":
28
+ return $english ? "Bosnian" : "Bosanski";
29
+ case "bg":
30
+ return $english ? "Bulgarian" : "български";
31
+ case "my":
32
+ return $english ? "Burmese" : "မြန်မာ";
33
+ case "ca":
34
+ return $english ? "Catalan" : "Català";
35
+ case "km":
36
+ return $english ? "Khmer" : "ភាសាខ្មែរ";
37
+ case "ny":
38
+ return $english ? "Chichewa" : "Chicheŵa";
39
+ case "co":
40
+ return $english ? "Corsican" : "Corsu";
41
+ case "zh":
42
+ return $english ? "Simplified Chinese" : "中文 (简体)";
43
+ case "tw":
44
+ return $english ? "Traditional Chinese" : "中文 (繁體)";
45
+ case "hr":
46
+ return $english ? "Croatian" : "Hrvatski";
47
+ case "cs":
48
+ return $english ? "Czech" : "Čeština";
49
+ case "da":
50
+ return $english ? "Danish" : "Dansk";
51
+ case "nl":
52
+ return $english ? "Dutch" : "Nederlands";
53
+ case "en":
54
+ return $english ? "English" : "English";
55
+ case "eo":
56
+ return $english ? "Esperanto" : "Esperanto";
57
+ case "et":
58
+ return $english ? "Estonian" : "Eesti";
59
  case "fj":
60
  return $english ? "Fijian" : "Fidžin";
61
+ case "fi":
62
+ return $english ? "Finnish" : "Suomi";
63
+ case "fr":
64
+ return $english ? "French" : "Français";
65
+ case "gl":
66
+ return $english ? "Galician" : "Galego";
67
+ case "ka":
68
+ return $english ? "Georgian" : "ქართული";
69
+ case "de":
70
+ return $english ? "German" : "Deutsch";
71
+ case "el":
72
+ return $english ? "Greek" : "Ελληνικά";
73
+ case "gu":
74
+ return $english ? "Gujarati" : "ગુજરાતી";
75
+ case "ht":
76
+ return $english ? "Haitian" : "Kreyòl ayisyen";
77
+ case "ha":
78
+ return $english ? "Hausa" : "Hausa";
79
+ case "he":
80
+ return $english ? "Hebrew" : "עברית";
81
+ case "hi":
82
+ return $english ? "Hindi" : "हिंदी";
83
+ case "hu":
84
+ return $english ? "Hungarian" : "Magyar";
85
+ case "is":
86
+ return $english ? "Icelandic" : "Íslenska";
87
+ case "ig":
88
+ return $english ? "Igbo" : "Igbo";
89
+ case "id":
90
+ return $english ? "Indonesian" : "Bahasa Indonesia";
91
+ case "ga":
92
+ return $english ? "Irish" : "Gaeilge";
93
+ case "it":
94
+ return $english ? "Italian" : "Italiano";
95
+ case "ja":
96
+ return $english ? "Japanese" : "日本語";
97
+ case "jv":
98
+ return $english ? "Javanese" : "baṣa Jawa";
99
+ case "kn":
100
+ return $english ? "Kannada" : "ಕನ್ನಡ";
101
+ case "kk":
102
+ return $english ? "Kazakh" : "Қазақша";
103
+ case "ko":
104
+ return $english ? "Korean" : "한국어";
105
+ case "ku":
106
+ return $english ? "Kurdish" : "Kurdí";
107
+ case "ky":
108
+ return $english ? "Kyrgyz" : "кыргызча";
109
+ case "lo":
110
+ return $english ? "Lao" : "ລາວ";
111
+ case "la":
112
+ return $english ? "Latin" : "Latine";
113
+ case "lv":
114
+ return $english ? "Latvian" : "Latviešu";
115
+ case "lt":
116
+ return $english ? "Lithuanian" : "Lietuvių";
117
+ case "lb":
118
+ return $english ? "Luxembourgish" : "Lëtzebuergesch";
119
+ case "mk":
120
+ return $english ? "Macedonian" : "Македонски";
121
+ case "mg":
122
+ return $english ? "Malagasy" : "Malagasy";
123
+ case "ms":
124
+ return $english ? "Malay" : "Bahasa Melayu";
125
+ case "ml":
126
+ return $english ? "Malayalam" : "മലയാളം";
127
+ case "mt":
128
+ return $english ? "Maltese" : "Malti";
129
+ case "mi":
130
+ return $english ? "Māori" : "Māori";
131
+ case "mr":
132
+ return $english ? "Marathi" : "मराठी";
133
+ case "mn":
134
+ return $english ? "Mongolian" : "Монгол";
135
+ case "ne":
136
+ return $english ? "Nepali" : "नेपाली";
137
+ case "no":
138
+ return $english ? "Norwegian" : "Norsk";
139
+ case "ps":
140
+ return $english ? "Pashto" : "پښتو";
141
+ case "fa":
142
+ return $english ? "Persian" : "فارسی";
143
+ case "pl":
144
+ return $english ? "Polish" : "Polski";
145
+ case "pt":
146
+ return $english ? "Portuguese" : "Português";
147
+ case "pa":
148
+ return $english ? "Punjabi" : "ਪੰਜਾਬੀ";
149
+ case "ro":
150
+ return $english ? "Romanian" : "Română";
151
+ case "ru":
152
+ return $english ? "Russian" : "Русский";
153
  case "sm":
154
  return $english ? "Samoan" : "Samoa";
155
+ case "gd":
156
+ return $english ? "Scottish Gaelic" : "Gàidhlig na h-Alba";
157
+ case "sr":
158
+ return $english ? "Serbian" : "Српски";
159
+ case "sn":
160
+ return $english ? "Shona" : "chiShona";
161
+ case "sd":
162
+ return $english ? "Sindhi" : "سنڌي";
163
+ case "si":
164
+ return $english ? "Sinhalese" : "සිංහල";
165
+ case "sk":
166
+ return $english ? "Slovak" : "Slovenčina";
167
+ case "sl":
168
+ return $english ? "Slovenian" : "Slovenščina";
169
+ case "so":
170
+ return $english ? "Somali" : "af Soomaali";
171
+ case "st":
172
+ return $english ? "Southern Sotho" : "seSotho";
173
+ case "es":
174
+ return $english ? "Spanish" : "Español";
175
+ case "su":
176
+ return $english ? "Sundanese" : "Sunda";
177
+ case "sw":
178
+ return $english ? "Swahili" : "Kiswahili";
179
+ case "sv":
180
+ return $english ? "Swedish" : "Svenska";
181
+ case "tl":
182
+ return $english ? "Tagalog" : "Tagalog";
183
  case "ty":
184
  return $english ? "Tahitian" : "Tahitian";
185
+ case "tg":
186
+ return $english ? "Tajik" : "Тоҷикӣ";
187
+ case "ta":
188
+ return $english ? "Tamil" : "தமிழ்";
189
+ case "tt":
190
+ return $english ? "Tatar" : "Tatar";
191
+ case "te":
192
+ return $english ? "Telugu" : "తెలుగు";
193
+ case "th":
194
+ return $english ? "Thai" : "ภาษาไทย";
195
  case "to":
196
  return $english ? "Tongan" : "Tonga";
197
+ case "tr":
198
+ return $english ? "Turkish" : "Türkçe";
199
+ case "uk":
200
+ return $english ? "Ukrainian" : "Українська";
201
+ case "ur":
202
+ return $english ? "Urdu" : "اردو";
203
+ case "uz":
204
+ return $english ? "Uzbek" : "O'zbek";
205
+ case "vi":
206
+ return $english ? "Vietnamese" : "Tiếng Việt";
207
  case "cy":
208
  return $english ? "Welsh" : "Cymraeg";
209
+ case "fy":
210
+ return $english ? "Western Frisian" : "Frysk";
211
+ case "xh":
212
+ return $english ? "Xhosa" : "isiXhosa";
213
+ case "yi":
214
+ return $english ? "Yiddish" : "ײִדיש";
215
+ case "yo":
216
+ return $english ? "Yoruba" : "Yorùbá";
217
+ case "zu":
218
+ return $english ? "Zulu" : "isiZulu";
219
  }
220
  }
221
 
WeglotPHPClient/src/Client.php CHANGED
@@ -35,11 +35,16 @@ class Client {
35
  return false;
36
  }
37
 
 
 
 
38
 
39
  public function checkText( $row ) {
40
  return ($row->parent()->tag != 'script'
41
  && $row->parent()->tag != 'style'
42
  && $row->parent()->tag != 'noscript'
 
 
43
  && ! is_numeric( $this->full_trim( $row->outertext ) )
44
  && ! preg_match( '/^\d+%$/',$this->full_trim( $row->outertext ) )
45
  && strpos( $row->outertext,'[vc_' ) === false);
@@ -81,6 +86,10 @@ class Client {
81
  return (strpos( $this->full_trim( $row->src ),'youtube.' ) !== false);
82
  }
83
 
 
 
 
 
84
  public function checkImg_src( $row ) {
85
  return true;
86
  }
@@ -93,7 +102,7 @@ class Client {
93
  return (
94
  strtolower( substr( $this->full_trim( $row->href ),-4 ) ) == '.pdf'
95
  || strtolower( substr( $this->full_trim( $row->href ),-4 ) ) == '.rar'
96
- || strtolower( substr( $this->full_trim( $row->href ),-4 ) ) == '.docx'
97
  );
98
  }
99
 
@@ -138,7 +147,17 @@ class Client {
138
  $nodes_to_ignore = array(
139
  array('<strong>','</strong>'),
140
  array('<em>','</em>'),
141
-
 
 
 
 
 
 
 
 
 
 
142
  );
143
 
144
  foreach ($nodes_to_ignore as $ignore) {
@@ -169,16 +188,37 @@ class Client {
169
  $nodes = array();
170
 
171
  $elements_to_check = array(
172
- 'text'
173
- => array(
174
- array(
175
- 'property' => 'outertext',
176
- 't' => 1,
177
- 'type' => 'text',
178
- ),
179
- ),
180
 
181
- "input[type='submit'],input[type='button']"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
182
  => array(
183
  array(
184
  'property' => 'value',
@@ -225,15 +265,6 @@ class Client {
225
  ),
226
  ),
227
 
228
- 'meta[name="description"],meta[property="og:title"],meta[property="og:description"],meta[property="og:site_name"],meta[name="twitter:title"],meta[name="twitter:description"]'
229
- => array(
230
- array(
231
- 'property' => 'content',
232
- 't' => 4,
233
- 'type' => 'meta_desc',
234
- ),
235
- ),
236
-
237
  'iframe'
238
  => array(
239
  array(
@@ -257,6 +288,15 @@ class Client {
257
  ),
258
  ),
259
 
 
 
 
 
 
 
 
 
 
260
  'a'
261
  => array(
262
  array(
35
  return false;
36
  }
37
 
38
+ public function checkTitle( $row ) {
39
+ return true;
40
+ }
41
 
42
  public function checkText( $row ) {
43
  return ($row->parent()->tag != 'script'
44
  && $row->parent()->tag != 'style'
45
  && $row->parent()->tag != 'noscript'
46
+ && $row->parent()->tag != 'title'
47
+ && $row->parent()->tag != 'code'
48
  && ! is_numeric( $this->full_trim( $row->outertext ) )
49
  && ! preg_match( '/^\d+%$/',$this->full_trim( $row->outertext ) )
50
  && strpos( $row->outertext,'[vc_' ) === false);
86
  return (strpos( $this->full_trim( $row->src ),'youtube.' ) !== false);
87
  }
88
 
89
+ public function checkSource_src( $row ) {
90
+ return true;
91
+ }
92
+
93
  public function checkImg_src( $row ) {
94
  return true;
95
  }
102
  return (
103
  strtolower( substr( $this->full_trim( $row->href ),-4 ) ) == '.pdf'
104
  || strtolower( substr( $this->full_trim( $row->href ),-4 ) ) == '.rar'
105
+ || strtolower( substr( $this->full_trim( $row->href ),-4 ) ) == 'docx'
106
  );
107
  }
108
 
147
  $nodes_to_ignore = array(
148
  array('<strong>','</strong>'),
149
  array('<em>','</em>'),
150
+ array('<abbr>','</abbr>'),
151
+ array('<acronym>','</acronym>'),
152
+ array('<b>','</b>'),
153
+ array('<bdo>','</bdo>'),
154
+ array('<big>','</big>'),
155
+ array('<cite>','</cite>'),
156
+ array('<kbd>','</kbd>'),
157
+ array('<q>','</q>'),
158
+ array('<small>','</small>'),
159
+ array('<sub>','</sub>'),
160
+ array('<sup>','</sup>'),
161
  );
162
 
163
  foreach ($nodes_to_ignore as $ignore) {
188
  $nodes = array();
189
 
190
  $elements_to_check = array(
 
 
 
 
 
 
 
 
191
 
192
+ 'title'
193
+ => array(
194
+ array(
195
+ 'property' => 'innertext',
196
+ 't' => 4,
197
+ 'type' => 'text',
198
+ ),
199
+ ),
200
+
201
+
202
+ 'meta[name="description"],meta[property="og:title"],meta[property="og:description"],meta[property="og:site_name"],meta[name="twitter:title"],meta[name="twitter:description"]'
203
+ => array(
204
+ array(
205
+ 'property' => 'content',
206
+ 't' => 4,
207
+ 'type' => 'meta_desc',
208
+ ),
209
+ ),
210
+
211
+ 'text'
212
+ => array(
213
+ array(
214
+ 'property' => 'outertext',
215
+ 't' => 1,
216
+ 'type' => 'text',
217
+ ),
218
+ ),
219
+
220
+
221
+ "input[type='submit'],input[type='button'],button"
222
  => array(
223
  array(
224
  'property' => 'value',
265
  ),
266
  ),
267
 
 
 
 
 
 
 
 
 
 
268
  'iframe'
269
  => array(
270
  array(
288
  ),
289
  ),
290
 
291
+ 'source'
292
+ => array(
293
+ array(
294
+ 'property' => 'src',
295
+ 't' => 5,
296
+ 'type' => 'source_src',
297
+ ),
298
+ ),
299
+
300
  'a'
301
  => array(
302
  array(
includes/wg-settings-page.php CHANGED
@@ -1,352 +1,1013 @@
1
  <?php
2
- $showRTL = false;
3
- $showLTR = false;
4
- if ( WGUtils::isLanguageRTL( $this->original_l ) ) { // Right lo left language
5
- if ( WGUtils::hasLanguageLTR( explode( ',',$this->destination_l ) ) ) {
6
- $showLTR = true;
7
- }
8
  } else { // Left to right language
9
- if ( WGUtils::hasLanguageRTL( explode( ',',$this->destination_l ) ) ) {
10
- $showRTL = true;
11
- }
12
  } ?>
13
  <div class="wrap">
14
- <?php if ( $this->allowed == 0 ) { ?>
15
- <div class="wg-status-box">
16
- <h3><?php echo sprintf( esc_html__( 'Weglot Translate service is not active because you have reached the end of the trial period.', 'weglot' ),esc_html__( $this->userInfo['limit'] ) ); ?></h3>
17
- <p><?php echo sprintf( esc_html__( 'To reactivate the service, please %1$supgrade your plan%2$s.', 'weglot' ), '<a target="_blank" href="https://weglot.com/change-plan">', '</a>' ); ?></p>
18
- </div>
19
- <?php } ?>
20
 
21
- <?php if ( esc_attr( get_option( 'show_box' ) ) == 'on' ) { ?>
22
- <div class="wgbox-blur">
23
- <div class="wgbox">
24
- <div class="wgclose-btn"><?php esc_html_e( 'Close','weglot' ); ?></div>
25
- <h3 class="wgbox-title"><?php esc_html_e( 'Well done! Your website is now multilingual.','weglot' ); ?></h3>
26
- <p class="wgbox-text"><?php esc_html_e( 'Go on your website, there is a language switcher. Try it :)','weglot' ); ?></p>
27
- <a class="wgbox-button button button-primary" href="
28
  <?php
29
- echo
30
- esc_html__( $this->home_dir );
31
- ?>
32
  /" target="_blank">
33
- <?php
34
- esc_html_e( 'Go on my front page.','weglot' );
35
- ?>
36
- </a>
37
- <p class="wgbox-subtext"><?php esc_html_e( 'Next step, edit your translations directly in your Weglot account.','weglot' ); ?></p>
38
- </div>
39
- </div>
40
- <?php
41
- list($wgfirstlang) = explode( ',', get_option( 'destination_l' ) );
42
- if ( strlen( $wgfirstlang ) == 2 ) {
43
- ?>
44
- <iframe style="visibility:hidden;" src="
45
  <?php
46
- echo esc_html__( $this->home_dir );
47
- ?>
48
- /<?php echo esc_html__( $wgfirstlang ); ?>/" width=1
49
- height =1
50
- ></iframe>
51
- <?php } ?>
52
- <?php update_option( 'show_box','off' ); } ?>
53
- <form class="wg-widget-option-form" method="post" action="options.php">
54
- <?php settings_fields( 'my-plugin-settings-group' ); ?>
55
- <?php do_settings_sections( 'my-plugin-settings-group' ); ?>
56
- <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;"><?php esc_html_e( 'Main configuration', 'weglot' ); ?></h3>
57
- <table class="form-table">
58
- <tr valign="top">
59
- <th scope="row"><?php esc_html_e( 'API Key', 'weglot' ); ?><p style="font-weight:normal;margin-top:2px;"><?php echo sprintf( esc_html__( 'Log in to %1$sWeglot%2$s to get your API key.', 'weglot' ),'<a target="_blank" href="https://weglot.com/register-wordpress">', '</a>' ); ?></p></th>
60
- <td><input type="text" class="wg-input-text" name="project_key" value="<?php echo esc_attr( get_option( 'project_key' ) ); ?>" placeholder="wg_XXXXXXXX" required /></td>
61
- </tr>
62
- <tr valign="top">
63
- <th scope="row"><?php esc_html_e( 'Original Language', 'weglot' ); ?><p style="font-weight:normal;margin-top:2px;"><?php esc_html_e( 'What is the original (current) language of your website?', 'weglot' ); ?></p></th>
64
- <td>
65
- <select class="wg-input-select" name="original_l" style="width :200px;">
66
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'af' ) { echo 'selected'; } ?> value="af"><?php esc_html_e( 'Afrikaans', 'weglot' ); ?></option>
67
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sq' ) { echo 'selected'; } ?> value="sq"><?php esc_html_e( 'Albanian', 'weglot' ); ?></option>
68
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ar' ) { echo 'selected'; } ?> value="ar"><?php esc_html_e( 'Arabic', 'weglot' ); ?></option>
69
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'hy' ) { echo 'selected'; } ?> value="hy"><?php esc_html_e( 'Armenian', 'weglot' ); ?></option>
70
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'az' ) { echo 'selected'; } ?> value="az"><?php esc_html_e( 'Azerbaijani', 'weglot' ); ?></option>
71
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'eu' ) { echo 'selected'; } ?> value="eu"><?php esc_html_e( 'Basque', 'weglot' ); ?></option>
72
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'bn' ) { echo 'selected'; } ?> value="bn"><?php esc_html_e( 'Bengali', 'weglot' ); ?></option>
73
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'bs' ) { echo 'selected'; } ?> value="bs"><?php esc_html_e( 'Bosnian', 'weglot' ); ?></option>
74
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'be' ) { echo 'selected'; } ?> value="be"><?php esc_html_e( 'Belarusian', 'weglot' ); ?></option>
75
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'bg' ) { echo 'selected'; } ?> value="bg"><?php esc_html_e( 'Bulgarian', 'weglot' ); ?></option>
76
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ca' ) { echo 'selected'; } ?> value="ca"><?php esc_html_e( 'Catalan', 'weglot' ); ?></option>
77
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'zh' ) { echo 'selected'; } ?> value="zh"><?php esc_html_e( 'Simplified Chinese', 'weglot' ); ?></option>
78
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'tw' ) { echo 'selected'; } ?> value="tw"><?php esc_html_e( 'Traditional Chinese', 'weglot' ); ?></option>
79
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'hr' ) { echo 'selected'; } ?> value="hr"><?php esc_html_e( 'Croatian', 'weglot' ); ?></option>
80
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'cs' ) { echo 'selected'; } ?> value="cs"><?php esc_html_e( 'Czech', 'weglot' ); ?></option>
81
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'da' ) { echo 'selected'; } ?> value="da"><?php esc_html_e( 'Danish', 'weglot' ); ?></option>
82
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'nl' ) { echo 'selected'; } ?> value="nl"><?php esc_html_e( 'Dutch', 'weglot' ); ?></option>
83
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'en'|| !get_option( 'original_l' ) ) { echo 'selected'; } ?> value="en"><?php esc_html_e( 'English', 'weglot' ); ?></option>
84
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'et' ) { echo 'selected'; } ?> value="et"><?php esc_html_e( 'Estonian', 'weglot' ); ?></option>
85
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'fj' ) { echo 'selected'; } ?> value="fj"><?php esc_html_e( 'Fijian', 'weglot' ); ?></option>
86
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'fi' ) { echo 'selected'; } ?> value="fi"><?php esc_html_e( 'Finnish', 'weglot' ); ?></option>
87
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'fr' ) { echo 'selected'; } ?> value="fr"><?php esc_html_e( 'French', 'weglot' ); ?></option>
88
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ka' ) { echo 'selected'; } ?> value="ka"><?php esc_html_e( 'Georgian', 'weglot' ); ?></option>
89
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'de' ) { echo 'selected'; } ?> value="de"><?php esc_html_e( 'German', 'weglot' ); ?></option>
90
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'el' ) { echo 'selected'; } ?> value="el"><?php esc_html_e( 'Greek', 'weglot' ); ?></option>
91
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ht' ) { echo 'selected'; } ?> value="ht"><?php esc_html_e( 'Haitian', 'weglot' ); ?></option>
92
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'he' ) { echo 'selected'; } ?> value="he"><?php esc_html_e( 'Hebrew', 'weglot' ); ?></option>
93
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'hi' ) { echo 'selected'; } ?> value="hi"><?php esc_html_e( 'Hindi', 'weglot' ); ?></option>
94
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'hu' ) { echo 'selected'; } ?> value="hu"><?php esc_html_e( 'Hungarian', 'weglot' ); ?></option>
95
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'is' ) { echo 'selected'; } ?> value="is"><?php esc_html_e( 'Icelandic', 'weglot' ); ?></option>
96
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'id' ) { echo 'selected'; } ?> value="id"><?php esc_html_e( 'Indonesian', 'weglot' ); ?></option>
97
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ga' ) { echo 'selected'; } ?> value="ga"><?php esc_html_e( 'Irish', 'weglot' ); ?></option>
98
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'it' ) { echo 'selected'; } ?> value="it"><?php esc_html_e( 'Italian', 'weglot' ); ?></option>
99
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ja' ) { echo 'selected'; } ?> value="ja"><?php esc_html_e( 'Japanese', 'weglot' ); ?></option>
100
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'kk' ) { echo 'selected'; } ?> value="kk"><?php esc_html_e( 'Kazakh', 'weglot' ); ?></option>
101
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ko' ) { echo 'selected'; } ?> value="ko"><?php esc_html_e( 'Korean', 'weglot' ); ?></option>
102
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ky' ) { echo 'selected'; } ?> value="ky"><?php esc_html_e( 'Kyrgyz', 'weglot' ); ?></option>
103
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'lv' ) { echo 'selected'; } ?> value="lv"><?php esc_html_e( 'Latvian', 'weglot' ); ?></option>
104
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'lt' ) { echo 'selected'; } ?> value="lt"><?php esc_html_e( 'Lithuanian', 'weglot' ); ?></option>
105
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'mk' ) { echo 'selected'; } ?> value="mk"><?php esc_html_e( 'Macedonian', 'weglot' ); ?></option>
106
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'mg' ) { echo 'selected'; } ?> value="mg"><?php esc_html_e( 'Malagasy', 'weglot' ); ?></option>
107
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ms' ) { echo 'selected'; } ?> value="ms"><?php esc_html_e( 'Malay', 'weglot' ); ?></option>
108
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'mt' ) { echo 'selected'; } ?> value="mt"><?php esc_html_e( 'Maltese', 'weglot' ); ?></option>
109
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'mn' ) { echo 'selected'; } ?> value="mn"><?php esc_html_e( 'Mongolian', 'weglot' ); ?></option>
110
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'no' ) { echo 'selected'; } ?> value="no"><?php esc_html_e( 'Norwegian', 'weglot' ); ?></option>
111
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'fa' ) { echo 'selected'; } ?> value="fa"><?php esc_html_e( 'Persian', 'weglot' ); ?></option>
112
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'pl' ) { echo 'selected'; } ?> value="pl"><?php esc_html_e( 'Polish', 'weglot' ); ?></option>
113
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'pt' ) { echo 'selected'; } ?> value="pt"><?php esc_html_e( 'Portuguese', 'weglot' ); ?></option>
114
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ro' ) { echo 'selected'; } ?> value="ro"><?php esc_html_e( 'Romanian', 'weglot' ); ?></option>
115
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ru' ) { echo 'selected'; } ?> value="ru"><?php esc_html_e( 'Russian', 'weglot' ); ?></option>
116
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sm' ) { echo 'selected'; } ?> value="sm"><?php esc_html_e( 'Samoan', 'weglot' ); ?></option>
117
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sr' ) { echo 'selected'; } ?> value="sr"><?php esc_html_e( 'Serbian', 'weglot' ); ?></option>
118
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sk' ) { echo 'selected'; } ?> value="sk"><?php esc_html_e( 'Slovak', 'weglot' ); ?></option>
119
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sl' ) { echo 'selected'; } ?> value="sl"><?php esc_html_e( 'Slovenian', 'weglot' ); ?></option>
120
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'es' ) { echo 'selected'; } ?> value="es"><?php esc_html_e( 'Spanish', 'weglot' ); ?></option>
121
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sw' ) { echo 'selected'; } ?> value="sw"><?php esc_html_e( 'Swahili', 'weglot' ); ?></option>
122
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'sv' ) { echo 'selected'; } ?> value="sv"><?php esc_html_e( 'Swedish', 'weglot' ); ?></option>
123
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ty' ) { echo 'selected'; } ?> value="ty"><?php esc_html_e( 'Tahitian', 'weglot' ); ?></option>
124
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'tg' ) { echo 'selected'; } ?> value="tg"><?php esc_html_e( 'Tajik', 'weglot' ); ?></option>
125
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'th' ) { echo 'selected'; } ?> value="th"><?php esc_html_e( 'Thai', 'weglot' ); ?></option>
126
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'to' ) { echo 'selected'; } ?> value="to"><?php esc_html_e( 'Tongan', 'weglot' ); ?></option>
127
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'tr' ) { echo 'selected'; } ?> value="tr"><?php esc_html_e( 'Turkish', 'weglot' ); ?></option>
128
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'uk' ) { echo 'selected'; } ?> value="uk"><?php esc_html_e( 'Ukrainian', 'weglot' ); ?></option>
129
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'ur' ) { echo 'selected'; } ?> value="ur"><?php esc_html_e( 'Urdu', 'weglot' ); ?></option>
130
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'uz' ) { echo 'selected'; } ?> value="uz"><?php esc_html_e( 'Uzbek', 'weglot' ); ?></option>
131
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'vi' ) { echo 'selected'; } ?> value="vi"><?php esc_html_e( 'Vietnamese', 'weglot' ); ?></option>
132
- <option <?php if ( esc_attr( get_option( 'original_l' ) ) == 'cy' ) { echo 'selected'; } ?> value="cy"><?php esc_html_e( 'Welsh', 'weglot' ); ?></option>
133
- </select>
134
- </td>
135
- </tr>
136
- <tr valign="top">
137
- <th scope="row"><?php esc_html_e( 'Destination Languages', 'weglot' ); ?><p style="font-weight:normal;margin-top:2px;"><?php echo sprintf( esc_html__( 'Choose languages you want to translate into. Supported languages can be found %1$shere%2$s.', 'weglot' ), '<a target="_blank" href="https://weglot.com/translation-api#languages_code">', '</a>' ); ?></p></th>
138
- <td>
139
- <div style="display:inline-block;width:300px; margin-top: 35px;">
140
- <select id="select-lto" multiple class="demo-default" style="" placeholder="French, German, Italian, Portuguese, …" name="destination_l" > <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'fr' ) !== false ) { echo 'selected'; } ?> value="fr"><?php esc_html_e( 'French', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'en' ) !== false ) { echo 'selected'; } ?> value="en"><?php esc_html_e( 'English', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'zh' ) !== false ) { echo 'selected'; } ?> value="zh"><?php esc_html_e( 'Simplified Chinese', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'tw' ) !== false ) { echo 'selected'; } ?> value="tw"><?php esc_html_e( 'Traditional Chinese', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ru' ) !== false ) { echo 'selected'; } ?> value="ru"><?php esc_html_e( 'Russian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'de' ) !== false ) { echo 'selected'; } ?> value="de"><?php esc_html_e( 'German', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'es' ) !== false ) { echo 'selected'; } ?> value="es"><?php esc_html_e( 'Spanish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sq' ) !== false ) { echo 'selected'; } ?> value="sq"><?php esc_html_e( 'Albanian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ar' ) !== false ) { echo 'selected'; } ?> value="ar"><?php esc_html_e( 'Arabic', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'hy' ) !== false ) { echo 'selected'; } ?> value="hy"><?php esc_html_e( 'Armenian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'az' ) !== false ) { echo 'selected'; } ?> value="az"><?php esc_html_e( 'Azerbaijani', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'af' ) !== false ) { echo 'selected'; } ?> value="af"><?php esc_html_e( 'Afrikaans', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'eu' ) !== false ) { echo 'selected'; } ?> value="eu"><?php esc_html_e( 'Basque', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'be' ) !== false ) { echo 'selected'; } ?> value="be"><?php esc_html_e( 'Belarusian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'bg' ) !== false ) { echo 'selected'; } ?> value="bg"><?php esc_html_e( 'Bulgarian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'bs' ) !== false ) { echo 'selected'; } ?> value="bs"><?php esc_html_e( 'Bosnian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'vi' ) !== false ) { echo 'selected'; } ?> value="vi"><?php esc_html_e( 'Vietnamese', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'hu' ) !== false ) { echo 'selected'; } ?> value="hu"><?php esc_html_e( 'Hungarian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ht' ) !== false ) { echo 'selected'; } ?> value="ht"><?php esc_html_e( 'Haitian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'nl' ) !== false ) { echo 'selected'; } ?> value="nl"><?php esc_html_e( 'Dutch', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'el' ) !== false ) { echo 'selected'; } ?> value="el"><?php esc_html_e( 'Greek', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ka' ) !== false ) { echo 'selected'; } ?> value="ka"><?php esc_html_e( 'Georgian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'da' ) !== false ) { echo 'selected'; } ?> value="da"><?php esc_html_e( 'Danish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'he' ) !== false ) { echo 'selected'; } ?> value="he"><?php esc_html_e( 'Hebrew', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'id' ) !== false ) { echo 'selected'; } ?> value="id"><?php esc_html_e( 'Indonesian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ga' ) !== false ) { echo 'selected'; } ?> value="ga"><?php esc_html_e( 'Irish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'it' ) !== false ) { echo 'selected'; } ?> value="it"><?php esc_html_e( 'Italian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'is' ) !== false ) { echo 'selected'; } ?> value="is"><?php esc_html_e( 'Icelandic', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'kk' ) !== false ) { echo 'selected'; } ?> value="kk"><?php esc_html_e( 'Kazakh', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ca' ) !== false ) { echo 'selected'; } ?> value="ca"><?php esc_html_e( 'Catalan', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ky' ) !== false ) { echo 'selected'; } ?> value="ky"><?php esc_html_e( 'Kyrgyz', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ko' ) !== false ) { echo 'selected'; } ?> value="ko"><?php esc_html_e( 'Korean', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'lv' ) !== false ) { echo 'selected'; } ?> value="lv"><?php esc_html_e( 'Latvian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'lt' ) !== false ) { echo 'selected'; } ?> value="lt"><?php esc_html_e( 'Lithuanian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'mg' ) !== false ) { echo 'selected'; } ?> value="mg"><?php esc_html_e( 'Malagasy', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ms' ) !== false ) { echo 'selected'; } ?> value="ms"><?php esc_html_e( 'Malay', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'mt' ) !== false ) { echo 'selected'; } ?> value="mt"><?php esc_html_e( 'Maltese', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'mk' ) !== false ) { echo 'selected'; } ?> value="mk"><?php esc_html_e( 'Macedonian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'mn' ) !== false ) { echo 'selected'; } ?> value="mn"><?php esc_html_e( 'Mongolian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'no' ) !== false ) { echo 'selected'; } ?> value="no"><?php esc_html_e( 'Norwegian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'fa' ) !== false ) { echo 'selected'; } ?> value="fa"><?php esc_html_e( 'Persian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'pl' ) !== false ) { echo 'selected'; } ?> value="pl"><?php esc_html_e( 'Polish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'pt' ) !== false ) { echo 'selected'; } ?> value="pt"><?php esc_html_e( 'Portuguese', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ro' ) !== false ) { echo 'selected'; } ?> value="ro"><?php esc_html_e( 'Romanian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sr' ) !== false ) { echo 'selected'; } ?> value="sr"><?php esc_html_e( 'Serbian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sk' ) !== false ) { echo 'selected'; } ?> value="sk"><?php esc_html_e( 'Slovak', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sl' ) !== false ) { echo 'selected'; } ?> value="sl"><?php esc_html_e( 'Slovenian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sw' ) !== false ) { echo 'selected'; } ?> value="sw"><?php esc_html_e( 'Swahili', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'tg' ) !== false ) { echo 'selected'; } ?> value="tg"><?php esc_html_e( 'Tajik', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'th' ) !== false ) { echo 'selected'; } ?> value="th"><?php esc_html_e( 'Thai', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'tr' ) !== false ) { echo 'selected'; } ?> value="tr"><?php esc_html_e( 'Turkish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'uz' ) !== false ) { echo 'selected'; } ?> value="uz"><?php esc_html_e( 'Uzbek', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'uk' ) !== false ) { echo 'selected'; } ?> value="uk"><?php esc_html_e( 'Ukrainian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'fi' ) !== false ) { echo 'selected'; } ?> value="fi"><?php esc_html_e( 'Finnish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'hr' ) !== false ) { echo 'selected'; } ?> value="hr"><?php esc_html_e( 'Croatian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'cs' ) !== false ) { echo 'selected'; } ?> value="cs"><?php esc_html_e( 'Czech', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sv' ) !== false ) { echo 'selected'; } ?> value="sv"><?php esc_html_e( 'Swedish', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'et' ) !== false ) { echo 'selected'; } ?> value="et"><?php esc_html_e( 'Estonian', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ja' ) !== false ) { echo 'selected'; } ?> value="ja"><?php esc_html_e( 'Japanese', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'hi' ) !== false ) { echo 'selected'; } ?> value="hi"><?php esc_html_e( 'Hindi', 'weglot' ); ?></option> <option <?php if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ur' ) !== false ) { echo 'selected'; } ?> value="ur"><?php esc_html_e( 'Urdu', 'weglot' ); ?></option>
141
- <option
142
- <?php
143
- if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'bn' ) !== false ) {
144
- echo 'selected'; }
145
- ?>
146
- value="bn"><?php esc_html_e( 'Bengali', 'weglot' ); ?></option>
147
- <option
148
- <?php
149
- if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'fj' ) !== false ) {
150
- echo 'selected'; }
151
- ?>
152
- value="fj"><?php esc_html_e( 'Fijian', 'weglot' ); ?></option>
153
- <option
154
- <?php
155
- if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'sm' ) !== false ) {
156
- echo 'selected'; }
157
- ?>
158
- value="sm"><?php esc_html_e( 'Samoan', 'weglot' ); ?></option>
159
- <option
160
- <?php
161
- if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'ty' ) !== false ) {
162
- echo 'selected'; }
163
- ?>
164
- value="ty"><?php esc_html_e( 'Tahitian', 'weglot' ); ?></option>
165
- <option
166
- <?php
167
- if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'to' ) !== false ) {
168
- echo 'selected'; }
169
- ?>
170
- value="to"><?php esc_html_e( 'Tongan', 'weglot' ); ?></option>
171
- <option
172
- <?php
173
- if ( strpos( esc_attr( get_option( 'destination_l' ) ) , 'cy' ) !== false ) {
174
- echo 'selected'; }
175
- ?>
176
- value="cy"><?php esc_html_e( 'Welsh', 'weglot' ); ?></option>
177
- </select>
178
- </div>
179
- <input id="destination_input_hidden" type="text" class="wg-input-text" name="destination_l" value="<?php echo esc_attr( get_option( 'destination_l' ) ); ?>" placeholder="en,es" required style="display:none;" />
180
- <?php
181
- if ( $this->userInfo['plan'] <= 0 ) { ?>
182
- <p class="wg-fsubtext"><?php echo sprintf( esc_html__( 'On the free plan, you can only choose one language and a maximum of 2000 words. If you want to use more than 1 language and 2000 words, please %1$supgrade your plan%2$s.', 'weglot' ), '<a target="_blank" href="https://weglot.com/change-plan">', '</a>' ); ?></p><?php } ?> <?php if ( $this->userInfo['plan'] >= 18 && $this->userInfo['plan'] <= 19 ) { ?> <p class="wg-fsubtext"><?php echo sprintf( esc_html__( 'On the Starter plan, you can only choose one language. If you want to use more than 1 language, please %1$supgrade your plan%2$s.', 'weglot' ), '<a target="_blank" href="https://weglot.com/change-plan">', '</a>' ); ?></p><?php } ?>
183
- </td>
184
- </tr>
185
- </table>
186
- <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;"><?php echo esc_html__( 'Language button appearance', 'weglot' ) . ' ' . esc_html__( '(Optional)', 'weglot' ); ?></h3>
187
- <p class="preview-text"><?php esc_html_e( 'Preview:', 'weglot' ); ?></p><div class="wg-widget-preview"></div>
188
- <table class="form-table">
189
- <tr valign="top">
190
- <th scope="row"><?php esc_html_e( 'Dropdown?', 'weglot' ); ?></th>
191
- <td><input id="id_is_dropdown" type="checkbox" name="is_dropdown"
192
- <?php
193
- if ( esc_attr( get_option( 'is_dropdown' ) ) == 'on' ) {
194
- echo 'checked';} ?>
195
- /><label for="id_is_dropdown" style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e( 'Check if you want the button to be a dropdown box.', 'weglot' ); ?></label></td>
196
- </tr>
197
- <tr valign="top">
198
- <th scope="row"><?php esc_html_e( 'With flags?', 'weglot' ); ?></th>
199
- <td><input id="id_with_flags" type="checkbox" name="with_flags"
200
- <?php
201
- if ( esc_attr( get_option( 'with_flags' ) ) == 'on' ) {
202
- echo 'checked';} ?>
203
- /><label for="id_with_flags" style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e( 'Check if you want flags in the language button.', 'weglot' ); ?></label></td>
204
- </tr>
205
- <tr valign="top">
206
- <th scope="row"><?php esc_html_e( 'Type of flags', 'weglot' ); ?></th>
207
- <td>
208
- <select class="wg-input-select" name="type_flags" style="width :200px;">
209
- <option <?php if ( esc_attr( get_option( 'type_flags' ) ) == '0' ) { echo 'selected'; } ?> value="0"><?php esc_html_e( 'Rectangle mat', 'weglot' ); ?></option>
210
- <option <?php if ( esc_attr( get_option( 'type_flags' ) ) == '1' ) { echo 'selected'; } ?> value="1"><?php esc_html_e( 'Rectangle shiny', 'weglot' ); ?></option>
211
- <option <?php if ( esc_attr( get_option( 'type_flags' ) ) == '2' ) { echo 'selected'; } ?> value="2"><?php esc_html_e( 'Square', 'weglot' ); ?></option>
212
- <option <?php if ( esc_attr( get_option( 'type_flags' ) ) == '3' ) { echo 'selected'; } ?> value="3"><?php esc_html_e( 'Circle', 'weglot' ); ?></option>
213
- </select>
214
- <div class="flag-style-openclose"><?php esc_html_e( 'Change country flags','weglot' ); ?></div>
215
- <div class="flag-style-wrapper" style="display:none;">
216
- <select class="flag-en-type wg-input-select"> <option value=0><?php esc_html_e( 'Choose English flag:','weglot' ); ?></option> <option value=0><?php esc_html_e( 'United Kingdom (default)','weglot' ); ?></option> <option value=1><?php esc_html_e( 'United States','weglot' ); ?></option> <option value=2><?php esc_html_e( 'Australia','weglot' ); ?></option> <option value=3><?php esc_html_e( 'Canada','weglot' ); ?></option> <option value=4><?php esc_html_e( 'New Zealand','weglot' ); ?></option> <option value=5><?php esc_html_e( 'Jamaica','weglot' ); ?></option> <option value=6><?php esc_html_e( 'Ireland','weglot' ); ?></option>
217
- </select>
218
- <select class="flag-es-type wg-input-select"> <option value=0><?php esc_html_e( 'Choose Spanish flag:','weglot' ); ?></option> <option value=0><?php esc_html_e( 'Spain (default)','weglot' ); ?></option> <option value=1><?php esc_html_e( 'Mexico','weglot' ); ?></option> <option value=2><?php esc_html_e( 'Argentina','weglot' ); ?></option> <option value=3><?php esc_html_e( 'Colombia','weglot' ); ?></option> <option value=4><?php esc_html_e( 'Peru','weglot' ); ?></option> <option value=5><?php esc_html_e( 'Bolivia','weglot' ); ?></option> <option value=6 ><?php esc_html_e( 'Uruguay','weglot' ); ?></option> <option value=7 ><?php esc_html_e( 'Venezuela','weglot' ); ?></option> <option value=8 ><?php esc_html_e( 'Chile','weglot' ); ?></option> <option value=9 ><?php esc_html_e( 'Ecuador','weglot' ); ?></option> <option value=10><?php esc_html_e( 'Guatemala','weglot' ); ?></option> <option value=11><?php esc_html_e( 'Cuba','weglot' ); ?></option> <option value=12><?php esc_html_e( 'Dominican Republic','weglot' ); ?></option> <option value=13><?php esc_html_e( 'Honduras','weglot' ); ?></option> <option value=14><?php esc_html_e( 'Paraguay','weglot' ); ?></option> <option value=15><?php esc_html_e( 'El Salvador','weglot' ); ?></option> <option value=16><?php esc_html_e( 'Nicaragua','weglot' ); ?></option> <option value=17><?php esc_html_e( 'Costa Rica','weglot' ); ?></option> <option value=18><?php esc_html_e( 'Puerto Rico','weglot' ); ?></option> <option value=19><?php esc_html_e( 'Panama','weglot' ); ?></option>
219
- </select>
220
- <select class="flag-pt-type wg-input-select"> <option value=0><?php esc_html_e( 'Choose Portuguese flag:','weglot' ); ?></option> <option value=0><?php esc_html_e( 'Brazil (default)','weglot' ); ?></option> <option value=1><?php esc_html_e( 'Portugal','weglot' ); ?></option>
221
- </select>
222
- <select class="flag-fr-type wg-input-select"> <option value=0><?php esc_html_e( 'Choose French flag:','weglot' ); ?></option> <option value=0><?php esc_html_e( 'France (default)','weglot' ); ?></option> <option value=1><?php esc_html_e( 'Belgium','weglot' ); ?></option> <option value=2><?php esc_html_e( 'Canada','weglot' ); ?></option> <option value=3><?php esc_html_e( 'Switzerland','weglot' ); ?></option> <option value=4><?php esc_html_e( 'Luxemburg','weglot' ); ?></option>
223
- </select>
224
- <select class="flag-ar-type wg-input-select"> <option value=0><?php esc_html_e( 'Choose Arabic flag:','weglot' ); ?></option> <option value=0><?php esc_html_e( 'Saudi Arabia (default)','weglot' ); ?></option> <option value=1><?php esc_html_e( 'Algeria','weglot' ); ?></option> <option value=2><?php esc_html_e( 'Egypt','weglot' ); ?></option> <option value=3><?php esc_html_e( 'Iraq','weglot' ); ?></option> <option value=4><?php esc_html_e( 'Jordan','weglot' ); ?></option> <option value=5><?php esc_html_e( 'Kuwait','weglot' ); ?></option> <option value=6><?php esc_html_e( 'Lebanon','weglot' ); ?></option> <option value=7><?php esc_html_e( 'Libya','weglot' ); ?></option> <option value=8><?php esc_html_e( 'Morocco','weglot' ); ?></option> <option value=9><?php esc_html_e( 'Qatar','weglot' ); ?></option> <option value=10><?php esc_html_e( 'Syria','weglot' ); ?></option> <option value=11><?php esc_html_e( 'Tunisia','weglot' ); ?></option> <option value=12><?php esc_html_e( 'United Arab Emirates','weglot' ); ?></option> <option value=13><?php esc_html_e( 'Yemen','weglot' ); ?></option>
225
- </select>
226
- <p><?php esc_html_e( 'If you want to use a different flag, just ask us.','weglot' ); ?></p>
227
- </div>
228
- </td>
229
- </tr>
230
- <tr valign="top">
231
- <th scope="row"><?php esc_html_e( 'With name?', 'weglot' ); ?></th>
232
- <td><input id="id_with_name" type="checkbox" name="with_name"
233
- <?php
234
- if ( esc_attr( get_option( 'with_name' ) ) == 'on' ) {
235
- echo 'checked';} ?>
236
- /><label for="id_with_name" style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e( 'Check if you want to display the name of languages.', 'weglot' ); ?></label></td>
237
- </tr>
238
- <tr valign="top">
239
- <th scope="row"><?php esc_html_e( 'Full name?', 'weglot' ); ?></th>
240
- <td><input id="id_is_fullname" type="checkbox" name="is_fullname"
241
- <?php
242
- if ( esc_attr( get_option( 'is_fullname' ) ) == 'on' ) {
243
- echo 'checked';} ?>
244
- /><label for="id_is_fullname" style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e( 'Check if you want the name of the languge. Don\'t check if you want the language code.', 'weglot' ); ?></label></td>
245
- </tr>
246
- <tr valign="top">
247
- <th scope="row"><?php esc_html_e( 'Override CSS', 'weglot' ); ?><p style="font-weight:normal;margin-top:2px;"><?php esc_html_e( 'Don\'t change it unless you want a specific style for your button.', 'weglot' ); ?></p></th>
248
- <td><textarea class="wg-input-textarea" type="text" rows = 10 cols = 30 name="override_css" placeholder=".country-selector {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
249
  margin-bottom: 20px;
250
  background-color: green!important;
251
  }
252
  .country-selector a {
253
  color: blue!important;
254
- }"><?php echo esc_attr( get_option( 'override_css' ) ); ?></textarea><textarea class="wg-input-textarea" type="text" name="flag_css" style="display:none;" ><?php echo esc_attr( get_option( 'flag_css' ) ); ?></textarea></td>
255
- </tr>
256
- </table>
257
- <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;"><?php echo esc_html__( 'Language button position', 'weglot' ) . ' ' . esc_html__( '(Optional)', 'weglot' ); ?></h3>
258
- <h4 style="font-size:14px;line-height: 1.3;font-weight: 600;"><?php esc_html_e( 'Where will the language button be on my website? By default, bottom right.','weglot' ); ?></h4>
259
- <table class="form-table">
260
- <tr valign="top">
261
- <th scope="row"><?php esc_html_e( 'In menu?', 'weglot' ); ?></th>
262
- <td><input id="id_is_menu" type="checkbox" name="is_menu"
263
- <?php
264
- if ( esc_attr( get_option( 'is_menu' ) ) == 'on' ) {
265
- echo 'checked';} ?>
266
- /><label for="id_is_menu" style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e( 'Check if you want to display the button in the navigation menu.', 'weglot' ); ?></label></td>
267
- </tr>
268
- <tr valign="top">
269
- <th scope="row"><?php esc_html_e( 'As a widget?', 'weglot' ); ?></th>
270
- <td><p style="font-weight: normal;font-style: italic;display: inline-block;"><?php esc_html_e( 'You can place the button in a widget area. Go to Appearance -> Widgets and drag and drop the Weglot Translate widget where you want.', 'weglot' ); ?></p></td>
271
- </tr>
272
- <tr valign="top">
273
- <th scope="row"><?php esc_html_e( 'With a shortcode?', 'weglot' ); ?></th>
274
- <td><p style="font-weight: normal;font-style: italic;display: inline-block;"><?php esc_html_e( 'You can use the Weglot shortcode [weglot_switcher] wherever you want to place the button.', 'weglot' ); ?></p></td>
275
- </tr>
276
- <tr valign="top">
277
- <th scope="row"><?php esc_html_e( 'In the source code?', 'weglot' ); ?></th>
278
- <td><p style="font-weight: normal;font-style: italic;display: inline-block;"><?php esc_html_e( 'You can add the code &lt;div id=&quot;weglot_here&quot;&gt;&lt;/div&gt; wherever you want in the source code of your HTML page. The button will appear at this place.', 'weglot' ); ?></p></td>
279
- </tr>
280
- </table>
281
- <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;">
282
- <?php
283
- echo esc_html__( 'Translation Exclusion', 'weglot' ) . ' ' . esc_html__( '(Optional)', 'weglot' );
284
- ?>
285
- </h3>
286
- <p><?php esc_html_e( 'By default, every page is translated. You can exclude parts of a page or a full page here.', 'weglot' ); ?></p>
287
- <table class="form-table">
288
- <tr valign="top">
289
- <th scope="row"><?php esc_html_e( 'Exclude URL here', 'weglot' ); ?><p style="font-weight:normal;margin-top:2px;"><?php esc_html_e( 'You can write regex.', 'weglot' ); ?><p></th>
290
- <td><textarea class="wg-input-textarea" type="text" rows = 3 cols = 30 name="exclude_url" placeholder=""><?php echo esc_attr( get_option( 'exclude_url' ) ); ?></textarea></td>
291
- </tr>
292
- <tr valign="top">
293
- <th scope="row"><?php esc_html_e( 'Exclude blocks', 'weglot' ); ?><p style="font-weight:normal;margin-top:2px;"><?php esc_html_e( 'Enter CSS selectors, separated by commas.', 'weglot' ); ?><p></th>
294
- <td><textarea class="wg-input-textarea" type="text" rows = 3 cols = 30 name="exclude_blocks" placeholder="#top-menu,footer a,.title-3"><?php echo esc_attr( get_option( 'exclude_blocks' ) ); ?></textarea></td>
295
- </tr>
296
- </table>
297
- <?php if ( $this->userInfo['plan'] > 0 ) { ?>
298
- <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;">
299
- <?php
300
- echo esc_html__( 'Other options', 'weglot' ) . ' ' . esc_html__( '(Optional)', 'weglot' );
301
- ?>
302
- </h3>
303
- <table class="form-table">
304
- <tr valign="top">
305
- <th scope="row"><?php esc_html_e( 'Auto redirect?', 'weglot' ); ?></th>
306
- <td><input id="id_auto_switch" type="checkbox" name="wg_auto_switch"
307
- <?php
308
- if ( esc_attr( get_option( 'wg_auto_switch' ) ) == 'on' ) {
309
- echo 'checked';} ?>
310
- /><label for="id_auto_switch" style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e( 'Check if you want to redirect users based on their browser language.', 'weglot' ); ?></label></td>
311
- </tr>
312
- </table>
313
- <?php } ?>
314
- <?php
315
- if ( $showLTR || $showRTL ) {
316
- $ltrOrRtl = $showLTR ? esc_html__( 'Left to Right languages','weglot' ) : esc_html__( 'Right to Left languages','weglot' );
317
- ?>
318
- <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;">
319
- <?php
320
- echo esc_html__( 'Customize style for ', 'weglot' ) . esc_html__( $ltrOrRtl )
321
- . ' ' . esc_html__( '(Optional)', 'weglot' );
322
- ?>
323
- </h3>
324
- <table class="form-table">
325
- <tr valign="top">
326
- <th scope="row"><?php echo sprintf( esc_html__( 'Write CSS rules to apply on %s page.', 'weglot' ),esc_html__( $ltrOrRtl ) ); ?><p style="font-weight:normal;margin-top:2px;"><p></th>
327
- <td><textarea class="wg-input-textarea" type="text" rows = 5 cols = 30 name="rtl_ltr_style" placeholder="body {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
328
  text-align: right;
329
- }"><?php echo esc_attr( get_option( 'rtl_ltr_style' ) ); ?></textarea></td>
330
- </tr>
331
- </table>
332
- <?php } ?>
333
- <?php submit_button(); ?>
334
- </form>
335
- <?php
336
- if ( esc_attr( get_option( 'show_box' ) ) == 'off' ) { ?>
337
- <div class="wginfobox">
338
- <h3><?php esc_html_e( 'Where are my translations?','weglot' ); ?></h3>
339
- <div>
340
- <p><?php esc_html_e( 'You can find all your translations in your Weglot account:','weglot' ); ?></p>
341
- <a href="<?php esc_html_e( 'https://weglot.com/dashboard','weglot' ); ?>" target="_blank" class="wg-editbtn"><?php esc_html_e( 'Edit my translations','weglot' ); ?></a>
342
- </div>
343
- </div><?php } ?>
344
- <br>
345
- <a target="_blank" href="http://wordpress.org/support/view/plugin-reviews/weglot?rate=5#postform">
346
- <?php esc_html_e( 'Love Weglot? Give us 5 stars on WordPress.org :)', 'weglot' ); ?>
347
- </a>
348
- <br><br>
349
- <i class="fa fa-question-circle" aria-hidden="true" style="font-size : 17px;"></i><p style="display:inline-block; margin-left:5px;"><?php echo sprintf( esc_html__( 'If you need any help, you can contact us via our live chat at %1$sweglot.com%2$s or email us at support@weglot.com.', 'weglot' ), '<a href="https://weglot.com/" target="_blank">','</a>' ).'<br>'.sprintf( esc_html__( 'You can also check our %1$sFAQ%2$s','weglot' ), '<a href="http://support.weglot.com/" target="_blank">','</a>'); ?></p>
 
 
 
 
 
350
  <br><br><br>
351
- <h2></h2>
352
  </div>
1
  <?php
2
+ $showRTL = false;
3
+ $showLTR = false;
4
+ if (WGUtils::isLanguageRTL($this->original_l)) { // Right lo left language
5
+ if (WGUtils::hasLanguageLTR(explode(',', $this->destination_l))) {
6
+ $showLTR = true;
7
+ }
8
  } else { // Left to right language
9
+ if (WGUtils::hasLanguageRTL(explode(',', $this->destination_l))) {
10
+ $showRTL = true;
11
+ }
12
  } ?>
13
  <div class="wrap">
14
+ <?php if ($this->allowed == 0) { ?>
15
+ <div class="wg-status-box">
16
+ <h3><?php echo sprintf(esc_html__('Weglot Translate service is not active because you have reached the end of the trial period.', 'weglot'), esc_html__($this->userInfo['limit'])); ?></h3>
17
+ <p><?php echo sprintf(esc_html__('To reactivate the service, please %1$supgrade your plan%2$s.', 'weglot'), '<a target="_blank" href="https://weglot.com/change-plan">', '</a>'); ?></p>
18
+ </div>
19
+ <?php } ?>
20
 
21
+ <?php if (esc_attr(get_option('show_box')) == 'on') { ?>
22
+ <div class="wgbox-blur">
23
+ <div class="wgbox">
24
+ <div class="wgclose-btn"><?php esc_html_e('Close', 'weglot'); ?></div>
25
+ <h3 class="wgbox-title"><?php esc_html_e('Well done! Your website is now multilingual.', 'weglot'); ?></h3>
26
+ <p class="wgbox-text"><?php esc_html_e('Go on your website, there is a language switcher. Try it :)', 'weglot'); ?></p>
27
+ <a class="wgbox-button button button-primary" href="
28
  <?php
29
+ echo esc_html__($this->home_dir);
30
+ ?>
 
31
  /" target="_blank">
32
+ <?php
33
+ esc_html_e('Go on my front page.', 'weglot');
34
+ ?>
35
+ </a>
36
+ <p class="wgbox-subtext"><?php esc_html_e('Next step, edit your translations directly in your Weglot account.', 'weglot'); ?></p>
37
+ </div>
38
+ </div>
39
+ <?php
40
+ list($wgfirstlang) = explode(',', get_option('destination_l'));
41
+ if (strlen($wgfirstlang) == 2) {
42
+ ?>
43
+ <iframe style="visibility:hidden;" src="
44
  <?php
45
+ echo esc_html__($this->home_dir);
46
+ ?>
47
+ /<?php echo esc_html__($wgfirstlang); ?>/" width=1
48
+ height=1
49
+ ></iframe>
50
+ <?php } ?>
51
+ <?php update_option('show_box', 'off');
52
+ } ?>
53
+ <form class="wg-widget-option-form" method="post" action="options.php">
54
+ <?php settings_fields('my-plugin-settings-group'); ?>
55
+ <?php do_settings_sections('my-plugin-settings-group'); ?>
56
+ <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;"><?php esc_html_e('Main configuration', 'weglot'); ?></h3>
57
+ <table class="form-table">
58
+ <tr valign="top">
59
+ <th scope="row"><?php esc_html_e('API Key', 'weglot'); ?><p
60
+ style="font-weight:normal;margin-top:2px;"><?php echo sprintf(esc_html__('Log in to %1$sWeglot%2$s to get your API key.', 'weglot'), '<a target="_blank" href="https://weglot.com/register-wordpress">', '</a>'); ?></p>
61
+ </th>
62
+ <td><input type="text" class="wg-input-text" name="project_key"
63
+ value="<?php echo esc_attr(get_option('project_key')); ?>"
64
+ placeholder="wg_XXXXXXXX" required/></td>
65
+ </tr>
66
+ <tr valign="top">
67
+ <th scope="row"><?php esc_html_e('Original Language', 'weglot'); ?><p
68
+ style="font-weight:normal;margin-top:2px;"><?php esc_html_e('What is the original (current) language of your website?', 'weglot'); ?></p>
69
+ </th>
70
+ <td>
71
+ <select class="wg-input-select" name="original_l"
72
+ style="width :200px;">
73
+ <option <?php if (esc_attr(get_option('original_l')) == 'af') {
74
+ echo 'selected';
75
+ } ?> value="af"><?php esc_html_e('Afrikaans', 'weglot'); ?></option>
76
+ <option <?php if (esc_attr(get_option('original_l')) == 'sq') {
77
+ echo 'selected';
78
+ } ?> value="sq"><?php esc_html_e('Albanian', 'weglot'); ?></option>
79
+ <option <?php if (esc_attr(get_option('original_l')) == 'am') {
80
+ echo 'selected';
81
+ } ?> value="am"><?php esc_html_e('Amharic', 'weglot'); ?></option>
82
+ <option <?php if (esc_attr(get_option('original_l')) == 'ar') {
83
+ echo 'selected';
84
+ } ?> value="ar"><?php esc_html_e('Arabic', 'weglot'); ?></option>
85
+ <option <?php if (esc_attr(get_option('original_l')) == 'hy') {
86
+ echo 'selected';
87
+ } ?> value="hy"><?php esc_html_e('Armenian', 'weglot'); ?></option>
88
+ <option <?php if (esc_attr(get_option('original_l')) == 'az') {
89
+ echo 'selected';
90
+ } ?> value="az"><?php esc_html_e('Azerbaijani', 'weglot'); ?></option>
91
+ <option <?php if (esc_attr(get_option('original_l')) == 'ba') {
92
+ echo 'selected';
93
+ } ?> value="ba"><?php esc_html_e('Bashkir', 'weglot'); ?></option>
94
+ <option <?php if (esc_attr(get_option('original_l')) == 'eu') {
95
+ echo 'selected';
96
+ } ?> value="eu"><?php esc_html_e('Basque', 'weglot'); ?></option>
97
+ <option <?php if (esc_attr(get_option('original_l')) == 'be') {
98
+ echo 'selected';
99
+ } ?> value="be"><?php esc_html_e('Belarusian', 'weglot'); ?></option>
100
+ <option <?php if (esc_attr(get_option('original_l')) == 'bn') {
101
+ echo 'selected';
102
+ } ?> value="bn"><?php esc_html_e('Bengali', 'weglot'); ?></option>
103
+ <option <?php if (esc_attr(get_option('original_l')) == 'bs') {
104
+ echo 'selected';
105
+ } ?> value="bs"><?php esc_html_e('Bosnian', 'weglot'); ?></option>
106
+ <option <?php if (esc_attr(get_option('original_l')) == 'bg') {
107
+ echo 'selected';
108
+ } ?> value="bg"><?php esc_html_e('Bulgarian', 'weglot'); ?></option>
109
+ <option <?php if (esc_attr(get_option('original_l')) == 'my') {
110
+ echo 'selected';
111
+ } ?> value="my"><?php esc_html_e('Burmese', 'weglot'); ?></option>
112
+ <option <?php if (esc_attr(get_option('original_l')) == 'ca') {
113
+ echo 'selected';
114
+ } ?> value="ca"><?php esc_html_e('Catalan', 'weglot'); ?></option>
115
+ <option <?php if (esc_attr(get_option('original_l')) == 'ny') {
116
+ echo 'selected';
117
+ } ?> value="ny"><?php esc_html_e('Chichewa', 'weglot'); ?></option>
118
+ <option <?php if (esc_attr(get_option('original_l')) == 'zh') {
119
+ echo 'selected';
120
+ } ?> value="zh"><?php esc_html_e('Simplified Chinese', 'weglot'); ?></option>
121
+ <option <?php if (esc_attr(get_option('original_l')) == 'tw') {
122
+ echo 'selected';
123
+ } ?> value="tw"><?php esc_html_e('Traditional Chinese', 'weglot'); ?></option>
124
+ <option <?php if (esc_attr(get_option('original_l')) == 'co') {
125
+ echo 'selected';
126
+ } ?> value="co"><?php esc_html_e('Corsican', 'weglot'); ?></option>
127
+ <option <?php if (esc_attr(get_option('original_l')) == 'hr') {
128
+ echo 'selected';
129
+ } ?> value="hr"><?php esc_html_e('Croatian', 'weglot'); ?></option>
130
+ <option <?php if (esc_attr(get_option('original_l')) == 'cs') {
131
+ echo 'selected';
132
+ } ?> value="cs"><?php esc_html_e('Czech', 'weglot'); ?></option>
133
+ <option <?php if (esc_attr(get_option('original_l')) == 'da') {
134
+ echo 'selected';
135
+ } ?> value="da"><?php esc_html_e('Danish', 'weglot'); ?></option>
136
+ <option <?php if (esc_attr(get_option('original_l')) == 'nl') {
137
+ echo 'selected';
138
+ } ?> value="nl"><?php esc_html_e('Dutch', 'weglot'); ?></option>
139
+ <option <?php if (esc_attr(get_option('original_l')) == 'en' || !get_option('original_l')) {
140
+ echo 'selected';
141
+ } ?> value="en"><?php esc_html_e('English', 'weglot'); ?></option>
142
+ <option <?php if (esc_attr(get_option('original_l')) == 'eo') {
143
+ echo 'selected';
144
+ } ?> value="eo"><?php esc_html_e('Esperanto', 'weglot'); ?></option>
145
+ <option <?php if (esc_attr(get_option('original_l')) == 'et') {
146
+ echo 'selected';
147
+ } ?> value="et"><?php esc_html_e('Estonian', 'weglot'); ?></option>
148
+ <option <?php if (esc_attr(get_option('original_l')) == 'fj') {
149
+ echo 'selected';
150
+ } ?> value="fj"><?php esc_html_e('Fijian', 'weglot'); ?></option>
151
+ <option <?php if (esc_attr(get_option('original_l')) == 'fi') {
152
+ echo 'selected';
153
+ } ?> value="fi"><?php esc_html_e('Finnish', 'weglot'); ?></option>
154
+ <option <?php if (esc_attr(get_option('original_l')) == 'fr') {
155
+ echo 'selected';
156
+ } ?> value="fr"><?php esc_html_e('French', 'weglot'); ?></option>
157
+ <option <?php if (esc_attr(get_option('original_l')) == 'gl') {
158
+ echo 'selected';
159
+ } ?> value="gl"><?php esc_html_e('Galician', 'weglot'); ?></option>
160
+ <option <?php if (esc_attr(get_option('original_l')) == 'ka') {
161
+ echo 'selected';
162
+ } ?> value="ka"><?php esc_html_e('Georgian', 'weglot'); ?></option>
163
+ <option <?php if (esc_attr(get_option('original_l')) == 'de') {
164
+ echo 'selected';
165
+ } ?> value="de"><?php esc_html_e('German', 'weglot'); ?></option>
166
+ <option <?php if (esc_attr(get_option('original_l')) == 'el') {
167
+ echo 'selected';
168
+ } ?> value="el"><?php esc_html_e('Greek', 'weglot'); ?></option>
169
+ <option <?php if (esc_attr(get_option('original_l')) == 'gu') {
170
+ echo 'selected';
171
+ } ?> value="gu"><?php esc_html_e('Gujarati', 'weglot'); ?></option>
172
+ <option <?php if (esc_attr(get_option('original_l')) == 'ht') {
173
+ echo 'selected';
174
+ } ?> value="ht"><?php esc_html_e('Haitian', 'weglot'); ?></option>
175
+ <option <?php if (esc_attr(get_option('original_l')) == 'ha') {
176
+ echo 'selected';
177
+ } ?> value="ha"><?php esc_html_e('Hausa', 'weglot'); ?></option>
178
+ <option <?php if (esc_attr(get_option('original_l')) == 'he') {
179
+ echo 'selected';
180
+ } ?> value="he"><?php esc_html_e('Hebrew', 'weglot'); ?></option>
181
+ <option <?php if (esc_attr(get_option('original_l')) == 'hi') {
182
+ echo 'selected';
183
+ } ?> value="hi"><?php esc_html_e('Hindi', 'weglot'); ?></option>
184
+ <option <?php if (esc_attr(get_option('original_l')) == 'hu') {
185
+ echo 'selected';
186
+ } ?> value="hu"><?php esc_html_e('Hungarian', 'weglot'); ?></option>
187
+ <option <?php if (esc_attr(get_option('original_l')) == 'is') {
188
+ echo 'selected';
189
+ } ?> value="is"><?php esc_html_e('Icelandic', 'weglot'); ?></option>
190
+ <option <?php if (esc_attr(get_option('original_l')) == 'ig') {
191
+ echo 'selected';
192
+ } ?> value="ig"><?php esc_html_e('Igbo', 'weglot'); ?></option>
193
+ <option <?php if (esc_attr(get_option('original_l')) == 'id') {
194
+ echo 'selected';
195
+ } ?> value="id"><?php esc_html_e('Indonesian', 'weglot'); ?></option>
196
+ <option <?php if (esc_attr(get_option('original_l')) == 'ga') {
197
+ echo 'selected';
198
+ } ?> value="ga"><?php esc_html_e('Irish', 'weglot'); ?></option>
199
+ <option <?php if (esc_attr(get_option('original_l')) == 'it') {
200
+ echo 'selected';
201
+ } ?> value="it"><?php esc_html_e('Italian', 'weglot'); ?></option>
202
+ <option <?php if (esc_attr(get_option('original_l')) == 'ja') {
203
+ echo 'selected';
204
+ } ?> value="ja"><?php esc_html_e('Japanese', 'weglot'); ?></option>
205
+ <option <?php if (esc_attr(get_option('original_l')) == 'jv') {
206
+ echo 'selected';
207
+ } ?> value="jv"><?php esc_html_e('Javanese', 'weglot'); ?></option>
208
+ <option <?php if (esc_attr(get_option('original_l')) == 'kn') {
209
+ echo 'selected';
210
+ } ?> value="kn"><?php esc_html_e('Kannada', 'weglot'); ?></option>
211
+ <option <?php if (esc_attr(get_option('original_l')) == 'kk') {
212
+ echo 'selected';
213
+ } ?> value="kk"><?php esc_html_e('Kazakh', 'weglot'); ?></option>
214
+ <option <?php if (esc_attr(get_option('original_l')) == 'km') {
215
+ echo 'selected';
216
+ } ?> value="km"><?php esc_html_e('Khmer', 'weglot'); ?></option>
217
+ <option <?php if (esc_attr(get_option('original_l')) == 'ko') {
218
+ echo 'selected';
219
+ } ?> value="ko"><?php esc_html_e('Korean', 'weglot'); ?></option>
220
+ <option <?php if (esc_attr(get_option('original_l')) == 'ku') {
221
+ echo 'selected';
222
+ } ?> value="ku"><?php esc_html_e('Kurdish', 'weglot'); ?></option>
223
+ <option <?php if (esc_attr(get_option('original_l')) == 'ky') {
224
+ echo 'selected';
225
+ } ?> value="ky"><?php esc_html_e('Kyrgyz', 'weglot'); ?></option>
226
+ <option <?php if (esc_attr(get_option('original_l')) == 'lo') {
227
+ echo 'selected';
228
+ } ?> value="lo"><?php esc_html_e('Lao', 'weglot'); ?></option>
229
+ <option <?php if (esc_attr(get_option('original_l')) == 'la') {
230
+ echo 'selected';
231
+ } ?> value="la"><?php esc_html_e('Latin', 'weglot'); ?></option>
232
+ <option <?php if (esc_attr(get_option('original_l')) == 'lv') {
233
+ echo 'selected';
234
+ } ?> value="lv"><?php esc_html_e('Latvian', 'weglot'); ?></option>
235
+ <option <?php if (esc_attr(get_option('original_l')) == 'lt') {
236
+ echo 'selected';
237
+ } ?> value="lt"><?php esc_html_e('Lithuanian', 'weglot'); ?></option>
238
+ <option <?php if (esc_attr(get_option('original_l')) == 'lb') {
239
+ echo 'selected';
240
+ } ?> value="lb"><?php esc_html_e('Luxembourgish', 'weglot'); ?></option>
241
+ <option <?php if (esc_attr(get_option('original_l')) == 'mk') {
242
+ echo 'selected';
243
+ } ?> value="mk"><?php esc_html_e('Macedonian', 'weglot'); ?></option>
244
+ <option <?php if (esc_attr(get_option('original_l')) == 'mg') {
245
+ echo 'selected';
246
+ } ?> value="mg"><?php esc_html_e('Malagasy', 'weglot'); ?></option>
247
+ <option <?php if (esc_attr(get_option('original_l')) == 'ms') {
248
+ echo 'selected';
249
+ } ?> value="ms"><?php esc_html_e('Malay', 'weglot'); ?></option>
250
+ <option <?php if (esc_attr(get_option('original_l')) == 'ml') {
251
+ echo 'selected';
252
+ } ?> value="ml"><?php esc_html_e('Malayalam', 'weglot'); ?></option>
253
+ <option <?php if (esc_attr(get_option('original_l')) == 'mt') {
254
+ echo 'selected';
255
+ } ?> value="mt"><?php esc_html_e('Maltese', 'weglot'); ?></option>
256
+ <option <?php if (esc_attr(get_option('original_l')) == 'mi') {
257
+ echo 'selected';
258
+ } ?> value="mi"><?php esc_html_e('Māori', 'weglot'); ?></option>
259
+ <option <?php if (esc_attr(get_option('original_l')) == 'mr') {
260
+ echo 'selected';
261
+ } ?> value="mr"><?php esc_html_e('Marathi', 'weglot'); ?></option>
262
+ <option <?php if (esc_attr(get_option('original_l')) == 'mn') {
263
+ echo 'selected';
264
+ } ?> value="mn"><?php esc_html_e('Mongolian', 'weglot'); ?></option>
265
+ <option <?php if (esc_attr(get_option('original_l')) == 'ne') {
266
+ echo 'selected';
267
+ } ?> value="ne"><?php esc_html_e('Nepali', 'weglot'); ?></option>
268
+ <option <?php if (esc_attr(get_option('original_l')) == 'no') {
269
+ echo 'selected';
270
+ } ?> value="no"><?php esc_html_e('Norwegian', 'weglot'); ?></option>
271
+ <option <?php if (esc_attr(get_option('original_l')) == 'ps') {
272
+ echo 'selected';
273
+ } ?> value="ps"><?php esc_html_e('Pashto', 'weglot'); ?></option>
274
+ <option <?php if (esc_attr(get_option('original_l')) == 'fa') {
275
+ echo 'selected';
276
+ } ?> value="fa"><?php esc_html_e('Persian', 'weglot'); ?></option>
277
+ <option <?php if (esc_attr(get_option('original_l')) == 'pl') {
278
+ echo 'selected';
279
+ } ?> value="pl"><?php esc_html_e('Polish', 'weglot'); ?></option>
280
+ <option <?php if (esc_attr(get_option('original_l')) == 'pt') {
281
+ echo 'selected';
282
+ } ?> value="pt"><?php esc_html_e('Portuguese', 'weglot'); ?></option>
283
+ <option <?php if (esc_attr(get_option('original_l')) == 'pa') {
284
+ echo 'selected';
285
+ } ?> value="pa"><?php esc_html_e('Punjabi', 'weglot'); ?></option>
286
+ <option <?php if (esc_attr(get_option('original_l')) == 'ro') {
287
+ echo 'selected';
288
+ } ?> value="ro"><?php esc_html_e('Romanian', 'weglot'); ?></option>
289
+ <option <?php if (esc_attr(get_option('original_l')) == 'ru') {
290
+ echo 'selected';
291
+ } ?> value="ru"><?php esc_html_e('Russian', 'weglot'); ?></option>
292
+ <option <?php if (esc_attr(get_option('original_l')) == 'sm') {
293
+ echo 'selected';
294
+ } ?> value="sm"><?php esc_html_e('Samoan', 'weglot'); ?></option>
295
+ <option <?php if (esc_attr(get_option('original_l')) == 'gd') {
296
+ echo 'selected';
297
+ } ?> value="gd"><?php esc_html_e('Scottish Gaelic', 'weglot'); ?></option>
298
+ <option <?php if (esc_attr(get_option('original_l')) == 'sr') {
299
+ echo 'selected';
300
+ } ?> value="sr"><?php esc_html_e('Serbian', 'weglot'); ?></option>
301
+ <option <?php if (esc_attr(get_option('original_l')) == 'sn') {
302
+ echo 'selected';
303
+ } ?> value="sn"><?php esc_html_e('Shona', 'weglot'); ?></option>
304
+ <option <?php if (esc_attr(get_option('original_l')) == 'sd') {
305
+ echo 'selected';
306
+ } ?> value="sd"><?php esc_html_e('Sindhi', 'weglot'); ?></option>
307
+ <option <?php if (esc_attr(get_option('original_l')) == 'si') {
308
+ echo 'selected';
309
+ } ?> value="si"><?php esc_html_e('Sinhalese', 'weglot'); ?></option>
310
+ <option <?php if (esc_attr(get_option('original_l')) == 'sk') {
311
+ echo 'selected';
312
+ } ?> value="sk"><?php esc_html_e('Slovak', 'weglot'); ?></option>
313
+ <option <?php if (esc_attr(get_option('original_l')) == 'sl') {
314
+ echo 'selected';
315
+ } ?> value="sl"><?php esc_html_e('Slovenian', 'weglot'); ?></option>
316
+ <option <?php if (esc_attr(get_option('original_l')) == 'so') {
317
+ echo 'selected';
318
+ } ?> value="so"><?php esc_html_e('Somali', 'weglot'); ?></option>
319
+ <option <?php if (esc_attr(get_option('original_l')) == 'st') {
320
+ echo 'selected';
321
+ } ?> value="st"><?php esc_html_e('Southern Sotho', 'weglot'); ?></option>
322
+ <option <?php if (esc_attr(get_option('original_l')) == 'es') {
323
+ echo 'selected';
324
+ } ?> value="es"><?php esc_html_e('Spanish', 'weglot'); ?></option>
325
+ <option <?php if (esc_attr(get_option('original_l')) == 'su') {
326
+ echo 'selected';
327
+ } ?> value="su"><?php esc_html_e('Sundanese', 'weglot'); ?></option>
328
+ <option <?php if (esc_attr(get_option('original_l')) == 'sw') {
329
+ echo 'selected';
330
+ } ?> value="sw"><?php esc_html_e('Swahili', 'weglot'); ?></option>
331
+ <option <?php if (esc_attr(get_option('original_l')) == 'sv') {
332
+ echo 'selected';
333
+ } ?> value="sv"><?php esc_html_e('Swedish', 'weglot'); ?></option>
334
+ <option <?php if (esc_attr(get_option('original_l')) == 'tl') {
335
+ echo 'selected';
336
+ } ?> value="tl"><?php esc_html_e('Tagalog', 'weglot'); ?></option>
337
+ <option <?php if (esc_attr(get_option('original_l')) == 'ty') {
338
+ echo 'selected';
339
+ } ?> value="ty"><?php esc_html_e('Tahitian', 'weglot'); ?></option>
340
+ <option <?php if (esc_attr(get_option('original_l')) == 'tg') {
341
+ echo 'selected';
342
+ } ?> value="tg"><?php esc_html_e('Tajik', 'weglot'); ?></option>
343
+ <option <?php if (esc_attr(get_option('original_l')) == 'ta') {
344
+ echo 'selected';
345
+ } ?> value="ta"><?php esc_html_e('Tamil', 'weglot'); ?></option>
346
+ <option <?php if (esc_attr(get_option('original_l')) == 'tt') {
347
+ echo 'selected';
348
+ } ?> value="tt"><?php esc_html_e('Tatar', 'weglot'); ?></option>
349
+ <option <?php if (esc_attr(get_option('original_l')) == 'te') {
350
+ echo 'selected';
351
+ } ?> value="te"><?php esc_html_e('Telugu', 'weglot'); ?></option>
352
+ <option <?php if (esc_attr(get_option('original_l')) == 'th') {
353
+ echo 'selected';
354
+ } ?> value="th"><?php esc_html_e('Thai', 'weglot'); ?></option>
355
+ <option <?php if (esc_attr(get_option('original_l')) == 'to') {
356
+ echo 'selected';
357
+ } ?> value="to"><?php esc_html_e('Tongan', 'weglot'); ?></option>
358
+ <option <?php if (esc_attr(get_option('original_l')) == 'tr') {
359
+ echo 'selected';
360
+ } ?> value="tr"><?php esc_html_e('Turkish', 'weglot'); ?></option>
361
+ <option <?php if (esc_attr(get_option('original_l')) == 'uk') {
362
+ echo 'selected';
363
+ } ?> value="uk"><?php esc_html_e('Ukrainian', 'weglot'); ?></option>
364
+ <option <?php if (esc_attr(get_option('original_l')) == 'ur') {
365
+ echo 'selected';
366
+ } ?> value="ur"><?php esc_html_e('Urdu', 'weglot'); ?></option>
367
+ <option <?php if (esc_attr(get_option('original_l')) == 'uz') {
368
+ echo 'selected';
369
+ } ?> value="uz"><?php esc_html_e('Uzbek', 'weglot'); ?></option>
370
+ <option <?php if (esc_attr(get_option('original_l')) == 'vi') {
371
+ echo 'selected';
372
+ } ?> value="vi"><?php esc_html_e('Vietnamese', 'weglot'); ?></option>
373
+ <option <?php if (esc_attr(get_option('original_l')) == 'cy') {
374
+ echo 'selected';
375
+ } ?> value="cy"><?php esc_html_e('Welsh', 'weglot'); ?></option>
376
+ <option <?php if (esc_attr(get_option('original_l')) == 'fy') {
377
+ echo 'selected';
378
+ } ?> value="fy"><?php esc_html_e('Western Frisian', 'weglot'); ?></option>
379
+ <option <?php if (esc_attr(get_option('original_l')) == 'xh') {
380
+ echo 'selected';
381
+ } ?> value="xh"><?php esc_html_e('Xhosa', 'weglot'); ?></option>
382
+ <option <?php if (esc_attr(get_option('original_l')) == 'yi') {
383
+ echo 'selected';
384
+ } ?> value="yi"><?php esc_html_e('Yiddish', 'weglot'); ?></option>
385
+ <option <?php if (esc_attr(get_option('original_l')) == 'yo') {
386
+ echo 'selected';
387
+ } ?> value="yo"><?php esc_html_e('Yoruba', 'weglot'); ?></option>
388
+ <option <?php if (esc_attr(get_option('original_l')) == 'zu') {
389
+ echo 'selected';
390
+ } ?> value="zu"><?php esc_html_e('Zulu', 'weglot'); ?></option>
391
+ </select>
392
+ </td>
393
+ </tr>
394
+ <tr valign="top">
395
+ <th scope="row"><?php esc_html_e('Destination Languages', 'weglot'); ?>
396
+ <p style="font-weight:normal;margin-top:2px;"><?php echo sprintf(esc_html__('Choose languages you want to translate into. Supported languages can be found %1$shere%2$s.', 'weglot'), '<a target="_blank" href="https://weglot.com/translation-api#languages_code">', '</a>'); ?></p>
397
+ </th>
398
+ <td>
399
+ <div style="display:inline-block;width:300px; margin-top: 35px;">
400
+ <select id="select-lto" multiple class="demo-default"
401
+ style=""
402
+ placeholder="French, German, Italian, Portuguese, …"
403
+ name="destination_l">
404
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'af') !== false) {
405
+ echo 'selected';
406
+ } ?> value="af"><?php esc_html_e('Afrikaans', 'weglot'); ?></option>
407
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sq') !== false) {
408
+ echo 'selected';
409
+ } ?> value="sq"><?php esc_html_e('Albanian', 'weglot'); ?></option>
410
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'am') !== false) {
411
+ echo 'selected';
412
+ } ?> value="am"><?php esc_html_e('Amharic', 'weglot'); ?></option>
413
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ar') !== false) {
414
+ echo 'selected';
415
+ } ?> value="ar"><?php esc_html_e('Arabic', 'weglot'); ?></option>
416
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'hy') !== false) {
417
+ echo 'selected';
418
+ } ?> value="hy"><?php esc_html_e('Armenian', 'weglot'); ?></option>
419
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'az') !== false) {
420
+ echo 'selected';
421
+ } ?> value="az"><?php esc_html_e('Azerbaijani', 'weglot'); ?></option>
422
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ba') !== false) {
423
+ echo 'selected';
424
+ } ?> value="ba"><?php esc_html_e('Bashkir', 'weglot'); ?></option>
425
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'eu') !== false) {
426
+ echo 'selected';
427
+ } ?> value="eu"><?php esc_html_e('Basque', 'weglot'); ?></option>
428
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'be') !== false) {
429
+ echo 'selected';
430
+ } ?> value="be"><?php esc_html_e('Belarusian', 'weglot'); ?></option>
431
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'bn') !== false) {
432
+ echo 'selected';
433
+ } ?> value="bn"><?php esc_html_e('Bengali', 'weglot'); ?></option>
434
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'bs') !== false) {
435
+ echo 'selected';
436
+ } ?> value="bs"><?php esc_html_e('Bosnian', 'weglot'); ?></option>
437
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'bg') !== false) {
438
+ echo 'selected';
439
+ } ?> value="bg"><?php esc_html_e('Bulgarian', 'weglot'); ?></option>
440
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'my') !== false) {
441
+ echo 'selected';
442
+ } ?> value="my"><?php esc_html_e('Burmese', 'weglot'); ?></option>
443
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ca') !== false) {
444
+ echo 'selected';
445
+ } ?> value="ca"><?php esc_html_e('Catalan', 'weglot'); ?></option>
446
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ny') !== false) {
447
+ echo 'selected';
448
+ } ?> value="ny"><?php esc_html_e('Chichewa', 'weglot'); ?></option>
449
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'zh') !== false) {
450
+ echo 'selected';
451
+ } ?> value="zh"><?php esc_html_e('Simplified Chinese', 'weglot'); ?></option>
452
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'tw') !== false) {
453
+ echo 'selected';
454
+ } ?> value="tw"><?php esc_html_e('Traditional Chinese', 'weglot'); ?></option>
455
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'co') !== false) {
456
+ echo 'selected';
457
+ } ?> value="co"><?php esc_html_e('Corsican', 'weglot'); ?></option>
458
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'hr') !== false) {
459
+ echo 'selected';
460
+ } ?> value="hr"><?php esc_html_e('Croatian', 'weglot'); ?></option>
461
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'cs') !== false) {
462
+ echo 'selected';
463
+ } ?> value="cs"><?php esc_html_e('Czech', 'weglot'); ?></option>
464
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'da') !== false) {
465
+ echo 'selected';
466
+ } ?> value="da"><?php esc_html_e('Danish', 'weglot'); ?></option>
467
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'nl') !== false) {
468
+ echo 'selected';
469
+ } ?> value="nl"><?php esc_html_e('Dutch', 'weglot'); ?></option>
470
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'en') !== false) {
471
+ echo 'selected';
472
+ } ?> value="en"><?php esc_html_e('English', 'weglot'); ?></option>
473
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'eo') !== false) {
474
+ echo 'selected';
475
+ } ?> value="eo"><?php esc_html_e('Esperanto', 'weglot'); ?></option>
476
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'et') !== false) {
477
+ echo 'selected';
478
+ } ?> value="et"><?php esc_html_e('Estonian', 'weglot'); ?></option>
479
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'fj') !== false) {
480
+ echo 'selected';
481
+ } ?> value="fj"><?php esc_html_e('Fijian', 'weglot'); ?></option>
482
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'fi') !== false) {
483
+ echo 'selected';
484
+ } ?> value="fi"><?php esc_html_e('Finnish', 'weglot'); ?></option>
485
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'fr') !== false) {
486
+ echo 'selected';
487
+ } ?> value="fr"><?php esc_html_e('French', 'weglot'); ?></option>
488
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'gl') !== false) {
489
+ echo 'selected';
490
+ } ?> value="gl"><?php esc_html_e('Galician', 'weglot'); ?></option>
491
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ka') !== false) {
492
+ echo 'selected';
493
+ } ?> value="ka"><?php esc_html_e('Georgian', 'weglot'); ?></option>
494
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'de') !== false) {
495
+ echo 'selected';
496
+ } ?> value="de"><?php esc_html_e('German', 'weglot'); ?></option>
497
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'el') !== false) {
498
+ echo 'selected';
499
+ } ?> value="el"><?php esc_html_e('Greek', 'weglot'); ?></option>
500
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'gu') !== false) {
501
+ echo 'selected';
502
+ } ?> value="gu"><?php esc_html_e('Gujarati', 'weglot'); ?></option>
503
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ht') !== false) {
504
+ echo 'selected';
505
+ } ?> value="ht"><?php esc_html_e('Haitian', 'weglot'); ?></option>
506
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ha') !== false) {
507
+ echo 'selected';
508
+ } ?> value="ha"><?php esc_html_e('Hausa', 'weglot'); ?></option>
509
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'he') !== false) {
510
+ echo 'selected';
511
+ } ?> value="he"><?php esc_html_e('Hebrew', 'weglot'); ?></option>
512
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'hi') !== false) {
513
+ echo 'selected';
514
+ } ?> value="hi"><?php esc_html_e('Hindi', 'weglot'); ?></option>
515
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'hu') !== false) {
516
+ echo 'selected';
517
+ } ?> value="hu"><?php esc_html_e('Hungarian', 'weglot'); ?></option>
518
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'is') !== false) {
519
+ echo 'selected';
520
+ } ?> value="is"><?php esc_html_e('Icelandic', 'weglot'); ?></option>
521
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ig') !== false) {
522
+ echo 'selected';
523
+ } ?> value="ig"><?php esc_html_e('Igbo', 'weglot'); ?></option>
524
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'id') !== false) {
525
+ echo 'selected';
526
+ } ?> value="id"><?php esc_html_e('Indonesian', 'weglot'); ?></option>
527
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ga') !== false) {
528
+ echo 'selected';
529
+ } ?> value="ga"><?php esc_html_e('Irish', 'weglot'); ?></option>
530
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'it') !== false) {
531
+ echo 'selected';
532
+ } ?> value="it"><?php esc_html_e('Italian', 'weglot'); ?></option>
533
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ja') !== false) {
534
+ echo 'selected';
535
+ } ?> value="ja"><?php esc_html_e('Japanese', 'weglot'); ?></option>
536
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'jv') !== false) {
537
+ echo 'selected';
538
+ } ?> value="jv"><?php esc_html_e('Javanese', 'weglot'); ?></option>
539
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'kn') !== false) {
540
+ echo 'selected';
541
+ } ?> value="kn"><?php esc_html_e('Kannada', 'weglot'); ?></option>
542
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'kk') !== false) {
543
+ echo 'selected';
544
+ } ?> value="kk"><?php esc_html_e('Kazakh', 'weglot'); ?></option>
545
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'km') !== false) {
546
+ echo 'selected';
547
+ } ?> value="km"><?php esc_html_e('Khmer', 'weglot'); ?></option>
548
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ko') !== false) {
549
+ echo 'selected';
550
+ } ?> value="ko"><?php esc_html_e('Korean', 'weglot'); ?></option>
551
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ku') !== false) {
552
+ echo 'selected';
553
+ } ?> value="ku"><?php esc_html_e('Kurdish', 'weglot'); ?></option>
554
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ky') !== false) {
555
+ echo 'selected';
556
+ } ?> value="ky"><?php esc_html_e('Kyrgyz', 'weglot'); ?></option>
557
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'lo') !== false) {
558
+ echo 'selected';
559
+ } ?> value="lo"><?php esc_html_e('Lao', 'weglot'); ?></option>
560
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'la') !== false) {
561
+ echo 'selected';
562
+ } ?> value="la"><?php esc_html_e('Latin', 'weglot'); ?></option>
563
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'lv') !== false) {
564
+ echo 'selected';
565
+ } ?> value="lv"><?php esc_html_e('Latvian', 'weglot'); ?></option>
566
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'lt') !== false) {
567
+ echo 'selected';
568
+ } ?> value="lt"><?php esc_html_e('Lithuanian', 'weglot'); ?></option>
569
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'lb') !== false) {
570
+ echo 'selected';
571
+ } ?> value="lb"><?php esc_html_e('Luxembourgish', 'weglot'); ?></option>
572
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'mk') !== false) {
573
+ echo 'selected';
574
+ } ?> value="mk"><?php esc_html_e('Macedonian', 'weglot'); ?></option>
575
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'mg') !== false) {
576
+ echo 'selected';
577
+ } ?> value="mg"><?php esc_html_e('Malagasy', 'weglot'); ?></option>
578
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ms') !== false) {
579
+ echo 'selected';
580
+ } ?> value="ms"><?php esc_html_e('Malay', 'weglot'); ?></option>
581
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ml') !== false) {
582
+ echo 'selected';
583
+ } ?> value="ml"><?php esc_html_e('Malayalam', 'weglot'); ?></option>
584
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'mt') !== false) {
585
+ echo 'selected';
586
+ } ?> value="mt"><?php esc_html_e('Maltese', 'weglot'); ?></option>
587
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'mi') !== false) {
588
+ echo 'selected';
589
+ } ?> value="mi"><?php esc_html_e('Māori', 'weglot'); ?></option>
590
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'mr') !== false) {
591
+ echo 'selected';
592
+ } ?> value="mr"><?php esc_html_e('Marathi', 'weglot'); ?></option>
593
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'mn') !== false) {
594
+ echo 'selected';
595
+ } ?> value="mn"><?php esc_html_e('Mongolian', 'weglot'); ?></option>
596
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ne') !== false) {
597
+ echo 'selected';
598
+ } ?> value="ne"><?php esc_html_e('Nepali', 'weglot'); ?></option>
599
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'no') !== false) {
600
+ echo 'selected';
601
+ } ?> value="no"><?php esc_html_e('Norwegian', 'weglot'); ?></option>
602
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ps') !== false) {
603
+ echo 'selected';
604
+ } ?> value="ps"><?php esc_html_e('Pashto', 'weglot'); ?></option>
605
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'fa') !== false) {
606
+ echo 'selected';
607
+ } ?> value="fa"><?php esc_html_e('Persian', 'weglot'); ?></option>
608
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'pl') !== false) {
609
+ echo 'selected';
610
+ } ?> value="pl"><?php esc_html_e('Polish', 'weglot'); ?></option>
611
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'pt') !== false) {
612
+ echo 'selected';
613
+ } ?> value="pt"><?php esc_html_e('Portuguese', 'weglot'); ?></option>
614
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'pa') !== false) {
615
+ echo 'selected';
616
+ } ?> value="pa"><?php esc_html_e('Punjabi', 'weglot'); ?></option>
617
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ro') !== false) {
618
+ echo 'selected';
619
+ } ?> value="ro"><?php esc_html_e('Romanian', 'weglot'); ?></option>
620
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ru') !== false) {
621
+ echo 'selected';
622
+ } ?> value="ru"><?php esc_html_e('Russian', 'weglot'); ?></option>
623
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sm') !== false) {
624
+ echo 'selected';
625
+ } ?> value="sm"><?php esc_html_e('Samoan', 'weglot'); ?></option>
626
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'gd') !== false) {
627
+ echo 'selected';
628
+ } ?> value="gd"><?php esc_html_e('Scottish Gaelic', 'weglot'); ?></option>
629
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sr') !== false) {
630
+ echo 'selected';
631
+ } ?> value="sr"><?php esc_html_e('Serbian', 'weglot'); ?></option>
632
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sn') !== false) {
633
+ echo 'selected';
634
+ } ?> value="sn"><?php esc_html_e('Shona', 'weglot'); ?></option>
635
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sd') !== false) {
636
+ echo 'selected';
637
+ } ?> value="sd"><?php esc_html_e('Sindhi', 'weglot'); ?></option>
638
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'si') !== false) {
639
+ echo 'selected';
640
+ } ?> value="si"><?php esc_html_e('Sinhalese', 'weglot'); ?></option>
641
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sk') !== false) {
642
+ echo 'selected';
643
+ } ?> value="sk"><?php esc_html_e('Slovak', 'weglot'); ?></option>
644
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sl') !== false) {
645
+ echo 'selected';
646
+ } ?> value="sl"><?php esc_html_e('Slovenian', 'weglot'); ?></option>
647
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'so') !== false) {
648
+ echo 'selected';
649
+ } ?> value="so"><?php esc_html_e('Somali', 'weglot'); ?></option>
650
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'st') !== false) {
651
+ echo 'selected';
652
+ } ?> value="st"><?php esc_html_e('Southern Sotho', 'weglot'); ?></option>
653
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'es') !== false) {
654
+ echo 'selected';
655
+ } ?> value="es"><?php esc_html_e('Spanish', 'weglot'); ?></option>
656
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'su') !== false) {
657
+ echo 'selected';
658
+ } ?> value="su"><?php esc_html_e('Sundanese', 'weglot'); ?></option>
659
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sw') !== false) {
660
+ echo 'selected';
661
+ } ?> value="sw"><?php esc_html_e('Swahili', 'weglot'); ?></option>
662
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'sv') !== false) {
663
+ echo 'selected';
664
+ } ?> value="sv"><?php esc_html_e('Swedish', 'weglot'); ?></option>
665
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'tl') !== false) {
666
+ echo 'selected';
667
+ } ?> value="tl"><?php esc_html_e('Tagalog', 'weglot'); ?></option>
668
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ty') !== false) {
669
+ echo 'selected';
670
+ } ?> value="ty"><?php esc_html_e('Tahitian', 'weglot'); ?></option>
671
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'tg') !== false) {
672
+ echo 'selected';
673
+ } ?> value="tg"><?php esc_html_e('Tajik', 'weglot'); ?></option>
674
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ta') !== false) {
675
+ echo 'selected';
676
+ } ?> value="ta"><?php esc_html_e('Tamil', 'weglot'); ?></option>
677
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'tt') !== false) {
678
+ echo 'selected';
679
+ } ?> value="tt"><?php esc_html_e('Tatar', 'weglot'); ?></option>
680
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'te') !== false) {
681
+ echo 'selected';
682
+ } ?> value="te"><?php esc_html_e('Telugu', 'weglot'); ?></option>
683
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'th') !== false) {
684
+ echo 'selected';
685
+ } ?> value="th"><?php esc_html_e('Thai', 'weglot'); ?></option>
686
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'to') !== false) {
687
+ echo 'selected';
688
+ } ?> value="to"><?php esc_html_e('Tongan', 'weglot'); ?></option>
689
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'tr') !== false) {
690
+ echo 'selected';
691
+ } ?> value="tr"><?php esc_html_e('Turkish', 'weglot'); ?></option>
692
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'uk') !== false) {
693
+ echo 'selected';
694
+ } ?> value="uk"><?php esc_html_e('Ukrainian', 'weglot'); ?></option>
695
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'ur') !== false) {
696
+ echo 'selected';
697
+ } ?> value="ur"><?php esc_html_e('Urdu', 'weglot'); ?></option>
698
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'uz') !== false) {
699
+ echo 'selected';
700
+ } ?> value="uz"><?php esc_html_e('Uzbek', 'weglot'); ?></option>
701
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'vi') !== false) {
702
+ echo 'selected';
703
+ } ?> value="vi"><?php esc_html_e('Vietnamese', 'weglot'); ?></option>
704
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'cy') !== false) {
705
+ echo 'selected';
706
+ } ?> value="cy"><?php esc_html_e('Welsh', 'weglot'); ?></option>
707
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'fy') !== false) {
708
+ echo 'selected';
709
+ } ?> value="fy"><?php esc_html_e('Western Frisian', 'weglot'); ?></option>
710
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'xh') !== false) {
711
+ echo 'selected';
712
+ } ?> value="xh"><?php esc_html_e('Xhosa', 'weglot'); ?></option>
713
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'yi') !== false) {
714
+ echo 'selected';
715
+ } ?> value="yi"><?php esc_html_e('Yiddish', 'weglot'); ?></option>
716
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'yo') !== false) {
717
+ echo 'selected';
718
+ } ?> value="yo"><?php esc_html_e('Yoruba', 'weglot'); ?></option>
719
+ <option <?php if (strpos(esc_attr(get_option('destination_l')), 'zu') !== false) {
720
+ echo 'selected';
721
+ } ?> value="zu"><?php esc_html_e('Zulu', 'weglot'); ?></option>
722
+ </select>
723
+ </div>
724
+ <input id="destination_input_hidden" type="text"
725
+ class="wg-input-text" name="destination_l"
726
+ value="<?php echo esc_attr(get_option('destination_l')); ?>"
727
+ placeholder="en,es" required style="display:none;"/>
728
+ <?php
729
+ if ($this->userInfo['plan'] <= 0) { ?>
730
+ <p class="wg-fsubtext"><?php echo sprintf(esc_html__('On the free plan, you can only choose one language and a maximum of 2000 words. If you want to use more than 1 language and 2000 words, please %1$supgrade your plan%2$s.', 'weglot'), '<a target="_blank" href="https://weglot.com/change-plan">', '</a>'); ?></p><?php } ?> <?php if ($this->userInfo['plan'] >= 18 && $this->userInfo['plan'] <= 19) { ?>
731
+ <p class="wg-fsubtext"><?php echo sprintf(esc_html__('On the Starter plan, you can only choose one language. If you want to use more than 1 language, please %1$supgrade your plan%2$s.', 'weglot'), '<a target="_blank" href="https://weglot.com/change-plan">', '</a>'); ?></p><?php } ?>
732
+ </td>
733
+ </tr>
734
+ </table>
735
+ <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;"><?php echo esc_html__('Language button appearance', 'weglot') . ' ' . esc_html__('(Optional)', 'weglot'); ?></h3>
736
+ <p class="preview-text"><?php esc_html_e('Preview:', 'weglot'); ?></p>
737
+ <div class="wg-widget-preview"></div>
738
+ <table class="form-table">
739
+ <tr valign="top">
740
+ <th scope="row"><?php esc_html_e('Dropdown?', 'weglot'); ?></th>
741
+ <td><input id="id_is_dropdown" type="checkbox" name="is_dropdown"
742
+ <?php
743
+ if (esc_attr(get_option('is_dropdown')) == 'on') {
744
+ echo 'checked';
745
+ } ?>
746
+ /><label for="id_is_dropdown"
747
+ style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e('Check if you want the button to be a dropdown box.', 'weglot'); ?></label>
748
+ </td>
749
+ </tr>
750
+ <tr valign="top">
751
+ <th scope="row"><?php esc_html_e('With flags?', 'weglot'); ?></th>
752
+ <td><input id="id_with_flags" type="checkbox" name="with_flags"
753
+ <?php
754
+ if (esc_attr(get_option('with_flags')) == 'on') {
755
+ echo 'checked';
756
+ } ?>
757
+ /><label for="id_with_flags"
758
+ style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e('Check if you want flags in the language button.', 'weglot'); ?></label>
759
+ </td>
760
+ </tr>
761
+ <tr valign="top">
762
+ <th scope="row"><?php esc_html_e('Type of flags', 'weglot'); ?></th>
763
+ <td>
764
+ <select class="wg-input-select" name="type_flags"
765
+ style="width :200px;">
766
+ <option <?php if (esc_attr(get_option('type_flags')) == '0') {
767
+ echo 'selected';
768
+ } ?> value="0"><?php esc_html_e('Rectangle mat', 'weglot'); ?></option>
769
+ <option <?php if (esc_attr(get_option('type_flags')) == '1') {
770
+ echo 'selected';
771
+ } ?> value="1"><?php esc_html_e('Rectangle shiny', 'weglot'); ?></option>
772
+ <option <?php if (esc_attr(get_option('type_flags')) == '2') {
773
+ echo 'selected';
774
+ } ?> value="2"><?php esc_html_e('Square', 'weglot'); ?></option>
775
+ <option <?php if (esc_attr(get_option('type_flags')) == '3') {
776
+ echo 'selected';
777
+ } ?> value="3"><?php esc_html_e('Circle', 'weglot'); ?></option>
778
+ </select>
779
+ <div class="flag-style-openclose"><?php esc_html_e('Change country flags', 'weglot'); ?></div>
780
+ <div class="flag-style-wrapper" style="display:none;">
781
+ <select class="flag-en-type wg-input-select">
782
+ <option value=0><?php esc_html_e('Choose English flag:', 'weglot'); ?></option>
783
+ <option value=0><?php esc_html_e('United Kingdom (default)', 'weglot'); ?></option>
784
+ <option value=1><?php esc_html_e('United States', 'weglot'); ?></option>
785
+ <option value=2><?php esc_html_e('Australia', 'weglot'); ?></option>
786
+ <option value=3><?php esc_html_e('Canada', 'weglot'); ?></option>
787
+ <option value=4><?php esc_html_e('New Zealand', 'weglot'); ?></option>
788
+ <option value=5><?php esc_html_e('Jamaica', 'weglot'); ?></option>
789
+ <option value=6><?php esc_html_e('Ireland', 'weglot'); ?></option>
790
+ </select>
791
+ <select class="flag-es-type wg-input-select">
792
+ <option value=0><?php esc_html_e('Choose Spanish flag:', 'weglot'); ?></option>
793
+ <option value=0><?php esc_html_e('Spain (default)', 'weglot'); ?></option>
794
+ <option value=1><?php esc_html_e('Mexico', 'weglot'); ?></option>
795
+ <option value=2><?php esc_html_e('Argentina', 'weglot'); ?></option>
796
+ <option value=3><?php esc_html_e('Colombia', 'weglot'); ?></option>
797
+ <option value=4><?php esc_html_e('Peru', 'weglot'); ?></option>
798
+ <option value=5><?php esc_html_e('Bolivia', 'weglot'); ?></option>
799
+ <option value=6><?php esc_html_e('Uruguay', 'weglot'); ?></option>
800
+ <option value=7><?php esc_html_e('Venezuela', 'weglot'); ?></option>
801
+ <option value=8><?php esc_html_e('Chile', 'weglot'); ?></option>
802
+ <option value=9><?php esc_html_e('Ecuador', 'weglot'); ?></option>
803
+ <option value=10><?php esc_html_e('Guatemala', 'weglot'); ?></option>
804
+ <option value=11><?php esc_html_e('Cuba', 'weglot'); ?></option>
805
+ <option value=12><?php esc_html_e('Dominican Republic', 'weglot'); ?></option>
806
+ <option value=13><?php esc_html_e('Honduras', 'weglot'); ?></option>
807
+ <option value=14><?php esc_html_e('Paraguay', 'weglot'); ?></option>
808
+ <option value=15><?php esc_html_e('El Salvador', 'weglot'); ?></option>
809
+ <option value=16><?php esc_html_e('Nicaragua', 'weglot'); ?></option>
810
+ <option value=17><?php esc_html_e('Costa Rica', 'weglot'); ?></option>
811
+ <option value=18><?php esc_html_e('Puerto Rico', 'weglot'); ?></option>
812
+ <option value=19><?php esc_html_e('Panama', 'weglot'); ?></option>
813
+ </select>
814
+ <select class="flag-pt-type wg-input-select">
815
+ <option value=0><?php esc_html_e('Choose Portuguese flag:', 'weglot'); ?></option>
816
+ <option value=0><?php esc_html_e('Brazil (default)', 'weglot'); ?></option>
817
+ <option value=1><?php esc_html_e('Portugal', 'weglot'); ?></option>
818
+ </select>
819
+ <select class="flag-fr-type wg-input-select">
820
+ <option value=0><?php esc_html_e('Choose French flag:', 'weglot'); ?></option>
821
+ <option value=0><?php esc_html_e('France (default)', 'weglot'); ?></option>
822
+ <option value=1><?php esc_html_e('Belgium', 'weglot'); ?></option>
823
+ <option value=2><?php esc_html_e('Canada', 'weglot'); ?></option>
824
+ <option value=3><?php esc_html_e('Switzerland', 'weglot'); ?></option>
825
+ <option value=4><?php esc_html_e('Luxemburg', 'weglot'); ?></option>
826
+ </select>
827
+ <select class="flag-ar-type wg-input-select">
828
+ <option value=0><?php esc_html_e('Choose Arabic flag:', 'weglot'); ?></option>
829
+ <option value=0><?php esc_html_e('Saudi Arabia (default)', 'weglot'); ?></option>
830
+ <option value=1><?php esc_html_e('Algeria', 'weglot'); ?></option>
831
+ <option value=2><?php esc_html_e('Egypt', 'weglot'); ?></option>
832
+ <option value=3><?php esc_html_e('Iraq', 'weglot'); ?></option>
833
+ <option value=4><?php esc_html_e('Jordan', 'weglot'); ?></option>
834
+ <option value=5><?php esc_html_e('Kuwait', 'weglot'); ?></option>
835
+ <option value=6><?php esc_html_e('Lebanon', 'weglot'); ?></option>
836
+ <option value=7><?php esc_html_e('Libya', 'weglot'); ?></option>
837
+ <option value=8><?php esc_html_e('Morocco', 'weglot'); ?></option>
838
+ <option value=14><?php esc_html_e('Oman', 'weglot'); ?></option>
839
+ <option value=9><?php esc_html_e('Qatar', 'weglot'); ?></option>
840
+ <option value=10><?php esc_html_e('Syria', 'weglot'); ?></option>
841
+ <option value=11><?php esc_html_e('Tunisia', 'weglot'); ?></option>
842
+ <option value=12><?php esc_html_e('United Arab Emirates', 'weglot'); ?></option>
843
+ <option value=13><?php esc_html_e('Yemen', 'weglot'); ?></option>
844
+ </select>
845
+ <p><?php esc_html_e('If you want to use a different flag, just ask us.', 'weglot'); ?></p>
846
+ </div>
847
+ </td>
848
+ </tr>
849
+ <tr valign="top">
850
+ <th scope="row"><?php esc_html_e('With name?', 'weglot'); ?></th>
851
+ <td><input id="id_with_name" type="checkbox" name="with_name"
852
+ <?php
853
+ if (esc_attr(get_option('with_name')) == 'on') {
854
+ echo 'checked';
855
+ } ?>
856
+ /><label for="id_with_name"
857
+ style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e('Check if you want to display the name of languages.', 'weglot'); ?></label>
858
+ </td>
859
+ </tr>
860
+ <tr valign="top">
861
+ <th scope="row"><?php esc_html_e('Full name?', 'weglot'); ?></th>
862
+ <td><input id="id_is_fullname" type="checkbox" name="is_fullname"
863
+ <?php
864
+ if (esc_attr(get_option('is_fullname')) == 'on') {
865
+ echo 'checked';
866
+ } ?>
867
+ /><label for="id_is_fullname"
868
+ style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e('Check if you want the name of the languge. Don\'t check if you want the language code.', 'weglot'); ?></label>
869
+ </td>
870
+ </tr>
871
+ <tr valign="top">
872
+ <th scope="row"><?php esc_html_e('Override CSS', 'weglot'); ?><p
873
+ style="font-weight:normal;margin-top:2px;"><?php esc_html_e('Don\'t change it unless you want a specific style for your button.', 'weglot'); ?></p>
874
+ </th>
875
+ <td><textarea class="wg-input-textarea" type="text" rows=10 cols=30
876
+ name="override_css" placeholder=".country-selector {
877
  margin-bottom: 20px;
878
  background-color: green!important;
879
  }
880
  .country-selector a {
881
  color: blue!important;
882
+ }"><?php echo esc_attr(get_option('override_css')); ?></textarea><textarea
883
+ class="wg-input-textarea" type="text" name="flag_css"
884
+ style="display:none;"><?php echo esc_attr(get_option('flag_css')); ?></textarea>
885
+ </td>
886
+ </tr>
887
+ </table>
888
+ <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;"><?php echo esc_html__('Language button position', 'weglot') . ' ' . esc_html__('(Optional)', 'weglot'); ?></h3>
889
+ <h4 style="font-size:14px;line-height: 1.3;font-weight: 600;"><?php esc_html_e('Where will the language button be on my website? By default, bottom right.', 'weglot'); ?></h4>
890
+ <table class="form-table">
891
+ <tr valign="top">
892
+ <th scope="row"><?php esc_html_e('In menu?', 'weglot'); ?></th>
893
+ <td><input id="id_is_menu" type="checkbox" name="is_menu"
894
+ <?php
895
+ if (esc_attr(get_option('is_menu')) == 'on') {
896
+ echo 'checked';
897
+ } ?>
898
+ /><label for="id_is_menu"
899
+ style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e('Check if you want to display the button in the navigation menu.', 'weglot'); ?></label>
900
+ </td>
901
+ </tr>
902
+ <tr valign="top">
903
+ <th scope="row"><?php esc_html_e('As a widget?', 'weglot'); ?></th>
904
+ <td>
905
+ <p style="font-weight: normal;font-style: italic;display: inline-block;"><?php esc_html_e('You can place the button in a widget area. Go to Appearance -> Widgets and drag and drop the Weglot Translate widget where you want.', 'weglot'); ?></p>
906
+ </td>
907
+ </tr>
908
+ <tr valign="top">
909
+ <th scope="row"><?php esc_html_e('With a shortcode?', 'weglot'); ?></th>
910
+ <td>
911
+ <p style="font-weight: normal;font-style: italic;display: inline-block;"><?php esc_html_e('You can use the Weglot shortcode [weglot_switcher] wherever you want to place the button.', 'weglot'); ?></p>
912
+ </td>
913
+ </tr>
914
+ <tr valign="top">
915
+ <th scope="row"><?php esc_html_e('In the source code?', 'weglot'); ?></th>
916
+ <td>
917
+ <p style="font-weight: normal;font-style: italic;display: inline-block;"><?php esc_html_e('You can add the code &lt;div id=&quot;weglot_here&quot;&gt;&lt;/div&gt; wherever you want in the source code of your HTML page. The button will appear at this place.', 'weglot'); ?></p>
918
+ </td>
919
+ </tr>
920
+ </table>
921
+ <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;">
922
+ <?php
923
+ echo esc_html__('Translation Exclusion', 'weglot') . ' ' . esc_html__('(Optional)', 'weglot');
924
+ ?>
925
+ </h3>
926
+ <p><?php esc_html_e('By default, every page is translated. You can exclude parts of a page or a full page here.', 'weglot'); ?></p>
927
+ <table class="form-table">
928
+ <tr valign="top">
929
+ <th scope="row"><?php esc_html_e('Exclude URL here', 'weglot'); ?><p
930
+ style="font-weight:normal;margin-top:2px;"><?php esc_html_e('You can write regex.', 'weglot'); ?>
931
+ <p></th>
932
+ <td><textarea class="wg-input-textarea" type="text" rows=3 cols=30
933
+ name="exclude_url"
934
+ placeholder=""><?php echo esc_attr(get_option('exclude_url')); ?></textarea>
935
+ </td>
936
+ </tr>
937
+ <tr valign="top">
938
+ <th scope="row"><?php esc_html_e('Exclude blocks', 'weglot'); ?><p
939
+ style="font-weight:normal;margin-top:2px;"><?php esc_html_e('Enter CSS selectors, separated by commas.', 'weglot'); ?>
940
+ <p></th>
941
+ <td><textarea class="wg-input-textarea" type="text" rows=3 cols=30
942
+ name="exclude_blocks"
943
+ placeholder="#top-menu,footer a,.title-3"><?php echo esc_attr(get_option('exclude_blocks')); ?></textarea>
944
+ </td>
945
+ </tr>
946
+ </table>
947
+ <?php if ($this->userInfo['plan'] > 0) { ?>
948
+ <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;">
949
+ <?php
950
+ echo esc_html__('Other options', 'weglot') . ' ' . esc_html__('(Optional)', 'weglot');
951
+ ?>
952
+ </h3>
953
+ <table class="form-table">
954
+ <tr valign="top">
955
+ <th scope="row"><?php esc_html_e('Auto redirect?', 'weglot'); ?></th>
956
+ <td><input id="id_auto_switch" type="checkbox"
957
+ name="wg_auto_switch"
958
+ <?php
959
+ if (esc_attr(get_option('wg_auto_switch')) == 'on') {
960
+ echo 'checked';
961
+ } ?>
962
+ /><label for="id_auto_switch"
963
+ style="font-weight: normal;margin-left: 20px;font-style: italic;display: inline-block;"><?php esc_html_e('Check if you want to redirect users based on their browser language.', 'weglot'); ?></label>
964
+ </td>
965
+ </tr>
966
+ </table>
967
+ <?php } ?>
968
+ <?php
969
+ if ($showLTR || $showRTL) {
970
+ $ltrOrRtl = $showLTR ? esc_html__('Left to Right languages', 'weglot') : esc_html__('Right to Left languages', 'weglot');
971
+ ?>
972
+ <h3 style="border-bottom:1px solid #c0c0c0;padding-bottom:10px;max-width:800px;margin-top:40px;">
973
+ <?php
974
+ echo esc_html__('Customize style for ', 'weglot') . esc_html__($ltrOrRtl) . ' ' . esc_html__('(Optional)', 'weglot');
975
+ ?>
976
+ </h3>
977
+ <table class="form-table">
978
+ <tr valign="top">
979
+ <th scope="row"><?php echo sprintf(esc_html__('Write CSS rules to apply on %s page.', 'weglot'), esc_html__($ltrOrRtl)); ?>
980
+ <p style="font-weight:normal;margin-top:2px;">
981
+ <p></th>
982
+ <td><textarea class="wg-input-textarea" type="text" rows=5
983
+ cols=30 name="rtl_ltr_style" placeholder="body {
984
  text-align: right;
985
+ }"><?php echo esc_attr(get_option('rtl_ltr_style')); ?></textarea></td>
986
+ </tr>
987
+ </table>
988
+ <?php } ?>
989
+ <?php submit_button(); ?>
990
+ </form>
991
+ <?php
992
+ if (esc_attr(get_option('show_box')) == 'off') { ?>
993
+ <div class="wginfobox">
994
+ <h3><?php esc_html_e('Where are my translations?', 'weglot'); ?></h3>
995
+ <div>
996
+ <p><?php esc_html_e('You can find all your translations in your Weglot account:', 'weglot'); ?></p>
997
+ <a href="<?php esc_html_e('https://weglot.com/dashboard', 'weglot'); ?>"
998
+ target="_blank"
999
+ class="wg-editbtn"><?php esc_html_e('Edit my translations', 'weglot'); ?></a>
1000
+ </div>
1001
+ </div><?php } ?>
1002
+ <br>
1003
+ <a target="_blank"
1004
+ href="http://wordpress.org/support/view/plugin-reviews/weglot?rate=5#postform">
1005
+ <?php esc_html_e('Love Weglot? Give us 5 stars on WordPress.org :)', 'weglot'); ?>
1006
+ </a>
1007
+ <br><br>
1008
+ <i class="fa fa-question-circle" aria-hidden="true"
1009
+ style="font-size : 17px;"></i>
1010
+ <p style="display:inline-block; margin-left:5px;"><?php echo sprintf(esc_html__('If you need any help, you can contact us via our live chat at %1$sweglot.com%2$s or email us at support@weglot.com.', 'weglot'), '<a href="https://weglot.com/" target="_blank">', '</a>') . '<br>' . sprintf(esc_html__('You can also check our %1$sFAQ%2$s', 'weglot'), '<a href="http://support.weglot.com/" target="_blank">', '</a>'); ?></p>
1011
  <br><br><br>
1012
+ <h2></h2>
1013
  </div>
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: remyb92
3
  Tags: translate,translation,language,multilingual,bilingual,international,localization,multilanguage,multi language,translations,translator,multilangues,traduction,traducteur,ubersetzung,mehrsprachig,traduccion,traduzione,vertaling,vertaler,meertalig
4
  Requires at least: 4.5
5
  Tested up to: 4.9
6
- Stable tag: 1.9.3
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -147,6 +147,11 @@ See changelog for upgrade changes.
147
 
148
  == Changelog ==
149
 
 
 
 
 
 
150
  = 1.9.3 =
151
  * Remove Freemius
152
 
3
  Tags: translate,translation,language,multilingual,bilingual,international,localization,multilanguage,multi language,translations,translator,multilangues,traduction,traducteur,ubersetzung,mehrsprachig,traduccion,traduzione,vertaling,vertaler,meertalig
4
  Requires at least: 4.5
5
  Tested up to: 4.9
6
+ Stable tag: 1.10
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
147
 
148
  == Changelog ==
149
 
150
+ = 1.10 =
151
+ * Add new languages + add Oman flag
152
+ * Can potentially translate email sent from admin
153
+ * Add tags to inline elements to ignore when parsing
154
+
155
  = 1.9.3 =
156
  * Remove Freemius
157
 
resources/wp-weglot-admin-js.js CHANGED
@@ -196,6 +196,7 @@ jQuery(
196
  ar_flags[11] = [720,7522,384,3936];
197
  ar_flags[12] = [690,7745,336,1104];
198
  ar_flags[13] = [600,8225,120,1272];
 
199
 
200
  var enval = $( "select.flag-en-type" ).val();
201
  var esval = $( "select.flag-es-type" ).val();
@@ -213,147 +214,219 @@ jQuery(
213
  }
214
  function getLangNameFromCode (original,english) {
215
  switch (original) {
 
 
216
  case "sq":
217
  return english ? "Albanian" : "Shqip";
218
- case "en":
219
- return english ? "English" : "English";
220
  case "ar":
221
  return english ? "Arabic" : "‏العربية‏";
222
  case "hy":
223
  return english ? "Armenian" : "հայերեն";
224
  case "az":
225
  return english ? "Azerbaijani" : "Azərbaycan dili";
226
- case "af":
227
- return english ? "Afrikaans" : "Afrikaans";
228
  case "eu":
229
  return english ? "Basque" : "Euskara";
230
  case "be":
231
  return english ? "Belarusian" : "Беларуская";
 
 
 
 
232
  case "bg":
233
  return english ? "Bulgarian" : "български";
234
- case "bs":
235
- return english ? "Bosnian" : "Bosanski";
236
- case "vi":
237
- return english ? "Vietnamese" : "Tiếng Việt";
238
- case "hu":
239
- return english ? "Hungarian" : "Magyar";
240
- case "ht":
241
- return english ? "Haitian" : "Kreyòl ayisyen";
242
- case "gl":
243
- return english ? "Galician" : "Galego";
244
- case "nl":
245
- return english ? "Dutch" : "Nederlands";
246
- case "el":
247
- return english ? "Greek" : "Ελληνικά";
248
- case "ka":
249
- return english ? "Georgian" : "ქართული";
250
- case "da":
251
- return english ? "Danish" : "Dansk";
252
- case "he":
253
- return english ? "Hebrew" : "עברית";
254
- case "id":
255
- return english ? "Indonesian" : "Bahasa Indonesia";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
256
  case "ga":
257
  return english ? "Irish" : "Gaeilge";
258
  case "it":
259
  return english ? "Italian" : "Italiano";
260
- case "is":
261
- return english ? "Icelandic" : "Íslenska";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
262
  case "es":
263
  return english ? "Spanish" : "Español";
264
- case "kk":
265
- return english ? "Kazakh" : "Қазақша";
266
- case "ca":
267
- return english ? "Catalan" : "Català";
268
- case "ky":
269
- return english ? "Kyrgyz" : "кыргызча";
270
- case "zh":
271
- return english ? "Simplified Chinese" : "中文 (简体)";
272
- case "tw":
273
- return english ? "Traditional Chinese" : "中文 (繁體)";
274
- case "ko":
275
- return english ? "Korean" : "한국어";
276
- case "lv":
277
- return english ? "Latvian" : "Latviešu";
278
- case "lt":
279
- return english ? "Lithuanian" : "Lietuvių";
280
- case "mg":
281
- return english ? "Malagasy" : "Malagasy";
282
- case "ms":
283
- return english ? "Malay" : "Bahasa Melayu";
284
- case "mt":
285
- return english ? "Maltese" : "Malti";
286
- case "mk":
287
- return english ? "Macedonian" : "Македонски";
288
- case "mn":
289
- return english ? "Mongolian" : "Монгол";
290
- case "de":
291
- return english ? "German" : "Deutsch";
292
- case "no":
293
- return english ? "Norwegian" : "Norsk";
294
- case "fa":
295
- return english ? "Persian" : "فارسی";
296
- case "pl":
297
- return english ? "Polish" : "Polski";
298
- case "pt":
299
- return english ? "Portuguese" : "Português";
300
- case "ro":
301
- return english ? "Romanian" : "Română";
302
- case "ru":
303
- return english ? "Russian" : "Русский";
304
- case "sr":
305
- return english ? "Serbian" : "Српски";
306
- case "sk":
307
- return english ? "Slovak" : "Slovenčina";
308
- case "sl":
309
- return english ? "Slovenian" : "Slovenščina";
310
- case "sw":
311
- return english ? "Swahili" : "Kiswahili";
312
- case "tg":
313
- return english ? "Tajik" : "Тоҷикӣ";
314
- case "th":
315
- return english ? "Thai" : "ภาษาไทย";
316
- case "tl":
317
- return english ? "Tagalog" : "Tagalog";
318
- case "tt":
319
- return english ? "Tatar" : "Tatar";
320
- case "tr":
321
- return english ? "Turkish" : "Türkçe";
322
  case "uz":
323
  return english ? "Uzbek" : "O'zbek";
324
- case "uk":
325
- return english ? "Ukrainian" : "Українська";
326
- case "fi":
327
- return english ? "Finnish" : "Suomi";
328
- case "fr":
329
- return english ? "French" : "Français";
330
- case "hr":
331
- return english ? "Croatian" : "Hrvatski";
332
- case "cs":
333
- return english ? "Czech" : "Čeština";
334
- case "sv":
335
- return english ? "Swedish" : "Svenska";
336
- case "et":
337
- return english ? "Estonian" : "Eesti";
338
- case "ja":
339
- return english ? "Japanese" : "日本語";
340
- case "hi":
341
- return english ? "Hindi" : "हिंदी";
342
- case "ur":
343
- return english ? "Urdu" : "اردو";
344
- case "bn":
345
- return english ? "Bengali" : "বাংলা";
346
- case "fj":
347
- return english ? "Fijian" : "Fidžin";
348
- case "sm":
349
- return english ? "Samoan" : "Samoa";
350
- case "ty":
351
- return english ? "Tahitian" : "Tahitian";
352
- case "to":
353
- return english ? "Tongan" : "Tonga";
354
- case "cy":
355
- return english ? "Welsh" : "Cymraeg";
356
- }
357
  }
358
 
359
  $selectL = $( '#select-lto' ).selectize(
196
  ar_flags[11] = [720,7522,384,3936];
197
  ar_flags[12] = [690,7745,336,1104];
198
  ar_flags[13] = [600,8225,120,1272];
199
+ ar_flags[14] = [660,5569,840,576];
200
 
201
  var enval = $( "select.flag-en-type" ).val();
202
  var esval = $( "select.flag-es-type" ).val();
214
  }
215
  function getLangNameFromCode (original,english) {
216
  switch (original) {
217
+ case "af":
218
+ return english ? "Afrikaans" : "Afrikaans";
219
  case "sq":
220
  return english ? "Albanian" : "Shqip";
221
+ case "am":
222
+ return english ? "Amharic" : "አማርኛ";
223
  case "ar":
224
  return english ? "Arabic" : "‏العربية‏";
225
  case "hy":
226
  return english ? "Armenian" : "հայերեն";
227
  case "az":
228
  return english ? "Azerbaijani" : "Azərbaycan dili";
229
+ case "ba":
230
+ return english ? "Bashkir" : "башҡорт теле";
231
  case "eu":
232
  return english ? "Basque" : "Euskara";
233
  case "be":
234
  return english ? "Belarusian" : "Беларуская";
235
+ case "bn":
236
+ return english ? "Bengali" : "বাংলা";
237
+ case "bs":
238
+ return english ? "Bosnian" : "Bosanski";
239
  case "bg":
240
  return english ? "Bulgarian" : "български";
241
+ case "my":
242
+ return english ? "Burmese" : "မြန်မာ";
243
+ case "ca":
244
+ return english ? "Catalan" : "Català";
245
+ case "km":
246
+ return english ? "Khmer" : "ភាសាខ្មែរ";
247
+ case "ny":
248
+ return english ? "Chichewa" : "Chicheŵa";
249
+ case "co":
250
+ return english ? "Corsican" : "Corsu";
251
+ case "zh":
252
+ return english ? "Simplified Chinese" : "中文 (简体)";
253
+ case "tw":
254
+ return english ? "Traditional Chinese" : "中文 (繁體)";
255
+ case "hr":
256
+ return english ? "Croatian" : "Hrvatski";
257
+ case "cs":
258
+ return english ? "Czech" : "Čeština";
259
+ case "da":
260
+ return english ? "Danish" : "Dansk";
261
+ case "nl":
262
+ return english ? "Dutch" : "Nederlands";
263
+ case "en":
264
+ return english ? "English" : "English";
265
+ case "eo":
266
+ return english ? "Esperanto" : "Esperanto";
267
+ case "et":
268
+ return english ? "Estonian" : "Eesti";
269
+ case "fj":
270
+ return english ? "Fijian" : "Fidžin";
271
+ case "fi":
272
+ return english ? "Finnish" : "Suomi";
273
+ case "fr":
274
+ return english ? "French" : "Français";
275
+ case "gl":
276
+ return english ? "Galician" : "Galego";
277
+ case "ka":
278
+ return english ? "Georgian" : "ქართული";
279
+ case "de":
280
+ return english ? "German" : "Deutsch";
281
+ case "el":
282
+ return english ? "Greek" : "Ελληνικά";
283
+ case "gu":
284
+ return english ? "Gujarati" : "ગુજરાતી";
285
+ case "ht":
286
+ return english ? "Haitian" : "Kreyòl ayisyen";
287
+ case "ha":
288
+ return english ? "Hausa" : "Hausa";
289
+ case "he":
290
+ return english ? "Hebrew" : "עברית";
291
+ case "hi":
292
+ return english ? "Hindi" : "हिंदी";
293
+ case "hu":
294
+ return english ? "Hungarian" : "Magyar";
295
+ case "is":
296
+ return english ? "Icelandic" : "Íslenska";
297
+ case "ig":
298
+ return english ? "Igbo" : "Igbo";
299
+ case "id":
300
+ return english ? "Indonesian" : "Bahasa Indonesia";
301
  case "ga":
302
  return english ? "Irish" : "Gaeilge";
303
  case "it":
304
  return english ? "Italian" : "Italiano";
305
+ case "ja":
306
+ return english ? "Japanese" : "日本語";
307
+ case "jv":
308
+ return english ? "Javanese" : "baṣa Jawa";
309
+ case "kn":
310
+ return english ? "Kannada" : "ಕನ್ನಡ";
311
+ case "kk":
312
+ return english ? "Kazakh" : "Қазақша";
313
+ case "ko":
314
+ return english ? "Korean" : "한국어";
315
+ case "ku":
316
+ return english ? "Kurdish" : "Kurdí";
317
+ case "ky":
318
+ return english ? "Kyrgyz" : "кыргызча";
319
+ case "lo":
320
+ return english ? "Lao" : "ລາວ";
321
+ case "la":
322
+ return english ? "Latin" : "Latine";
323
+ case "lv":
324
+ return english ? "Latvian" : "Latviešu";
325
+ case "lt":
326
+ return english ? "Lithuanian" : "Lietuvių";
327
+ case "lb":
328
+ return english ? "Luxembourgish" : "Lëtzebuergesch";
329
+ case "mk":
330
+ return english ? "Macedonian" : "Македонски";
331
+ case "mg":
332
+ return english ? "Malagasy" : "Malagasy";
333
+ case "ms":
334
+ return english ? "Malay" : "Bahasa Melayu";
335
+ case "ml":
336
+ return english ? "Malayalam" : "മലയാളം";
337
+ case "mt":
338
+ return english ? "Maltese" : "Malti";
339
+ case "mi":
340
+ return english ? "Māori" : "Māori";
341
+ case "mr":
342
+ return english ? "Marathi" : "मराठी";
343
+ case "mn":
344
+ return english ? "Mongolian" : "Монгол";
345
+ case "ne":
346
+ return english ? "Nepali" : "नेपाली";
347
+ case "no":
348
+ return english ? "Norwegian" : "Norsk";
349
+ case "ps":
350
+ return english ? "Pashto" : "پښتو";
351
+ case "fa":
352
+ return english ? "Persian" : "فارسی";
353
+ case "pl":
354
+ return english ? "Polish" : "Polski";
355
+ case "pt":
356
+ return english ? "Portuguese" : "Português";
357
+ case "pa":
358
+ return english ? "Punjabi" : "ਪੰਜਾਬੀ";
359
+ case "ro":
360
+ return english ? "Romanian" : "Română";
361
+ case "ru":
362
+ return english ? "Russian" : "Русский";
363
+ case "sm":
364
+ return english ? "Samoan" : "Samoa";
365
+ case "gd":
366
+ return english ? "Scottish Gaelic" : "Gàidhlig na h-Alba";
367
+ case "sr":
368
+ return english ? "Serbian" : "Српски";
369
+ case "sn":
370
+ return english ? "Shona" : "chiShona";
371
+ case "sd":
372
+ return english ? "Sindhi" : "سنڌي";
373
+ case "si":
374
+ return english ? "Sinhalese" : "සිංහල";
375
+ case "sk":
376
+ return english ? "Slovak" : "Slovenčina";
377
+ case "sl":
378
+ return english ? "Slovenian" : "Slovenščina";
379
+ case "so":
380
+ return english ? "Somali" : "af Soomaali";
381
+ case "st":
382
+ return english ? "Southern Sotho" : "seSotho";
383
  case "es":
384
  return english ? "Spanish" : "Español";
385
+ case "su":
386
+ return english ? "Sundanese" : "Sunda";
387
+ case "sw":
388
+ return english ? "Swahili" : "Kiswahili";
389
+ case "sv":
390
+ return english ? "Swedish" : "Svenska";
391
+ case "tl":
392
+ return english ? "Tagalog" : "Tagalog";
393
+ case "ty":
394
+ return english ? "Tahitian" : "Tahitian";
395
+ case "tg":
396
+ return english ? "Tajik" : "Тоҷикӣ";
397
+ case "ta":
398
+ return english ? "Tamil" : "தமிழ்";
399
+ case "tt":
400
+ return english ? "Tatar" : "Tatar";
401
+ case "te":
402
+ return english ? "Telugu" : "తెలుగు";
403
+ case "th":
404
+ return english ? "Thai" : "ภาษาไทย";
405
+ case "to":
406
+ return english ? "Tongan" : "Tonga";
407
+ case "tr":
408
+ return english ? "Turkish" : "Türkçe";
409
+ case "uk":
410
+ return english ? "Ukrainian" : "Українська";
411
+ case "ur":
412
+ return english ? "Urdu" : "اردو";
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
413
  case "uz":
414
  return english ? "Uzbek" : "O'zbek";
415
+ case "vi":
416
+ return english ? "Vietnamese" : "Tiếng Việt";
417
+ case "cy":
418
+ return english ? "Welsh" : "Cymraeg";
419
+ case "fy": //t
420
+ return english ? "Western Frisian" : "Frysk";
421
+ case "xh"://t
422
+ return english ? "Xhosa" : "isiXhosa";
423
+ case "yi"://t
424
+ return english ? "Yiddish" : "ײִדיש";
425
+ case "yo"://t
426
+ return english ? "Yoruba" : "Yorùbá";
427
+ case "zu"://t
428
+ return english ? "Zulu" : "isiZulu";
429
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
430
  }
431
 
432
  $selectL = $( '#select-lto' ).selectize(
resources/wp-weglot-css.css CHANGED
@@ -169,73 +169,119 @@
169
  height: 20px;
170
  }
171
 
 
172
  .wg-li.sq a:before { background-position: -2580px 0; }
173
- .wg-li.en a:before { background-position: -1920px 0; }
174
  .wg-li.ar a:before { background-position: -510px 0; }
175
  .wg-li.hy a:before { background-position: -2880px 0; }
176
  .wg-li.az a:before { background-position: -6840px 0; }
177
- .wg-li.af a:before { background-position: -6570px 0; }
178
- .wg-li.eu a:before { background-position: -7260px 0; } /* a faire */
179
  .wg-li.be a:before { background-position: -5310px 0; }
180
- .wg-li.bg a:before { background-position: -2730px 0; }
181
  .wg-li.bs a:before { background-position: -6390px 0; }
182
- .wg-li.vi a:before { background-position: -2850px 0; }
183
- .wg-li.hu a:before { background-position: -2430px 0; }
184
- .wg-li.ht a:before { background-position: -4650px 0; }
 
 
 
 
 
 
 
 
185
  .wg-li.nl a:before { background-position: -2100px 0; }
186
- .wg-li.el a:before { background-position: -2460px 0; }
 
 
 
 
 
 
187
  .wg-li.ka a:before { background-position: -5040px 0; }
188
- .wg-li.da a:before { background-position: -2670px 0; }
 
 
 
 
189
  .wg-li.he a:before { background-position: -1050px 0; }
 
 
 
 
190
  .wg-li.id a:before { background-position: -3510px 0; }
191
  .wg-li.ga a:before { background-position: -2340px 0; }
192
  .wg-li.it a:before { background-position: -2310px 0; }
193
- .wg-li.is a:before { background-position: -2400px 0; }
194
- .wg-li.es a:before { background-position: -480px 0; }
 
195
  .wg-li.kk a:before { background-position: -3150px 0; }
196
- .wg-li.ca a:before { background-position: -7230px 0; }
197
- .wg-li.ky a:before { background-position: -3420px 0; }
198
- .wg-li.zh a:before { background-position: -3690px 0; }
199
- .wg-li.tw a:before { background-position: -2970px 0; }
200
  .wg-li.ko a:before { background-position: -6990px 0; }
 
 
 
 
201
  .wg-li.lv a:before { background-position: -2280px 0; }
202
  .wg-li.lt a:before { background-position: -2250px 0; }
 
 
203
  .wg-li.mg a:before { background-position: -1200px 0; }
204
  .wg-li.ms a:before { background-position: -3360px 0; }
 
205
  .wg-li.mt a:before { background-position: -2130px 0; }
206
- .wg-li.mk a:before { background-position: -2190px 0; }
 
207
  .wg-li.mn a:before { background-position: -6000px 0; }
208
- .wg-li.de a:before { background-position: -2490px 0; }
209
  .wg-li.no a:before { background-position: -5850px 0; }
 
210
  .wg-li.fa a:before { background-position: -6690px 0; }
211
  .wg-li.pl a:before { background-position: -2160px 0; }
212
  .wg-li.pt a:before { background-position: -6630px 0; }
 
213
  .wg-li.ro a:before { background-position: -2070px 0; }
214
  .wg-li.ru a:before { background-position: -2040px 0; }
 
 
215
  .wg-li.sr a:before { background-position: -4290px 0; }
 
 
 
216
  .wg-li.sk a:before { background-position: -6810px 0; }
217
  .wg-li.sl a:before { background-position: -2010px 0; }
 
 
 
 
218
  .wg-li.sw a:before { background-position: -1290px 0; }
 
 
 
219
  .wg-li.tg a:before { background-position: -2940px 0; }
 
 
 
220
  .wg-li.th a:before { background-position: -2910px 0; }
 
221
  .wg-li.tr a:before { background-position: -1950px 0; }
222
- .wg-li.uz a:before { background-position: -2880px 0; }
223
  .wg-li.uk a:before { background-position: -1890px 0; }
224
- .wg-li.fi a:before { background-position: -2550px 0; }
225
- .wg-li.fr a:before { background-position: -2520px 0; }
226
- .wg-li.hr a:before { background-position: -5910px 0; }
227
- .wg-li.cs a:before { background-position: -2700px 0; }
228
- .wg-li.sv a:before { background-position: -1980px 0; }
229
- .wg-li.et a:before { background-position: -2640px 0; }
230
- .wg-li.ja a:before { background-position: -3480px 0; }
231
- .wg-li.hi a:before { background-position: -1170px 0; }
232
  .wg-li.ur a:before { background-position: -3180px 0; }
233
- .wg-li.bn a:before { background-position: -5400px 0; }
234
- .wg-li.fj a:before { background-position: -1710px 0; }
235
- .wg-li.sm a:before { background-position: -4620px 0; }
236
- .wg-li.ty a:before { background-position: -6270px 0; }
237
- .wg-li.to a:before { background-position: -6540px 0; }
238
  .wg-li.cy a:before { background-position: -6420px 0; }
 
 
 
 
 
 
 
 
 
 
 
 
239
 
240
  .wg-flags.flag-1 a:before {
241
  background-image: url("../images/rect_bright.png");
@@ -244,74 +290,113 @@
244
  height: 20px;
245
  }
246
 
247
- .wg-li.flag-1.sq a:before { background-position: -97px 0; }
248
- .wg-li.flag-1.en a:before { background-position: -7777px 0; }
249
- .wg-li.flag-1.ar a:before { background-position: -6465px 0; }
250
- .wg-li.flag-1.hy a:before { background-position: -385px 0; }
251
- .wg-li.flag-1.az a:before { background-position: -513px 0; }
252
- .wg-li.flag-1.af a:before { background-position: -6848px 0; }
253
- .wg-li.flag-1.eu a:before { background-position: -8353px 0; }
254
- .wg-li.flag-1.be a:before { background-position: -705px 0; }
255
- .wg-li.flag-1.bg a:before { background-position: -1121px 0; }
256
- .wg-li.flag-1.bs a:before { background-position: -929px 0; }
257
- .wg-li.flag-1.vi a:before { background-position: -8097px 0; }
258
- .wg-li.flag-1.hu a:before { background-position: -3265px 0; }
259
- .wg-li.flag-1.ht a:before { background-position: -3169px 0; }
260
- .wg-li.flag-1.nl a:before { background-position: -5121px 0; }
261
- .wg-li.flag-1.el a:before { background-position: -2881px 0; }
262
- .wg-li.flag-1.ka a:before { background-position: -2721px 0; }
263
- .wg-li.flag-1.da a:before { background-position: -1985px 0; }
264
- .wg-li.flag-1.he a:before { background-position: -3521px 0; }
265
- .wg-li.flag-1.id a:before { background-position: -3361px 0; }
266
- .wg-li.flag-1.ga a:before { background-position: -3457px 0; }
267
- .wg-li.flag-1.it a:before { background-position: -3553px 0; }
268
- .wg-li.flag-1.is a:before { background-position: -3297px 0; }
269
- .wg-li.flag-1.es a:before { background-position: -7009px 0; }
270
- .wg-li.flag-1.kk a:before { background-position: -3713px 0; }
271
- .wg-li.flag-1.ca a:before { background-position: -8321px 0; }
272
- .wg-li.flag-1.ky a:before { background-position: -3873px 0; }
273
- .wg-li.flag-1.zh a:before { background-position: -1505px 0; }
274
- .wg-li.flag-1.tw a:before { background-position: -6369px 0; }
275
- .wg-li.flag-1.ko a:before { background-position: -6913px 0; }
276
- .wg-li.flag-1.lv a:before { background-position: -3937px 0; }
277
- .wg-li.flag-1.lt a:before { background-position: -4129px 0; }
278
- .wg-li.flag-1.mg a:before { background-position: -4257px 0; }
279
- .wg-li.flag-1.ms a:before { background-position: -4321px 0; }
280
- .wg-li.flag-1.mt a:before { background-position: -4417px 0; }
281
- .wg-li.flag-1.mk a:before { background-position: -4225px 0; }
282
- .wg-li.flag-1.mn a:before { background-position: -4769px 0; }
283
- .wg-li.flag-1.de a:before { background-position: -2753px 0; }
284
- .wg-li.flag-1.no a:before { background-position: -5505px 0; }
285
- .wg-li.flag-1.fa a:before { background-position: -3393px 0; }
286
- .wg-li.flag-1.pl a:before { background-position: -5889px 0; }
287
- .wg-li.flag-1.pt a:before { background-position: -993px 0; }
288
- .wg-li.flag-1.ro a:before { background-position: -6081px 0; }
289
- .wg-li.flag-1.ru a:before { background-position: -6113px 0; }
290
- .wg-li.flag-1.sr a:before { background-position: -6561px 0; }
291
- .wg-li.flag-1.sk a:before { background-position: -6689px 0; }
292
- .wg-li.flag-1.sl a:before { background-position: -6721px 0; }
293
- .wg-li.flag-1.sw a:before { background-position: -3745px 0; }
294
- .wg-li.flag-1.tg a:before { background-position: -7297px 0; }
295
- .wg-li.flag-1.th a:before { background-position: -7361px 0; }
296
- .wg-li.flag-1.tr a:before { background-position: -7553px 0; }
297
- .wg-li.flag-1.uz a:before { background-position: -7969px 0; }
298
- .wg-li.flag-1.uk a:before { background-position: -7713px 0; }
299
- .wg-li.flag-1.fi a:before { background-position: -2529px 0; }
300
- .wg-li.flag-1.fr a:before { background-position: -2561px 0; }
301
- .wg-li.flag-1.hr a:before { background-position: -1793px 0; }
302
- .wg-li.flag-1.cs a:before { background-position: -1921px 0; }
303
- .wg-li.flag-1.sv a:before { background-position: -7169px 0; }
304
- .wg-li.flag-1.et a:before { background-position: -2337px 0; }
305
- .wg-li.flag-1.ja a:before { background-position: -3617px 0; }
306
- .wg-li.flag-1.hi a:before { background-position: -3329px 0; }
307
- .wg-li.flag-1.ur a:before { background-position: -5600px 0; }
308
- .wg-li.flag-1.ur a:before { background-position: -5600px 0; }
309
- .wg-li.flag-1.bn a:before { background-position: -609px 0; }
310
- .wg-li.flag-1.fj a:before { background-position: -2497px 0; }
311
- .wg-li.flag-1.sm a:before { background-position: -6369px 0; }
312
- .wg-li.flag-1.ty a:before { background-position: -2593px 0; }
313
- .wg-li.flag-1.to a:before { background-position: -7456px 0; }
314
- .wg-li.flag-1.cy a:before { background-position: -8129px 0; }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
315
 
316
  .wg-flags.flag-2 a:before {
317
  background-image: url("../images/square_flag.png");
@@ -320,73 +405,112 @@
320
  height: 24px;
321
  }
322
 
323
- .wg-li.flag-2.sq a:before { background-position: -2976px 0; }
324
- .wg-li.flag-2.en a:before { background-position: -312px 0; }
325
- .wg-li.flag-2.ar a:before { background-position: -768px 0; }
326
- .wg-li.flag-2.hy a:before { background-position: 0 0; }
327
- .wg-li.flag-2.az a:before { background-position: -5136px 0; }
328
- .wg-li.flag-2.af a:before { background-position: -4968px 0; }
329
- .wg-li.flag-2.eu a:before { background-position: -5376px 0; }
330
- .wg-li.flag-2.be a:before { background-position: -4224px 0; }
331
- .wg-li.flag-2.bg a:before { background-position: -5040px 0; }
332
- .wg-li.flag-2.bs a:before { background-position: -3984px 0; }
333
- .wg-li.flag-2.vi a:before { background-position: -144px 0; }
334
- .wg-li.flag-2.hu a:before { background-position: -2088px 0; }
335
- .wg-li.flag-2.ht a:before { background-position: -3528px 0; }
336
- .wg-li.flag-2.nl a:before { background-position: -1296px 0; }
337
- .wg-li.flag-2.el a:before { background-position: -2208px 0; }
338
- .wg-li.flag-2.ka a:before { background-position: -3744px 0; }
339
- .wg-li.flag-2.da a:before { background-position: -2448px 0; }
340
- .wg-li.flag-2.he a:before { background-position: -1992px 0; }
341
- .wg-li.flag-2.id a:before { background-position: -2040px 0; }
342
- .wg-li.flag-2.ga a:before { background-position: -2016px 0; }
343
- .wg-li.flag-2.it a:before { background-position: -1968px 0; }
344
- .wg-li.flag-2.is a:before { background-position: -2064px 0; }
345
- .wg-li.flag-2.es a:before { background-position: -96px 0; }
346
- .wg-li.flag-2.kk a:before { background-position: -1704px 0; }
347
- .wg-li.flag-2.ca a:before { background-position: -5352px 0; }
348
- .wg-li.flag-2.ky a:before { background-position: -1800px 0; }
349
- .wg-li.flag-2.zh a:before { background-position: -2592px 0; }
350
- .wg-li.flag-2.tw a:before { background-position: -3408px 0; }
351
- .wg-li.flag-2.ko a:before { background-position: -1848px 0; }
352
- .wg-li.flag-2.lv a:before { background-position: -1752px 0; }
353
- .wg-li.flag-2.lt a:before { background-position: -1656px 0; }
354
- .wg-li.flag-2.mg a:before { background-position: -1560px 0; }
355
- .wg-li.flag-2.ms a:before { background-position: -1536px 0; }
356
- .wg-li.flag-2.mt a:before { background-position: -1200px 0; }
357
- .wg-li.flag-2.mk a:before { background-position: -1440px 0; }
358
- .wg-li.flag-2.mn a:before { background-position: -4800px 0; }
359
- .wg-li.flag-2.de a:before { background-position: -2256px 0; }
360
- .wg-li.flag-2.no a:before { background-position: -4776px 0; }
361
- .wg-li.flag-2.fa a:before { background-position: -5088px 0; }
362
- .wg-li.flag-2.pl a:before { background-position: -984px 0; }
363
- .wg-li.flag-2.pt a:before { background-position: -2784px 0; }
364
- .wg-li.flag-2.ro a:before { background-position: -960px 0; }
365
- .wg-li.flag-2.ru a:before { background-position: -936px 0; }
366
- .wg-li.flag-2.sr a:before { background-position: -3120px 0; }
367
- .wg-li.flag-2.sk a:before { background-position: -4152px 0; }
368
- .wg-li.flag-2.sl a:before { background-position: -696px 0; }
369
- .wg-li.flag-2.sw a:before { background-position: -1872px 0; }
370
- .wg-li.flag-2.tg a:before { background-position: -264px 0; }
371
- .wg-li.flag-2.th a:before { background-position: -456px 0; }
372
- .wg-li.flag-2.tr a:before { background-position: -360px 0; }
373
- .wg-li.flag-2.uz a:before { background-position: -240px 0; }
374
- .wg-li.flag-2.uk a:before { background-position: -288px 0; }
375
- .wg-li.flag-2.fi a:before { background-position: -2328px 0; }
376
- .wg-li.flag-2.fr a:before { background-position: -2304px 0; }
377
- .wg-li.flag-2.hr a:before { background-position: -4416px 0; }
378
- .wg-li.flag-2.cs a:before { background-position: -2472px 0; }
379
- .wg-li.flag-2.sv a:before { background-position: -552px 0; }
380
- .wg-li.flag-2.et a:before { background-position: -2424px 0; }
381
- .wg-li.flag-2.ja a:before { background-position: -1920px 0; }
382
- .wg-li.flag-2.hi a:before { background-position: -1728px 0; }
383
- .wg-li.flag-2.ur a:before { background-position: -1128px 0; }
384
- .wg-li.flag-2.bn a:before { background-position: -4056px 0; }
385
- .wg-li.flag-2.fj a:before { background-position: -576px 0; }
386
- .wg-li.flag-2.sm a:before { background-position: -3408px 0; }
387
- .wg-li.flag-2.ty a:before { background-position: -4512px 0; }
388
- .wg-li.flag-2.to a:before { background-position: -3264px 0; }
389
- .wg-li.flag-2.cy a:before { background-position: -4848px 0; }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
390
 
391
  .wg-flags.flag-3 a:before {
392
  background-image: url("../images/circular_flag.png");
@@ -395,70 +519,109 @@
395
  height: 24px;
396
  }
397
 
 
398
  .wg-li.flag-3.sq a:before { background-position: -4776px 0; }
399
- .wg-li.flag-3.en a:before { background-position: -2520px 0; }
400
  .wg-li.flag-3.ar a:before { background-position: -3336px 0; }
401
  .wg-li.flag-3.hy a:before { background-position: -4632px 0; }
402
  .wg-li.flag-3.az a:before { background-position: -4536px 0; }
403
- .wg-li.flag-3.af a:before { background-position: -5496px 0; }
404
  .wg-li.flag-3.eu a:before { background-position: -5808px 0; }
405
  .wg-li.flag-3.be a:before { background-position: -144px 0; }
406
- .wg-li.flag-3.bg a:before { background-position: -4296px 0; }
407
  .wg-li.flag-3.bs a:before { background-position: -4392px 0; }
408
- .wg-li.flag-3.vi a:before { background-position: -3384px 0; }
409
- .wg-li.flag-3.hu a:before { background-position: -1920px 0; }
410
- .wg-li.flag-3.ht a:before { background-position: -5160px 0; }
 
 
 
 
 
 
 
 
411
  .wg-li.flag-3.nl a:before { background-position: -3360px 0; }
412
- .wg-li.flag-3.el a:before { background-position: -1416px 0; }
 
 
 
 
 
 
413
  .wg-li.flag-3.ka a:before { background-position: -1536px 0; }
414
- .wg-li.flag-3.da a:before { background-position: -3024px 0; }
 
 
 
 
415
  .wg-li.flag-3.he a:before { background-position: -1608px 0; }
 
 
 
 
416
  .wg-li.flag-3.id a:before { background-position: -4992px 0; }
417
  .wg-li.flag-3.ga a:before { background-position: -2016px 0; }
418
  .wg-li.flag-3.it a:before { background-position: -336px 0; }
419
- .wg-li.flag-3.is a:before { background-position: -840px 0; }
420
- .wg-li.flag-3.es a:before { background-position: -3576px 0; }
 
421
  .wg-li.flag-3.kk a:before { background-position: -3912px 0; }
422
- .wg-li.flag-3.ca a:before { background-position: -5784px 0; }
423
- .wg-li.flag-3.ky a:before { background-position: -744px 0; }
424
- .wg-li.flag-3.zh a:before { background-position: -3240px 0; }
425
- .wg-li.flag-3.tw a:before { background-position: -4008px 0; }
426
  .wg-li.flag-3.ko a:before { background-position: -2256px 0; }
 
 
 
 
427
  .wg-li.flag-3.lv a:before { background-position: -216px 0; }
428
  .wg-li.flag-3.lt a:before { background-position: -1776px 0; }
 
 
429
  .wg-li.flag-3.mg a:before { background-position: -5064px 0; }
430
  .wg-li.flag-3.ms a:before { background-position: -864px 0; }
 
431
  .wg-li.flag-3.mt a:before { background-position: -4920px 0; }
432
- .wg-li.flag-3.mk a:before { background-position: -2208px 0; }
 
433
  .wg-li.flag-3.mn a:before { background-position: -24px 0; }
434
- .wg-li.flag-3.de a:before { background-position: -1488px 0; }
435
  .wg-li.flag-3.no a:before { background-position: -984px 0; }
 
436
  .wg-li.flag-3.fa a:before { background-position: -816px 0; }
437
  .wg-li.flag-3.pl a:before { background-position: -4944px 0; }
438
  .wg-li.flag-3.pt a:before { background-position: -4344px 0; }
 
439
  .wg-li.flag-3.ro a:before { background-position: -3744px 0; }
440
  .wg-li.flag-3.ru a:before { background-position: -2664px 0; }
 
 
441
  .wg-li.flag-3.sr a:before { background-position: -3312px 0; }
 
 
 
442
  .wg-li.flag-3.sk a:before { background-position: -552px 0; }
443
  .wg-li.flag-3.sl a:before { background-position: -936px 0; }
 
 
 
 
444
  .wg-li.flag-3.sw a:before { background-position: -912px 0; }
 
 
 
445
  .wg-li.flag-3.tg a:before { background-position: -3720px 0; }
 
 
 
446
  .wg-li.flag-3.th a:before { background-position: -4848px 0; }
 
447
  .wg-li.flag-3.tr a:before { background-position: -432px 0; }
448
- .wg-li.flag-3.uz a:before { background-position: -2160px 0; }
449
  .wg-li.flag-3.uk a:before { background-position: -5736px 0; }
450
- .wg-li.flag-3.fi a:before { background-position: -2784px 0; }
451
- .wg-li.flag-3.fr a:before { background-position: -2760px 0; }
452
- .wg-li.flag-3.hr a:before { background-position: -3048px 0; }
453
- .wg-li.flag-3.cs a:before { background-position: -5280px 0; }
454
- .wg-li.flag-3.sv a:before { background-position: -264px 0; }
455
- .wg-li.flag-3.et a:before { background-position: -2856px 0; }
456
- .wg-li.flag-3.ja a:before { background-position: -2448px 0; }
457
- .wg-li.flag-3.hi a:before { background-position: -2304px 0; }
458
  .wg-li.flag-3.ur a:before { background-position: -1992px 0; }
459
- .wg-li.flag-3.bn a:before { background-position: -4488px 0; }
460
- .wg-li.flag-3.fj a:before { background-position: -0px 0; }
461
- .wg-li.flag-3.sm a:before { background-position: -1248px 0; }
462
- .wg-li.flag-3.ty a:before { background-position: -1512px 0; }
463
- .wg-li.flag-3.to a:before { background-position: -1680px 0; }
464
- .wg-li.flag-3.cy a:before { background-position: -5040px 0; }
 
 
169
  height: 20px;
170
  }
171
 
172
+ .wg-li.af a:before { background-position: -6570px 0; }
173
  .wg-li.sq a:before { background-position: -2580px 0; }
174
+ .wg-li.am a:before { background-position: -5130px 0; }
175
  .wg-li.ar a:before { background-position: -510px 0; }
176
  .wg-li.hy a:before { background-position: -2880px 0; }
177
  .wg-li.az a:before { background-position: -6840px 0; }
178
+ .wg-li.ba a:before { background-position: -2040px 0; }
179
+ .wg-li.eu a:before { background-position: -7260px 0; }
180
  .wg-li.be a:before { background-position: -5310px 0; }
181
+ .wg-li.bn a:before { background-position: -5400px 0; }
182
  .wg-li.bs a:before { background-position: -6390px 0; }
183
+ .wg-li.bg a:before { background-position: -2730px 0; }
184
+ .wg-li.my a:before { background-position: -3299px 0; }
185
+ .wg-li.ca a:before { background-position: -7230px 0; }
186
+ .wg-li.zh a:before { background-position: -3690px 0; }
187
+ .wg-li.tw a:before { background-position: -2970px 0; }
188
+ .wg-li.km a:before { background-position: -6930px 0; }
189
+ .wg-li.ny a:before { background-position: -1140px 0; }
190
+ .wg-li.co a:before { background-position: -2520px 0; } /* a faire */
191
+ .wg-li.hr a:before { background-position: -5910px 0; }
192
+ .wg-li.cs a:before { background-position: -2700px 0; }
193
+ .wg-li.da a:before { background-position: -2670px 0; }
194
  .wg-li.nl a:before { background-position: -2100px 0; }
195
+ .wg-li.en a:before { background-position: -1920px 0; }
196
+ .wg-li.eo a:before { background-position: -1920px 0; } /* a faire */
197
+ .wg-li.et a:before { background-position: -2640px 0; }
198
+ .wg-li.fj a:before { background-position: -1710px 0; }
199
+ .wg-li.fi a:before { background-position: -2550px 0; }
200
+ .wg-li.fr a:before { background-position: -2520px 0; }
201
+ .wg-li.gl a:before { background-position: -480px 0; }
202
  .wg-li.ka a:before { background-position: -5040px 0; }
203
+ .wg-li.de a:before { background-position: -2490px 0; }
204
+ .wg-li.el a:before { background-position: -2460px 0; }
205
+ .wg-li.gu a:before { background-position: -1170px 0; }
206
+ .wg-li.ht a:before { background-position: -4650px 0; }
207
+ .wg-li.ha a:before { background-position: -900px 0; }
208
  .wg-li.he a:before { background-position: -1050px 0; }
209
+ .wg-li.hi a:before { background-position: -1170px 0; }
210
+ .wg-li.hu a:before { background-position: -2430px 0; }
211
+ .wg-li.is a:before { background-position: -2400px 0; }
212
+ .wg-li.ig a:before { background-position: -870px 0; }
213
  .wg-li.id a:before { background-position: -3510px 0; }
214
  .wg-li.ga a:before { background-position: -2340px 0; }
215
  .wg-li.it a:before { background-position: -2310px 0; }
216
+ .wg-li.ja a:before { background-position: -3480px 0; }
217
+ .wg-li.jv a:before { background-position: -3360px 0; }
218
+ .wg-li.kn a:before { background-position: -1170px 0; }
219
  .wg-li.kk a:before { background-position: -3150px 0; }
 
 
 
 
220
  .wg-li.ko a:before { background-position: -6990px 0; }
221
+ .wg-li.ku a:before { background-position: -2430px 0; } /* a faire */
222
+ .wg-li.ky a:before { background-position: -3420px 0; }
223
+ .wg-li.lo a:before { background-position: -3450px 0; } /* a faire */
224
+ .wg-li.la a:before { background-position: -2310px 0; }
225
  .wg-li.lv a:before { background-position: -2280px 0; }
226
  .wg-li.lt a:before { background-position: -2250px 0; }
227
+ .wg-li.lb a:before { background-position: -2220px 0; }
228
+ .wg-li.mk a:before { background-position: -2190px 0; }
229
  .wg-li.mg a:before { background-position: -1200px 0; }
230
  .wg-li.ms a:before { background-position: -3360px 0; }
231
+ .wg-li.ml a:before { background-position: -1170px 0; }
232
  .wg-li.mt a:before { background-position: -2130px 0; }
233
+ .wg-li.mi a:before { background-position: -3240px 0; }
234
+ .wg-li.mr a:before { background-position: -1170px 0; }
235
  .wg-li.mn a:before { background-position: -6000px 0; }
236
+ .wg-li.ne a:before { background-position: -3270px 0; }
237
  .wg-li.no a:before { background-position: -5850px 0; }
238
+ .wg-li.ps a:before { background-position: -5189px 0; }
239
  .wg-li.fa a:before { background-position: -6690px 0; }
240
  .wg-li.pl a:before { background-position: -2160px 0; }
241
  .wg-li.pt a:before { background-position: -6630px 0; }
242
+ .wg-li.pa a:before { background-position: -3180px 0; }
243
  .wg-li.ro a:before { background-position: -2070px 0; }
244
  .wg-li.ru a:before { background-position: -2040px 0; }
245
+ .wg-li.sm a:before { background-position: -4620px 0; }
246
+ .wg-li.gd a:before { background-position: -30px 0; }
247
  .wg-li.sr a:before { background-position: -4290px 0; }
248
+ .wg-li.sn a:before { background-position: -540px 0; }
249
+ .wg-li.sd a:before { background-position: -3180px 0; }
250
+ .wg-li.si a:before { background-position: -2820px 0; }
251
  .wg-li.sk a:before { background-position: -6810px 0; }
252
  .wg-li.sl a:before { background-position: -2010px 0; }
253
+ .wg-li.so a:before { background-position: -4560px 0; }
254
+ .wg-li.st a:before { background-position: -4830px 0; }
255
+ .wg-li.es a:before { background-position: -480px 0; }
256
+ .wg-li.su a:before { background-position: -4530px 0; }
257
  .wg-li.sw a:before { background-position: -1290px 0; }
258
+ .wg-li.sv a:before { background-position: -1980px 0; }
259
+ .wg-li.tl a:before { background-position: -3060px 0; }
260
+ .wg-li.ty a:before { background-position: -6270px 0; }
261
  .wg-li.tg a:before { background-position: -2940px 0; }
262
+ .wg-li.ta a:before { background-position: -1170px 0; }
263
+ .wg-li.tt a:before { background-position: -2040px 0; }
264
+ .wg-li.te a:before { background-position: -1170px 0; }
265
  .wg-li.th a:before { background-position: -2910px 0; }
266
+ .wg-li.to a:before { background-position: -6540px 0; }
267
  .wg-li.tr a:before { background-position: -1950px 0; }
 
268
  .wg-li.uk a:before { background-position: -1890px 0; }
 
 
 
 
 
 
 
 
269
  .wg-li.ur a:before { background-position: -3180px 0; }
270
+ .wg-li.uz a:before { background-position: -2880px 0; }
271
+ .wg-li.vi a:before { background-position: -2850px 0; }
 
 
 
272
  .wg-li.cy a:before { background-position: -6420px 0; }
273
+ .wg-li.fy a:before { background-position: -2100px 0; }
274
+ .wg-li.xh a:before { background-position: -6570px 0; }
275
+ .wg-li.yi a:before { background-position: -1050px 0; }
276
+ .wg-li.yo a:before { background-position: -870px 0; }
277
+ .wg-li.zu a:before { background-position: -6570px 0; }
278
+
279
+
280
+
281
+
282
+
283
+
284
+
285
 
286
  .wg-flags.flag-1 a:before {
287
  background-image: url("../images/rect_bright.png");
290
  height: 20px;
291
  }
292
 
293
+ .wg-li.flag-1.af a:before { background-position: -6848px 0; }
294
+ .wg-li.flag-1.sq a:before { background-position: -97px 0; }
295
+ .wg-li.flag-1.am a:before { background-position: -2369px 0; }
296
+ .wg-li.flag-1.ar a:before { background-position: -6465px 0; }
297
+ .wg-li.flag-1.hy a:before { background-position: -385px 0; }
298
+ .wg-li.flag-1.az a:before { background-position: -513px 0; }
299
+ .wg-li.flag-1.ba a:before { background-position: -6113px 0; }
300
+ .wg-li.flag-1.eu a:before { background-position: -8353px 0; }
301
+ .wg-li.flag-1.be a:before { background-position: -705px 0; }
302
+ .wg-li.flag-1.bn a:before { background-position: -609px 0; }
303
+ .wg-li.flag-1.bs a:before { background-position: -929px 0; }
304
+ .wg-li.flag-1.bg a:before { background-position: -1121px 0; }
305
+ .wg-li.flag-1.my a:before { background-position: -4929px 0; }
306
+ .wg-li.flag-1.ca a:before { background-position: -8321px 0; }
307
+ .wg-li.flag-1.zh a:before { background-position: -1505px 0; }
308
+ .wg-li.flag-1.tw a:before { background-position: -6369px 0; }
309
+ .wg-li.flag-1.km a:before { background-position: -1217px 0; }
310
+ .wg-li.flag-1.ny a:before { background-position: -4289px 0; }
311
+ .wg-li.flag-1.co a:before { background-position: -2561px 0; }
312
+ .wg-li.flag-1.hr a:before { background-position: -1793px 0; }
313
+ .wg-li.flag-1.cs a:before { background-position: -1921px 0; }
314
+ .wg-li.flag-1.da a:before { background-position: -1985px 0; }
315
+ .wg-li.flag-1.nl a:before { background-position: -5121px 0; }
316
+ .wg-li.flag-1.en a:before { background-position: -7777px 0; }
317
+ .wg-li.flag-1.eo a:before { background-position: -7777px 0; }
318
+ .wg-li.flag-1.et a:before { background-position: -2337px 0; }
319
+ .wg-li.flag-1.fj a:before { background-position: -2497px 0; }
320
+ .wg-li.flag-1.fi a:before { background-position: -2529px 0; }
321
+ .wg-li.flag-1.fr a:before { background-position: -2561px 0; }
322
+ .wg-li.flag-1.gl a:before { background-position: -7009px 0; }
323
+ .wg-li.flag-1.ka a:before { background-position: -2721px 0; }
324
+ .wg-li.flag-1.de a:before { background-position: -2753px 0; }
325
+ .wg-li.flag-1.el a:before { background-position: -2881px 0; }
326
+ .wg-li.flag-1.gu a:before { background-position: -3329px 0; }
327
+ .wg-li.flag-1.ht a:before { background-position: -3169px 0; }
328
+ .wg-li.flag-1.ha a:before { background-position: -5281px 0; }
329
+ .wg-li.flag-1.he a:before { background-position: -3521px 0; }
330
+ .wg-li.flag-1.hi a:before { background-position: -3329px 0; }
331
+ .wg-li.flag-1.hu a:before { background-position: -3265px 0; }
332
+ .wg-li.flag-1.is a:before { background-position: -3297px 0; }
333
+ .wg-li.flag-1.ig a:before { background-position: -5313px 0; }
334
+ .wg-li.flag-1.id a:before { background-position: -3361px 0; }
335
+ .wg-li.flag-1.ga a:before { background-position: -3457px 0; }
336
+ .wg-li.flag-1.it a:before { background-position: -3553px 0; }
337
+ .wg-li.flag-1.ja a:before { background-position: -3617px 0; }
338
+ .wg-li.flag-1.jv a:before { background-position: -4321px 0; }
339
+ .wg-li.flag-1.kn a:before { background-position: -3329px 0; }
340
+ .wg-li.flag-1.kk a:before { background-position: -3713px 0; }
341
+ .wg-li.flag-1.ko a:before { background-position: -6913px 0; }
342
+ .wg-li.flag-1.ku a:before { background-position: -3265px 0; }
343
+ .wg-li.flag-1.ky a:before { background-position: -3873px 0; }
344
+ .wg-li.flag-1.lo a:before { background-position: -3904px 0; }
345
+ .wg-li.flag-1.la a:before { background-position: -3553px 0; }
346
+ .wg-li.flag-1.lv a:before { background-position: -3937px 0; }
347
+ .wg-li.flag-1.lt a:before { background-position: -4129px 0; }
348
+ .wg-li.flag-1.lb a:before { background-position: -4161px 0; }
349
+ .wg-li.flag-1.mk a:before { background-position: -4225px 0; }
350
+ .wg-li.flag-1.mg a:before { background-position: -4257px 0; }
351
+ .wg-li.flag-1.ms a:before { background-position: -4321px 0; }
352
+ .wg-li.flag-1.ml a:before { background-position: -3329px 0; }
353
+ .wg-li.flag-1.mt a:before { background-position: -4417px 0; }
354
+ .wg-li.flag-1.mi a:before { background-position: -5217px 0; }
355
+ .wg-li.flag-1.mr a:before { background-position: -3329px 0; }
356
+ .wg-li.flag-1.mn a:before { background-position: -4769px 0; }
357
+ .wg-li.flag-1.ne a:before { background-position: -5091px 0; }
358
+ .wg-li.flag-1.no a:before { background-position: -5505px 0; }
359
+ .wg-li.flag-1.ps a:before { background-position: -33px 0; }
360
+ .wg-li.flag-1.fa a:before { background-position: -3393px 0; }
361
+ .wg-li.flag-1.pl a:before { background-position: -5889px 0; }
362
+ .wg-li.flag-1.pt a:before { background-position: -993px 0; }
363
+ .wg-li.flag-1.pa a:before { background-position: -3329px 0; }
364
+ .wg-li.flag-1.ro a:before { background-position: -6081px 0; }
365
+ .wg-li.flag-1.ru a:before { background-position: -6113px 0; }
366
+ .wg-li.flag-1.sm a:before { background-position: -6369px 0; }
367
+ .wg-li.flag-1.gd a:before { background-position: -6497px 0; }
368
+ .wg-li.flag-1.sr a:before { background-position: -6561px 0; }
369
+ .wg-li.flag-1.sn a:before { background-position: -8287px 0; }
370
+ .wg-li.flag-1.sd a:before { background-position: -5601px 0; }
371
+ .wg-li.flag-1.si a:before { background-position: -7039px 0; }
372
+ .wg-li.flag-1.sk a:before { background-position: -6689px 0; }
373
+ .wg-li.flag-1.sl a:before { background-position: -6721px 0; }
374
+ .wg-li.flag-1.so a:before { background-position: -6785px 0; }
375
+ .wg-li.flag-1.st a:before { background-position: -4001px 0; }
376
+ .wg-li.flag-1.es a:before { background-position: -7009px 0; }
377
+ .wg-li.flag-1.su a:before { background-position: -7073px 0; }
378
+ .wg-li.flag-1.sw a:before { background-position: -3745px 0; }
379
+ .wg-li.flag-1.sv a:before { background-position: -7169px 0; }
380
+ .wg-li.flag-1.tl a:before { background-position: -5823px 0; }
381
+ .wg-li.flag-1.ty a:before { background-position: -2593px 0; }
382
+ .wg-li.flag-1.tg a:before { background-position: -7297px 0; }
383
+ .wg-li.flag-1.ta a:before { background-position: -3329px 0; }
384
+ .wg-li.flag-1.tt a:before { background-position: -6113px 0; }
385
+ .wg-li.flag-1.te a:before { background-position: -3329px 0; }
386
+ .wg-li.flag-1.th a:before { background-position: -7361px 0; }
387
+ .wg-li.flag-1.to a:before { background-position: -7456px 0; }
388
+ .wg-li.flag-1.tr a:before { background-position: -7553px 0; }
389
+ .wg-li.flag-1.uk a:before { background-position: -7713px 0; }
390
+ .wg-li.flag-1.ur a:before { background-position: -5600px 0; }
391
+ .wg-li.flag-1.uz a:before { background-position: -7969px 0; }
392
+ .wg-li.flag-1.vi a:before { background-position: -8097px 0; }
393
+ .wg-li.flag-1.cy a:before { background-position: -8129px 0; }
394
+ .wg-li.flag-1.fy a:before { background-position: -5121px 0; }
395
+ .wg-li.flag-1.xh a:before { background-position: -6848px 0; }
396
+ .wg-li.flag-1.yi a:before { background-position: -3521px 0; }
397
+ .wg-li.flag-1.yo a:before { background-position: -5313px 0; }
398
+ .wg-li.flag-1.zu a:before { background-position: -6848px 0; }
399
+
400
 
401
  .wg-flags.flag-2 a:before {
402
  background-image: url("../images/square_flag.png");
405
  height: 24px;
406
  }
407
 
408
+ .wg-li.flag-2.af a:before { background-position: -4968px 0; }
409
+ .wg-li.flag-2.sq a:before { background-position: -2976px 0; }
410
+ .wg-li.flag-2.am a:before { background-position: -3816px 0; }
411
+ .wg-li.flag-2.ar a:before { background-position: -768px 0; }
412
+ .wg-li.flag-2.hy a:before { background-position: 0 0; }
413
+ .wg-li.flag-2.az a:before { background-position: -5136px 0; }
414
+ .wg-li.flag-2.ba a:before { background-position: -936px 0; }
415
+ .wg-li.flag-2.eu a:before { background-position: -5376px 0; }
416
+ .wg-li.flag-2.be a:before { background-position: -4224px 0; }
417
+ .wg-li.flag-2.bn a:before { background-position: -4056px 0; }
418
+ .wg-li.flag-2.bs a:before { background-position: -3984px 0; }
419
+ .wg-li.flag-2.bg a:before { background-position: -5040px 0; }
420
+ .wg-li.flag-2.my a:before { background-position: -1248px 0; }
421
+ .wg-li.flag-2.ca a:before { background-position: -5352px 0; }
422
+ .wg-li.flag-2.zh a:before { background-position: -2592px 0; }
423
+ .wg-li.flag-2.tw a:before { background-position: -3408px 0; }
424
+ .wg-li.flag-2.km a:before { background-position: -5160px 0; }
425
+ .wg-li.flag-2.ny a:before { background-position: -1392px 0; }
426
+ .wg-li.flag-2.co a:before { background-position: -2304px 0; }
427
+ .wg-li.flag-2.hr a:before { background-position: -4416px 0; }
428
+ .wg-li.flag-2.cs a:before { background-position: -2472px 0; }
429
+ .wg-li.flag-2.da a:before { background-position: -2448px 0; }
430
+ .wg-li.flag-2.nl a:before { background-position: -1296px 0; }
431
+ .wg-li.flag-2.en a:before { background-position: -312px 0; }
432
+ .wg-li.flag-2.eo a:before { background-position: -312px 0; } /* a faire */
433
+ .wg-li.flag-2.et a:before { background-position: -2424px 0; }
434
+ .wg-li.flag-2.fj a:before { background-position: -576px 0; }
435
+ .wg-li.flag-2.fi a:before { background-position: -2328px 0; }
436
+ .wg-li.flag-2.fr a:before { background-position: -2304px 0; }
437
+ .wg-li.flag-2.gl a:before { background-position: -96px 0; }
438
+ .wg-li.flag-2.ka a:before { background-position: -3744px 0; }
439
+ .wg-li.flag-2.de a:before { background-position: -2256px 0; }
440
+ .wg-li.flag-2.el a:before { background-position: -2208px 0; }
441
+ .wg-li.flag-2.gu a:before { background-position: -1728px 0; }
442
+ .wg-li.flag-2.ht a:before { background-position: -3528px 0; }
443
+ .wg-li.flag-2.ha a:before { background-position: -1176px 0; }
444
+ .wg-li.flag-2.he a:before { background-position: -1992px 0; }
445
+ .wg-li.flag-2.hi a:before { background-position: -1728px 0; }
446
+ .wg-li.flag-2.hu a:before { background-position: -2088px 0; }
447
+ .wg-li.flag-2.is a:before { background-position: -2064px 0; }
448
+ .wg-li.flag-2.ig a:before { background-position: -1103px 0; }
449
+ .wg-li.flag-2.id a:before { background-position: -2040px 0; }
450
+ .wg-li.flag-2.ga a:before { background-position: -2016px 0; }
451
+ .wg-li.flag-2.it a:before { background-position: -1968px 0; }
452
+ .wg-li.flag-2.ja a:before { background-position: -1920px 0; }
453
+ .wg-li.flag-2.jv a:before { background-position: -1536px 0; }
454
+ .wg-li.flag-2.kn a:before { background-position: -1728px 0; }
455
+ .wg-li.flag-2.kk a:before { background-position: -1704px 0; }
456
+ .wg-li.flag-2.ko a:before { background-position: -1848px 0; }
457
+ .wg-li.flag-2.ku a:before { background-position: -2088px 0; }
458
+ .wg-li.flag-2.ky a:before { background-position: -1800px 0; }
459
+ .wg-li.flag-2.lo a:before { background-position: -1776px 0; }
460
+ .wg-li.flag-2.la a:before { background-position: -1968px 0; }
461
+ .wg-li.flag-2.lv a:before { background-position: -1752px 0; }
462
+ .wg-li.flag-2.lt a:before { background-position: -1656px 0; }
463
+ .wg-li.flag-2.lb a:before { background-position: -1632px 0; }
464
+ .wg-li.flag-2.mk a:before { background-position: -1440px 0; }
465
+ .wg-li.flag-2.mg a:before { background-position: -1560px 0; }
466
+ .wg-li.flag-2.ms a:before { background-position: -1536px 0; }
467
+ .wg-li.flag-2.ml a:before { background-position: -1728px 0; }
468
+ .wg-li.flag-2.mt a:before { background-position: -1200px 0; }
469
+ .wg-li.flag-2.mi a:before { background-position: -1224px 0; }
470
+ .wg-li.flag-2.mr a:before { background-position: -1728px 0; }
471
+ .wg-li.flag-2.mn a:before { background-position: -4800px 0; }
472
+ .wg-li.flag-2.ne a:before { background-position: -1320px 0; }
473
+ .wg-li.flag-2.no a:before { background-position: -4776px 0; }
474
+ .wg-li.flag-2.ps a:before { background-position: -4008px 0; }
475
+ .wg-li.flag-2.fa a:before { background-position: -5088px 0; }
476
+ .wg-li.flag-2.pl a:before { background-position: -984px 0; }
477
+ .wg-li.flag-2.pt a:before { background-position: -2784px 0; }
478
+ .wg-li.flag-2.pa a:before { background-position: -1728px 0; }
479
+ .wg-li.flag-2.ro a:before { background-position: -960px 0; }
480
+ .wg-li.flag-2.ru a:before { background-position: -936px 0; }
481
+ .wg-li.flag-2.sm a:before { background-position: -3408px 0; }
482
+ .wg-li.flag-2.gd a:before { background-position: -4872px 0; }
483
+ .wg-li.flag-2.sr a:before { background-position: -3120px 0; }
484
+ .wg-li.flag-2.sn a:before { background-position: -72px 0; }
485
+ .wg-li.flag-2.sd a:before { background-position: -1128px 0; }
486
+ .wg-li.flag-2.si a:before { background-position: -480px 0; }
487
+ .wg-li.flag-2.sk a:before { background-position: -4152px 0; }
488
+ .wg-li.flag-2.sl a:before { background-position: -696px 0; }
489
+ .wg-li.flag-2.so a:before { background-position: -3336px 0; }
490
+ .wg-li.flag-2.st a:before { background-position: -3552px 0; }
491
+ .wg-li.flag-2.es a:before { background-position: -96px 0; }
492
+ .wg-li.flag-2.su a:before { background-position: -3312px 0; }
493
+ .wg-li.flag-2.sw a:before { background-position: -1872px 0; }
494
+ .wg-li.flag-2.sv a:before { background-position: -552px 0; }
495
+ .wg-li.flag-2.tl a:before { background-position: -1008px 0; }
496
+ .wg-li.flag-2.ty a:before { background-position: -4512px 0; }
497
+ .wg-li.flag-2.tg a:before { background-position: -264px 0; }
498
+ .wg-li.flag-2.ta a:before { background-position: -1728px 0; }
499
+ .wg-li.flag-2.tt a:before { background-position: -936px 0; }
500
+ .wg-li.flag-2.te a:before { background-position: -1728px 0; }
501
+ .wg-li.flag-2.th a:before { background-position: -456px 0; }
502
+ .wg-li.flag-2.to a:before { background-position: -3264px 0; }
503
+ .wg-li.flag-2.tr a:before { background-position: -360px 0; }
504
+ .wg-li.flag-2.uk a:before { background-position: -288px 0; }
505
+ .wg-li.flag-2.ur a:before { background-position: -1128px 0; }
506
+ .wg-li.flag-2.uz a:before { background-position: -240px 0; }
507
+ .wg-li.flag-2.vi a:before { background-position: -144px 0; }
508
+ .wg-li.flag-2.cy a:before { background-position: -4848px 0; }
509
+ .wg-li.flag-2.fy a:before { background-position: -1296px 0; }
510
+ .wg-li.flag-2.xh a:before { background-position: -4968px 0; }
511
+ .wg-li.flag-2.yi a:before { background-position: -1992px 0; }
512
+ .wg-li.flag-2.yo a:before { background-position: -1103px 0; }
513
+ .wg-li.flag-2.zu a:before { background-position: -4968px 0; }
514
 
515
  .wg-flags.flag-3 a:before {
516
  background-image: url("../images/circular_flag.png");
519
  height: 24px;
520
  }
521
 
522
+ .wg-li.flag-3.af a:before { background-position: -5496px 0; }
523
  .wg-li.flag-3.sq a:before { background-position: -4776px 0; }
524
+ .wg-li.flag-3.am a:before { background-position: -192px 0; }
525
  .wg-li.flag-3.ar a:before { background-position: -3336px 0; }
526
  .wg-li.flag-3.hy a:before { background-position: -4632px 0; }
527
  .wg-li.flag-3.az a:before { background-position: -4536px 0; }
528
+ .wg-li.flag-3.ba a:before { background-position: -2664px 0; }
529
  .wg-li.flag-3.eu a:before { background-position: -5808px 0; }
530
  .wg-li.flag-3.be a:before { background-position: -144px 0; }
531
+ .wg-li.flag-3.bn a:before { background-position: -4488px 0; }
532
  .wg-li.flag-3.bs a:before { background-position: -4392px 0; }
533
+ .wg-li.flag-3.bg a:before { background-position: -4296px 0; }
534
+ .wg-li.flag-3.my a:before { background-position: -3769px 0; }
535
+ .wg-li.flag-3.ca a:before { background-position: -5784px 0; }
536
+ .wg-li.flag-3.zh a:before { background-position: -3240px 0; }
537
+ .wg-li.flag-3.tw a:before { background-position: -4008px 0; }
538
+ .wg-li.flag-3.km a:before { background-position: -4201px 0; }
539
+ .wg-li.flag-3.ny a:before { background-position: -384px 0; }
540
+ .wg-li.flag-3.co a:before { background-position: -2760px 0; } /* a faire */
541
+ .wg-li.flag-3.hr a:before { background-position: -3048px 0; }
542
+ .wg-li.flag-3.cs a:before { background-position: -5280px 0; }
543
+ .wg-li.flag-3.da a:before { background-position: -3024px 0; }
544
  .wg-li.flag-3.nl a:before { background-position: -3360px 0; }
545
+ .wg-li.flag-3.en a:before { background-position: -2520px 0; }
546
+ .wg-li.flag-3.eo a:before { background-position: -2520px 0; } /* a faire */
547
+ .wg-li.flag-3.et a:before { background-position: -2856px 0; }
548
+ .wg-li.flag-3.fj a:before { background-position: -0px 0; }
549
+ .wg-li.flag-3.fi a:before { background-position: -2784px 0; }
550
+ .wg-li.flag-3.fr a:before { background-position: -2760px 0; }
551
+ .wg-li.flag-3.gl a:before { background-position: -3576px 0; }
552
  .wg-li.flag-3.ka a:before { background-position: -1536px 0; }
553
+ .wg-li.flag-3.de a:before { background-position: -1488px 0; }
554
+ .wg-li.flag-3.el a:before { background-position: -1416px 0; }
555
+ .wg-li.flag-3.gu a:before { background-position: -2304px 0; }
556
+ .wg-li.flag-3.ht a:before { background-position: -5160px 0; }
557
+ .wg-li.flag-3.ha a:before { background-position: -361px 0; }
558
  .wg-li.flag-3.he a:before { background-position: -1608px 0; }
559
+ .wg-li.flag-3.hi a:before { background-position: -2304px 0; }
560
+ .wg-li.flag-3.hu a:before { background-position: -1920px 0; }
561
+ .wg-li.flag-3.is a:before { background-position: -840px 0; }
562
+ .wg-li.flag-3.ig a:before { background-position: -3457px 0; }
563
  .wg-li.flag-3.id a:before { background-position: -4992px 0; }
564
  .wg-li.flag-3.ga a:before { background-position: -2016px 0; }
565
  .wg-li.flag-3.it a:before { background-position: -336px 0; }
566
+ .wg-li.flag-3.ja a:before { background-position: -2448px 0; }
567
+ .wg-li.flag-3.jv a:before { background-position: -864px 0; }
568
+ .wg-li.flag-3.kn a:before { background-position: -2304px 0; }
569
  .wg-li.flag-3.kk a:before { background-position: -3912px 0; }
 
 
 
 
570
  .wg-li.flag-3.ko a:before { background-position: -2256px 0; }
571
+ .wg-li.flag-3.ku a:before { background-position: -1920px 0; }
572
+ .wg-li.flag-3.ky a:before { background-position: -744px 0; }
573
+ .wg-li.flag-3.lo a:before { background-position: -3816px 0; }
574
+ .wg-li.flag-3.la a:before { background-position: -336px 0; }
575
  .wg-li.flag-3.lv a:before { background-position: -216px 0; }
576
  .wg-li.flag-3.lt a:before { background-position: -1776px 0; }
577
+ .wg-li.flag-3.lb a:before { background-position: -1945px 0; }
578
+ .wg-li.flag-3.mk a:before { background-position: -2208px 0; }
579
  .wg-li.flag-3.mg a:before { background-position: -5064px 0; }
580
  .wg-li.flag-3.ms a:before { background-position: -864px 0; }
581
+ .wg-li.flag-3.ml a:before { background-position: -2304px 0; }
582
  .wg-li.flag-3.mt a:before { background-position: -4920px 0; }
583
+ .wg-li.flag-3.mi a:before { background-position: -2113px 0; }
584
+ .wg-li.flag-3.mr a:before { background-position: -2304px 0; }
585
  .wg-li.flag-3.mn a:before { background-position: -24px 0; }
586
+ .wg-li.flag-3.ne a:before { background-position: -5642px 0; }
587
  .wg-li.flag-3.no a:before { background-position: -984px 0; }
588
+ .wg-li.flag-3.ps a:before { background-position: -4753px 0; }
589
  .wg-li.flag-3.fa a:before { background-position: -816px 0; }
590
  .wg-li.flag-3.pl a:before { background-position: -4944px 0; }
591
  .wg-li.flag-3.pt a:before { background-position: -4344px 0; }
592
+ .wg-li.flag-3.pa a:before { background-position: -2304px 0; }
593
  .wg-li.flag-3.ro a:before { background-position: -3744px 0; }
594
  .wg-li.flag-3.ru a:before { background-position: -2664px 0; }
595
+ .wg-li.flag-3.sm a:before { background-position: -1248px 0; }
596
+ .wg-li.flag-3.gd a:before { background-position: -3841px 0; }
597
  .wg-li.flag-3.sr a:before { background-position: -3312px 0; }
598
+ .wg-li.flag-3.sn a:before { background-position: -5521px 0; }
599
+ .wg-li.flag-3.sd a:before { background-position: -1993px 0; }
600
+ .wg-li.flag-3.si a:before { background-position: -2833px 0; } /* a faire */
601
  .wg-li.flag-3.sk a:before { background-position: -552px 0; }
602
  .wg-li.flag-3.sl a:before { background-position: -936px 0; }
603
+ .wg-li.flag-3.so a:before { background-position: -4032px 0; }
604
+ .wg-li.flag-3.st a:before { background-position: -3961px 0; }
605
+ .wg-li.flag-3.es a:before { background-position: -3576px 0; }
606
+ .wg-li.flag-3.su a:before { background-position: -3985px 0; }
607
  .wg-li.flag-3.sw a:before { background-position: -912px 0; }
608
+ .wg-li.flag-3.sv a:before { background-position: -264px 0; }
609
+ .wg-li.flag-3.tl a:before { background-position: -5232px 0; }
610
+ .wg-li.flag-3.ty a:before { background-position: -1512px 0; }
611
  .wg-li.flag-3.tg a:before { background-position: -3720px 0; }
612
+ .wg-li.flag-3.ta a:before { background-position: -2304px 0; }
613
+ .wg-li.flag-3.tt a:before { background-position: -2664px 0; }
614
+ .wg-li.flag-3.te a:before { background-position: -2304px 0; }
615
  .wg-li.flag-3.th a:before { background-position: -4848px 0; }
616
+ .wg-li.flag-3.to a:before { background-position: -1680px 0; }
617
  .wg-li.flag-3.tr a:before { background-position: -432px 0; }
 
618
  .wg-li.flag-3.uk a:before { background-position: -5736px 0; }
 
 
 
 
 
 
 
 
619
  .wg-li.flag-3.ur a:before { background-position: -1992px 0; }
620
+ .wg-li.flag-3.uz a:before { background-position: -2160px 0; }
621
+ .wg-li.flag-3.vi a:before { background-position: -3384px 0; }
622
+ .wg-li.flag-3.cy a:before { background-position: -5040px 0; }
623
+ .wg-li.flag-3.fy a:before { background-position: -3360px 0; }
624
+ .wg-li.flag-3.xh a:before { background-position: -5496px 0; }
625
+ .wg-li.flag-3.yi a:before { background-position: -1608px 0; }
626
+ .wg-li.flag-3.yo a:before { background-position: -3457px 0; }
627
+ .wg-li.flag-3.zu a:before { background-position: -5496px 0; }
weglot.php CHANGED
@@ -1,7 +1,7 @@
1
  <?php
2
  /**
3
  * @package Weglot
4
- * @version 1.9.3
5
  */
6
 
7
  /*
@@ -12,7 +12,7 @@ Author: Weglot Translate team
12
  Author URI: https://weglot.com/
13
  Text Domain: weglot
14
  Domain Path: /languages/
15
- Version: 1.9.3
16
  */
17
 
18
  /*
@@ -45,7 +45,7 @@ if ( ! defined( 'ABSPATH' ) ) {
45
 
46
 
47
 
48
- define( 'WEGLOT_VERSION', '1.9.3' );
49
  define( 'WEGLOT_DIR', dirname( __FILE__ ) );
50
  define( 'WEGLOT_BNAME', plugin_basename( __FILE__ ) );
51
  define( 'WEGLOT_DIRURL', plugin_dir_url( __FILE__ ) );
@@ -95,7 +95,6 @@ class Weglot {
95
 
96
  add_action( 'plugins_loaded', array( &$this, 'wg_load_textdomain' ) );
97
  add_action( 'init', array( &$this, 'init_function' ),11 );
98
- add_action( 'wp_head',array( &$this, 'add_alternate' ) );
99
  add_action( 'wp', array( &$this, 'rr_404_my_event' ) );
100
  add_filter( 'plugin_action_links_' . plugin_basename( __FILE__ ), array( &$this, 'wg_plugin_action_links' ) );
101
 
@@ -106,8 +105,6 @@ class Weglot {
106
  $this->request_uri = $this->getRequestUri( $this->home_dir );
107
  $this->network_paths = $this->getListOfNetworkPath();
108
 
109
-
110
-
111
  $this->noredirect = false;
112
  if ( strpos( $this->request_uri, '?no_lredirect=true' ) !== false ) {
113
  $this->noredirect = true;
@@ -141,8 +138,8 @@ class Weglot {
141
  add_filter( 'woocommerce_get_checkout_order_received_url', array( &$this,'filter_woocommerce_get_checkout_order_received_url'));
142
 
143
  add_filter('woocommerce_login_redirect', array( &$this,'wg_log_redirect'));
144
- add_filter( 'login_redirect', array( &$this,'wg_log_redirect'), 10, 3 );
145
- add_filter( 'logout_redirect', array( &$this,'wg_log_redirect'), 10, 3 );
146
 
147
  //add_filter( 'wp_mail' , array( &$this, 'translate_emails'), 10,1);
148
 
@@ -174,6 +171,7 @@ class Weglot {
174
 
175
  $isURLOK = $this->isEligibleURL( $this->request_uri_no_language );
176
  if ( $isURLOK ) {
 
177
  add_action( 'widgets_init', array( &$this, 'addWidget' ) );
178
  add_shortcode( 'weglot_switcher', array( &$this, 'wg_switcher_creation' ) );
179
  if ( get_option( 'is_menu' ) == 'on' ) {
@@ -313,7 +311,7 @@ class Weglot {
313
  }
314
  }
315
 
316
- public function wg_log_redirect( $redirect_to, $request, $user ) {
317
 
318
  if($this->currentlang != $this->original_l) {
319
  return $this->replaceUrl($redirect_to, $this->currentlang);
@@ -338,14 +336,24 @@ class Weglot {
338
  }
339
  elseif(isset($_SERVER['HTTP_REFERER'])) {
340
  $l = $this->getLangFromUrl($this->URLToRelative( $_SERVER['HTTP_REFERER']));
341
- if($l && $l != $this->original_l)
342
  $messageAndSubjectTranslated = $this->translateEmail($messageAndSubject,$l);
 
 
 
 
 
 
 
 
 
343
  }
344
 
345
  if (strpos($messageAndSubjectTranslated, '</p>') !== false) {
346
  $pos = strpos($messageAndSubjectTranslated, '</p>')+4;
347
  $args['subject'] = substr($messageAndSubjectTranslated,3,$pos-7);
348
  $args['message'] = substr($messageAndSubjectTranslated,$pos);
 
349
  }
350
  return $args;
351
  }
@@ -479,7 +487,7 @@ class Weglot {
479
  false) {
480
 
481
  $d = explode( ',',preg_replace( '/\s+/', '', trim( $this->destination_l,',' ) ) );
482
- $accepted = array( 'sq', 'en', 'ar', 'hy', 'az', 'af', 'eu', 'be', 'bg', 'bs', 'vi', 'hu', 'ht', 'nl', 'el', 'ka', 'da', 'he', 'id', 'ga', 'it', 'is', 'es', 'kk', 'ca', 'ky', 'zh', 'tw', 'ko', 'lv', 'lt', 'mg', 'ms', 'mt', 'mk', 'mn', 'de', 'no', 'fa', 'pl', 'pt', 'ro', 'ru', 'sr', 'sk', 'sl', 'sw', 'tg', 'th', 'tr', 'uz', 'uk', 'fi', 'fr', 'hr', 'cs', 'sv', 'et', 'ja', 'hi', 'ur','bn','fj','sm','ty','to','cy' );
483
  foreach ( $d as $k => $l ) {
484
  if ( ! in_array( $l,$accepted ) || $l == $this->original_l ) {
485
  unset( $d[ $k ] );
@@ -534,7 +542,7 @@ class Weglot {
534
  public function treatPage( $final ) {
535
 
536
  $request_uri = $this->request_uri;
537
- if ( ! is_admin() && strpos( $request_uri,'wc-ajax' ) === false && $this->original_l != '' && $this->destination_l != '' ) {
538
 
539
  // $final = file_get_contents(__DIR__.'/content.html'); //Testing purpose.
540
  // Get the original request
@@ -579,10 +587,41 @@ class Weglot {
579
  $final = (strpos( $final, '</body>' ) !== false) ? WGUtils::str_lreplace( '</body>',$button . ' </body>',$final ) : WGUtils::str_lreplace( '</footer>',$button . ' </footer>',$final );
580
  }
581
  return $final;
582
- } else {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
583
  return $final;
584
  }
585
- } elseif ( (strpos( $request_uri,'ajax' ) !== false ) &&
586
  $this->destination_l != '' && $this->original_l != '' && isset(
587
  $_SERVER['HTTP_REFERER']
588
  ) && strpos( $_SERVER['HTTP_REFERER'] ,'admin' ) === false ) {
@@ -629,6 +668,9 @@ class Weglot {
629
  if ( WGUtils::is_AJAX_HTML( $val ) ) {
630
  $array[ $key ] = $this->translatePageTo( $val,$to );
631
  }
 
 
 
632
  }
633
  }
634
  return $array;
1
  <?php
2
  /**
3
  * @package Weglot
4
+ * @version 1.10
5
  */
6
 
7
  /*
12
  Author URI: https://weglot.com/
13
  Text Domain: weglot
14
  Domain Path: /languages/
15
+ Version: 1.10
16
  */
17
 
18
  /*
45
 
46
 
47
 
48
+ define( 'WEGLOT_VERSION', '1.10' );
49
  define( 'WEGLOT_DIR', dirname( __FILE__ ) );
50
  define( 'WEGLOT_BNAME', plugin_basename( __FILE__ ) );
51
  define( 'WEGLOT_DIRURL', plugin_dir_url( __FILE__ ) );
95
 
96
  add_action( 'plugins_loaded', array( &$this, 'wg_load_textdomain' ) );
97
  add_action( 'init', array( &$this, 'init_function' ),11 );
 
98
  add_action( 'wp', array( &$this, 'rr_404_my_event' ) );
99
  add_filter( 'plugin_action_links_' . plugin_basename( __FILE__ ), array( &$this, 'wg_plugin_action_links' ) );
100
 
105
  $this->request_uri = $this->getRequestUri( $this->home_dir );
106
  $this->network_paths = $this->getListOfNetworkPath();
107
 
 
 
108
  $this->noredirect = false;
109
  if ( strpos( $this->request_uri, '?no_lredirect=true' ) !== false ) {
110
  $this->noredirect = true;
138
  add_filter( 'woocommerce_get_checkout_order_received_url', array( &$this,'filter_woocommerce_get_checkout_order_received_url'));
139
 
140
  add_filter('woocommerce_login_redirect', array( &$this,'wg_log_redirect'));
141
+ add_filter( 'login_redirect', array( &$this,'wg_log_redirect') );
142
+ add_filter( 'logout_redirect', array( &$this,'wg_log_redirect') );
143
 
144
  //add_filter( 'wp_mail' , array( &$this, 'translate_emails'), 10,1);
145
 
171
 
172
  $isURLOK = $this->isEligibleURL( $this->request_uri_no_language );
173
  if ( $isURLOK ) {
174
+ add_action( 'wp_head',array( &$this, 'add_alternate' ) );
175
  add_action( 'widgets_init', array( &$this, 'addWidget' ) );
176
  add_shortcode( 'weglot_switcher', array( &$this, 'wg_switcher_creation' ) );
177
  if ( get_option( 'is_menu' ) == 'on' ) {
311
  }
312
  }
313
 
314
+ public function wg_log_redirect( $redirect_to ) {
315
 
316
  if($this->currentlang != $this->original_l) {
317
  return $this->replaceUrl($redirect_to, $this->currentlang);
336
  }
337
  elseif(isset($_SERVER['HTTP_REFERER'])) {
338
  $l = $this->getLangFromUrl($this->URLToRelative( $_SERVER['HTTP_REFERER']));
339
+ if($l && $l != $this->original_l) { //If language in referer
340
  $messageAndSubjectTranslated = $this->translateEmail($messageAndSubject,$l);
341
+ }
342
+ elseif(strpos($_SERVER['HTTP_REFERER'], 'wg_language=') !== false) { //If language in parameter
343
+ $pos = strpos($_SERVER['HTTP_REFERER'], 'wg_language=');
344
+ $start = $pos + strlen('wg_language=');
345
+ $l = substr($_SERVER['HTTP_REFERER'],$start,2);
346
+ if($l && $l != $this->original_l) {
347
+ $messageAndSubjectTranslated = $this->translateEmail($messageAndSubject,$l);
348
+ }
349
+ }
350
  }
351
 
352
  if (strpos($messageAndSubjectTranslated, '</p>') !== false) {
353
  $pos = strpos($messageAndSubjectTranslated, '</p>')+4;
354
  $args['subject'] = substr($messageAndSubjectTranslated,3,$pos-7);
355
  $args['message'] = substr($messageAndSubjectTranslated,$pos);
356
+
357
  }
358
  return $args;
359
  }
487
  false) {
488
 
489
  $d = explode( ',',preg_replace( '/\s+/', '', trim( $this->destination_l,',' ) ) );
490
+ $accepted = array( 'af','sq','am','ar','hy','az','ba','eu','be','bn','bs','bg','my','ca','km','ny','co','hr','cs','da','nl','en','eo','et','fj','fi','fr','gl','ka','de','el','gu','ht','ha','he','hi','hu','is','ig','id','ga','it','ja','jv','kn','kk','ko','ku','ky','lo','la','lv','lt','lb','mk','mg','ms','ml','mt','mi','mr','mn','ne','no','ps','fa','pl','pt','pa','ro','ru','sm','gd','sr','sn','zh','sd','si','sk','sl','so','st','es','su','sw','sv','tl','ty','tg','ta','tt','te','th','to','tw','tr','uk','ur','uz','vi','cy','fy','xh','yi','yo','zu' );
491
  foreach ( $d as $k => $l ) {
492
  if ( ! in_array( $l,$accepted ) || $l == $this->original_l ) {
493
  unset( $d[ $k ] );
542
  public function treatPage( $final ) {
543
 
544
  $request_uri = $this->request_uri;
545
+ if ( ! is_admin() && strpos( $request_uri,'jax' ) === false && $this->original_l != '' && $this->destination_l != '' ) {
546
 
547
  // $final = file_get_contents(__DIR__.'/content.html'); //Testing purpose.
548
  // Get the original request
587
  $final = (strpos( $final, '</body>' ) !== false) ? WGUtils::str_lreplace( '</body>',$button . ' </body>',$final ) : WGUtils::str_lreplace( '</footer>',$button . ' </footer>',$final );
588
  }
589
  return $final;
590
+ }
591
+ elseif($this->isEligibleURL( $url ) && $final[0] == '{' || ($final[0] == '[' && $final[1] == '{') ) {
592
+ $thisL = $this->getLangFromUrl(
593
+ $this->URLToRelative(
594
+ $_SERVER['HTTP_REFERER']
595
+ )
596
+ );
597
+ if ( isset( $thisL ) && $thisL != '' ) {
598
+ try {
599
+ if ( $final[0] == '{' || ($final[0] == '[' && $final[1] == '{') ) {
600
+ $json = json_decode( $final,true );
601
+ if ( json_last_error() == JSON_ERROR_NONE ) {
602
+ $jsonT = $this->translateArray( $json,$thisL );
603
+ return wp_json_encode( $jsonT );
604
+ } else {
605
+ return $final;
606
+ }
607
+ } elseif ( WGUtils::is_AJAX_HTML( $final ) ) {
608
+ return $this->translatePageTo( $final,$thisL );
609
+ } else {
610
+ return $final;
611
+ }
612
+ } catch ( \Weglot\WeglotException $e ) {
613
+ return $final;
614
+ } catch ( \Exception $e ) {
615
+ return $final;
616
+ }
617
+ } else {
618
+ return $final;
619
+ }
620
+ }
621
+ else {
622
  return $final;
623
  }
624
+ } elseif ( (strpos( $request_uri,'jax' ) !== false ) &&
625
  $this->destination_l != '' && $this->original_l != '' && isset(
626
  $_SERVER['HTTP_REFERER']
627
  ) && strpos( $_SERVER['HTTP_REFERER'] ,'admin' ) === false ) {
668
  if ( WGUtils::is_AJAX_HTML( $val ) ) {
669
  $array[ $key ] = $this->translatePageTo( $val,$to );
670
  }
671
+ elseif(in_array($key,'redirecturl','url')) {
672
+ $array[ $key] = $this->replaceUrl($val,$to);
673
+ }
674
  }
675
  }
676
  return $array;