‪TYPO3CMS  10.4
site_language.php
Go to the documentation of this file.
1 <?php
2 
3 return [
4  'ctrl' => [
5  'label' => 'languageId',
6  'label_userFunc' => \TYPO3\CMS\Backend\Configuration\TCA\UserFunctions::class . '->getSiteLanguageTitle',
7  'title' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.ctrl.title',
8  'typeicon_classes' => [
9  'default' => 'mimetypes-x-content-domain',
10  ],
11  ],
12  'columns' => [
13  'languageId' => [
14  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.languageId',
15  'config' => [
16  'type' => 'select',
17  'renderType' => 'selectSingle',
18  'items' => [
19  ['Default Language', 0],
20  ],
21  'foreign_table' => 'sys_language',
22  'size' => 1,
23  'min' => 1,
24  'max' => 1,
25  ],
26  ],
27  'title' => [
28  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.title',
29  'config' => [
30  'type' => 'input',
31  'size' => 15,
32  'eval' => 'required, trim',
33  'placeholder' => 'English',
34  ],
35  ],
36  'navigationTitle' => [
37  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.navigationTitle',
38  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.navigationTitle',
39  'config' => [
40  'type' => 'input',
41  'size' => 15,
42  'eval' => 'trim',
43  'placeholder' => 'English',
44  ],
45  ],
46  'base' => [
47  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.base',
48  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.base',
49  'config' => [
50  'type' => 'input',
51  'eval' => 'required, trim',
52  'default' => '/',
53  'placeholder' => '/',
54  ],
55  ],
56  'websiteTitle' => [
57  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.websiteTitle',
58  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.websiteTitle',
59  'config' => [
60  'type' => 'input',
61  'eval' => 'trim',
62  'default' => '',
63  ],
64  ],
65  'locale' => [
66  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.locale',
67  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.locale',
68  'config' => [
69  'type' => 'input',
70  'eval' => 'required, trim',
71  'size' => 10,
72  'placeholder' => 'en_US.UTF-8',
73  ],
74  ],
75  'iso-639-1' => [
76  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.iso-639-1',
77  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.iso-639-1',
78  'config' => [
79  'type' => 'select',
80  'renderType' => 'selectSingle',
81  // Fed by data provider
82  'items' => [],
83  ],
84  ],
85  'hreflang' => [
86  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.hreflang',
87  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.hreflang',
88  'config' => [
89  'type' => 'input',
90  'eval' => 'trim',
91  'size' => 6,
92  'placeholder' => 'en-US',
93  ],
94  ],
95  'enabled' => [
96  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.enabled',
97  'config' => [
98  'type' => 'check',
99  'renderType' => 'checkboxToggle',
100  'default' => 1,
101  'items' => [
102  [
103  0 => '',
104  1 => ''
105  ]
106  ]
107  ],
108  ],
109  'direction' => [
110  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.direction',
111  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.direction',
112  'config' => [
113  'type' => 'select',
114  'renderType' => 'selectSingle',
115  'items' => [
116  ['None', '', ''],
117  ['Left to Right', 'ltr', ''],
118  ['Right to Left', 'rtl', ''],
119  ],
120  ],
121  ],
122  'typo3Language' => [
123  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.typo3Language',
124  'description' => 'LLL:EXT:backend/Resources/Private/Language/siteconfiguration_fieldinformation.xlf:site_language.typo3Language',
125  'config' => [
126  'type' => 'select',
127  'renderType' => 'selectSingle',
128  // Fed by data provider
129  'items' => [],
130  'default' => 'default'
131  ],
132  ],
133  'flag' => [
134  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.flag',
135  'config' => [
136  'type' => 'select',
137  'renderType' => 'selectSingle',
138  'items' => [
139  ['global', 'global', 'flags-multiple'],
140  ['ad', 'ad', 'flags-ad'],
141  ['ae', 'ae', 'flags-ae'],
142  ['af', 'af', 'flags-af'],
143  ['ag', 'ag', 'flags-ag'],
144  ['ai', 'ai', 'flags-ai'],
145  ['al', 'al', 'flags-al'],
146  ['am', 'am', 'flags-am'],
147  ['an', 'an', 'flags-an'],
148  ['ao', 'ao', 'flags-ao'],
149  ['aq', 'aq', 'flags-aq'],
150  ['ar', 'ar', 'flags-ar'],
151  ['as', 'as', 'flags-as'],
152  ['at', 'at', 'flags-at'],
153  ['au', 'au', 'flags-au'],
154  ['aw', 'aw', 'flags-aw'],
155  ['ax', 'ax', 'flags-ax'],
156  ['az', 'az', 'flags-az'],
157  ['ba', 'ba', 'flags-ba'],
158  ['bb', 'bb', 'flags-bb'],
159  ['bd', 'bd', 'flags-bd'],
160  ['be', 'be', 'flags-be'],
161  ['bf', 'bf', 'flags-bf'],
162  ['bg', 'bg', 'flags-bg'],
163  ['bh', 'bh', 'flags-bh'],
164  ['bi', 'bi', 'flags-bi'],
165  ['bj', 'bj', 'flags-bj'],
166  ['bl', 'bl', 'flags-bl'],
167  ['bm', 'bm', 'flags-bm'],
168  ['bn', 'bn', 'flags-bn'],
169  ['bo', 'bo', 'flags-bo'],
170  ['bq', 'bq', 'flags-bq'],
171  ['br', 'br', 'flags-br'],
172  ['bs', 'bs', 'flags-bs'],
173  ['bt', 'bt', 'flags-bt'],
174  ['bv', 'bv', 'flags-bv'],
175  ['bw', 'bw', 'flags-bw'],
176  ['by', 'by', 'flags-by'],
177  ['bz', 'bz', 'flags-bz'],
178  ['ca', 'ca', 'flags-ca'],
179  ['catalonia', 'catalonia', 'flags-catalonia'],
180  ['cc', 'cc', 'flags-cc'],
181  ['cd', 'cd', 'flags-cd'],
182  ['cf', 'cf', 'flags-cf'],
183  ['cg', 'cg', 'flags-cg'],
184  ['ch', 'ch', 'flags-ch'],
185  ['ci', 'ci', 'flags-ci'],
186  ['ck', 'ck', 'flags-ck'],
187  ['cl', 'cl', 'flags-cl'],
188  ['cm', 'cm', 'flags-cm'],
189  ['cn', 'cn', 'flags-cn'],
190  ['co', 'co', 'flags-co'],
191  ['cr', 'cr', 'flags-cr'],
192  ['cs', 'cs', 'flags-cs'],
193  ['cu', 'cu', 'flags-cu'],
194  ['cv', 'cv', 'flags-cv'],
195  ['cw', 'cw', 'flags-cw'],
196  ['cx', 'cx', 'flags-cx'],
197  ['cy', 'cy', 'flags-cy'],
198  ['cz', 'cz', 'flags-cz'],
199  ['de', 'de', 'flags-de'],
200  ['dj', 'dj', 'flags-dj'],
201  ['dk', 'dk', 'flags-dk'],
202  ['dm', 'dm', 'flags-dm'],
203  ['do', 'do', 'flags-do'],
204  ['dz', 'dz', 'flags-dz'],
205  ['ec', 'ec', 'flags-ec'],
206  ['ee', 'ee', 'flags-ee'],
207  ['eg', 'eg', 'flags-eg'],
208  ['eh', 'eh', 'flags-eh'],
209  ['en-us-gb', 'en-us-gb', 'flags-en-us-gb'],
210  ['gb-eng', 'gb-eng', 'flags-gb-eng'],
211  ['er', 'er', 'flags-er'],
212  ['es', 'es', 'flags-es'],
213  ['et', 'et', 'flags-et'],
214  ['eu', 'eu', 'flags-eu'],
215  ['fi', 'fi', 'flags-fi'],
216  ['fj', 'fj', 'flags-fj'],
217  ['fk', 'fk', 'flags-fk'],
218  ['fm', 'fm', 'flags-fm'],
219  ['fo', 'fo', 'flags-fo'],
220  ['fr', 'fr', 'flags-fr'],
221  ['ga', 'ga', 'flags-ga'],
222  ['gb', 'gb', 'flags-gb'],
223  ['gd', 'gd', 'flags-gd'],
224  ['ge', 'ge', 'flags-ge'],
225  ['gf', 'gf', 'flags-gf'],
226  ['gg', 'gg', 'flags-gg'],
227  ['gh', 'gh', 'flags-gh'],
228  ['gi', 'gi', 'flags-gi'],
229  ['gl', 'gl', 'flags-gl'],
230  ['gm', 'gm', 'flags-gm'],
231  ['gn', 'gn', 'flags-gn'],
232  ['gp', 'gp', 'flags-gp'],
233  ['gq', 'gq', 'flags-gq'],
234  ['gr', 'gr', 'flags-gr'],
235  ['gs', 'gs', 'flags-gs'],
236  ['gt', 'gt', 'flags-gt'],
237  ['gu', 'gu', 'flags-gu'],
238  ['gw', 'gw', 'flags-gw'],
239  ['gy', 'gy', 'flags-gy'],
240  ['hk', 'hk', 'flags-hk'],
241  ['hm', 'hm', 'flags-hm'],
242  ['hn', 'hn', 'flags-hn'],
243  ['hr', 'hr', 'flags-hr'],
244  ['ht', 'ht', 'flags-ht'],
245  ['hu', 'hu', 'flags-hu'],
246  ['id', 'id', 'flags-id'],
247  ['ie', 'ie', 'flags-ie'],
248  ['il', 'il', 'flags-il'],
249  ['im', 'im', 'flags-im'],
250  ['in', 'in', 'flags-in'],
251  ['io', 'io', 'flags-io'],
252  ['iq', 'iq', 'flags-iq'],
253  ['ir', 'ir', 'flags-ir'],
254  ['is', 'is', 'flags-is'],
255  ['it', 'it', 'flags-it'],
256  ['jm', 'jm', 'flags-jm'],
257  ['jo', 'jo', 'flags-jo'],
258  ['jp', 'jp', 'flags-jp'],
259  ['ke', 'ke', 'flags-ke'],
260  ['kg', 'kg', 'flags-kg'],
261  ['kh', 'kh', 'flags-kh'],
262  ['ki', 'ki', 'flags-ki'],
263  ['kl', 'kl', 'flags-kl'],
264  ['km', 'km', 'flags-km'],
265  ['kn', 'kn', 'flags-kn'],
266  ['kp', 'kp', 'flags-kp'],
267  ['kr', 'kr', 'flags-kr'],
268  ['kw', 'kw', 'flags-kw'],
269  ['ky', 'ky', 'flags-ky'],
270  ['kz', 'kz', 'flags-kz'],
271  ['la', 'la', 'flags-la'],
272  ['lb', 'lb', 'flags-lb'],
273  ['lc', 'lc', 'flags-lc'],
274  ['li', 'li', 'flags-li'],
275  ['lk', 'lk', 'flags-lk'],
276  ['lr', 'lr', 'flags-lr'],
277  ['ls', 'ls', 'flags-ls'],
278  ['lt', 'lt', 'flags-lt'],
279  ['lu', 'lu', 'flags-lu'],
280  ['lv', 'lv', 'flags-lv'],
281  ['ly', 'ly', 'flags-ly'],
282  ['ma', 'ma', 'flags-ma'],
283  ['mc', 'mc', 'flags-mc'],
284  ['md', 'md', 'flags-md'],
285  ['me', 'me', 'flags-me'],
286  ['mf', 'mf', 'flags-mf'],
287  ['mg', 'mg', 'flags-mg'],
288  ['mh', 'mh', 'flags-mh'],
289  ['mi', 'mi', 'flags-mi'],
290  ['mk', 'mk', 'flags-mk'],
291  ['ml', 'ml', 'flags-ml'],
292  ['mm', 'mm', 'flags-mm'],
293  ['mn', 'mn', 'flags-mn'],
294  ['mo', 'mo', 'flags-mo'],
295  ['mp', 'mp', 'flags-mp'],
296  ['mq', 'mq', 'flags-mq'],
297  ['mr', 'mr', 'flags-mr'],
298  ['ms', 'ms', 'flags-ms'],
299  ['mt', 'mt', 'flags-mt'],
300  ['mu', 'mu', 'flags-mu'],
301  ['mv', 'mv', 'flags-mv'],
302  ['mw', 'mw', 'flags-mw'],
303  ['mx', 'mx', 'flags-mx'],
304  ['my', 'my', 'flags-my'],
305  ['mz', 'mz', 'flags-mz'],
306  ['na', 'na', 'flags-na'],
307  ['nc', 'nc', 'flags-nc'],
308  ['ne', 'ne', 'flags-ne'],
309  ['nf', 'nf', 'flags-nf'],
310  ['ng', 'ng', 'flags-ng'],
311  ['ni', 'ni', 'flags-ni'],
312  ['gb-nir', 'gb-nir', 'flags-gb-nir'],
313  ['nl', 'nl', 'flags-nl'],
314  ['no', 'no', 'flags-no'],
315  ['np', 'np', 'flags-np'],
316  ['nr', 'nr', 'flags-nr'],
317  ['nu', 'nu', 'flags-nu'],
318  ['nz', 'nz', 'flags-nz'],
319  ['om', 'om', 'flags-om'],
320  ['pa', 'pa', 'flags-pa'],
321  ['pe', 'pe', 'flags-pe'],
322  ['pf', 'pf', 'flags-pf'],
323  ['pg', 'pg', 'flags-pg'],
324  ['ph', 'ph', 'flags-ph'],
325  ['pk', 'pk', 'flags-pk'],
326  ['pl', 'pl', 'flags-pl'],
327  ['pm', 'pm', 'flags-pm'],
328  ['pn', 'pn', 'flags-pn'],
329  ['pr', 'pr', 'flags-pr'],
330  ['ps', 'ps', 'flags-ps'],
331  ['pt', 'pt', 'flags-pt'],
332  ['pw', 'pw', 'flags-pw'],
333  ['py', 'py', 'flags-py'],
334  ['qa', 'qa', 'flags-qa'],
335  ['qc', 'qc', 'flags-qc'],
336  ['re', 're', 'flags-re'],
337  ['ro', 'ro', 'flags-ro'],
338  ['rs', 'rs', 'flags-rs'],
339  ['ru', 'ru', 'flags-ru'],
340  ['rw', 'rw', 'flags-rw'],
341  ['sa', 'sa', 'flags-sa'],
342  ['sb', 'sb', 'flags-sb'],
343  ['sc', 'sc', 'flags-sc'],
344  ['gb-sct', 'gb-sct', 'flags-gb-sct'],
345  ['sd', 'sd', 'flags-sd'],
346  ['se', 'se', 'flags-se'],
347  ['sg', 'sg', 'flags-sg'],
348  ['sh', 'sh', 'flags-sh'],
349  ['si', 'si', 'flags-si'],
350  ['sj', 'sj', 'flags-sj'],
351  ['sk', 'sk', 'flags-sk'],
352  ['sl', 'sl', 'flags-sl'],
353  ['sm', 'sm', 'flags-sm'],
354  ['sn', 'sn', 'flags-sn'],
355  ['so', 'so', 'flags-so'],
356  ['sr', 'sr', 'flags-sr'],
357  ['ss', 'ss', 'flags-ss'],
358  ['st', 'st', 'flags-st'],
359  ['sv', 'sv', 'flags-sv'],
360  ['sx', 'sx', 'flags-sx'],
361  ['sy', 'sy', 'flags-sy'],
362  ['sz', 'sz', 'flags-sz'],
363  ['tc', 'tc', 'flags-tc'],
364  ['td', 'td', 'flags-td'],
365  ['tf', 'tf', 'flags-tf'],
366  ['tg', 'tg', 'flags-tg'],
367  ['th', 'th', 'flags-th'],
368  ['tj', 'tj', 'flags-tj'],
369  ['tk', 'tk', 'flags-tk'],
370  ['tl', 'tl', 'flags-tl'],
371  ['tm', 'tm', 'flags-tm'],
372  ['tn', 'tn', 'flags-tn'],
373  ['to', 'to', 'flags-to'],
374  ['tr', 'tr', 'flags-tr'],
375  ['tt', 'tt', 'flags-tt'],
376  ['tv', 'tv', 'flags-tv'],
377  ['tw', 'tw', 'flags-tw'],
378  ['tz', 'tz', 'flags-tz'],
379  ['ua', 'ua', 'flags-ua'],
380  ['ug', 'ug', 'flags-ug'],
381  ['um', 'um', 'flags-um'],
382  ['us', 'us', 'flags-us'],
383  ['uy', 'uy', 'flags-uy'],
384  ['uz', 'uz', 'flags-uz'],
385  ['va', 'va', 'flags-va'],
386  ['vc', 'vc', 'flags-vc'],
387  ['ve', 've', 'flags-ve'],
388  ['vg', 'vg', 'flags-vg'],
389  ['vi', 'vi', 'flags-vi'],
390  ['vn', 'vn', 'flags-vn'],
391  ['vu', 'vu', 'flags-vu'],
392  ['gb-wls', 'gb-wls', 'flags-gb-wls'],
393  ['wf', 'wf', 'flags-wf'],
394  ['ws', 'ws', 'flags-ws'],
395  ['ye', 'ye', 'flags-ye'],
396  ['yt', 'yt', 'flags-yt'],
397  ['za', 'za', 'flags-za'],
398  ['zm', 'zm', 'flags-zm'],
399  ['zw', 'zw', 'flags-zw'],
400  ],
401  'size' => 1,
402  'minitems' => 0,
403  'maxitems' => 1,
404  'fieldWizard' => [
405  'selectIcons' => [
406  'disabled' => false,
407  ],
408  ],
409  ],
410  ],
411  'fallbackType' => [
412  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.fallbackType',
413  'displayCond' => 'FIELD:languageId:>:0',
414  'config' => [
415  'type' => 'select',
416  'renderType' => 'selectSingle',
417  'items' => [
418  ['Strict: Show only translated content, based on overlays', 'strict'],
419  ['Fallback: Show default language if no translation exists', 'fallback'],
420  ['Free mode: Ignore translation and overlay concept, only show data from selected language', 'free'],
421  ],
422  ],
423  ],
424  'fallbacks' => [
425  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.fallbacks',
426  'displayCond' => 'FIELD:languageId:>:0',
427  'config' => [
428  'type' => 'select',
429  'renderType' => 'selectMultipleSideBySide',
430  'items' => [
431  ['Default Language', 0],
432  ],
433  'foreign_table' => 'sys_language',
434  'size' => 5,
435  'min' => 0,
436  ],
437  ],
438  ],
439  'types' => [
440  '1' => [
441  'showitem' => '--palette--;;default, --palette--;;locale-related, --palette--;;rendering-related, flag, --palette--;;languageIdPalette',
442  ],
443  ],
444  'palettes' => [
445  'default' => [
446  'showitem' => 'title, enabled, --linebreak--, base'
447  ],
448  'languageIdPalette' => [
449  'showitem' => 'languageId',
450  'isHiddenPalette' => true,
451  ],
452  'locale-related' => [
453  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.palette.locales',
454  'showitem' => 'typo3Language, locale, iso-639-1'
455  ],
456  'rendering-related' => [
457  'label' => 'LLL:EXT:backend/Resources/Private/Language/locallang_siteconfiguration_tca.xlf:site_language.palette.frontend',
458  'showitem' => 'websiteTitle, --linebreak--, navigationTitle, hreflang, direction, --linebreak--, fallbackType, --linebreak--, fallbacks'
459  ]
460  ]
461 ];