[Typo3] Adding new field in tt_content

Papis papiseckfr at yahoo.fr
Mon Dec 5 11:08:18 CET 2005


Hi All,
  I just want to add a new field in tt_content in backend  (in the file file link)
  This field must be  filled with records from a nother table "user_famille"
  so i see in typo3 core API and i add in the php file tbl_tt_content.php this
  *************************************************************
      'uid_famille' => Array (          
              'exclude' => 1,
              'label' => 'Famille ',
              'config' => Array (
                  'type' => 'select',
                  'items' => Array (
                      Array('', 0),
                  ),
                  'foreign_table' => 'user_famille',
                  
              )
          ),
  And 
  $TCA['tt_content'] = Array (
      'ctrl' => $TCA['tt_content']['ctrl'],
      'interface' => Array (
          'always_description' => 0,
          'showRecordFieldList' =>  'CType,header,header_link,bodytext,image,imagewidth,imageorient,media,records,colPos,starttime,endtime,fe_group,author,author_email,keywords,abstract,client,uid_famille'
      ),
  And at last
  'uploads' =>     Array('showitem' => 'CType;;;button;1-1-1,
                                                  
                                                    media;;;;5-5-5,
                                               filelink_size,
                                                    date_creation_fichier,
                                               author,
                                               author_email,
                                                 client;;;;5-5-5,
                                                 uid_famille,
                                               type_document,                                            
                                               abstract;;9;richtext[*]:rte_transform[flag=rte_enabled|mode=ts];3-3-3,  text_properties, 
                                               keywords
                          '),
  But my probleme is i dont see where to precise what column to select in user_famille table.
  In Typo3 Cor Apis they say:
  foreign_table:(tablename) The item-array will be filled with records  from the table defined here. The table must be configured in $TCA. See  the other related options below.
  I notice that while processing the backend form for file link typo3  make a defaulf join between my table (user_famille) and page table on  pid. ???
  Thanks in advance, Any help is welcome 
  
  


Alioune Seck 
Ingénieur en Informatique 
Tel: (+221) 516 97 77
 


		
---------------------------------
 Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger
 Téléchargez le ici !  


More information about the TYPO3-english mailing list