[ Index ]
 

Code source de Typo3 4.1.3

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/t3lib/ -> class.t3lib_admin.php (sommaire)

Contains a class for evaluation of database integrity according to $TCA Most of these functions are considered obsolete! $Id: class.t3lib_admin.php 2061 2007-02-20 21:16:23Z mundaun $ Revised for TYPO3 3.6 July/2003 by Kasper Skaarhoj XHTML compliant

Author: Kasper Skaarhoj <kasperYYYY@typo3.com>
Poids: 739 lignes (26 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 0 fichiers

Définit 1 class

t3lib_admin:: (14 méthodes):
  genTree()
  genTree_records()
  genTreeStatus()
  lostRecords()
  fixLostRecord()
  countRecords()
  getGroupFields()
  getFileFields()
  getDBFields()
  selectNonEmptyRecordsWithFkeys()
  testFileRefs()
  testDBRefs()
  whereIsRecordReferenced()
  whereIsFileReferenced()


Classe: t3lib_admin  - X-Ref

This class holds functions used by the TYPO3 backend to check the integrity of the database (The DBint module, 'lowlevel' extension)

Depends on:        Depends on loaddbgroup from t3lib/

genTree($theID, $depthData, $versions=FALSE)   X-Ref
Generates a list of Page-uid's that corresponds to the tables in the tree. This list should ideally include all records in the pages-table.

param: integer        a pid (page-record id) from which to start making the tree
param: string        HTML-code (image-tags) used when this function calls itself recursively.
param: boolean        Internal variable, don't set from outside!
return: void

genTree_records($theID, $depthData, $table='', $versions=FALSE)   X-Ref

param: [type]        $theID: ...
param: [type]        $depthData: ...
param: [type]        $table: ...
param: [type]        $versions: ...
return: [type]        ...

genTreeStatus($root=0)   X-Ref
[Describe function...]

return: [type]        ...

lostRecords($pid_list)   X-Ref
Fills $this->lRecords with the records from all tc-tables that are not attached to a PID in the pid-list.

param: string        list of pid's (page-record uid's). This list is probably made by genTree()
return: void

fixLostRecord($table,$uid)   X-Ref
Fixes lost record from $table with uid $uid by setting the PID to zero. If there is a disabled column for the record that will be set as well.

param: string        Database tablename
param: integer        The uid of the record which will have the PID value set to 0 (zero)
return: boolean        True if done.

countRecords($pid_list)   X-Ref
Counts records from $TCA-tables that ARE attached to an existing page.

param: string        list of pid's (page-record uid's). This list is probably made by genTree()
return: array        an array with the number of records from all $TCA-tables that are attached to a PID in the pid-list.

getGroupFields($mode)   X-Ref
Finding relations in database based on type 'group' (files or database-uid's in a list)

param: string        $mode = file, $mode = db, $mode = '' (all...)
return: array        An array with all fields listed that somehow are references to other records (foreign-keys) or files

getFileFields($uploadfolder)   X-Ref
Finds all fields that hold filenames from uploadfolder

param: string        Path to uploadfolder
return: array        An array with all fields listed that have references to files in the $uploadfolder

getDBFields($theSearchTable)   X-Ref
Returns an array with arrays of table/field pairs which are allowed to hold references to the input table name - according to $TCA

param: string        Table name
return: array

selectNonEmptyRecordsWithFkeys($fkey_arrays)   X-Ref
This selects non-empty-records from the tables/fields in the fkey_array generated by getGroupFields()

param: array        Array with tables/fields generated by getGroupFields()
return: void

testFileRefs()   X-Ref
Depends on selectNonEmpty.... to be executed first!!

return: array        Report over files; keys are "moreReferences", "noReferences", "noFile", "error"

testDBRefs($theArray)   X-Ref
Depends on selectNonEmpty.... to be executed first!!

param: array        Table with key/value pairs being table names and arrays with uid numbers
return: string        HTML Error message

whereIsRecordReferenced($searchTable,$id)   X-Ref
Finding all references to record based on table/uid

param: string        Table name
param: integer        Uid of database record
return: array        Array with other arrays containing information about where references was found

whereIsFileReferenced($uploadfolder,$filename)   X-Ref
Finding all references to file based on uploadfolder / filename

param: string        Upload folder where file is found
param: string        Filename to search for
return: array        Array with other arrays containing information about where references was found



Généré le : Sun Nov 25 17:13:16 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics