enables to have specific HTTP status codes on a sys_domain record when doing a redire...
[Packages/TYPO3.CMS.git] / typo3 / sysext / cms / tbl_cms.php
1 <?php
2 /***************************************************************
3 * Copyright notice
4 *
5 * (c) 1999-2008 Kasper Skaarhoj (kasperYYYY@typo3.com)
6 * All rights reserved
7 *
8 * This script is part of the TYPO3 project. The TYPO3 project is
9 * free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * The GNU General Public License can be found at
15 * http://www.gnu.org/copyleft/gpl.html.
16 * A copy is found in the textfile GPL.txt and important notices to the license
17 * from the author is found in LICENSE.txt distributed with these scripts.
18 *
19 *
20 * This script is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 * GNU General Public License for more details.
24 *
25 * This copyright notice MUST APPEAR in all copies of the script!
26 ***************************************************************/
27 /**
28 * Dynamic configuation of the system-related tables, typ. sys_* series
29 *
30 * $Id$
31 *
32 * @author Kasper Skaarhoj <kasperYYYY@typo3.com>
33 */
34
35
36
37
38
39 // ******************************************************************
40 // fe_users
41 //
42 // FrontEnd users - login on the website
43 // ******************************************************************
44 $TCA['fe_users'] = array(
45 'ctrl' => $TCA['fe_users']['ctrl'],
46 'interface' => array(
47 'showRecordFieldList' => 'username,password,usergroup,lockToDomain,name,title,company,address,zip,city,country,email,www,telephone,fax,disable,starttime,endtime'
48 ),
49 'feInterface' => $TCA['fe_users']['feInterface'],
50 'columns' => array(
51 'username' => array(
52 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_users.username',
53 'config' => array(
54 'type' => 'input',
55 'size' => '20',
56 'max' => '50',
57 'eval' => 'nospace,lower,uniqueInPid,required'
58 )
59 ),
60 'password' => array(
61 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_users.password',
62 'config' => array(
63 'type' => 'input',
64 'size' => '10',
65 'max' => '40',
66 'eval' => 'nospace,required,password'
67 )
68 ),
69 'usergroup' => array(
70 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_users.usergroup',
71 'config' => array(
72 'type' => 'select',
73 'foreign_table' => 'fe_groups',
74 'size' => '6',
75 'minitems' => '1',
76 'maxitems' => '50'
77 )
78 ),
79 'lockToDomain' => array(
80 'exclude' => 1,
81 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_users.lockToDomain',
82 'config' => array(
83 'type' => 'input',
84 'size' => '20',
85 'eval' => 'trim',
86 'max' => '50',
87 'checkbox' => '',
88 'softref' => 'substitute'
89 )
90 ),
91 'name' => array(
92 'exclude' => 1,
93 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.name',
94 'config' => array(
95 'type' => 'input',
96 'size' => '40',
97 'eval' => 'trim',
98 'max' => '80'
99 )
100 ),
101 'address' => array(
102 'exclude' => 1,
103 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.address',
104 'config' => array(
105 'type' => 'text',
106 'cols' => '20',
107 'rows' => '3'
108 )
109 ),
110 'telephone' => array(
111 'exclude' => 1,
112 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.phone',
113 'config' => array(
114 'type' => 'input',
115 'eval' => 'trim',
116 'size' => '20',
117 'max' => '20'
118 )
119 ),
120 'fax' => array(
121 'exclude' => 1,
122 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.fax',
123 'config' => array(
124 'type' => 'input',
125 'size' => '20',
126 'eval' => 'trim',
127 'max' => '20'
128 )
129 ),
130 'email' => array(
131 'exclude' => 1,
132 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.email',
133 'config' => array(
134 'type' => 'input',
135 'size' => '20',
136 'eval' => 'trim',
137 'max' => '80'
138 )
139 ),
140 'title' => array(
141 'exclude' => 1,
142 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.title_person',
143 'config' => array(
144 'type' => 'input',
145 'size' => '20',
146 'eval' => 'trim',
147 'max' => '40'
148 )
149 ),
150 'zip' => array(
151 'exclude' => 1,
152 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.zip',
153 'config' => array(
154 'type' => 'input',
155 'eval' => 'trim',
156 'size' => '10',
157 'max' => '10'
158 )
159 ),
160 'city' => array(
161 'exclude' => 1,
162 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.city',
163 'config' => array(
164 'type' => 'input',
165 'size' => '20',
166 'eval' => 'trim',
167 'max' => '50'
168 )
169 ),
170 'country' => array(
171 'exclude' => 1,
172 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.country',
173 'config' => array(
174 'type' => 'input',
175 'size' => '20',
176 'eval' => 'trim',
177 'max' => '40'
178 )
179 ),
180 'www' => array(
181 'exclude' => 1,
182 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.www',
183 'config' => array(
184 'type' => 'input',
185 'eval' => 'trim',
186 'size' => '20',
187 'max' => '80'
188 )
189 ),
190 'company' => array(
191 'exclude' => 1,
192 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.company',
193 'config' => array(
194 'type' => 'input',
195 'eval' => 'trim',
196 'size' => '20',
197 'max' => '80'
198 )
199 ),
200 'image' => array(
201 'exclude' => 1,
202 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.image',
203 'config' => array(
204 'type' => 'group',
205 'internal_type' => 'file',
206 'allowed' => $GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext'],
207 'max_size' => $GLOBALS['TYPO3_CONF_VARS']['BE']['maxFileSize'],
208 'uploadfolder' => 'uploads/pics',
209 'show_thumbs' => '1',
210 'size' => '3',
211 'maxitems' => '6',
212 'minitems' => '0'
213 )
214 ),
215 'disable' => array(
216 'exclude' => 1,
217 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.disable',
218 'config' => array(
219 'type' => 'check'
220 )
221 ),
222 'starttime' => array(
223 'exclude' => 1,
224 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.starttime',
225 'config' => array(
226 'type' => 'input',
227 'size' => '8',
228 'max' => '20',
229 'eval' => 'date',
230 'default' => '0',
231 'checkbox' => '0'
232 )
233 ),
234 'endtime' => array(
235 'exclude' => 1,
236 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.endtime',
237 'config' => array(
238 'type' => 'input',
239 'size' => '8',
240 'max' => '20',
241 'eval' => 'date',
242 'checkbox' => '0',
243 'default' => '0',
244 'range' => array(
245 'upper' => mktime(0,0,0,12,31,2020),
246 )
247 )
248 ),
249 'TSconfig' => array(
250 'exclude' => 1,
251 'label' => 'TSconfig:',
252 'config' => array(
253 'type' => 'text',
254 'cols' => '40',
255 'rows' => '10',
256 'wizards' => array(
257 '_PADDING' => 4,
258 '0' => array(
259 # 'type' => t3lib_extMgm::isLoaded('tsconfig_help')?'popup':'',
260 'title' => 'TSconfig QuickReference',
261 'script' => 'wizard_tsconfig.php?mode=fe_users',
262 'icon' => 'wizard_tsconfig.gif',
263 'JSopenParams' => 'height=500,width=780,status=0,menubar=0,scrollbars=1',
264 )
265 ),
266 'softref' => 'TSconfig'
267 ),
268 'defaultExtras' => 'fixed-font : enable-tab',
269 )
270 ),
271 'types' => array(
272 '0' => array('showitem' => '
273 disable,username;;;;1-1-1, password, usergroup,
274 --div--;LLL:EXT:cms/locallang_tca.xml:fe_users.tabs.personelData, name;;1;;1-1-1, address, zip, city, country, telephone, fax, email, www, image;;;;2-2-2,
275 --div--;LLL:EXT:cms/locallang_tca.xml:fe_users.tabs.options, lockToDomain;;;;1-1-1, TSconfig;;;;2-2-2,
276 --div--;LLL:EXT:cms/locallang_tca.xml:fe_users.tabs.access, starttime, endtime,
277 --div--;LLL:EXT:cms/locallang_tca.xml:fe_users.tabs.extended
278
279 ')
280 ),
281 'palettes' => array(
282 '1' => array('showitem' => 'title,company')
283 )
284 );
285
286
287
288
289
290 // ******************************************************************
291 // fe_groups
292 //
293 // FrontEnd usergroups - Membership of these determines access to elements
294 // ******************************************************************
295 $TCA['fe_groups'] = array(
296 'ctrl' => $TCA['fe_groups']['ctrl'],
297 'interface' => array(
298 'showRecordFieldList' => 'title,hidden,subgroup,lockToDomain,description'
299 ),
300 'columns' => array(
301 'hidden' => array(
302 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.disable',
303 'exclude' => 1,
304 'config' => array(
305 'type' => 'check',
306 'default' => '0'
307 )
308 ),
309 'title' => array(
310 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_groups.title',
311 'config' => array(
312 'type' => 'input',
313 'size' => '20',
314 'max' => '50',
315 'eval' => 'trim,required'
316 )
317 ),
318 'subgroup' => array(
319 'exclude' => 1,
320 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_groups.subgroup',
321 'config' => array(
322 'type' => 'select',
323 'foreign_table' => 'fe_groups',
324 'foreign_table_where' => 'AND NOT(fe_groups.uid = ###THIS_UID###) AND fe_groups.hidden=0 ORDER BY fe_groups.title',
325 'size' => 6,
326 'autoSizeMax' => 10,
327 'minitems' => 0,
328 'maxitems' => 20
329 )
330 ),
331 'lockToDomain' => array(
332 'exclude' => 1,
333 'label' => 'LLL:EXT:cms/locallang_tca.php:fe_groups.lockToDomain',
334 'config' => array(
335 'type' => 'input',
336 'size' => '20',
337 'eval' => 'trim',
338 'max' => '50',
339 'checkbox' => ''
340 )
341 ),
342 'description' => array(
343 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.description',
344 'config' => array(
345 'type' => 'text',
346 'rows' => 5,
347 'cols' => 48
348 )
349 ),
350 'TSconfig' => array(
351 'exclude' => 1,
352 'label' => 'TSconfig:',
353 'config' => array(
354 'type' => 'text',
355 'cols' => '40',
356 'rows' => '10',
357 'wizards' => array(
358 '_PADDING' => 4,
359 '0' => array(
360 # 'type' => t3lib_extMgm::isLoaded('tsconfig_help')?'popup':'',
361 'title' => 'TSconfig QuickReference',
362 'script' => 'wizard_tsconfig.php?mode=fe_users',
363 'icon' => 'wizard_tsconfig.gif',
364 'JSopenParams' => 'height=500,width=780,status=0,menubar=0,scrollbars=1',
365 )
366 ),
367 'softref' => 'TSconfig'
368 ),
369 'defaultExtras' => 'fixed-font : enable-tab',
370 )
371 ),
372 'types' => array(
373 '0' => array('showitem' => '
374 hidden;;;;1-1-1,title;;;;2-2-2,description,subgroup;;;;3-3-3,
375 --div--;LLL:EXT:cms/locallang_tca.xml:fe_groups.tabs.options, lockToDomain;;;;1-1-1, TSconfig;;;;2-2-2,
376 --div--;LLL:EXT:cms/locallang_tca.xml:fe_groups.tabs.extended
377 ')
378 )
379 );
380
381
382
383
384 // ******************************************************************
385 // sys_domain
386 // ******************************************************************
387 $TCA['sys_domain'] = array(
388 'ctrl' => $TCA['sys_domain']['ctrl'],
389 'interface' => array(
390 'showRecordFieldList' => 'hidden,domainName,redirectTo'
391 ),
392 'columns' => array(
393 'domainName' => array(
394 'label' => 'LLL:EXT:cms/locallang_tca.php:sys_domain.domainName',
395 'config' => array(
396 'type' => 'input',
397 'size' => '35',
398 'max' => '80',
399 'eval' => 'required,unique,lower,trim',
400 'softref' => 'substitute'
401 ),
402 ),
403 'redirectTo' => array(
404 'label' => 'LLL:EXT:cms/locallang_tca.php:sys_domain.redirectTo',
405 'config' => array(
406 'type' => 'input',
407 'size' => '35',
408 'max' => '120',
409 'checkbox' => '',
410 'default' => '',
411 'eval' => 'trim',
412 'softref' => 'substitute'
413 ),
414 ),
415 'redirectHttpStatusCode' => array(
416 'exclude' => 1,
417 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_domain.redirectHttpStatusCode',
418 'config' => array(
419 'type' => 'select',
420 'items' => array(
421 array('LLL:EXT:cms/locallang_tca.xml:sys_domain.redirectHttpStatusCode.301', '301'),
422 array('LLL:EXT:cms/locallang_tca.xml:sys_domain.redirectHttpStatusCode.302', '302'),
423 array('LLL:EXT:cms/locallang_tca.xml:sys_domain.redirectHttpStatusCode.303', '303'),
424 array('LLL:EXT:cms/locallang_tca.xml:sys_domain.redirectHttpStatusCode.307', '307'),
425 ),
426 'size' => 1,
427 'maxitems' => 1,
428 ),
429 ),
430 'hidden' => array(
431 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.disable',
432 'exclude' => 1,
433 'config' => array(
434 'type' => 'check',
435 'default' => '0'
436 )
437 ),
438 'prepend_params' => array(
439 'label' => 'LLL:EXT:cms/locallang_tca.php:sys_domain.prepend_params',
440 'exclude' => 1,
441 'config' => array(
442 'type' => 'check',
443 'default' => '0'
444 )
445 )
446 ),
447 'types' => array(
448 '1' => array('showitem' => 'hidden;;;;1-1-1,domainName;;1;;3-3-3,prepend_params')
449 ),
450 'palettes' => array(
451 '1' => array('showitem' => 'redirectTo, redirectHttpStatusCode')
452 )
453 );
454
455
456
457
458
459 // ******************************************************************
460 // pages_language_overlay
461 // ******************************************************************
462 $TCA['pages_language_overlay'] = array(
463 'ctrl' => $TCA['pages_language_overlay']['ctrl'],
464 'interface' => array(
465 'showRecordFieldList' => 'title,hidden,starttime,endtime,keywords,description,abstract'
466 ),
467 'columns' => array(
468 'hidden' => array(
469 'exclude' => 1,
470 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.hidden',
471 'config' => array(
472 'type' => 'check',
473 'default' => '0'
474 )
475 ),
476 'starttime' => array(
477 'exclude' => 1,
478 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.starttime',
479 'config' => array(
480 'type' => 'input',
481 'size' => '8',
482 'max' => '20',
483 'eval' => 'date',
484 'checkbox' => '0',
485 'default' => '0'
486 )
487 ),
488 'endtime' => array(
489 'exclude' => 1,
490 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.endtime',
491 'config' => array(
492 'type' => 'input',
493 'size' => '8',
494 'max' => '20',
495 'eval' => 'date',
496 'checkbox' => '0',
497 'default' => '0',
498 'range' => array(
499 'upper' => mktime(0,0,0,12,31,2020),
500 )
501 )
502 ),
503 'title' => array(
504 'l10n_mode' => 'prefixLangTitle',
505 'label' => $TCA['pages']['columns']['title']['label'],
506 'l10n_cat' => 'text',
507 'config' => array(
508 'type' => 'input',
509 'size' => '30',
510 'max' => '256',
511 'eval' => 'required'
512 )
513 ),
514 'subtitle' => array(
515 'exclude' => 1,
516 'l10n_cat' => 'text',
517 'label' => $TCA['pages']['columns']['subtitle']['label'],
518 'config' => array(
519 'type' => 'input',
520 'size' => '30',
521 'max' => '256',
522 'eval' => ''
523 )
524 ),
525 'nav_title' => array(
526 'exclude' => 1,
527 'l10n_cat' => 'text',
528 'label' => $TCA['pages']['columns']['nav_title']['label'],
529 'config' => array(
530 'type' => 'input',
531 'size' => '30',
532 'max' => '256',
533 'checkbox' => '',
534 'eval' => 'trim'
535 )
536 ),
537 'keywords' => array(
538 'exclude' => 1,
539 'label' => $TCA['pages']['columns']['keywords']['label'],
540 'config' => array(
541 'type' => 'text',
542 'cols' => '40',
543 'rows' => '3'
544 )
545 ),
546 'description' => array(
547 'exclude' => 1,
548 'label' => $TCA['pages']['columns']['description']['label'],
549 'config' => array(
550 'type' => 'input',
551 'size' => '40',
552 'eval' => 'trim'
553 )
554 ),
555 'abstract' => array(
556 'exclude' => 1,
557 'label' => $TCA['pages']['columns']['abstract']['label'],
558 'config' => array(
559 'type' => 'text',
560 'cols' => '40',
561 'rows' => '3'
562 )
563 ),
564 'author' => array(
565 'exclude' => 1,
566 'label' => $TCA['pages']['columns']['author']['label'],
567 'config' => array(
568 'type' => 'input',
569 'size' => '20',
570 'eval' => 'trim',
571 'max' => '80'
572 )
573 ),
574 'author_email' => array(
575 'exclude' => 1,
576 'label' => $TCA['pages']['columns']['author_email']['label'],
577 'config' => array(
578 'type' => 'input',
579 'size' => '20',
580 'eval' => 'trim',
581 'max' => '80'
582 )
583 ),
584 'media' => array(
585 'exclude' => 1,
586 'label' => $TCA['pages']['columns']['media']['label'],
587 'config' => array(
588 'type' => 'group',
589 'internal_type' => 'file',
590 'allowed' => $TCA['pages']['columns']['media']['config']['allowed'],
591 'max_size' => $GLOBALS['TYPO3_CONF_VARS']['BE']['maxFileSize'],
592 'uploadfolder' => 'uploads/media',
593 'show_thumbs' => '1',
594 'size' => '3',
595 'maxitems' => '5',
596 'minitems' => '0'
597 )
598 ),
599 'sys_language_uid' => array(
600 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.language',
601 'config' => array(
602 'type' => 'select',
603 'foreign_table' => 'sys_language',
604 'foreign_table_where' => 'ORDER BY sys_language.title',
605 'items' => array(
606 array('LLL:EXT:lang/locallang_general.php:LGL.default_value',0)
607 )
608 )
609 ),
610 'tx_impexp_origuid' => array('config'=>array('type'=>'passthrough')),
611 'l18n_diffsource' => array('config'=>array('type'=>'passthrough')),
612 't3ver_label' => array(
613 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.versionLabel',
614 'config' => array(
615 'type' => 'input',
616 'size' => '30',
617 'max' => '30',
618 )
619 ),
620 ),
621 'types' => array(
622 '0' => array('showitem' => 'hidden;;;;1-1-1, sys_language_uid, title;;;;2-2-2, subtitle, nav_title, --div--, abstract;;5;;3-3-3, keywords, description, media;;;;4-4-4')
623 ),
624 'palettes' => array(
625 '1' => array('showitem' => 'starttime,endtime'),
626 '5' => array('showitem' => 'author,author_email')
627 )
628 );
629
630
631
632 // ******************************************************************
633 // sys_template
634 // ******************************************************************
635 $TCA['sys_template'] = array(
636 'ctrl' => $TCA['sys_template']['ctrl'],
637 'interface' => array(
638 'showRecordFieldList' => 'title,clear,root,include_static,basedOn,nextLevel,resources,sitetitle,description,hidden,starttime,endtime'
639 ),
640 'columns' => array(
641 'title' => array(
642 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.title',
643 'config' => array(
644 'type' => 'input',
645 'size' => '25',
646 'max' => '256',
647 'eval' => 'required'
648 )
649 ),
650 'hidden' => array(
651 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.disable',
652 'exclude' => 1,
653 'config' => array(
654 'type' => 'check',
655 'default' => '0'
656 )
657 ),
658 'starttime' => array(
659 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.starttime',
660 'exclude' => 1,
661 'config' => array(
662 'type' => 'input',
663 'size' => '8',
664 'max' => '20',
665 'eval' => 'date',
666 'checkbox' => '0',
667 'default' => '0'
668 )
669 ),
670 'endtime' => array(
671 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.endtime',
672 'exclude' => 1,
673 'config' => array(
674 'type' => 'input',
675 'size' => '8',
676 'max' => '20',
677 'eval' => 'date',
678 'checkbox' => '0',
679 'default' => '0',
680 'range' => array(
681 'upper' => mktime(0,0,0,12,31,2020),
682 )
683 )
684 ),
685 'root' => array(
686 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.root',
687 'config' => array(
688 'type' => 'check'
689 )
690 ),
691 'clear' => array(
692 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.clear',
693 'config' => array(
694 'type' => 'check',
695 'items' => array(
696 array('Constants', ''),
697 array('Setup', '')
698 ),
699 'cols' => 2
700 )
701 ),
702 'sitetitle' => array(
703 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.sitetitle',
704 'config' => array(
705 'type' => 'input',
706 'size' => '25',
707 'max' => '256'
708 )
709 ),
710 'constants' => array(
711 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.constants',
712 'config' => array(
713 'type' => 'text',
714 'cols' => '48',
715 'rows' => '10',
716 'wrap' => 'OFF',
717 'softref' => 'TStemplate,email[subst],url[subst]'
718 ),
719 'defaultExtras' => 'fixed-font : enable-tab',
720 ),
721 'resources' => array(
722 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.resources',
723 'config' => array(
724 'type' => 'group',
725 'internal_type' => 'file',
726 'allowed' => $GLOBALS['TYPO3_CONF_VARS']['GFX']['imagefile_ext'].',html,htm,ttf,pfb,pfm,txt,css,tmpl,inc,ico,js,xml',
727 'max_size' => $GLOBALS['TYPO3_CONF_VARS']['BE']['maxFileSize'],
728 'uploadfolder' => 'uploads/tf',
729 'show_thumbs' => '1',
730 'size' => '7',
731 'maxitems' => '100',
732 'minitems' => '0'
733 )
734 ),
735 'nextLevel' => array(
736 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.nextLevel',
737 'config' => array(
738 'type' => 'group',
739 'internal_type' => 'db',
740 'allowed' => 'sys_template',
741 'show_thumbs' => '1',
742 'size' => '1',
743 'maxitems' => '1',
744 'minitems' => '0',
745 'default' => ''
746 )
747 ),
748 'include_static' => array(
749 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.include_static',
750 'config' => array(
751 'type' => 'select',
752 'foreign_table' => 'static_template',
753 'foreign_table_where' => 'ORDER BY static_template.title DESC',
754 'size' => 10,
755 'maxitems' => 20,
756 'default' => '',
757 ),
758 ),
759 'include_static_file' => array(
760 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.include_static_file',
761 'config' => array(
762 'type' => 'select',
763 'size' => 10,
764 'maxitems' => 100,
765 'items' => array(
766 ),
767 'softref' => 'ext_fileref'
768 )
769 ),
770 'basedOn' => array(
771 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.basedOn',
772 'config' => array(
773 'type' => 'group',
774 'internal_type' => 'db',
775 'allowed' => 'sys_template',
776 'show_thumbs' => '1',
777 'size' => '3',
778 'maxitems' => '50',
779 'autoSizeMax' => 10,
780 'minitems' => '0',
781 'default' => '',
782 'wizards' => array(
783 '_PADDING' => 4,
784 '_VERTICAL' => 1,
785 'edit' => array(
786 'type' => 'popup',
787 'title' => 'Edit template',
788 'script' => 'wizard_edit.php',
789 'popup_onlyOpenIfSelected' => 1,
790 'icon' => 'edit2.gif',
791 'JSopenParams' => 'height=350,width=580,status=0,menubar=0,scrollbars=1',
792 ),
793 'add' => array(
794 'type' => 'script',
795 'title' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.basedOn_add',
796 'icon' => 'add.gif',
797 'params' => array(
798 'table'=>'sys_template',
799 'pid' => '###CURRENT_PID###',
800 'setValue' => 'prepend'
801 ),
802 'script' => 'wizard_add.php',
803 )
804 )
805 )
806 ),
807 'includeStaticAfterBasedOn' => array(
808 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.includeStaticAfterBasedOn',
809 'exclude' => 1,
810 'config' => array(
811 'type' => 'check',
812 'default' => '0'
813 )
814 ),
815 'config' => array(
816 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.config',
817 'config' => array(
818 'type' => 'text',
819 'rows' => 10,
820 'cols' => 48,
821 'wizards' => array(
822 '_PADDING' => 4,
823 '0' => array(
824 # 'type' => t3lib_extMgm::isLoaded('tsconfig_help')?'popup':'',
825 'title' => 'TSref online',
826 'script' => 'wizard_tsconfig.php?mode=tsref',
827 'icon' => 'wizard_tsconfig.gif',
828 'JSopenParams' => 'height=500,width=780,status=0,menubar=0,scrollbars=1',
829 )
830 ),
831 'wrap' => 'OFF',
832 'softref' => 'TStemplate,email[subst],url[subst]'
833 ),
834 'defaultExtras' => 'fixed-font : enable-tab',
835 ),
836 'editorcfg' => array(
837 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.editorcfg',
838 'config' => array(
839 'type' => 'text',
840 'rows' => 8,
841 'cols' => 48,
842 'wrap' => 'OFF'
843 ),
844 'defaultExtras' => 'fixed-font : enable-tab',
845 ),
846 'description' => array(
847 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.description',
848 'config' => array(
849 'type' => 'text',
850 'rows' => 5,
851 'cols' => 48
852 )
853 ),
854 'static_file_mode' => array(
855 'label' => 'LLL:EXT:cms/locallang_tca.xml:sys_template.static_file_mode',
856 'config' => array(
857 'type' => 'select',
858 'items' => array(
859 array('Default (Include before if Root-flag is set)', '0'),
860 array('Always include before this template record', '1'),
861 array('Never include before this template record', '2'),
862 ),
863 'default' => '0'
864 )
865 ),
866 'tx_impexp_origuid' => array('config' => array('type' => 'passthrough')),
867 't3ver_label' => array(
868 'label' => 'LLL:EXT:lang/locallang_general.php:LGL.versionLabel',
869 'config' => array(
870 'type' => 'input',
871 'size' => '30',
872 'max' => '30',
873 )
874 ),
875 ),
876 'types' => array(
877 '1' => array('showitem' => '
878 hidden,title;;1;;2-2-2, sitetitle, constants;;;;3-3-3, config, description;;;;4-4-4,
879 --div--;LLL:EXT:cms/locallang_tca.xml:sys_template.tabs.options, clear, root, nextLevel, editorcfg;;;;5-5-5,
880 --div--;LLL:EXT:cms/locallang_tca.xml:sys_template.tabs.include, include_static,includeStaticAfterBasedOn,6-6-6, include_static_file, basedOn, static_file_mode,
881 --div--;LLL:EXT:cms/locallang_tca.xml:sys_template.tabs.files, resources,
882 --div--;LLL:EXT:cms/locallang_tca.xml:sys_template.tabs.access, starttime, endtime'
883 )
884 )
885 );
886
887
888
889
890
891 // ******************************************************************
892 // static_template
893 // ******************************************************************
894 $TCA['static_template'] = array(
895 'ctrl' => $TCA['static_template']['ctrl'],
896 'interface' => array(
897 'showRecordFieldList' => 'title,include_static,description'
898 ),
899 'columns' => array(
900 'title' => array(
901 'label' => 'Template title:',
902 'config' => array(
903 'type' => 'input',
904 'size' => '25',
905 'max' => '256',
906 'eval' => 'required'
907 )
908 ),
909 'constants' => array(
910 'label' => 'Constants:',
911 'config' => array(
912 'type' => 'text',
913 'cols' => '48',
914 'rows' => '10',
915 'wrap' => 'OFF'
916 ),
917 'defaultExtras' => 'fixed-font : enable-tab',
918 ),
919 'include_static' => array(
920 'label' => 'Include static:',
921 'config' => array(
922 'type' => 'select',
923 'foreign_table' => 'static_template',
924 'foreign_table_where' => 'ORDER BY static_template.title',
925 'size' => 10,
926 'maxitems' => 20,
927 'default' => ''
928 )
929 ),
930 'config' => array(
931 'label' => 'Setup:',
932 'config' => array(
933 'type' => 'text',
934 'rows' => 10,
935 'cols' => 48,
936 'wrap' => 'OFF'
937 ),
938 'defaultExtras' => 'fixed-font : enable-tab',
939 ),
940 'editorcfg' => array(
941 'label' => 'Backend Editor Configuration:',
942 'config' => array(
943 'type' => 'text',
944 'rows' => 4,
945 'cols' => 48,
946 'wrap' => 'OFF'
947 ),
948 'defaultExtras' => 'fixed-font : enable-tab',
949 ),
950 'description' => array(
951 'label' => 'Description:',
952 'config' => array(
953 'type' => 'text',
954 'rows' => 10,
955 'cols' => 48
956 )
957 )
958 ),
959 'types' => array(
960 '1' => array('showitem' => 'title;;;;2-2-2, constants;;;;3-3-3, config, include_static;;;;5-5-5, description;;;;5-5-5, editorcfg')
961 )
962 );
963
964
965
966 ?>