‪TYPO3CMS  10.4
TYPO3\CMS\Core\DataHandling\DataHandler Class Reference
Inheritance diagram for TYPO3\CMS\Core\DataHandling\DataHandler:

Public Member Functions

 __construct (ReferenceIndexUpdater $referenceIndexUpdater=null)
 
 setControl (array $control)
 
 start ($data, $cmd, $altUserObject=null)
 
 setMirror ($mirror)
 
 setDefaultsFromUserTS ($userTS)
 
 process_uploads ()
 
 hook_processDatamap_afterDatabaseOperations (&$hookObjectsArr, &$status, &$table, &$id, &$fieldArray)
 
bool void process_datamap ()
 
 placeholderShadowing ($table, $id)
 
string getPlaceholderTitleForTableLabel ($table, $placeholderContent=null)
 
array fillInFieldArray ($table, $id, $fieldArray, $incomingFieldArray, $realPid, $status, $tscPID)
 
array checkValue ($table, $field, $value, $id, $status, $realPid, $tscPID, $incomingFieldArray=[])
 
array checkValue_SW ($res, $value, $tcaFieldConf, $table, $id, $curValue, $status, $realPid, $recFID, $field, $uploadedFiles, $tscPID, array $additionalData=null)
 
string checkValue_flexArray2Xml ($array, $addPrologue=false)
 
 checkValue_inline ($res, $value, $tcaFieldConf, $PP, $field, array $additionalData=null)
 
array bool checkValueForInline ($res, $value, $tcaFieldConf, $table, $id, $status, $field, array $additionalData=null)
 
array checkValue_checkMax ($tcaFieldConf, $valueArray)
 
string getUnique ($table, $field, $value, $id, $newPid=0)
 
array getRecordsWithSameValue ($tableName, $uid, $fieldName, $value, $pageId=0)
 
array checkValue_text_Eval ($value, $evalArray, $is_in)
 
array checkValue_input_Eval ($value, $evalArray, $is_in, string $table='', $id='')
 
array checkValue_group_select_processDBdata ($valueArray, $tcaFieldConf, $id, $status, $type, $currentTable, $currentField)
 
array checkValue_group_select_explodeSelectGroupValue ($value)
 
array checkValue_flex_procInData ($dataPart, $dataPart_current, $uploadedFiles, $dataStructure, $pParams, $callBackFunc='', array $workspaceOptions=[])
 
 checkValue_flex_procInData_travDS (&$dataValues, $dataValues_current, $uploadedFiles, $DSelements, $pParams, $callBackFunc, $structurePath, array $workspaceOptions=[])
 
void bool process_cmdmap ()
 
int null copyRecord ($table, $uid, $destPid, $first=false, $overrideValues=[], $excludeFields='', $language=0, $ignoreLocalization=false)
 
 copyPages ($uid, $destPid)
 
int null copySpecificPage ($uid, $destPid, $copyTablesArray, $first=false)
 
int copyRecord_raw ($table, $uid, $pid, $overrideArray=[], array $workspaceOptions=[])
 
int insertNewCopyVersion ($table, $fieldArray, $realPid)
 
array string copyRecord_procBasedOnFieldType ($table, $uid, $field, $value, $row, $conf, $realDestPid, $language=0, array $workspaceOptions=[])
 
array copyRecord_flexFormCallBack ($pParams, $dsConf, $dataValue, $_1, $_2, $_3, $workspaceOptions)
 
 copyL10nOverlayRecords ($table, $uid, $destPid, $first=false, $overrideValues=[], $excludeFields='')
 
 moveRecord ($table, $uid, $destPid)
 
 moveRecord_raw ($table, $uid, $destPid)
 
 moveRecord_procFields ($table, $uid, $destPid)
 
 moveRecord_procBasedOnFieldType ($table, $uid, $destPid, $field, $value, $conf)
 
 moveL10nOverlayRecords ($table, $uid, $destPid, $originalRecordDestinationPid)
 
int bool localize ($table, $uid, $language)
 
 deleteAction ($table, $id)
 
 deleteEl ($table, $uid, $noRecordCheck=false, $forceHardDelete=false, bool $deleteRecordsOnPage=true)
 
 deleteVersionsForRecord ($table, $uid, $forceHardDelete)
 
 undeleteRecord ($table, $uid)
 
 deleteRecord ($table, $uid, $noRecordCheck=false, $forceHardDelete=false, $undeleteRecord=false)
 
 deletePages ($uid, $force=false, $forceHardDelete=false, bool $deleteRecordsOnPage=true)
 
 deleteSpecificPage ($uid, $forceHardDelete=false, bool $deleteRecordsOnPage=true)
 
int[] string canDeletePage ($uid)
 
string cannotDeleteRecord ($table, $id)
 
bool isRecordUndeletable ($table, $uid)
 
 deleteRecord_procFields ($table, $uid, $undeleteRecord=false)
 
 deleteRecord_procBasedOnFieldType ($table, $uid, $field, $value, $conf, $undeleteRecord=false)
 
 deleteL10nOverlayRecords ($table, $uid)
 
 discard (string $table, ?int $uid, array $record=null)
 
int null versionizeRecord ($table, $id, $label, $delete=false)
 
 version_remapMMForVersionSwap ($table, $id, $swapWith)
 
 version_remapMMForVersionSwap_flexFormCallBack ($pParams, $dsConf, $dataValue, $dataValue_ext1, $dataValue_ext2, $path)
 
 version_remapMMForVersionSwap_execSwap ($table, $id, $swapWith)
 
 remapListedDBRecords ()
 
array remapListedDBRecords_flexFormCallBack ($pParams, $dsConf, $dataValue, $dataValue_ext1, $dataValue_ext2)
 
array null remapListedDBRecords_procDBRefs ($conf, $value, $MM_localUid, $table)
 
 remapListedDBRecords_procInline ($conf, $value, $uid, $table)
 
 processRemapStack ()
 
 addRemapAction ($table, $id, array $callback, array $arguments)
 
 getVersionizedIncomingFieldArray ($table, $id, &$incomingFieldArray, &$registerDBList)
 
bool checkModifyAccessList ($table)
 
bool isRecordInWebMount ($table, $id)
 
bool isInWebMount ($pid)
 
bool checkRecordUpdateAccess ($table, $id, $data=false, $hookObjectsArr=null)
 
bool checkRecordInsertAccess ($insertTable, $pid, $action=SystemLogDatabaseAction::INSERT)
 
bool isTableAllowedForThisPage ($page_uid, $checkTable)
 
bool doesRecordExist ($table, $id, $perms)
 
string int doesBranchExist ($inList, $pid, $perms, $recurse)
 
bool tableReadOnly ($table)
 
bool tableAdminOnly ($table)
 
bool destNotInsideSelf ($destinationId, $id)
 
array getExcludeListArray ()
 
bool array doesPageHaveUnallowedTables ($page_uid, $doktype)
 
string pageInfo ($id, $field)
 
array null recordInfo ($table, $id, $fieldList)
 
array getRecordProperties ($table, $id, $noWSOL=false)
 
array null getRecordPropertiesFromRow ($table, $row)
 
int eventPid ($table, $uid, $pid)
 
 updateDB ($table, $id, $fieldArray)
 
int null insertDB ($table, $id, $fieldArray, $newVersion=false, $suggestedUid=0, $dontSetNewIdIndex=false)
 
array null checkStoredRecord ($table, $id, $fieldArray, $action)
 
 setHistory ($table, $id, $logId)
 
 updateRefIndex ($table, $uid, int $workspace=null)
 
 registerReferenceIndexRowsForDrop (string $table, int $uid, int $workspace)
 
int array bool null getSortNumber ($table, $uid, $pid)
 
array setTSconfigPermissions ($fieldArray, $TSConfig_p)
 
array newFieldArray ($table)
 
 addDefaultPermittedLanguageIfNotSet ($table, &$incomingFieldArray)
 
array overrideFieldArray ($table, $data)
 
array compareFieldArrayWithCurrentAndUnset ($table, $id, $fieldArray)
 
int assemblePermissions ($string)
 
string convNumEntityToByteValue ($input)
 
 disableDeleteClause ()
 
string deleteClause ($table)
 
array getTableEntries ($table, $TSconfig)
 
int false getPID ($table, $uid)
 
 dbAnalysisStoreExec ()
 
array int_pageTreeInfo ($CPtable, $pid, $counter, $rootID)
 
array compileAdminTables ()
 
 fixUniqueInPid ($table, $uid)
 
array fixCopyAfterDuplFields ($table, $uid, $prevUid, $update, $newData=[])
 
bool isReferenceField ($conf)
 
string bool getInlineFieldType ($conf)
 
string getCopyHeader ($table, $pid, $field, $value, $count, $prevTitle='')
 
string prependLabel ($table)
 
int resolvePid ($table, $pid)
 
string clearPrefixFromValue ($table, $value)
 
bool isRecordCopied ($table, $uid)
 
 registerRecordIdForPageCacheClearing ($table, $uid, $pid=null)
 
 clear_cacheCmd ($cacheCmd)
 
int log ($table, $recuid, $action, $recpid, $error, $details, $details_nr=-1, $data=[], $event_pid=-1, $NEWid='')
 
int newlog ($message, $error=SystemLogErrorClassification::MESSAGE)
 
 printLogErrorMessages ()
 
array insertUpdateDB_preprocessBasedOnFieldType ($table, $fieldArray)
 
bool hasDeletedRecord ($tableName, $uid)
 
int null getAutoVersionId ($table, $id)
 
bool isOuterMostInstance ()
 
 setCorrelationId (CorrelationId $correlationId)
 
CorrelationId null getCorrelationId ()
 
array getHistoryRecords ()
 

Public Attributes

bool $storeLogMessages = true
 
bool $enableLogging = true
 
bool $reverseOrder = false
 
bool $checkSimilar = true
 
bool $checkStoredRecords = true
 
bool $checkStoredRecords_loose = true
 
bool $deleteTree = false
 
bool $neverHideAtCopy = false
 
bool $isImporting = false
 
bool $dontProcessTransformations = false
 
bool $bypassWorkspaceRestrictions = false
 
bool $bypassAccessCheckForRecords = false
 
string $copyWhichTables = '*'
 
int $copyTree = 0
 
array $defaultValues = array( )
 
array $overrideValues = array( )
 
array $data_disableFields = array( )
 
array $suggestedInsertUids = array( )
 
object $callBackObj
 
array $autoVersionIdMap = array( )
 
array $substNEWwithIDs = array( )
 
array $substNEWwithIDs_table = array( )
 
array $newRelatedIDs = array( )
 
array $copyMappingArray_merged = array( )
 
array $errorLog = array( )
 
array $pagetreeRefreshFieldsFromPages = array( 'pid', 'sorting', 'deleted', 'hidden', 'title', 'doktype', 'is_siteroot', 'fe_group', 'nav_hide', 'nav_title', 'module', 'starttime', 'endtime', 'content_from_pid', 'extendToSubpages' )
 
bool $pagetreeNeedsRefresh = false
 
BackendUserAuthentication $BE_USER
 
int $userid
 
string $username
 
bool $admin
 
array $defaultPermissions
 
array $datamap = array( )
 
array $cmdmap = array( )
 
array $pMap
 
int $sortIntervals = 256
 
array $dbAnalysisStore = array( )
 
array $registerDBList = array( )
 
array $registerDBPids = array( )
 
array $copyMappingArray = array( )
 
array $remapStack = array( )
 
array $remapStackRecords = array( )
 
bool $callFromImpExp = false
 
array $checkValue_currentRecord = array( )
 

Protected Member Functions

array applyDefaultsForFieldArray (string $table, int $pageId, array $prepopulatedFieldArray)
 
array getCheckModifyAccessListHookObjects ()
 
string normalizeTimeFormat (string $table, string $value, string $dbType)
 
array resolveSortingAndPidForNewRecord (string $table, int $pid, array $fieldArray)
 
array resolveFieldConfigurationAndRespectColumnsOverrides (string $table, string $field)
 
array checkValueForInternalReferences (array $res, $value, $tcaFieldConf, $table, $id, $field)
 
array checkValueForText ($value, $tcaFieldConf, $table, $id, $realPid, $field)
 
array checkValueForInput ($value, $tcaFieldConf, $table, $id, $realPid, $field)
 
array checkValueForSlug (string $value, array $tcaFieldConf, string $table, $id, int $realPid, string $field, array $incomingFieldArray=[])
 
array checkValueForCheck ($res, $value, $tcaFieldConf, $table, $id, $realPid, $field)
 
array checkValueForRadio ($res, $value, $tcaFieldConf, $table, $id, $pid, $field)
 
array checkValueForGroupSelect ($res, $value, $tcaFieldConf, $table, $id, $curValue, $status, $recFID, $uploadedFiles, $field)
 
array mixed applyFiltersToValues (array $tcaFieldConfiguration, array $values)
 
array checkValueForFlex ($res, $value, $tcaFieldConf, $table, $id, $curValue, $status, $realPid, $recFID, $tscPID, $uploadedFiles, $field)
 
 _ACTION_FLEX_FORMdata (&$valueArray, $actionCMDs)
 
QueryBuilder getUniqueCountStatement (string $value, string $table, string $field, int $uid, int $pid)
 
 checkValue_input_ValidateEmail ($value, &$set, string $table, $id)
 
string checkValue_inline_processDBdata ($valueArray, $tcaFieldConf, $id, $status, $table, $field, array $additionalData=null)
 
array getAllowedTablesToCopyWhenCopyingAPage ()
 
mixed copyRecord_processManyToMany ($table, $uid, $field, $value, $conf, $language)
 
string copyRecord_processInline ( $table, $uid, $field, $value, $row, $conf, $realDestPid, $language, array $workspaceOptions)
 
 copy_remapTranslationSourceField ($table, $l10nRecords, $languageSourceMap)
 
 inlineLocalizeSynchronize ($table, $id, $command)
 
bool isRecordLocalized (string $table, int $uid, int $language)
 
 copyMovedRecordToNewLocation ($table, $uid)
 
 discardSubPagesAndRecordsOnPage (array $page)
 
 discardRecordRelations (string $table, array $record)
 
 discardMmRelations (string $table, array $fieldConfig, array $record)
 
 discardLocalizationOverlayRecords (string $table, array $record)
 
DataHandler getLocalTCE ()
 
 updateFlexFormData ($flexFormId, array $modifications)
 
 triggerRemapAction ($table, $id, array $callback, array $arguments, $forceRemapStackActions=false)
 
 hardDeleteSingleRecord (string $table, int $uid)
 
bool array doesRecordExist_pageLookUp ($id, $perms, $columns=['uid'])
 
array bool recordInfoWithPermissionCheck (string $table, int $id, $perms, string $fieldList=' *')
 
RecordHistoryStore getRecordHistoryStore ()
 
 increaseSortingOfFollowingRecords (string $table, int $pid, int $sortingValue=null)
 
int getPreviousLocalizedRecordUid ($table, $uid, $pid, $language)
 
bool isSubmittedValueEqualToStoredValue ($submittedValue, $storedValue, $storedType, $allowNull=false)
 
 addDeleteRestriction (QueryRestrictionContainerInterface $restrictions)
 
int[] getOriginalParentOfRecord ($table, $uid)
 
bool fixUniqueInSite (string $table, int $uid)
 
 fixUniqueInSiteForSubpages (int $pageId)
 
int string castReferenceValue ($value, array $configuration)
 
string[] null checkForRecordsFromDisallowedTables (array $pageIds)
 
 processClearCacheQueue ()
 
array prepareCacheFlush ($table, $uid, $pid)
 
int getDefaultLanguagePageId (int $pageId)
 
int overlayAutoVersionId ($table, $id)
 
 addNewValuesToRemapStackChildIds (array $idValues)
 
array resolveVersionedRecords ($tableName, $fieldNames, $sortingField, array $liveIds)
 
DataHandler getOuterMostInstance ()
 
FrontendInterface getRuntimeCache ()
 
bool isNestedElementCallRegistered ($table, $id, $identifier)
 
 registerNestedElementCall ($table, $id, $identifier)
 
 resetNestedElementCalls ()
 
bool isElementToBeDeleted ($table, $id)
 
 registerElementsToBeDeleted ()
 
 resetElementsToBeDeleted ()
 
array unsetElementsToBeDeleted (array $elements)
 
array getCommandMapElements ($needle)
 
 controlActiveElements ()
 
 setNullValues (array $active, array &$haystack)
 
int postProcessDatabaseInsert (Connection $connection, string $tableName, int $suggestedUid)
 
int postProcessSqlServerInsert (Connection $connection, string $tableName)
 
 postProcessPostgresqlInsert (Connection $connection, string $tableName)
 
string getFieldEvalCacheIdentifier ($additionalIdentifier)
 
RelationHandler createRelationHandlerInstance ()
 
CacheManager getCacheManager ()
 
ResourceFactory getResourceFactory ()
 
LanguageService getLanguageService ()
 

Protected Attributes

bool $useTransOrigPointerField = true
 
CorrelationId null $correlationId
 
array $deletedRecords = array( )
 
PagePermissionAssembler $pagePermissionAssembler
 
array $excludedTablesAndFields = array( )
 
array $control = array( )
 
array $mmHistoryRecords = array( )
 
array $historyRecords = array( )
 
array $recInsertAccessCache = array( )
 
array $isRecordInWebMount_Cache = array( )
 
array $isInWebMount_Cache = array( )
 
array $pageCache = array( )
 
array $remapStackChildIds = array( )
 
array $remapStackActions = array( )
 
ReferenceIndexUpdater $referenceIndexUpdater
 
bool $disableDeleteClause = false
 
array $checkModifyAccessListHookObjects
 
array $version_remapMMForVersionSwap_reg
 
TYPO3 CMS Core DataHandling DataHandler $outerMostInstance
 
TYPO3 CMS Core Cache Frontend FrontendInterface $runtimeCache
 
string $cachePrefixNestedElementCalls = 'core-datahandler-nestedElementCalls-'
 

Static Protected Attributes

static array $recordsToClearCacheFor = array( )
 
static array $recordPidsForDeletedRecords = array( )
 

Detailed Description

The main data handler class which takes care of correctly updating and inserting records. This class was formerly known as TCEmain.

This is the TYPO3 Core Engine class for manipulation of the database This class is used by eg. the tce_db BE route (SimpleDataHandlerController) which provides an interface for POST forms to this class.

Dependencies:

  • ‪$GLOBALS['TCA'] must exist
  • ‪$GLOBALS['LANG'] must exist

Also see document 'TYPO3 Core API' for details.

Definition at line 83 of file DataHandler.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\DataHandling\DataHandler::__construct ( ReferenceIndexUpdater  $referenceIndexUpdater = null)

Sets up the data handler cache and some additional options, the main logic is done in the start() method.

Parameters
ReferenceIndexUpdater | null$referenceIndexUpdater‪Hand over from outer most instance to sub instances

Definition at line 587 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$referenceIndexUpdater, and TYPO3\CMS\Core\DataHandling\DataHandler\getRuntimeCache().

Member Function Documentation

◆ _ACTION_FLEX_FORMdata()

TYPO3\CMS\Core\DataHandling\DataHandler::_ACTION_FLEX_FORMdata ( $valueArray,
  $actionCMDs 
)
protected

Actions for flex form element (move, delete) allows to remove and move flexform sections

Parameters
array$valueArray‪by reference
array$actionCMDs

Definition at line 2286 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForFlex().

◆ addDefaultPermittedLanguageIfNotSet()

TYPO3\CMS\Core\DataHandling\DataHandler::addDefaultPermittedLanguageIfNotSet (   $table,
$incomingFieldArray 
)

If a "languageField" is specified for $table this function will add a possible value to the incoming array if none is found in there already.

Parameters
string$table‪Table name
array$incomingFieldArray‪Incoming array (passed by reference)

should only be used from within DataHandler

Definition at line 7764 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ addDeleteRestriction()

◆ addNewValuesToRemapStackChildIds()

TYPO3\CMS\Core\DataHandling\DataHandler::addNewValuesToRemapStackChildIds ( array  $idValues)
protected

◆ addRemapAction()

TYPO3\CMS\Core\DataHandling\DataHandler::addRemapAction (   $table,
  $id,
array  $callback,
array  $arguments 
)

Adds an instruction to the remap action stack (used with IRRE).

Parameters
string$table‪The affected table
int$id‪The affected ID
array$callback‪The callback information (object and method)
array$arguments‪The arguments to be used with the callback

should only be used from within DataHandler

Definition at line 6399 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\triggerRemapAction(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap_processFields().

◆ applyDefaultsForFieldArray()

array TYPO3\CMS\Core\DataHandling\DataHandler::applyDefaultsForFieldArray ( string  $table,
int  $pageId,
array  $prepopulatedFieldArray 
)
protected

When a new record is created, all values that haven't been set but are set via PageTSconfig / UserTSconfig get applied here.

This is only executed for new records. The most important part is that the pageTS of the actual resolved $pid is taken, and a new field array with empty defaults is set again.

Parameters
string$table
int$pageId
array$prepopulatedFieldArray
Returns
‪array

Definition at line 736 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Backend\Utility\BackendUtility\getPagesTSconfig(), TYPO3\CMS\Core\DataHandling\DataHandler\newFieldArray(), and TYPO3\CMS\Core\DataHandling\DataHandler\setDefaultsFromUserTS().

◆ applyFiltersToValues()

array mixed TYPO3\CMS\Core\DataHandling\DataHandler::applyFiltersToValues ( array  $tcaFieldConfiguration,
array  $values 
)
protected

Applies the filter methods from a column's TCA configuration to a value array.

Parameters
array$tcaFieldConfiguration
array$values
Returns
‪array|mixed
Exceptions

Definition at line 2130 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_inline_processDBdata(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect().

◆ assemblePermissions()

int TYPO3\CMS\Core\DataHandling\DataHandler::assemblePermissions (   $string)

Calculates the bitvalue of the permissions given in a string, comma-separated

Parameters
string$string‪List of pMap strings
Returns
‪int Integer mask
See also
setTSconfigPermissions()
newFieldArray()
Deprecated:
‪will be removed in TYPO3 v11.0 - Use PagePermissionAssembler instead.

Definition at line 7909 of file DataHandler.php.

References TYPO3\CMS\Core\Type\Bitmask\Permission\getMap(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\setTSconfigPermissions().

◆ canDeletePage()

int [] string TYPO3\CMS\Core\DataHandling\DataHandler::canDeletePage (   $uid)

◆ cannotDeleteRecord()

string TYPO3\CMS\Core\DataHandling\DataHandler::cannotDeleteRecord (   $table,
  $id 
)

Returns TRUE if record CANNOT be deleted, otherwise FALSE. Used to check before the versioning API allows a record to be marked for deletion.

Parameters
string$table‪Record Table
int$id‪Record UID
Returns
‪string Returns a string IF there is an error (error string explaining). FALSE means record can be deleted

should only be used from within DataHandler

Definition at line 5222 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\canDeletePage(), TYPO3\CMS\Core\Type\Bitmask\Permission\CONTENT_EDIT, TYPO3\CMS\Core\DataHandling\DataHandler\doesRecordExist(), and TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_EDIT.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\versionizeRecord().

◆ castReferenceValue()

int string TYPO3\CMS\Core\DataHandling\DataHandler::castReferenceValue (   $value,
array  $configuration 
)
protected

Casts a reference value. In case MM relations or foreign_field references are used. All other configurations, as well as foreign_table(!) could be stored as comma-separated-values as well. Since the system is not able to determine the default value automatically then, the TCA default value is used if it has been defined.

Parameters
int | string$value‪The value to be casted (e.g. '', '0', '1,2,3')
array$configuration‪The TCA configuration of the accordant field
Returns
‪int|string

Definition at line 8256 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_inline_processDBdata(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect(), and TYPO3\CMS\Core\DataHandling\DataHandler\processRemapStack().

◆ checkForRecordsFromDisallowedTables()

string [] null TYPO3\CMS\Core\DataHandling\DataHandler::checkForRecordsFromDisallowedTables ( array  $pageIds)
protected

Check if there are records from tables on the pages to be deleted which the current user is not allowed to

Parameters
int[]$pageIds‪IDs of pages which should be checked
Returns
‪string[]|null Return null, if permission granted, otherwise an array with the tables that are not allowed to be deleted
See also
canDeletePage()

Definition at line 8410 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkModifyAccessList(), TYPO3\CMS\Core\DataHandling\DataHandler\compileAdminTables(), and TYPO3\CMS\Core\DataHandling\DataHandler\tableReadOnly().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\canDeletePage().

◆ checkModifyAccessList()

bool TYPO3\CMS\Core\DataHandling\DataHandler::checkModifyAccessList (   $table)

Checking group modify_table access list

Parameters
string$table‪Table name
Returns
‪bool Returns TRUE if the user has general access to modify the $table

should only be used from within DataHandler

Definition at line 6472 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getCheckModifyAccessListHookObjects(), and TYPO3\CMS\Core\DataHandling\DataHandler\tableAdminOnly().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkForRecordsFromDisallowedTables(), TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ checkRecordInsertAccess()

bool TYPO3\CMS\Core\DataHandling\DataHandler::checkRecordInsertAccess (   $insertTable,
  $pid,
  $action = SystemLogDatabaseAction::INSERT 
)

Checks if user may insert a record from $insertTable on $pid Does not check for workspace, use BE_USER->workspaceAllowLiveRecordsInPID for this in addition to this function call.

Parameters
string$insertTable‪Tablename to check
int$pid‪Integer PID
int$action‪For logging: Action number.
Returns
‪bool Returns TRUE if the user may insert a record from table $insertTable on page $pid

should only be used from within DataHandler

Definition at line 6574 of file DataHandler.php.

References TYPO3\CMS\Core\Type\Bitmask\Permission\CONTENT_EDIT, TYPO3\CMS\Core\DataHandling\DataHandler\doesRecordExist(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Backend\Utility\BackendUtility\isRootLevelRestrictionIgnored(), TYPO3\CMS\Core\DataHandling\DataHandler\isTableAllowedForThisPage(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_EDIT, and TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_NEW.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ checkRecordUpdateAccess()

bool TYPO3\CMS\Core\DataHandling\DataHandler::checkRecordUpdateAccess (   $table,
  $id,
  $data = false,
  $hookObjectsArr = null 
)

Checks if user may update a record with uid=$id from $table

Parameters
string$table‪Record table
int$id‪Record UID
array | bool$data‪Record data
array$hookObjectsArr‪Hook objects
Returns
‪bool Returns TRUE if the user may update the record given by $table and $id

should only be used from within DataHandler

Definition at line 6525 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Type\Bitmask\Permission\CONTENT_EDIT, TYPO3\CMS\Core\DataHandling\DataHandler\doesRecordExist(), and TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_EDIT.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\discard(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap(), TYPO3\CMS\Redirects\Hooks\DataHandlerSlugUpdateHook\processDatamap_preProcessFieldArray(), TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_setStage(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ checkStoredRecord()

array null TYPO3\CMS\Core\DataHandling\DataHandler::checkStoredRecord (   $table,
  $id,
  $fieldArray,
  $action 
)

Checking stored record to see if the written values are properly updated.

Parameters
string$table‪Record table name
int$id‪Record uid
array$fieldArray‪Array of field=>value pairs to insert/update
string$action‪Action, for logging only.
Returns
‪array|null Selected row
See also
insertDB()
updateDB()

should only be used from within DataHandler

Definition at line 7288 of file DataHandler.php.

References $errors, $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\log(), and TYPO3\CMS\Core\DataHandling\DataHandler\normalizeTimeFormat().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\insertDB(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateDB().

◆ checkValue()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue (   $table,
  $field,
  $value,
  $id,
  $status,
  $realPid,
  $tscPID,
  $incomingFieldArray = [] 
)

Evaluates a value according to $table/$field settings. This function is for real database fields - NOT FlexForm "pseudo" fields. NOTICE: Calling this function expects this: 1) That the data is saved!

Parameters
string$table‪Table name
string$field‪Field name
string$value‪Value to be evaluated. Notice, this is the INPUT value from the form. The original value (from any existing record) must be manually looked up inside the function if needed - or taken from $currentRecord array.
string$id‪The record-uid, mainly - but not exclusively - used for logging
string$status‪'update' or 'new' flag
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
int$tscPID‪TSconfig PID
array$incomingFieldArray‪the fields being explicitly set by the outside (unlike $fieldArray)
Returns
‪array Returns the evaluated $value as key "value" in this array. Can be checked with isset($res['value']) ...

should only be used from within DataHandler

Definition at line 1502 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW(), TYPO3\CMS\Core\DataHandling\DataHandler\doesPageHaveUnallowedTables(), TYPO3\CMS\Core\DataHandling\DataHandler\getDefaultLanguagePageId(), TYPO3\CMS\Core\DataHandling\DataHandler\getLanguageService(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), and TYPO3\CMS\Core\DataHandling\DataHandler\resolveFieldConfigurationAndRespectColumnsOverrides().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\fillInFieldArray(), and TYPO3\CMS\Core\DataHandling\DataHandler\insertNewCopyVersion().

◆ checkValue_checkMax()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_checkMax (   $tcaFieldConf,
  $valueArray 
)

Checks if a fields has more items than defined via TCA in maxitems. If there are more items than allowed, the item list is truncated to the defined number.

Parameters
array$tcaFieldConf‪Field configuration from TCA
array$valueArray‪Current value array of items
Returns
‪array The truncated value array of items

should only be used from within DataHandler

Definition at line 2388 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_inline_processDBdata(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect(), and TYPO3\CMS\Core\DataHandling\DataHandler\processRemapStack().

◆ checkValue_flex_procInData()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_flex_procInData (   $dataPart,
  $dataPart_current,
  $uploadedFiles,
  $dataStructure,
  $pParams,
  $callBackFunc = '',
array  $workspaceOptions = [] 
)

Starts the processing the input data for flexforms. This will traverse all sheets / languages and for each it will traverse the sub-structure. See checkValue_flex_procInData_travDS() for more details. WARNING: Currently, it traverses based on the actual data array and NOT the structure. This means that values for non-valid fields, lKey/vKey/sKeys will be accepted! For traversal of data with a call back function you should rather use \TYPO3\CMS\Core\Configuration\FlexForm\FlexFormTools

Parameters
array$dataPart‪The 'data' part of the INPUT flexform data
array$dataPart_current‪The 'data' part of the CURRENT flexform data
array$uploadedFiles‪The uploaded files for the 'data' part of the INPUT flexform data
array$dataStructure‪Data structure for the form (might be sheets or not). Only values in the data array which has a configuration in the data structure will be processed.
array$pParams‪A set of parameters to pass through for the calling of the evaluation functions
string$callBackFunc‪Optional call back function, see checkValue_flex_procInData_travDS() DEPRECATED, use \TYPO3\CMS\Core\Configuration\FlexForm\FlexFormTools instead for traversal!
array$workspaceOptions
Returns
‪array The modified 'data' part.
See also
checkValue_flex_procInData_travDS()

should only be used from within DataHandler

Definition at line 2885 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flex_procInData_travDS().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForFlex(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_procBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords(), and TYPO3\CMS\Core\DataHandling\DataHandler\version_remapMMForVersionSwap().

◆ checkValue_flex_procInData_travDS()

TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_flex_procInData_travDS ( $dataValues,
  $dataValues_current,
  $uploadedFiles,
  $DSelements,
  $pParams,
  $callBackFunc,
  $structurePath,
array  $workspaceOptions = [] 
)

Processing of the sheet/language data array When it finds a field with a value the processing is done by ->checkValue_SW() by default but if a call back function name is given that method in this class will be called for the processing instead.

Parameters
array$dataValues‪New values (those being processed): Multidimensional Data array for sheet/language, passed by reference!
array$dataValues_current‪Current values: Multidimensional Data array. May be empty array() if not needed (for callBackFunctions)
array$uploadedFiles‪Uploaded files array for sheet/language. May be empty array() if not needed (for callBackFunctions)
array$DSelements‪Data structure which fits the data array
array$pParams‪A set of parameters to pass through for the calling of the evaluation functions / call back function
string$callBackFunc‪Call back function, default is checkValue_SW(). If $this->callBackObj is set to an object, the callback function in that object is called instead.
string$structurePath
array$workspaceOptions
See also
checkValue_flex_procInData()

should only be used from within DataHandler

Definition at line 2923 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flex_procInData().

◆ checkValue_flexArray2Xml()

string TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_flexArray2Xml (   $array,
  $addPrologue = false 
)

Converts an array to FlexForm XML

Parameters
array$array‪Array with FlexForm data
bool$addPrologue‪If set, the XML prologue is returned as well.
Returns
‪string Input array converted to XML

should only be used from within DataHandler

Definition at line 2272 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForFlex(), TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateFlexFormData().

◆ checkValue_group_select_explodeSelectGroupValue()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_group_select_explodeSelectGroupValue (   $value)

Explodes the $value, which is a list of files/uids (group select)

Parameters
string$value‪Input string, comma separated values. For each part it will also be detected if a '|' is found and the first part will then be used if that is the case. Further the value will be rawurldecoded.
Returns
‪array The value array.

should only be used from within DataHandler

Definition at line 2858 of file DataHandler.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect().

◆ checkValue_group_select_processDBdata()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_group_select_processDBdata (   $valueArray,
  $tcaFieldConf,
  $id,
  $status,
  $type,
  $currentTable,
  $currentField 
)

Returns data for group/db and select fields

Parameters
array$valueArray‪Current value array
array$tcaFieldConf‪TCA field config
int$id‪Record id, used for look-up of MM relations (local_uid)
string$status‪Status string ('update' or 'new')
string$type‪The type, either 'select', 'group' or 'inline'
string$currentTable‪Table name, needs to be passed to \TYPO3\CMS\Core\Database\RelationHandler
string$currentField‪field name, needs to be set for writing to sys_history
Returns
‪array Modified value array

should only be used from within DataHandler

Definition at line 2806 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_inline_processDBdata(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect().

◆ checkValue_inline()

TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_inline (   $res,
  $value,
  $tcaFieldConf,
  $PP,
  $field,
array  $additionalData = null 
)

Evaluates 'inline' type values. (partly copied from the select_group function on this issue)

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
array$PP‪Additional parameters in a numeric array: $table,$id,$curValue,$status,$realPid,$recFID
string$field‪Field name
array$additionalData‪Additional data to be forwarded to sub-processors

should only be used from within DataHandler

Definition at line 2328 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInline().

◆ checkValue_inline_processDBdata()

string TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_inline_processDBdata (   $valueArray,
  $tcaFieldConf,
  $id,
  $status,
  $table,
  $field,
array  $additionalData = null 
)
protected

Returns data for inline fields.

Parameters
array$valueArray‪Current value array
array$tcaFieldConf‪TCA field config
int$id‪Record id
string$status‪Status string ('update' or 'new')
string$table‪Table name, needs to be passed to \TYPO3\CMS\Core\Database\RelationHandler
string$field‪The current field the values are modified for
array$additionalData‪Additional data to be forwarded to sub-processors
Returns
‪string Modified values

Definition at line 3034 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\applyFiltersToValues(), TYPO3\CMS\Core\DataHandling\DataHandler\castReferenceValue(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_checkMax(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_group_select_processDBdata(), TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), and TYPO3\CMS\Core\DataHandling\DataHandler\getInlineFieldType().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInline().

◆ checkValue_input_Eval()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_input_Eval (   $value,
  $evalArray,
  $is_in,
string  $table = '',
  $id = '' 
)

Evaluation of 'input'-type values based on 'eval' list

Parameters
string$value‪Value to evaluate
array$evalArray‪Array of evaluations to traverse.
string$is_in‪Is-in string for 'is_in' evaluation
string$table‪Table name the eval is evaluated on
string | int$id‪Record ID the eval is evaluated on
Returns
‪array Modified $value in key 'value' or empty array

should only be used from within DataHandler

Definition at line 2617 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_input_ValidateEmail(), and TYPO3\CMS\Core\Utility\HttpUtility\idn_to_ascii().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInput(), TYPO3\CMS\Core\Tests\Unit\DataHandling\DataHandlerTest\checkValueInputEvalWithSaltedPasswordKeepsExistingHash(), TYPO3\CMS\Core\Tests\Unit\DataHandling\DataHandlerTest\checkValueInputEvalWithSaltedPasswordReturnsHashForSaltedPassword(), and TYPO3\CMS\Core\DataHandling\DataHandler\getPlaceholderTitleForTableLabel().

◆ checkValue_input_ValidateEmail()

TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_input_ValidateEmail (   $value,
$set,
string  $table,
  $id 
)
protected

If $value is not a valid e-mail address, $set will be set to false and a flash error message will be added

Parameters
string$value‪Value to evaluate
bool$set‪TRUE if an update should be done
Exceptions

Definition at line 2774 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getLanguageService(), and TYPO3\CMS\Core\DataHandling\DataHandler\log().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_input_Eval().

◆ checkValue_SW()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_SW (   $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $curValue,
  $status,
  $realPid,
  $recFID,
  $field,
  $uploadedFiles,
  $tscPID,
array  $additionalData = null 
)

Branches out evaluation of a field value based on its type as configured in $GLOBALS['TCA'] Can be called for FlexForm pseudo fields as well, BUT must not have $field set if so.

Parameters
array$res‪The result array. The processed value (if any!) is set in the "value" key.
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from $GLOBALS['TCA']
string$table‪Table name
int$id‪UID of record
mixed$curValue‪Current value of the field
string$status‪'update' or 'new' flag
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$recFID‪Field identifier [table:uid:field] for flexforms
string$field‪Field name. Must NOT be set if the call is for a flexform field (since flexforms are not allowed within flexforms).
array$uploadedFiles
int$tscPID‪TSconfig PID
array$additionalData‪Additional data to be forwarded to sub-processors
Returns
‪array Returns the evaluated $value as key "value" in this array.

should only be used from within DataHandler

Definition at line 1631 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForCheck(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForFlex(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInline(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInput(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInternalReferences(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForRadio(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForSlug(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForText().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flex_procInData_travDS().

◆ checkValue_text_Eval()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValue_text_Eval (   $value,
  $evalArray,
  $is_in 
)
Parameters
string$value‪The field value to be evaluated
array$evalArray‪Array of evaluations to traverse.
string$is_in‪The "is_in" value of the field configuration from TCA
Returns
‪array

should only be used from within DataHandler

Definition at line 2575 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForText().

◆ checkValueForCheck()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForCheck (   $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $realPid,
  $field 
)
protected

Evaluates 'check' type values.

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$field‪Field name
Returns
‪array Modified $res array

Definition at line 1930 of file DataHandler.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\getItemLabel(), TYPO3\CMS\Core\DataHandling\DataHandler\getLanguageService(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordsWithSameValue(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForFlex()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForFlex (   $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $curValue,
  $status,
  $realPid,
  $recFID,
  $tscPID,
  $uploadedFiles,
  $field 
)
protected

Evaluates 'flex' type values.

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string | array$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
mixed$curValue‪Current value of the field
string$status‪'update' or 'new' flag
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$recFID‪Field identifier [table:uid:field] for flexforms
int$tscPID‪TSconfig PID
array$uploadedFiles‪Uploaded files for the field
string$field‪Field name
Returns
‪array Modified $res array

Definition at line 2167 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$checkValue_currentRecord, $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\_ACTION_FLEX_FORMdata(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flex_procInData(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flexArray2Xml(), TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled(), TYPO3\CMS\Core\Utility\ArrayUtility\mergeRecursiveWithOverrule(), and TYPO3\CMS\Core\Utility\GeneralUtility\xml2array().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForGroupSelect()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForGroupSelect (   $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $curValue,
  $status,
  $recFID,
  $uploadedFiles,
  $field 
)
protected

Evaluates 'group' or 'select' type values.

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string | array$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
mixed$curValue‪Current value of the field
string$status‪'update' or 'new' flag
string$recFID‪Field identifier [table:uid:field] for flexforms
array$uploadedFiles
string$field‪Field name
Returns
‪array Modified $res array

Definition at line 2051 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addNewValuesToRemapStackChildIds(), TYPO3\CMS\Core\DataHandling\DataHandler\applyFiltersToValues(), TYPO3\CMS\Core\DataHandling\DataHandler\castReferenceValue(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_checkMax(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_group_select_explodeSelectGroupValue(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_group_select_processDBdata(), TYPO3\CMS\Core\DataHandling\DataHandler\convNumEntityToByteValue(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForInline()

array bool TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForInline (   $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $status,
  $field,
array  $additionalData = null 
)

Evaluates 'inline' type values. (partly copied from the select_group function on this issue)

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
string$status‪'update' or 'new' flag
string$field‪Field name
array$additionalData‪Additional data to be forwarded to sub-processors
Returns
‪array|bool Modified $res array

should only be used from within DataHandler

Definition at line 2349 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addNewValuesToRemapStackChildIds(), TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_inline_processDBdata(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_inline(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForInput()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForInput (   $value,
  $tcaFieldConf,
  $table,
  $id,
  $realPid,
  $field 
)
protected

Evaluate "input" type values.

Parameters
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$field‪Field name
Returns
‪array $res The result array. The processed value (if any!) is set in the "value" key.

Definition at line 1786 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_input_Eval(), TYPO3\CMS\Core\Database\Query\QueryHelper\getDateTimeFormats(), TYPO3\CMS\Core\Database\Query\QueryHelper\getDateTimeTypes(), TYPO3\CMS\Core\DataHandling\DataHandler\getFieldEvalCacheIdentifier(), TYPO3\CMS\Core\DataHandling\DataHandler\getUnique(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForInternalReferences()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForInternalReferences ( array  $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $field 
)
protected

Checks values that are used for internal references. If the provided $value is a NEW-identifier, the direct processing is stopped. Instead, the value is forwarded to the remap-stack to be post-processed and resolved into a proper UID after all data has been resolved.

This method considers TCA types that cannot handle and resolve these internal values directly, like 'passthrough', 'none' or 'user'. Values are only modified here if the $field is used as 'transOrigPointerField' or 'translationSource'.

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
string$field‪The field name
Returns
‪array The result array. The processed value (if any!) is set in the "value" key.

Definition at line 1698 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\DataHandling\DataHandler\addNewValuesToRemapStackChildIds().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForRadio()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForRadio (   $res,
  $value,
  $tcaFieldConf,
  $table,
  $id,
  $pid,
  $field 
)
protected

Evaluates 'radio' type values.

Parameters
array$res‪The result array. The processed value (if any!) is set in the 'value' key.
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪The table of the record
int$id‪The id of the record
int$pid‪The pid of the record
string$field‪The field to check
Returns
‪array Modified $res array

Definition at line 2002 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForSlug()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForSlug ( string  $value,
array  $tcaFieldConf,
string  $table,
  $id,
int  $realPid,
string  $field,
array  $incomingFieldArray = [] 
)
protected

Evaluate "slug" type values.

Parameters
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$field‪Field name
array$incomingFieldArray‪the fields being explicitly set by the outside (unlike $fieldArray) for the record
Returns
‪array $res The result array. The processed value (if any!) is set in the "value" key.
See also
SlugEnricher
SlugHelper

Definition at line 1885 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\Model\RecordStateFactory\forName(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ checkValueForText()

array TYPO3\CMS\Core\DataHandling\DataHandler::checkValueForText (   $value,
  $tcaFieldConf,
  $table,
  $id,
  $realPid,
  $field 
)
protected

Evaluate "text" type values.

Parameters
string$value‪The value to set.
array$tcaFieldConf‪Field configuration from TCA
string$table‪Table name
int$id‪UID of record
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$field‪Field name
Returns
‪array $res The result array. The processed value (if any!) is set in the "value" key.

Definition at line 1742 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_text_Eval(), TYPO3\CMS\Core\DataHandling\DataHandler\getFieldEvalCacheIdentifier(), TYPO3\CMS\Backend\Utility\BackendUtility\getTCAtypeValue(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_SW().

◆ clear_cacheCmd()

TYPO3\CMS\Core\DataHandling\DataHandler::clear_cacheCmd (   $cacheCmd)

Clears the cache based on the command $cacheCmd.

$cacheCmd='pages' Clears cache for all pages and page-based caches inside the cache manager. Requires admin-flag to be set for BE_USER.

$cacheCmd='all' Clears all cache_tables. This is necessary if templates are updated. Requires admin-flag to be set for BE_USER.

The following cache_* are intentionally not cleared by 'all'

  • ‪imagesizes: Clearing this table would cause a lot of unneeded Imagemagick calls because the size information has to be fetched again after clearing.
  • ‪all caches inside the cache manager that are inside the group "system"
  • ‪they are only needed to build up the core system and templates. If the group of system caches needs to be deleted explicitly, use flushCachesInGroup('system') of CacheManager directly.

$cacheCmd=[integer] Clears cache for the page pointed to by $cacheCmd (an integer).

$cacheCmd='cacheTag:[string]' Flush page and pagesection cache by given tag

$cacheCmd='cacheId:[string]' Removes cache identifier from page and page section cache

Can call a list of post processing functions as defined in $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['clearCachePostProc'] (numeric array with values being the function references, called by GeneralUtility::callUserFunction()).

Parameters
string$cacheCmd‪The cache command, see above description

Definition at line 8735 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), TYPO3\CMS\Core\Cache\CacheManager\flushCaches(), TYPO3\CMS\Core\Cache\CacheManager\flushCachesInGroup(), TYPO3\CMS\Core\Cache\CacheManager\flushCachesInGroupByTags(), and TYPO3\CMS\Core\DataHandling\DataHandler\getCacheManager().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\processClearCacheQueue().

◆ clearPrefixFromValue()

string TYPO3\CMS\Core\DataHandling\DataHandler::clearPrefixFromValue (   $table,
  $value 
)

Removes the prependAtCopy prefix on values

Parameters
string$table‪Table name
string$value‪The value to fix
Returns
‪string Clean name

should only be used from within DataHandler

Definition at line 8397 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\prependLabel().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord().

◆ compareFieldArrayWithCurrentAndUnset()

array TYPO3\CMS\Core\DataHandling\DataHandler::compareFieldArrayWithCurrentAndUnset (   $table,
  $id,
  $fieldArray 
)

Compares the incoming field array with the current record and unsets all fields which are the same. Used for existing records being updated

Parameters
string$table‪Record table name
int$id‪Record uid
array$fieldArray‪Array of field=>value pairs intended to be inserted into the database. All keys with values matching exactly the current value will be unset!
Returns
‪array Returns $fieldArray. If the returned array is empty, then the record should not be updated!

should only be used from within DataHandler

Definition at line 7816 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\DataHandling\DataHandler\isSubmittedValueEqualToStoredValue().

Referenced by TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ compileAdminTables()

array TYPO3\CMS\Core\DataHandling\DataHandler::compileAdminTables ( )

◆ controlActiveElements()

TYPO3\CMS\Core\DataHandling\DataHandler::controlActiveElements ( )
protected

Controls active elements and sets NULL values if not active. Datamap is modified accordant to submitted control values.

Definition at line 9204 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\setNullValues().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ convNumEntityToByteValue()

string TYPO3\CMS\Core\DataHandling\DataHandler::convNumEntityToByteValue (   $input)

Converts a HTML entity (like {) to the character '123'

Parameters
string$input‪Input string
Returns
‪string Output string

should only be used from within DataHandler

Definition at line 7930 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForGroupSelect().

◆ copy_remapTranslationSourceField()

TYPO3\CMS\Core\DataHandling\DataHandler::copy_remapTranslationSourceField (   $table,
  $l10nRecords,
  $languageSourceMap 
)
protected

Remap languageSource field to uids of newly created records

Parameters
string$table‪Table name
array$l10nRecords‪array of localized records from the page we're copying from (source records)
array$languageSourceMap‪array mapping source records uids to newly copied uids

Definition at line 3988 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyL10nOverlayRecords(), and TYPO3\CMS\Core\DataHandling\DataHandler\copySpecificPage().

◆ copyL10nOverlayRecords()

TYPO3\CMS\Core\DataHandling\DataHandler::copyL10nOverlayRecords (   $table,
  $uid,
  $destPid,
  $first = false,
  $overrideValues = [],
  $excludeFields = '' 
)

◆ copyMovedRecordToNewLocation()

TYPO3\CMS\Core\DataHandling\DataHandler::copyMovedRecordToNewLocation (   $table,
  $uid 
)
protected

Copies the move placeholder of a record to its new location (pid). This will create a "new" placeholder at the new location and a version for this new placeholder. The original move placeholder is then deleted because it is not needed anymore.

This method is used to assure that moved records are not deleted when the origin page is deleted.

Parameters
string$table‪Record table
int$uid‪Record uid

Definition at line 5125 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$enableLogging, TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Backend\Utility\BackendUtility\getMovePlaceholder(), and TYPO3\CMS\Backend\Utility\BackendUtility\getRecord().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteSpecificPage().

◆ copyPages()

TYPO3\CMS\Core\DataHandling\DataHandler::copyPages (   $uid,
  $destPid 
)

Copying pages Main function for copying pages.

Parameters
int$uidPage UID to copy
int$destPid‪Destination PID: >=0 then it points to a page-id on which to insert the record (as the first element). <0 then it points to a uid from its own table after which to insert it (works if

should only be used from within DataHandler

Definition at line 3359 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\copySpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\getAllowedTablesToCopyWhenCopyingAPage(), TYPO3\CMS\Core\DataHandling\DataHandler\int_pageTreeInfo(), and TYPO3\CMS\Core\DataHandling\DataHandler\log().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ copyRecord()

int null TYPO3\CMS\Core\DataHandling\DataHandler::copyRecord (   $table,
  $uid,
  $destPid,
  $first = false,
  $overrideValues = [],
  $excludeFields = '',
  $language = 0,
  $ignoreLocalization = false 
)

Copying a single record

Parameters
string$table‪Element table
int$uid‪Element UID
int$destPid‪>=0 then it points to a page-id on which to insert the record (as the first element). <0 then it points to a uid from its own table after which to insert it (works if
bool$first‪Is a flag set, if the record copied is NOT a 'slave' to another record copied. That is, if this record was asked to be copied in the cmd-array
array$overrideValues‪Associative array with field/value pairs to override directly. Notice; Fields must exist in the table record and NOT be among excluded fields!
string$excludeFields‪Commalist of fields to exclude from the copy process (might get default values)
int$language‪Language ID (from sys_language table)
bool$ignoreLocalization‪If TRUE, any localization routine is skipped
Returns
‪int|null ID of new record, if any

should only be used from within DataHandler

Definition at line 3232 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$overrideValues, TYPO3\CMS\Core\DataHandling\DataHandler\clearPrefixFromValue(), TYPO3\CMS\Core\DataHandling\DataHandler\copyL10nOverlayRecords(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_procBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\fixCopyAfterDuplFields(), TYPO3\CMS\Core\DataHandling\DataHandler\getCopyHeader(), TYPO3\CMS\Core\DataHandling\DataHandler\getLocalTCE(), TYPO3\CMS\Backend\Utility\BackendUtility\getPagesTSconfig(), TYPO3\CMS\Core\DataHandling\DataHandler\getTableEntries(), TYPO3\CMS\Backend\Utility\BackendUtility\getTSconfig_pidValue(), TYPO3\CMS\Core\Utility\StringUtility\getUniqueId(), TYPO3\CMS\Core\DataHandling\DataHandler\isRecordCopied(), TYPO3\CMS\Core\DataHandling\DataHandler\isTableAllowedForThisPage(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_SHOW, TYPO3\CMS\Backend\Utility\BackendUtility\purgeComputedPropertiesFromRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfoWithPermissionCheck(), TYPO3\CMS\Core\DataHandling\DataHandler\resolvePid(), TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode(), and TYPO3\CMS\Backend\Utility\BackendUtility\workspaceOL().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyL10nOverlayRecords(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processInline(), TYPO3\CMS\Core\DataHandling\DataHandler\copySpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\localize(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ copyRecord_flexFormCallBack()

array TYPO3\CMS\Core\DataHandling\DataHandler::copyRecord_flexFormCallBack (   $pParams,
  $dsConf,
  $dataValue,
  $_1,
  $_2,
  $_3,
  $workspaceOptions 
)

Callback function for traversing the FlexForm structure in relation to creating copied files of file relations inside of flex form structures.

Parameters
array$pParams‪Array of parameters in num-indexes: table, uid, field
array$dsConf‪TCA field configuration (from Data Structure XML)
string$dataValue‪The value of the flexForm field
string$_1‪Not used.
string$_2‪Not used.
string$_3‪Not used.
array$workspaceOptions
Returns
‪array Result array with key "value" containing the value of the processing.
See also
copyRecord()
checkValue_flex_procInData_travDS()

should only be used from within DataHandler

Definition at line 3889 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_procBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\getInlineFieldType(), and TYPO3\CMS\Core\DataHandling\DataHandler\isReferenceField().

◆ copyRecord_procBasedOnFieldType()

array string TYPO3\CMS\Core\DataHandling\DataHandler::copyRecord_procBasedOnFieldType (   $table,
  $uid,
  $field,
  $value,
  $row,
  $conf,
  $realDestPid,
  $language = 0,
array  $workspaceOptions = [] 
)

Processing/Preparing content for copyRecord() function

Parameters
string$table‪Table name
int$uid‪Record uid
string$field‪Field name being processed
string$value‪Input value to be processed.
array$row‪Record array
array$conf‪TCA field configuration
int$realDestPid‪Real page id (pid) the record is copied to
int$language‪Language ID (from sys_language table) used in the duplicated record
array$workspaceOptions‪Options to be forwarded if actions happen on a workspace currently
Returns
‪array|string
See also
copyRecord()

Definition at line 3702 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flex_procInData(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processInline(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processManyToMany(), TYPO3\CMS\Core\DataHandling\DataHandler\getInlineFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\isReferenceField(), and TYPO3\CMS\Core\Utility\GeneralUtility\xml2array().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_flexFormCallBack(), and TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_raw().

◆ copyRecord_processInline()

string TYPO3\CMS\Core\DataHandling\DataHandler::copyRecord_processInline (   $table,
  $uid,
  $field,
  $value,
  $row,
  $conf,
  $realDestPid,
  $language,
array  $workspaceOptions 
)
protected

◆ copyRecord_processManyToMany()

mixed TYPO3\CMS\Core\DataHandling\DataHandler::copyRecord_processManyToMany (   $table,
  $uid,
  $field,
  $value,
  $conf,
  $language 
)
protected

Processes the children of an MM relation field (select, group, inline) when the parent record is copied.

Parameters
string$table
int$uid
string$field
mixed$value
array$conf
string$language
Returns
‪mixed

Definition at line 3745 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecordLocalization(), TYPO3\CMS\Core\DataHandling\DataHandler\isNestedElementCallRegistered(), TYPO3\CMS\Backend\Utility\BackendUtility\isTableLocalizable(), and TYPO3\CMS\Core\DataHandling\DataHandler\localize().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_procBasedOnFieldType().

◆ copyRecord_raw()

int TYPO3\CMS\Core\DataHandling\DataHandler::copyRecord_raw (   $table,
  $uid,
  $pid,
  $overrideArray = [],
array  $workspaceOptions = [] 
)

Copying records, but makes a "raw" copy of a record. Basically the only thing observed is field processing like the copying of files and correction of ids. All other fields are 1-1 copied. Technically the copy is made with THIS instance of the DataHandler class contrary to copyRecord() which creates a new instance and uses the processData() function. The copy is created by insertNewCopyVersion() which bypasses most of the regular input checking associated with processData() - maybe copyRecord() should even do this as well!? This function is used to create new versions of a record. NOTICE: DOES NOT CHECK PERMISSIONS to create! And since page permissions are just passed through and not changed to the user who executes the copy we cannot enforce permissions without getting an incomplete copy - unless we change permissions of course.

Parameters
string$table‪Element table
int$uid‪Element UID
int$pid‪Element PID (real PID, not checked)
array$overrideArray‪Override array - must NOT contain any fields not in the table!
array$workspaceOptions‪Options to be forwarded if actions happen on a workspace currently
Returns
‪int Returns the new ID of the record (if applicable)

should only be used from within DataHandler

Definition at line 3568 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_procBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\dbAnalysisStoreExec(), TYPO3\CMS\Core\DataHandling\DataHandler\insertNewCopyVersion(), TYPO3\CMS\Core\DataHandling\DataHandler\isElementToBeDeleted(), TYPO3\CMS\Core\DataHandling\DataHandler\isRecordCopied(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_SHOW, and TYPO3\CMS\Core\DataHandling\DataHandler\recordInfoWithPermissionCheck().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processInline(), and TYPO3\CMS\Core\DataHandling\DataHandler\versionizeRecord().

◆ copySpecificPage()

int null TYPO3\CMS\Core\DataHandling\DataHandler::copySpecificPage (   $uid,
  $destPid,
  $copyTablesArray,
  $first = false 
)

Copying a single page ($uid) to $destPid and all tables in the array copyTablesArray.

Parameters
int$uidPage uid
int$destPid‪Destination PID: >=0 then it points to a page-id on which to insert the record (as the first element). <0 then it points to a uid from its own table after which to insert it (works if
array$copyTablesArray‪Table on pages to copy along with the page.
bool$first‪Is a flag set, if the record copied is NOT a 'slave' to another record copied. That is, if this record was asked to be copied in the cmd-array
Returns
‪int|null The id of the new page, if applicable.

should only be used from within DataHandler

Definition at line 3431 of file DataHandler.php.

References $fields, $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$overrideValues, TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), TYPO3\CMS\Core\DataHandling\DataHandler\copy_remapTranslationSourceField(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), if, TYPO3\CMS\Backend\Utility\BackendUtility\isTableLocalizable(), TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Versioning\VersionState\MOVE_PLACEHOLDER, TYPO3\CMS\Core\DataHandling\DataHandler\processRemapStack(), and TYPO3\CMS\Core\DataHandling\DataHandler\resolveVersionedRecords().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyPages().

◆ createRelationHandlerInstance()

◆ dbAnalysisStoreExec()

TYPO3\CMS\Core\DataHandling\DataHandler::dbAnalysisStoreExec ( )

Executing dbAnalysisStore This will save MM relations for new records but is executed after records are created because we need to know the ID of them

should only be used from within DataHandler

Definition at line 8044 of file DataHandler.php.

References TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), and TYPO3\CMS\Backend\Utility\BackendUtility\wsMapId().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_raw(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ deleteAction()

◆ deleteClause()

string TYPO3\CMS\Core\DataHandling\DataHandler::deleteClause (   $table)

Returns delete-clause for the $table

Parameters
string$table‪Table name
Returns
‪string Delete clause

should only be used from within DataHandler

Definition at line 7963 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\DataHandling\DataHandler\disableDeleteClause().

◆ deleteEl()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteEl (   $table,
  $uid,
  $noRecordCheck = false,
  $forceHardDelete = false,
bool  $deleteRecordsOnPage = true 
)

Delete element from any table

Parameters
string$table‪Table name
int$uid‪Record UID
bool$noRecordCheck‪Flag: If $noRecordCheck is set, then the function does not check permission to delete record
bool$forceHardDelete‪If TRUE, the "deleted" flag is ignored if applicable for record and the record is deleted COMPLETELY!
bool$deleteRecordsOnPage‪If false and if deleting pages, records on the page will not be deleted (edge case while swapping workspaces)

should only be used from within DataHandler

Definition at line 4776 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\deletePages(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\deleteVersionsForRecord().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteAction(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteVersionsForRecord(), TYPO3\CMS\Workspaces\Hook\DataHandlerHook\processCmdmap_deleteAction(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ deleteL10nOverlayRecords()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteL10nOverlayRecords (   $table,
  $uid 
)

◆ deletePages()

TYPO3\CMS\Core\DataHandling\DataHandler::deletePages (   $uid,
  $force = false,
  $forceHardDelete = false,
bool  $deleteRecordsOnPage = true 
)

Used to delete page because it will check for branch below pages and disallowed tables on the page as well.

Parameters
int$uidPage id
bool$force‪If TRUE, pages are not checked for permission.
bool$forceHardDelete‪If TRUE, the "deleted" flag is ignored if applicable for record and the record is deleted COMPLETELY!
bool$deleteRecordsOnPage‪If false, records on the page will not be deleted (edge case while swapping workspaces)

should only be used from within DataHandler

Definition at line 4977 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\canDeletePage(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteSpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\doesBranchExist(), TYPO3\CMS\Core\Utility\GeneralUtility\intExplode(), and TYPO3\CMS\Core\DataHandling\DataHandler\log().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteEl(), and TYPO3\CMS\Core\DataHandling\DataHandler\deleteVersionsForRecord().

◆ deleteRecord()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteRecord (   $table,
  $uid,
  $noRecordCheck = false,
  $forceHardDelete = false,
  $undeleteRecord = false 
)

Deleting/Undeleting a record This function may not be used to delete pages-records unless the underlying records are already deleted Deletes a record regardless of versioning state (live or offline, doesn't matter, the uid decides) If both $noRecordCheck and $forceHardDelete are set it could even delete a "deleted"-flagged record!

Parameters
string$table‪Table name
int$uid‪Record UID
bool$noRecordCheck‪Flag: If $noRecordCheck is set, then the function does not check permission to delete record
bool$forceHardDelete‪If TRUE, the "deleted" flag is ignored if applicable for record and the record is deleted COMPLETELY!
bool$undeleteRecord‪If TRUE, the "deleted" flag is set to 0 again and thus, the item is undeleted.

should only be used from within DataHandler

Definition at line 4857 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Type\Bitmask\Permission\CONTENT_EDIT, TYPO3\CMS\Core\DataHandling\DataHandler\deleteL10nOverlayRecords(), TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord_procFields(), TYPO3\CMS\Core\DataHandling\DataHandler\doesRecordExist(), TYPO3\CMS\Core\DataHandling\DataHandler\getDefaultLanguagePageId(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordHistoryStore(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Backend\Utility\BackendUtility\getTSCpid(), TYPO3\CMS\Core\DataHandling\DataHandler\hardDeleteSingleRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\hasDeletedRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_DELETE, TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_EDIT, TYPO3\CMS\Core\DataHandling\DataHandler\registerRecordIdForPageCacheClearing(), TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\undeleteRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateRefIndex().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyMovedRecordToNewLocation(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteEl(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteSpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteVersionsForRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\undeleteRecord().

◆ deleteRecord_procBasedOnFieldType()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteRecord_procBasedOnFieldType (   $table,
  $uid,
  $field,
  $value,
  $conf,
  $undeleteRecord = false 
)

Process fields of a record to be deleted and search for special handling, like inline type, MM records, etc.

Parameters
string$table‪Record Table
string$uid‪Record UID
string$field‪Record field
string$value‪Record field value
array$conf‪TCA configuration of current field
bool$undeleteRecord‪If a record should be undeleted (e.g. from history/undo)
See also
deleteRecord()

should only be used from within DataHandler

Definition at line 5299 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteAction(), TYPO3\CMS\Core\DataHandling\DataHandler\getInlineFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\isReferenceField(), TYPO3\CMS\Core\DataHandling\DataHandler\undeleteRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateRefIndex().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord_procFields().

◆ deleteRecord_procFields()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteRecord_procFields (   $table,
  $uid,
  $undeleteRecord = false 
)

Before a record is deleted, check if it has references such as inline type or MM references. If so, set these child records also to be deleted.

Parameters
string$table‪Record Table
string$uid‪Record UID
bool$undeleteRecord‪If a record should be undeleted (e.g. from history/undo)
See also
deleteRecord()

should only be used from within DataHandler

Definition at line 5274 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord_procBasedOnFieldType(), and TYPO3\CMS\Backend\Utility\BackendUtility\getRecord().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord().

◆ deleteSpecificPage()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteSpecificPage (   $uid,
  $forceHardDelete = false,
bool  $deleteRecordsOnPage = true 
)

◆ deleteVersionsForRecord()

TYPO3\CMS\Core\DataHandling\DataHandler::deleteVersionsForRecord (   $table,
  $uid,
  $forceHardDelete 
)

◆ destNotInsideSelf()

bool TYPO3\CMS\Core\DataHandling\DataHandler::destNotInsideSelf (   $destinationId,
  $id 
)

Checks if page $id is a uid in the rootline of page id $destinationId Used when moving a page

Parameters
int$destinationId‪Destination Page ID to test
int$idPage ID to test for presence inside Destination
Returns
‪bool Returns FALSE if ID is inside destination (including equal to)

should only be used from within DataHandler

Definition at line 6796 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), and TYPO3\CMS\Backend\Utility\BackendUtility\fixVersioningPid().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw().

◆ disableDeleteClause()

TYPO3\CMS\Core\DataHandling\DataHandler::disableDeleteClause ( )

Disables the delete clause for fetching records. In general only undeleted records will be used. If the delete clause is disabled, also deleted records are taken into account.

Definition at line 7951 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), and TYPO3\CMS\Core\DataHandling\DataHandler\deleteClause().

◆ discard()

TYPO3\CMS\Core\DataHandling\DataHandler::discard ( string  $table,
?int  $uid,
array  $record = null 
)

Discard a versioned record from this workspace. This deletes records from the database - no soft delete. This main entry method is called recursive for sub pages, localizations, relations and records on a page. The method checks user access and gathers facts about this record to hand the deletion over to detail methods.

The incoming $uid or $row can be anything: The workspace of current user is respected and only records of current user workspace are discarded. If giving a live record uid, the versioned overly will be fetched.

Parameters
string$tableDatabase table name
int | null$uid‪Uid of live or versioned record to be discarded, or null if $record is given
array | null$record‪Record row that should be discarded. Used instead of $uid within recursion.

Definition at line 5400 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Type\Enumeration\cast(), TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordUpdateAccess(), TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\discardLocalizationOverlayRecords(), TYPO3\CMS\Core\DataHandling\DataHandler\discardRecordRelations(), TYPO3\CMS\Core\DataHandling\DataHandler\discardSubPagesAndRecordsOnPage(), TYPO3\CMS\Backend\Utility\BackendUtility\getLiveVersionOfRecord(), TYPO3\CMS\Backend\Utility\BackendUtility\getMovePlaceholder(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordHistoryStore(), TYPO3\CMS\Backend\Utility\BackendUtility\getWorkspaceVersionOfRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\hardDeleteSingleRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\hasDeletedRecord(), if, TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Versioning\VersionState\MOVE_POINTER, TYPO3\CMS\Core\Versioning\VersionState\NEW_PLACEHOLDER, TYPO3\CMS\Core\Versioning\VersionState\NEW_PLACEHOLDER_VERSION, TYPO3\CMS\Core\DataHandling\DataHandler\newlog(), and TYPO3\CMS\Core\DataHandling\DataHandler\registerReferenceIndexRowsForDrop().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\discardLocalizationOverlayRecords(), TYPO3\CMS\Core\DataHandling\DataHandler\discardRecordRelations(), TYPO3\CMS\Core\DataHandling\DataHandler\discardSubPagesAndRecordsOnPage(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\processCmdmap().

◆ discardLocalizationOverlayRecords()

TYPO3\CMS\Core\DataHandling\DataHandler::discardLocalizationOverlayRecords ( string  $table,
array  $record 
)
protected

◆ discardMmRelations()

TYPO3\CMS\Core\DataHandling\DataHandler::discardMmRelations ( string  $table,
array  $fieldConfig,
array  $record 
)
protected

When a workspace record row is discarded that has mm relations, existing mm table rows need to be deleted. The method performs the delete operation depending on TCA field configuration.

Parameters
string$table‪Handled table name
array$fieldConfig‪TCA configuration of this field
array$record‪The full record of a left- or ride-side relation

Definition at line 5637 of file DataHandler.php.

References TYPO3\CMS\Core\Database\Query\QueryHelper\stripLogicalOperatorPrefix().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\discardRecordRelations().

◆ discardRecordRelations()

TYPO3\CMS\Core\DataHandling\DataHandler::discardRecordRelations ( string  $table,
array  $record 
)
protected

◆ discardSubPagesAndRecordsOnPage()

TYPO3\CMS\Core\DataHandling\DataHandler::discardSubPagesAndRecordsOnPage ( array  $page)
protected

◆ doesBranchExist()

string int TYPO3\CMS\Core\DataHandling\DataHandler::doesBranchExist (   $inList,
  $pid,
  $perms,
  $recurse 
)

Checks if a whole branch of pages exists

Tests the branch under $pid like doesRecordExist(), but it doesn't test the page with $pid as uid - use doesRecordExist() for this purpose. If $recurse is set, the function will follow subpages. This MUST be set, if we need the id-list for deleting pages or else we get an incomplete list

Parameters
string$inList‪List of page uids, this is added to and returned in the end
int$pidPage ID to select subpages from.
int$perms‪Perms integer to check each page record for.
bool$recurse‪Recursion flag: If set, it will go out through the branch.
Returns
‪string|int List of page IDs in branch, if there are subpages, empty string if there are none or -1 if no permission

should only be used from within DataHandler

Definition at line 6730 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\canDeletePage(), and TYPO3\CMS\Core\DataHandling\DataHandler\deletePages().

◆ doesPageHaveUnallowedTables()

bool array TYPO3\CMS\Core\DataHandling\DataHandler::doesPageHaveUnallowedTables (   $page_uid,
  $doktype 
)

Checks if there are records on a page from tables that are not allowed

Parameters
int$page_uidPage ID
int$doktypePage doktype
Returns
‪bool|array Returns a list of the tables that are 'present' on the page but not allowed with the page_uid/doktype

should only be used from within DataHandler

Definition at line 6863 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\compileAdminTables(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue().

◆ doesRecordExist()

bool TYPO3\CMS\Core\DataHandling\DataHandler::doesRecordExist (   $table,
  $id,
  $perms 
)

Checks if record can be selected based on given permission criteria

Parameters
string$table‪Record table name
int$id‪Record UID
int | string$perms‪Permission restrictions to observe: Either an integer that will be bitwise AND'ed or a string, which points to a key in the ->pMap array. Only integers are supported starting with TYPO3 v11.
Returns
‪bool Returns TRUE if the record given by $table, $id and $perms can be selected
Exceptions

Definition at line 6659 of file DataHandler.php.

References TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), and TYPO3\CMS\Core\DataHandling\DataHandler\recordInfoWithPermissionCheck().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\canDeletePage(), TYPO3\CMS\Core\DataHandling\DataHandler\cannotDeleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordInsertAccess(), TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordUpdateAccess(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\localize(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ doesRecordExist_pageLookUp()

bool array TYPO3\CMS\Core\DataHandling\DataHandler::doesRecordExist_pageLookUp (   $id,
  $perms,
  $columns = ['uid'] 
)
protected

Looks up a page based on permissions.

Parameters
int$idPage id
int$perms‪Permission integer
array$columns‪Columns to select
Returns
‪bool|array
See also
doesRecordExist()

Definition at line 6677 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), TYPO3\CMS\Core\Type\Bitmask\Permission\CONTENT_EDIT, TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_DELETE, and TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_EDIT.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\recordInfoWithPermissionCheck().

◆ eventPid()

◆ fillInFieldArray()

array TYPO3\CMS\Core\DataHandling\DataHandler::fillInFieldArray (   $table,
  $id,
  $fieldArray,
  $incomingFieldArray,
  $realPid,
  $status,
  $tscPID 
)

Filling in the field array $this->excludedTablesAndFields is used to filter fields if needed.

Parameters
string$table‪Table name
int$id‪Record ID
array$fieldArray‪Default values, Preset $fieldArray with 'pid' maybe (pid and uid will be not be overridden anyway)
array$incomingFieldArray‪Is which fields/values you want to set. There are processed and put into $fieldArray if OK
int$realPid‪The real PID value of the record. For updates, this is just the pid of the record. For new records this is the PID of the page where it is inserted.
string$status‪Is 'new' or 'update'
int$tscPID‪TSconfig PID
Returns
‪array Field Array

should only be used from within DataHandler

Definition at line 1348 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\checkValue(), TYPO3\CMS\Backend\Utility\BackendUtility\fixVersioningPid(), TYPO3\CMS\Core\Utility\ArrayUtility\mergeRecursiveWithOverrule(), TYPO3\CMS\Core\DataHandling\DataHandler\pageInfo(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), and TYPO3\CMS\Backend\Utility\BackendUtility\workspaceOL().

◆ fixCopyAfterDuplFields()

array TYPO3\CMS\Core\DataHandling\DataHandler::fixCopyAfterDuplFields (   $table,
  $uid,
  $prevUid,
  $update,
  $newData = [] 
)

When er record is copied you can specify fields from the previous record which should be copied into the new one This function is also called with new elements. But then $update must be set to zero and $newData containing the data array. In that case data in the incoming array is NOT overridden. (250202)

Parameters
string$table‪Table name
int$uid‪Record UID
int$prevUid‪UID of previous record
bool$update‪If set, updates the record
array$newData‪Input array. If fields are already specified AND $update is not set, values are not set in output array.
Returns
‪array Output array (For when the copying operation needs to get the information instead of updating the info)

should only be used from within DataHandler

Definition at line 8227 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateDB().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord().

◆ fixUniqueInPid()

TYPO3\CMS\Core\DataHandling\DataHandler::fixUniqueInPid (   $table,
  $uid 
)

Checks if any uniqueInPid eval input fields are in the record and if so, they are re-written to be correct.

Parameters
string$table‪Table name
int$uid‪Record UID

should only be used from within DataHandler

Definition at line 8140 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\getUnique(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateDB().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw().

◆ fixUniqueInSite()

bool TYPO3\CMS\Core\DataHandling\DataHandler::fixUniqueInSite ( string  $table,
int  $uid 
)
protected

Checks if any uniqueInSite eval fields are in the record and if so, they are re-written to be correct.

Parameters
string$table‪Table name
int$uid‪Record UID
Returns
‪bool whether the record had to be fixed or not

Definition at line 8172 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\Model\RecordStateFactory\forName(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateDB().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInSiteForSubpages(), and TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw().

◆ fixUniqueInSiteForSubpages()

TYPO3\CMS\Core\DataHandling\DataHandler::fixUniqueInSiteForSubpages ( int  $pageId)
protected

Check if there are subpages that need an adoption as well

Parameters
int$pageId

Definition at line 8202 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInSite(), and TYPO3\CMS\Core\DataHandling\DataHandler\int_pageTreeInfo().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw().

◆ getAllowedTablesToCopyWhenCopyingAPage()

array TYPO3\CMS\Core\DataHandling\DataHandler::getAllowedTablesToCopyWhenCopyingAPage ( )
protected

Compile a list of tables that should be copied along when a page is about to be copied.

First, get the list that the user is allowed to modify (all if admin), and then check against a possible limitation within "DataHandler->copyWhichTables" if not set to "*" to limit the list further down

Returns
‪array

Definition at line 3400 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\compileAdminTables(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyPages().

◆ getAutoVersionId()

int null TYPO3\CMS\Core\DataHandling\DataHandler::getAutoVersionId (   $table,
  $id 
)

Gets the automatically versionized id of a record.

Parameters
string$table‪Name of the table
int$id‪Uid of the record
Returns
‪int|null

should only be used from within TYPO3 Core

Definition at line 8965 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\localize(), TYPO3\CMS\Core\DataHandling\DataHandler\overlayAutoVersionId(), and TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords_procInline().

◆ getCacheManager()

CacheManager TYPO3\CMS\Core\DataHandling\DataHandler::getCacheManager ( )
protected

◆ getCheckModifyAccessListHookObjects()

array TYPO3\CMS\Core\DataHandling\DataHandler::getCheckModifyAccessListHookObjects ( )
protected

Gets the 'checkModifyAccessList' hook objects. The first call initializes the accordant objects.

Returns
‪array The 'checkModifyAccessList' hook objects (if any)
Exceptions

Definition at line 807 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$checkModifyAccessListHookObjects, and $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkModifyAccessList().

◆ getCommandMapElements()

array TYPO3\CMS\Core\DataHandling\DataHandler::getCommandMapElements (   $needle)
protected

Gets elements of the command map that match a particular command.

Parameters
string$needle‪The command to be matched
Returns
‪array

Definition at line 9185 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\registerElementsToBeDeleted(), and TYPO3\CMS\Core\DataHandling\DataHandler\unsetElementsToBeDeleted().

◆ getCopyHeader()

string TYPO3\CMS\Core\DataHandling\DataHandler::getCopyHeader (   $table,
  $pid,
  $field,
  $value,
  $count,
  $prevTitle = '' 
)

Get modified header for a copied record

Parameters
string$table‪Table name
int$pid‪PID value in which other records to test might be
string$field‪Field name to get header value for.
string$value‪Current field value
int$count‪Counter (number of recursions)
string$prevTitle‪Previous title we checked for (in previous recursion)
Returns
‪string The field value, possibly appended with a "copy label

should only be used from within DataHandler

Definition at line 8322 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), and TYPO3\CMS\Core\DataHandling\DataHandler\prependLabel().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord().

◆ getCorrelationId()

◆ getDefaultLanguagePageId()

int TYPO3\CMS\Core\DataHandling\DataHandler::getDefaultLanguagePageId ( int  $pageId)
protected

Find out if the record is a localization. If so, get the uid of the default language page. Always returns the uid of the workspace live record: No explicit workspace overlay is applied.

Parameters
int$pageIdPage UID, can be the default page record, or a page translation record ID
Returns
‪int UID of the default page record in live workspace

Definition at line 8906 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\canDeletePage(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteSpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw(), TYPO3\CMS\Core\DataHandling\DataHandler\prepareCacheFlush(), TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords_procInline(), and TYPO3\CMS\Core\DataHandling\DataHandler\resolveSortingAndPidForNewRecord().

◆ getExcludeListArray()

array TYPO3\CMS\Core\DataHandling\DataHandler::getExcludeListArray ( )

Generate an array of fields to be excluded from editing for the user. Based on "exclude"-field in TCA and a look up in non_exclude_fields Will also generate this list for admin-users so they must be check for before calling the function

Returns
‪array Array of [table]-[field] pairs to exclude from editing.

should only be used from within DataHandler

Definition at line 6833 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\start().

◆ getFieldEvalCacheIdentifier()

string TYPO3\CMS\Core\DataHandling\DataHandler::getFieldEvalCacheIdentifier (   $additionalIdentifier)
protected

Return the cache entry identifier for field evals

Parameters
string$additionalIdentifier
Returns
‪string

Definition at line 9357 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInput(), and TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForText().

◆ getHistoryRecords()

array TYPO3\CMS\Core\DataHandling\DataHandler::getHistoryRecords ( )

should only be used from within TYPO3 Core

Returns
‪array

Definition at line 9408 of file DataHandler.php.

◆ getInlineFieldType()

◆ getLanguageService()

◆ getLocalTCE()

◆ getOriginalParentOfRecord()

int [] TYPO3\CMS\Core\DataHandling\DataHandler::getOriginalParentOfRecord (   $table,
  $uid 
)
protected

Gets UID of parent record. If record is deleted it will be looked up in an array built before the record was deleted

Parameters
string$table‪Table where record lives/lived
int$uid‪Record UID
Returns
‪int[] Parent UIDs

Definition at line 7992 of file DataHandler.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\getTSCpid().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\processClearCacheQueue().

◆ getOuterMostInstance()

DataHandler TYPO3\CMS\Core\DataHandling\DataHandler::getOuterMostInstance ( )
protected

Gets the outer most instance of \TYPO3\CMS\Core\DataHandling\DataHandler Since \TYPO3\CMS\Core\DataHandling\DataHandler can create nested objects of itself, this method helps to determine the first (= outer most) one.

Returns
DataHandler

Definition at line 9050 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$outerMostInstance.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\isOuterMostInstance().

◆ getPID()

int false TYPO3\CMS\Core\DataHandling\DataHandler::getPID (   $table,
  $uid 
)

Returns the pid of a record from $table with $uid

Parameters
string$table‪Table name
int$uid‪Record uid
Returns
‪int|false PID value (unless the record did not exist in which case FALSE is returned)

should only be used from within DataHandler

Definition at line 8025 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\prepareCacheFlush().

◆ getPlaceholderTitleForTableLabel()

string TYPO3\CMS\Core\DataHandling\DataHandler::getPlaceholderTitleForTableLabel (   $table,
  $placeholderContent = null 
)

Create a placeholder title for the label field that does match the field requirements

Parameters
string$table‪The table name
string$placeholderContent‪Placeholder content to be used
Returns
‪string placeholder value

should only be used from within DataHandler

Definition at line 1318 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_input_Eval(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Workspaces\Hook\DataHandlerHook\moveRecord_wsPlaceholders(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ getPreviousLocalizedRecordUid()

int TYPO3\CMS\Core\DataHandling\DataHandler::getPreviousLocalizedRecordUid (   $table,
  $uid,
  $pid,
  $language 
)
protected

Returning uid of previous localized record, if any, for tables with a "sortby" column Used when new localized records are created so that localized records are sorted in the same order as the default language records

For a given record (A) uid (record we're translating) it finds first default language record (from the same colpos) with sorting smaller than given record (B). Then it fetches a translated version of record B and returns it's uid.

If there is no record B, or it has no translation in given language, the record A uid is returned. The localized record will be placed the after record which uid is returned.

Parameters
string$table‪Table name
int$uid‪Uid of default language record
int$pid‪Pid of default language record
int$language‪Language of localization
Returns
‪int uid of record after which the localized record should be inserted

Definition at line 7647 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecord(), and TYPO3\CMS\Backend\Utility\BackendUtility\getRecordLocalization().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\localize().

◆ getRecordHistoryStore()

◆ getRecordProperties()

◆ getRecordPropertiesFromRow()

array null TYPO3\CMS\Core\DataHandling\DataHandler::getRecordPropertiesFromRow (   $table,
  $row 
)

◆ getRecordsWithSameValue()

array TYPO3\CMS\Core\DataHandling\DataHandler::getRecordsWithSameValue (   $tableName,
  $uid,
  $fieldName,
  $value,
  $pageId = 0 
)

gets all records that have the same value in a field excluding the given uid

Parameters
string$tableName‪Table name
int$uid‪UID to filter out in the lookup (the record itself...)
string$fieldName‪Field name for which $value must be unique
string$value‪Value string.
int$pageId‪If set, the value will be unique for this PID
Returns
‪array

should only be used from within DataHandler

Definition at line 2528 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForCheck().

◆ getResourceFactory()

ResourceFactory TYPO3\CMS\Core\DataHandling\DataHandler::getResourceFactory ( )
protected

Gets the resourceFactory

Returns
‪ResourceFactory

Definition at line 9391 of file DataHandler.php.

◆ getRuntimeCache()

FrontendInterface TYPO3\CMS\Core\DataHandling\DataHandler::getRuntimeCache ( )
protected

Gets an instance of the runtime cache.

Returns
‪FrontendInterface

Definition at line 9081 of file DataHandler.php.

References TYPO3\CMS\Core\Cache\CacheManager\getCache(), and TYPO3\CMS\Core\DataHandling\DataHandler\getCacheManager().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\__construct().

◆ getSortNumber()

int array bool null TYPO3\CMS\Core\DataHandling\DataHandler::getSortNumber (   $table,
  $uid,
  $pid 
)

Returning sorting number for tables with a "sortby" column Using when new records are created and existing records are moved around.

The strategy is:

  • ‪if no record exists: set interval as sorting number
  • ‪if inserted before an element: put in the middle of the existing elements
  • ‪if inserted behind the last element: add interval to last sorting number
  • ‪if collision: move all subsequent records by 2 * interval, insert new record with collision + interval

How to calculate the maximum possible inserts for the worst case of adding all records to the top, such that the sorting number stays within INT_MAX

i = interval (currently 256) c = number of inserts until collision s = max sorting number to reach (INT_MAX - 32bit) n = number of records (~83 million)

c = 2 * g g = log2(i) / 2 + 1 n = g * s / i - g + 1

The algorithm can be tuned by adjusting the interval value. Higher value means less collisions, but also less inserts are possible to stay within INT_MAX.

Parameters
string$table‪Table name
int$uid‪Uid of record to find sorting number for. May be zero in case of new.
int$pid‪Positioning PID, either >=0 (pointing to page in which case we find sorting number for first record in page) or <0 (pointing to record in which case to find next sorting number after this record)
Returns
‪int|array|bool|null Returns integer if PID is >=0, otherwise an array with PID and sorting number. Possibly FALSE in case of error.

should only be used from within DataHandler

Definition at line 7453 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$sortIntervals, TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), TYPO3\CMS\Backend\Utility\BackendUtility\getLiveVersionOfRecord(), TYPO3\CMS\Backend\Utility\BackendUtility\getMovePlaceholder(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Core\DataHandling\DataHandler\increaseSortingOfFollowingRecords(), TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled(), and TYPO3\CMS\Core\DataHandling\DataHandler\log().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw(), and TYPO3\CMS\Core\DataHandling\DataHandler\resolveSortingAndPidForNewRecord().

◆ getTableEntries()

array TYPO3\CMS\Core\DataHandling\DataHandler::getTableEntries (   $table,
  $TSconfig 
)

Extract entries from TSconfig for a specific table. This will merge specific and default configuration together.

Parameters
string$table‪Table name
array$TSconfig‪TSconfig for page
Returns
‪array TSconfig merged

should only be used from within DataHandler

Definition at line 8009 of file DataHandler.php.

References TYPO3\CMS\Core\Utility\ArrayUtility\mergeRecursiveWithOverrule().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\localize().

◆ getUnique()

string TYPO3\CMS\Core\DataHandling\DataHandler::getUnique (   $table,
  $field,
  $value,
  $id,
  $newPid = 0 
)

Gets a unique value for $table/$id/$field based on $value

Parameters
string$table‪Table name
string$field‪Field name for which $value must be unique
string$value‪Value string.
int$id‪UID to filter out in the lookup (the record itself...)
int$newPid‪If set, the value will be unique for this PID
Returns
‪string Modified value (if not-unique). Will be the value appended with a number (until 100, then the function just breaks).
Todo:
‪: consider workspaces, especially when publishing a unique value which has a unique value already in live

should only be used from within DataHandler

Definition at line 2416 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\getUniqueCountStatement(), and TYPO3\CMS\Core\DataHandling\DataHandler\log().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForInput(), and TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInPid().

◆ getUniqueCountStatement()

QueryBuilder TYPO3\CMS\Core\DataHandling\DataHandler::getUniqueCountStatement ( string  $value,
string  $table,
string  $field,
int  $uid,
int  $pid 
)
protected

Gets the count of records for a unique field

Parameters
string$value‪The string value which should be unique
string$table‪Table name
string$field‪Field name for which $value must be unique
int$uid‪UID to filter out in the lookup (the record itself...)
int$pid‪If set, the value will be unique for this PID
Returns
‪QueryBuilder Return the prepared statement to check uniqueness

Definition at line 2467 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getUnique().

◆ getVersionizedIncomingFieldArray()

TYPO3\CMS\Core\DataHandling\DataHandler::getVersionizedIncomingFieldArray (   $table,
  $id,
$incomingFieldArray,
$registerDBList 
)

If a parent record was versionized on a workspace in $this->process_datamap, it might be possible, that child records (e.g. on using IRRE) were affected. This function finds these relations and updates their uids in the $incomingFieldArray. The $incomingFieldArray is updated by reference!

Parameters
string$table‪Table name of the parent record
int$id‪Uid of the parent record
array$incomingFieldArray‪Reference to the incomingFieldArray of process_datamap
array$registerDBList‪Reference to the $registerDBList array that was created/updated by versionizing calls to DataHandler in process_datamap.

should only be used from within DataHandler

Definition at line 6423 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Core\DataHandling\DataHandler\$registerDBList.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ hardDeleteSingleRecord()

TYPO3\CMS\Core\DataHandling\DataHandler::hardDeleteSingleRecord ( string  $table,
int  $uid 
)
protected

Simple helper method to hard delete one row from table ignoring delete TCA field

Parameters
string$table‪A row from this table should be deleted
int$uid‪Uid of row to be deleted

Definition at line 6453 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\discard(), and TYPO3\CMS\Core\DataHandling\DataHandler\insertDB().

◆ hasDeletedRecord()

bool TYPO3\CMS\Core\DataHandling\DataHandler::hasDeletedRecord (   $tableName,
  $uid 
)

Determines whether a particular record has been deleted using DataHandler::deleteRecord() in this instance.

Parameters
string$tableName
string$uid
Returns
‪bool

should only be used from within TYPO3 Core

Definition at line 8949 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\discard(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ hook_processDatamap_afterDatabaseOperations()

TYPO3\CMS\Core\DataHandling\DataHandler::hook_processDatamap_afterDatabaseOperations ( $hookObjectsArr,
$status,
$table,
$id,
$fieldArray 
)

Hook: processDatamap_afterDatabaseOperations (calls $hookObj->processDatamap_afterDatabaseOperations($status, $table, $id, $fieldArray, $this);)

Note: When using the hook after INSERT operations, you will only get the temporary NEW... id passed to your hook as $id, but you can easily translate it to the real uid of the inserted record using the $this->substNEWwithIDs array.

Parameters
array$hookObjectsArr‪(reference) Array with hook objects
string$status‪(reference) Status of the current operation, 'new' or 'update
string$table‪(reference) The table currently processing data for
string$id‪(reference) The record uid currently processing data for, [integer] or [string] (like 'NEW...')
array$fieldArray‪(reference) The field array of a record

should only be used from within DataHandler

Definition at line 782 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ increaseSortingOfFollowingRecords()

TYPO3\CMS\Core\DataHandling\DataHandler::increaseSortingOfFollowingRecords ( string  $table,
int  $pid,
int  $sortingValue = null 
)
protected

Increases sorting field value of all records with sorting higher than $sortingValue

Used internally by getSortNumber() to "make space" in sorting values when inserting new record

Parameters
string$table‪Table name
int$pidPage Uid in which to resort records
int$sortingValue‪All sorting numbers larger than this number will be shifted
See also
getSortNumber()

Definition at line 7601 of file DataHandler.php.

References $GLOBALS, and TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getSortNumber().

◆ inlineLocalizeSynchronize()

TYPO3\CMS\Core\DataHandling\DataHandler::inlineLocalizeSynchronize (   $table,
  $id,
  $command 
)
protected

Performs localization or synchronization of child records. The $command argument expects an array, but supports a string for backward-compatibility.

$command = array( 'field' => 'tx_myfieldname', 'language' => 2, // either the key 'action' or 'ids' must be set 'action' => 'synchronize', // or 'localize' 'ids' => array(1, 2, 3, 4) // child element ids );

Parameters
string$table‪The table of the localized parent record
int$id‪The uid of the localized parent record
array | string$command‪Defines the command to be performed (see example above)

Definition at line 4574 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$enableLogging, $GLOBALS, TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), TYPO3\CMS\Core\DataHandling\DataHandler\eventPid(), TYPO3\CMS\Core\DataHandling\DataHandler\getInlineFieldType(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecordLocalization(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecordWSOL(), TYPO3\CMS\Core\DataHandling\DataHandler\isRecordLocalized(), TYPO3\CMS\Core\DataHandling\DataHandler\localize(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\DataHandling\DataHandler\overlayAutoVersionId(), TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode(), TYPO3\CMS\Core\DataHandling\DataHandler\updateDB(), and TYPO3\CMS\Backend\Utility\BackendUtility\workspaceOL().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ insertDB()

int null TYPO3\CMS\Core\DataHandling\DataHandler::insertDB (   $table,
  $id,
  $fieldArray,
  $newVersion = false,
  $suggestedUid = 0,
  $dontSetNewIdIndex = false 
)

Insert into database Does not check permissions but expects them to be verified on beforehand

Parameters
string$table‪Record table name
string$id‪"NEW...." uid string
array$fieldArray‪Array of field=>value pairs to insert. FIELDS MUST MATCH the database FIELDS. No check is done. "pid" must point to the destination of the record!
bool$newVersion‪Set to TRUE if new version is created.
int$suggestedUid‪Suggested UID value for the inserted record. See the array $this->suggestedInsertUids; Admin-only feature
bool$dontSetNewIdIndex‪If TRUE, the ->substNEWwithIDs array is not updated. Only useful in very rare circumstances!
Returns
‪int|null Returns ID on success.

should only be used from within DataHandler

Definition at line 7188 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\addRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\checkStoredRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordHistoryStore(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordPropertiesFromRow(), TYPO3\CMS\Core\DataHandling\DataHandler\hardDeleteSingleRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\insertUpdateDB_preprocessBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Database\Connection\PARAM_LOB, TYPO3\CMS\Core\DataHandling\DataHandler\postProcessDatabaseInsert(), TYPO3\CMS\Core\DataHandling\DataHandler\registerRecordIdForPageCacheClearing(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateRefIndex().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\insertNewCopyVersion(), TYPO3\CMS\Workspaces\Hook\DataHandlerHook\moveRecord_wsPlaceholders(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ insertNewCopyVersion()

int TYPO3\CMS\Core\DataHandling\DataHandler::insertNewCopyVersion (   $table,
  $fieldArray,
  $realPid 
)

Inserts a record in the database, passing TCA configuration values through checkValue() but otherwise does NOTHING and checks nothing regarding permissions. Passes the "version" parameter to insertDB() so the copy will look like a new version in the log - should probably be changed or modified a bit for more broad usage...

Parameters
string$table‪Table name
array$fieldArray‪Field array to insert as a record
int$realPid‪The value of PID field.
Returns
‪int Returns the new ID of the record (if applicable)

should only be used from within DataHandler

Definition at line 3649 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$dontProcessTransformations, $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$userid, TYPO3\CMS\Core\DataHandling\DataHandler\checkValue(), TYPO3\CMS\Core\Utility\StringUtility\getUniqueId(), and TYPO3\CMS\Core\DataHandling\DataHandler\insertDB().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_raw().

◆ insertUpdateDB_preprocessBasedOnFieldType()

array TYPO3\CMS\Core\DataHandling\DataHandler::insertUpdateDB_preprocessBasedOnFieldType (   $table,
  $fieldArray 
)

Preprocesses field array based on field type. Some fields must be adjusted before going to database. This is done on the copy of the field array because original values are used in remap action later.

Parameters
string$table‪Table name
array$fieldArray‪Field array to check
Returns
‪array Updated field array

should only be used from within TYPO3 Core

Definition at line 8927 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\insertDB(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateDB().

◆ int_pageTreeInfo()

array TYPO3\CMS\Core\DataHandling\DataHandler::int_pageTreeInfo (   $CPtable,
  $pid,
  $counter,
  $rootID 
)

Returns array, $CPtable, of pages under the $pid going down to $counter levels. Selecting ONLY pages which the user has read-access to!

Parameters
array$CPtable‪Accumulation of page uid=>pid pairs in branch of $pid
int$pidPage ID for which to find subpages
int$counter‪Number of levels to go down.
int$rootID‪ID of root point for new copied branch: The idea seems to be that a copy is not made of the already new page!
Returns
‪array Return array.

should only be used from within DataHandler

Definition at line 8065 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addDeleteRestriction(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_SHOW, and TYPO3\CMS\Core\DataHandling\DataHandler\resolveVersionedRecords().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyPages(), and TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInSiteForSubpages().

◆ isElementToBeDeleted()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isElementToBeDeleted (   $table,
  $id 
)
protected

Determines whether an element was registered to be deleted in the registry.

Parameters
string$table‪Name of the table
int$id‪Uid of the record
Returns
‪bool
See also
registerElementsToBeDeleted
resetElementsToBeDeleted
copyRecord_raw
versionizeRecord

Definition at line 9134 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_raw(), and TYPO3\CMS\Core\DataHandling\DataHandler\versionizeRecord().

◆ isInWebMount()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isInWebMount (   $pid)

Checks if the input page ID is in the BE_USER webmounts

Parameters
int$pidPage ID to check
Returns
‪bool TRUE if OK. Cached results.

should only be used from within DataHandler

Definition at line 6507 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\isRecordInWebMount().

◆ isNestedElementCallRegistered()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isNestedElementCallRegistered (   $table,
  $id,
  $identifier 
)
protected

Determines nested element calls.

Parameters
string$table‪Name of the table
int$id‪Uid of the record
string$identifier‪Name of the action to be checked
Returns
‪bool

Definition at line 9094 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processManyToMany(), and TYPO3\CMS\Core\DataHandling\DataHandler\localize().

◆ isOuterMostInstance()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isOuterMostInstance ( )

Determines whether the this object is the outer most instance of itself Since DataHandler can create nested objects of itself, this method helps to determine the first (= outer most) one.

Returns
‪bool

Definition at line 9071 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getOuterMostInstance().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ isRecordCopied()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isRecordCopied (   $table,
  $uid 
)

Determine if a record was copied or if a record is the result of a copy action.

Parameters
string$table‪The tablename of the record
int$uid‪The uid of the record
Returns
‪bool Returns TRUE if the record is copied or is the result of a copy action

should only be used from within DataHandler

Definition at line 8448 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_raw(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\moveRecord().

◆ isRecordInWebMount()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isRecordInWebMount (   $table,
  $id 
)

Checking if a record with uid $id from $table is in the BE_USERS webmounts which is required for editing etc.

Parameters
string$table‪Table name
int$id‪UID of record
Returns
‪bool Returns TRUE if OK. Cached results.

should only be used from within DataHandler

Definition at line 6491 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), and TYPO3\CMS\Core\DataHandling\DataHandler\isInWebMount().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\recordInfoWithPermissionCheck().

◆ isRecordLocalized()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isRecordLocalized ( string  $table,
int  $uid,
int  $language 
)
protected

Returns true if a localization of a record exists.

Parameters
string$table
int$uid
int$language
Returns
‪bool

Definition at line 4728 of file DataHandler.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\getRecordLocalization(), and TYPO3\CMS\Backend\Utility\BackendUtility\getRecordWSOL().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\inlineLocalizeSynchronize().

◆ isRecordUndeletable()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isRecordUndeletable (   $table,
  $uid 
)

Determines whether a record can be undeleted.

Parameters
string$table‪Table name of the record
int$uid‪uid of the record
Returns
‪bool Whether the record can be undeleted

should only be used from within DataHandler

Definition at line 5245 of file DataHandler.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\getRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\log().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\undeleteRecord().

◆ isReferenceField()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isReferenceField (   $conf)

◆ isSubmittedValueEqualToStoredValue()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isSubmittedValueEqualToStoredValue (   $submittedValue,
  $storedValue,
  $storedType,
  $allowNull = false 
)
protected

Determines whether submitted values and stored values are equal. This prevents from adding superfluous field changes which would be shown in the record history as well. For NULL fields (see accordant TCA definition 'eval' = 'null'), a special handling is required since (!strcmp(NULL, '')) would be a false-positive.

Parameters
mixed$submittedValue‪Value that has submitted (e.g. from a backend form)
mixed$storedValue‪Value that is currently stored in the database
string$storedType‪SQL type of the stored value column (see mysql_field_type(), e.g 'int', 'string', ...)
bool$allowNull‪Whether NULL values are allowed by accordant TCA definition ('eval' = 'null')
Returns
‪bool Whether both values are considered to be equal

Definition at line 7878 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\compareFieldArrayWithCurrentAndUnset().

◆ isTableAllowedForThisPage()

bool TYPO3\CMS\Core\DataHandling\DataHandler::isTableAllowedForThisPage (   $page_uid,
  $checkTable 
)

Checks if a table is allowed on a certain page id according to allowed tables set for the page "doktype" and its [ctrl][rootLevel]-settings if any.

Parameters
int$page_uidPage id for which to check, including 0 (zero) if checking for page tree root.
string$checkTable‪Table name to check
Returns
‪bool TRUE if OK

should only be used from within DataHandler

Definition at line 6621 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Backend\Utility\BackendUtility\isRootLevelRestrictionIgnored(), TYPO3\CMS\Core\DataHandling\DataHandler\pageInfo(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordInsertAccess(), and TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord().

◆ localize()

int bool TYPO3\CMS\Core\DataHandling\DataHandler::localize (   $table,
  $uid,
  $language 
)

Localizes a record to another system language

Parameters
string$table‪Table name
int$uid‪Record uid (to be localized)
int$language‪Language ID (from sys_language table)
Returns
‪int|bool The uid (int) of the new translated record or FALSE (bool) if something went wrong

should only be used from within DataHandler

Definition at line 4410 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$overrideValues, TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\doesRecordExist(), TYPO3\CMS\Core\DataHandling\DataHandler\getAutoVersionId(), TYPO3\CMS\Core\DataHandling\DataHandler\getLanguageService(), TYPO3\CMS\Core\DataHandling\DataHandler\getLocalTCE(), TYPO3\CMS\Backend\Utility\BackendUtility\getPagesTSconfig(), TYPO3\CMS\Core\DataHandling\DataHandler\getPreviousLocalizedRecordUid(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecord(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecordLocalization(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecordWSOL(), TYPO3\CMS\Core\DataHandling\DataHandler\getTableEntries(), TYPO3\CMS\Backend\Utility\BackendUtility\getTSCpid(), TYPO3\CMS\Core\Utility\StringUtility\getUniqueId(), TYPO3\CMS\Core\DataHandling\DataHandler\isNestedElementCallRegistered(), TYPO3\CMS\Core\DataHandling\DataHandler\newlog(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_SHOW, TYPO3\CMS\Core\DataHandling\DataHandler\registerNestedElementCall(), TYPO3\CMS\Core\Localization\LanguageService\sL(), and TYPO3\CMS\Core\DataHandling\DataHandler\triggerRemapAction().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processInline(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_processManyToMany(), TYPO3\CMS\Core\DataHandling\DataHandler\inlineLocalizeSynchronize(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ log()

int TYPO3\CMS\Core\DataHandling\DataHandler::log (   $table,
  $recuid,
  $action,
  $recpid,
  $error,
  $details,
  $details_nr = -1,
  $data = [],
  $event_pid = -1,
  $NEWid = '' 
)

Logging actions from DataHandler

Parameters
string$table‪Table name the log entry is concerned with. Blank if NA
int$recuid‪Record UID. Zero if NA
int$action‪Action number: 0=No category, 1=new record, 2=update record, 3= delete record, 4= move record, 5= Check/evaluate
int$recpid‪Normally 0 (zero). If set, it indicates that this log-entry is used to notify the backend of a record which is moved to another location
int$error‪The severity: 0 = message, 1 = error, 2 = System Error, 3 = security notice (admin), 4 warning
string$details‪Default error message in english
int$details_nr‪This number is unique for every combination of $type and $action. This is the error-message number, which can later be used to translate error messages. 0 if not categorized, -1 if temporary
array$data‪Array with special information that may go into $details by 's' marks / sprintf() when the log is shown
int$event_pid‪The page_uid (pid) where the event occurred. Used to select log-content for specific pages.
string$NEWid‪NEW id for new records
Returns
‪int Log entry UID (0 if no log entry was written or logging is disabled)
See also
‪\TYPO3\CMS\Core\SysLog\Action\Database for all available values of argument $action
‪\TYPO3\CMS\Core\SysLog\Error for all available values of argument $error

should only be used from within TYPO3 Core

Definition at line 8822 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordInsertAccess(), TYPO3\CMS\Core\DataHandling\DataHandler\checkStoredRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_input_ValidateEmail(), TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForCheck(), TYPO3\CMS\Core\DataHandling\DataHandler\copyPages(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord_raw(), TYPO3\CMS\Core\DataHandling\DataHandler\copySpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\deletePages(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\discard(), TYPO3\CMS\Core\DataHandling\DataHandler\getSortNumber(), TYPO3\CMS\Core\DataHandling\DataHandler\getUnique(), TYPO3\CMS\Core\DataHandling\DataHandler\inlineLocalizeSynchronize(), TYPO3\CMS\Core\DataHandling\DataHandler\insertDB(), TYPO3\CMS\Core\DataHandling\DataHandler\isRecordUndeletable(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw(), TYPO3\CMS\Core\DataHandling\DataHandler\newlog(), TYPO3\CMS\Core\DataHandling\DataHandler\placeholderShadowing(), TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap(), TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap(), TYPO3\CMS\Workspaces\Hook\DataHandlerHook\sendStageChangeNotification(), TYPO3\CMS\Core\DataHandling\DataHandler\updateDB(), TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_setStage(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ moveL10nOverlayRecords()

TYPO3\CMS\Core\DataHandling\DataHandler::moveL10nOverlayRecords (   $table,
  $uid,
  $destPid,
  $originalRecordDestinationPid 
)

Find l10n-overlay records and perform the requested move action for these records.

Parameters
string$table‪Record Table
string$uid‪Record UID
string$destPid‪Position to move to
string$originalRecordDestinationPid‪Position to move the original record to

should only be used from within DataHandler

Definition at line 4351 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Backend\Utility\BackendUtility\isTableLocalizable(), and TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\moveRecord_wsPlaceholders().

◆ moveRecord()

◆ moveRecord_procBasedOnFieldType()

TYPO3\CMS\Core\DataHandling\DataHandler::moveRecord_procBasedOnFieldType (   $table,
  $uid,
  $destPid,
  $field,
  $value,
  $conf 
)

Move child records depending on the field type of the parent record.

Parameters
string$table‪Record Table
string$uid‪Record UID
string$destPid‪Position to move to
string$field‪Record field
string$value‪Record field value
array$conf‪TCA configuration of current field

should only be used from within DataHandler

Definition at line 4313 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), TYPO3\CMS\Core\DataHandling\DataHandler\getInlineFieldType(), and TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_procFields().

◆ moveRecord_procFields()

TYPO3\CMS\Core\DataHandling\DataHandler::moveRecord_procFields (   $table,
  $uid,
  $destPid 
)

Walk through all fields of the moved record and look for children of e.g. the inline type. If child records are found, they are also move to the new $destPid.

Parameters
string$table‪Record Table
int$uid‪Record UID
int$destPid‪Position to move to

should only be used from within DataHandler

Definition at line 4291 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Backend\Utility\BackendUtility\getRecordWSOL(), and TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_procBasedOnFieldType().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw().

◆ moveRecord_raw()

TYPO3\CMS\Core\DataHandling\DataHandler::moveRecord_raw (   $table,
  $uid,
  $destPid 
)

Moves a record without checking security of any sort. USE ONLY INTERNALLY

Parameters
string$table‪Table name to move
int$uid‪Record uid to move
int$destPid‪Position to move to: $destPid: >=0 then it points to a page-id on which to insert the record (as the first element). <0 then it points to a uid from its own table after which to insert it (works if
See also
moveRecord()

should only be used from within DataHandler

Definition at line 4116 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\destNotInsideSelf(), TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInPid(), TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInSite(), TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInSiteForSubpages(), TYPO3\CMS\Core\DataHandling\DataHandler\getDefaultLanguagePageId(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordHistoryStore(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Core\DataHandling\DataHandler\getSortNumber(), TYPO3\CMS\Backend\Utility\BackendUtility\getTSCpid(), TYPO3\CMS\Backend\Utility\BackendUtility\getWorkspaceVersionOfRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\DataHandling\DataHandler\moveL10nOverlayRecords(), TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\moveRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_procFields(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), TYPO3\CMS\Core\DataHandling\DataHandler\registerRecordIdForPageCacheClearing(), and TYPO3\CMS\Core\DataHandling\DataHandler\resolvePid().

Referenced by TYPO3\CMS\Workspaces\Hook\DataHandlerHook\moveRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\moveRecord_wsPlaceholders().

◆ newFieldArray()

array TYPO3\CMS\Core\DataHandling\DataHandler::newFieldArray (   $table)

Returns a fieldArray with default values. Values will be picked up from the TCA array looking at the config key "default" for each column. If values are set in ->defaultValues they will overrule though. Used for new records and during copy operations for defaults

Parameters
string$table‪Table name for which to set default values.
Returns
‪array Array with default values.

should only be used from within DataHandler

Definition at line 7742 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\applyDefaultsForFieldArray(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ newlog()

int TYPO3\CMS\Core\DataHandling\DataHandler::newlog (   $message,
  $error = SystemLogErrorClassification::MESSAGE 
)

◆ normalizeTimeFormat()

string TYPO3\CMS\Core\DataHandling\DataHandler::normalizeTimeFormat ( string  $table,
string  $value,
string  $dbType 
)
protected
Parameters
string$table
string$value
string$dbType
Returns
‪string

Definition at line 1199 of file DataHandler.php.

References TYPO3\CMS\Core\Database\Query\QueryHelper\getDateTimeFormats().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkStoredRecord().

◆ overlayAutoVersionId()

int TYPO3\CMS\Core\DataHandling\DataHandler::overlayAutoVersionId (   $table,
  $id 
)
protected

Overlays the automatically versionized id of a record.

Parameters
string$table‪Name of the table
int$id‪Uid of the record
Returns
‪int

Definition at line 8981 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getAutoVersionId().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\inlineLocalizeSynchronize().

◆ overrideFieldArray()

array TYPO3\CMS\Core\DataHandling\DataHandler::overrideFieldArray (   $table,
  $data 
)

Returns the $data array from $table overridden in the fields defined in ->overrideValues.

Parameters
string$table‪Table name
array$data‪Data array with fields from table. These will be overlaid with values in $this->overrideValues[$table]
Returns
‪array Data array, processed.

should only be used from within DataHandler

Definition at line 7798 of file DataHandler.php.

◆ pageInfo()

string TYPO3\CMS\Core\DataHandling\DataHandler::pageInfo (   $id,
  $field 
)

Returns the value of the $field from page $id NOTICE; the function caches the result for faster delivery next time. You can use this function repeatedly without performance loss since it doesn't look up the same record twice!

Parameters
int$idPage uid
string$field‪Field name for which to return value
Returns
‪string Value of the field. Result is cached in $this->pageCache[$id][$field] and returned from there next time!

should only be used from within DataHandler

Definition at line 6915 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteSpecificPage(), TYPO3\CMS\Core\DataHandling\DataHandler\fillInFieldArray(), and TYPO3\CMS\Core\DataHandling\DataHandler\isTableAllowedForThisPage().

◆ placeholderShadowing()

TYPO3\CMS\Core\DataHandling\DataHandler::placeholderShadowing (   $table,
  $id 
)

◆ postProcessDatabaseInsert()

int TYPO3\CMS\Core\DataHandling\DataHandler::postProcessDatabaseInsert ( Connection  $connection,
string  $tableName,
int  $suggestedUid 
)
protected

Entry point to post process a database insert. Currently bails early unless a UID has been forced and the database platform is not MySQL.

Parameters
\TYPO3\CMS\Core\Database\Connection$connection
string$tableName
int$suggestedUid
Returns
‪int

Definition at line 9264 of file DataHandler.php.

References TYPO3\CMS\Core\Database\Connection\lastInsertId(), TYPO3\CMS\Core\DataHandling\DataHandler\postProcessPostgresqlInsert(), and TYPO3\CMS\Core\DataHandling\DataHandler\postProcessSqlServerInsert().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\insertDB().

◆ postProcessPostgresqlInsert()

TYPO3\CMS\Core\DataHandling\DataHandler::postProcessPostgresqlInsert ( Connection  $connection,
string  $tableName 
)
protected

PostgreSQL works with sequences for auto increment columns. A sequence is not updated when a value is written to such a column. To avoid clashes when the sequence returns an existing ID this helper will update the sequence to the current max value of the column.

Parameters
\TYPO3\CMS\Core\Database\Connection$connection
string$tableName

Definition at line 9316 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\postProcessDatabaseInsert().

◆ postProcessSqlServerInsert()

int TYPO3\CMS\Core\DataHandling\DataHandler::postProcessSqlServerInsert ( Connection  $connection,
string  $tableName 
)
protected

Get the last insert ID from sql server

  • ‪first checks whether doctrine might be able to fetch the ID from the sequence table
  • ‪if that does not succeed it manually selects the current IDENTITY value from a table
  • ‪returns 0 if both fail
Parameters
\TYPO3\CMS\Core\Database\Connection$connection
string$tableName
Returns
‪int
Exceptions

Definition at line 9295 of file DataHandler.php.

References TYPO3\CMS\Core\Database\Connection\lastInsertId(), and TYPO3\CMS\Core\Database\Connection\quoteIdentifier().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\postProcessDatabaseInsert().

◆ prepareCacheFlush()

array TYPO3\CMS\Core\DataHandling\DataHandler::prepareCacheFlush (   $table,
  $uid,
  $pid 
)
protected

Prepare the cache clearing

Parameters
string$table‪Table name of record that needs to be cleared
int$uid‪UID of record for which the cache needs to be cleared
int$pid‪Original pid of the page of the record which the cache needs to be cleared
Returns
‪array Array with tagsToClear and clearCacheCommands

This function is internal only it may be changed/removed also in minor version numbers.

Definition at line 8541 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\getDefaultLanguagePageId(), TYPO3\CMS\Backend\Utility\BackendUtility\getPagesTSconfig(), TYPO3\CMS\Core\DataHandling\DataHandler\getPID(), TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\processClearCacheQueue().

◆ prependLabel()

string TYPO3\CMS\Core\DataHandling\DataHandler::prependLabel (   $table)

Return "copy" label for a table. Although the name is "prepend" it actually APPENDs the label (after ...)

Parameters
string$table‪Table name
Returns
‪string Label to append, containing "%s" for the number
See also
getCopyHeader()

should only be used from within DataHandler

Definition at line 8358 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\getLanguageService(), and TYPO3\CMS\Core\Localization\LanguageService\sL().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\clearPrefixFromValue(), and TYPO3\CMS\Core\DataHandling\DataHandler\getCopyHeader().

◆ printLogErrorMessages()

TYPO3\CMS\Core\DataHandling\DataHandler::printLogErrorMessages ( )

Print log error messages from the operations of this script instance

should only be used from within TYPO3 Core

Definition at line 8859 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\Messaging\AbstractMessage\ERROR, and TYPO3\CMS\Core\Messaging\AbstractMessage\WARNING.

◆ process_cmdmap()

◆ process_datamap()

bool void TYPO3\CMS\Core\DataHandling\DataHandler::process_datamap ( )

Processing the data-array Call this function to process the data-array set by start()

Returns
‪bool|void

Definition at line 833 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$enableLogging, $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\$registerDBList, TYPO3\CMS\Core\DataHandling\DataHandler\addDefaultPermittedLanguageIfNotSet(), TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger(), TYPO3\CMS\Core\DataHandling\DataHandler\checkModifyAccessList(), TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordInsertAccess(), TYPO3\CMS\Core\DataHandling\DataHandler\checkRecordUpdateAccess(), TYPO3\CMS\Core\DataHandling\DataHandler\controlActiveElements(), TYPO3\CMS\Core\DataHandling\DataHandler\dbAnalysisStoreExec(), TYPO3\CMS\Core\DataHandling\DataHandler\getPlaceholderTitleForTableLabel(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordProperties(), TYPO3\CMS\Core\DataHandling\DataHandler\getVersionizedIncomingFieldArray(), TYPO3\CMS\Backend\Utility\BackendUtility\getWorkspaceVersionOfRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\hook_processDatamap_afterDatabaseOperations(), TYPO3\CMS\Core\DataHandling\DataHandler\insertDB(), TYPO3\CMS\Core\DataHandling\Localization\DataMapProcessor\instance(), TYPO3\CMS\Core\DataHandling\DataHandler\isOuterMostInstance(), TYPO3\CMS\Backend\Utility\BackendUtility\isTableWorkspaceEnabled(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\Versioning\VersionState\NEW_PLACEHOLDER, TYPO3\CMS\Core\Versioning\VersionState\NEW_PLACEHOLDER_VERSION, TYPO3\CMS\Core\DataHandling\DataHandler\newFieldArray(), TYPO3\CMS\Core\DataHandling\DataHandler\newlog(), TYPO3\CMS\Core\DataHandling\DataHandler\placeholderShadowing(), TYPO3\CMS\Core\DataHandling\Localization\DataMapProcessor\process(), TYPO3\CMS\Core\DataHandling\DataHandler\processClearCacheQueue(), TYPO3\CMS\Core\DataHandling\DataHandler\processRemapStack(), TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo(), TYPO3\CMS\Core\DataHandling\DataHandler\registerElementsToBeDeleted(), TYPO3\CMS\Core\DataHandling\DataHandler\resetElementsToBeDeleted(), TYPO3\CMS\Core\DataHandling\DataHandler\resolveSortingAndPidForNewRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\tableReadOnly(), TYPO3\CMS\Core\DataHandling\DataHandler\triggerRemapAction(), TYPO3\CMS\Core\DataHandling\DataHandler\unsetElementsToBeDeleted(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateDB().

Referenced by TYPO3\CMS\Core\Tests\Unit\DataHandling\DataHandlerTest\processDatamapForFrozenNonZeroWorkspaceReturnsFalse().

◆ process_uploads()

TYPO3\CMS\Core\DataHandling\DataHandler::process_uploads ( )

Dummy method formerly used for file handling.

Deprecated:
‪since TYPO3 v10.0, will be removed in TYPO3 v11.0.

Definition at line 758 of file DataHandler.php.

◆ processClearCacheQueue()

◆ processRemapStack()

TYPO3\CMS\Core\DataHandling\DataHandler::processRemapStack ( )

◆ recordInfo()

array null TYPO3\CMS\Core\DataHandling\DataHandler::recordInfo (   $table,
  $id,
  $fieldList 
)

◆ recordInfoWithPermissionCheck()

array bool TYPO3\CMS\Core\DataHandling\DataHandler::recordInfoWithPermissionCheck ( string  $table,
int  $id,
  $perms,
string  $fieldList = '*' 
)
protected

◆ registerElementsToBeDeleted()

TYPO3\CMS\Core\DataHandling\DataHandler::registerElementsToBeDeleted ( )
protected

Registers elements to be deleted in the registry.

See also
process_datamap

Definition at line 9145 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getCommandMapElements().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ registerNestedElementCall()

TYPO3\CMS\Core\DataHandling\DataHandler::registerNestedElementCall (   $table,
  $id,
  $identifier 
)
protected

Registers nested elements calls. This is used to track nested calls (e.g. for following m:n relations).

Parameters
string$table‪Name of the table
int$id‪Uid of the record
string$identifier‪Name of the action to be tracked

Definition at line 9108 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\localize().

◆ registerRecordIdForPageCacheClearing()

TYPO3\CMS\Core\DataHandling\DataHandler::registerRecordIdForPageCacheClearing (   $table,
  $uid,
  $pid = null 
)

Clearing the cache based on a page being updated If the $table is 'pages' then cache is cleared for all pages on the same level (and subsequent?) Else just clear the cache for the parent page of the record.

Parameters
string$table‪Table name of record that was just updated.
int$uid‪UID of updated / inserted record
int$pid‪REAL PID of page of a deleted/moved record to get TSconfig in ClearCache.

This method is not meant to be called directly but only from the core itself or from hooks

Definition at line 8476 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\insertDB(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw(), TYPO3\CMS\Core\DataHandling\DataHandler\updateDB(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ registerReferenceIndexRowsForDrop()

TYPO3\CMS\Core\DataHandling\DataHandler::registerReferenceIndexRowsForDrop ( string  $table,
int  $uid,
int  $workspace 
)

Delete rows from sys_refindex a table / uid combination is involved in: Either on left side (tablename + recuid) OR right side (ref_table + ref_uid). Useful in scenarios like workspace-discard where parents or children are hard deleted: The expensive updateRefIndex() does not need to be called since we can just drop straight ahead.

Parameters
string$table‪Table name, used as tablename and ref_table
int$uid‪Record uid, used as recuid and ref_uid
int$workspace‪Workspace the record lives in

Definition at line 7412 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\discard(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ remapListedDBRecords()

◆ remapListedDBRecords_flexFormCallBack()

array TYPO3\CMS\Core\DataHandling\DataHandler::remapListedDBRecords_flexFormCallBack (   $pParams,
  $dsConf,
  $dataValue,
  $dataValue_ext1,
  $dataValue_ext2 
)

Callback function for traversing the FlexForm structure in relation to creating copied files of file relations inside of flex form structures.

Parameters
array$pParams‪Set of parameters in numeric array: table, uid, field
array$dsConf‪TCA config for field (from Data Structure of course)
string$dataValue‪Field value (from FlexForm XML)
string$dataValue_ext1‪Not used
string$dataValue_ext2‪Not used
Returns
‪array Array where the "value" key carries the value.
See also
checkValue_flex_procInData_travDS()
remapListedDBRecords()

should only be used from within DataHandler

Definition at line 6022 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\isReferenceField(), and TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords_procDBRefs().

◆ remapListedDBRecords_procDBRefs()

array null TYPO3\CMS\Core\DataHandling\DataHandler::remapListedDBRecords_procDBRefs (   $conf,
  $value,
  $MM_localUid,
  $table 
)

Performs remapping of old UID values to NEW uid values for a DB reference field.

Parameters
array$conf‪TCA field config
string$value‪Field value
int$MM_localUid‪UID of local record (for MM relations - might need to change if support for FlexForms should be done!)
string$table‪Table name
Returns
‪array|null Returns array of items ready to implode for field content.
See also
remapListedDBRecords()

should only be used from within DataHandler

Definition at line 6048 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), TYPO3\CMS\Backend\Utility\BackendUtility\getLiveVersionIdOfRecord(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords(), TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords_flexFormCallBack(), and TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords_procInline().

◆ remapListedDBRecords_procInline()

TYPO3\CMS\Core\DataHandling\DataHandler::remapListedDBRecords_procInline (   $conf,
  $value,
  $uid,
  $table 
)

◆ resetElementsToBeDeleted()

TYPO3\CMS\Core\DataHandling\DataHandler::resetElementsToBeDeleted ( )
protected

Resets the elements to be deleted in the registry.

See also
process_datamap

Definition at line 9156 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ resetNestedElementCalls()

TYPO3\CMS\Core\DataHandling\DataHandler::resetNestedElementCalls ( )
protected

Resets the nested element calls.

Definition at line 9118 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ resolveFieldConfigurationAndRespectColumnsOverrides()

array TYPO3\CMS\Core\DataHandling\DataHandler::resolveFieldConfigurationAndRespectColumnsOverrides ( string  $table,
string  $field 
)
protected

Use columns overrides for evaluation.

Fetch the TCA ["config"] part for a specific field, including the columnsOverrides value. Used for checkValue purposes currently (as it takes the checkValue_currentRecord value).

Parameters
string$table
string$field
Returns
‪array

Definition at line 1600 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Backend\Utility\BackendUtility\getTCAtypeValue(), and TYPO3\CMS\Core\Utility\ArrayUtility\mergeRecursiveWithOverrule().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValue().

◆ resolvePid()

int TYPO3\CMS\Core\DataHandling\DataHandler::resolvePid (   $table,
  $pid 
)

Get the final pid based on $table and $pid ($destPid type... pos/neg)

Parameters
string$table‪Table name
int$pid‪"Destination pid" : If the value is >= 0 it's just returned directly (through (int)though) but if the value is <0 then the method looks up the record with the uid equal to abs($pid) (positive number) and returns the PID of that record! The idea is that negative numbers point to the record AFTER WHICH the position is supposed to be!
Returns
‪int

should only be used from within DataHandler

Definition at line 8371 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\moveRecord_raw().

◆ resolveSortingAndPidForNewRecord()

array TYPO3\CMS\Core\DataHandling\DataHandler::resolveSortingAndPidForNewRecord ( string  $table,
int  $pid,
array  $fieldArray 
)
protected

Sets the "sorting" DB field and the "pid" field of an incoming record that should be added (NEW1234) depending on the record that should be added or where it should be added.

This method is called from process_datamap()

Parameters
string$table‪the table name of the record to insert
int$pid‪the real PID (numeric) where the record should be
array$fieldArray‪field+value pairs to add
Returns
‪array the modified field array

Definition at line 1225 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\getDefaultLanguagePageId(), TYPO3\CMS\Core\DataHandling\DataHandler\getSortNumber(), and TYPO3\CMS\Core\DataHandling\DataHandler\recordInfo().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ resolveVersionedRecords()

array TYPO3\CMS\Core\DataHandling\DataHandler::resolveVersionedRecords (   $tableName,
  $fieldNames,
  $sortingField,
array  $liveIds 
)
protected

Resolves versioned records for the current workspace scope. Delete placeholders and move placeholders are substituted and removed.

Parameters
string$tableName‪Name of the table to be processed
string$fieldNames‪List of the field names to be fetched
string$sortingField‪Name of the sorting field to be used
array$liveIds‪Flat array of (live) record ids
Returns
‪array

Definition at line 9014 of file DataHandler.php.

References TYPO3\CMS\Backend\Utility\BackendUtility\getRecord().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copySpecificPage(), and TYPO3\CMS\Core\DataHandling\DataHandler\int_pageTreeInfo().

◆ setControl()

TYPO3\CMS\Core\DataHandling\DataHandler::setControl ( array  $control)
Parameters
array$control

Definition at line 605 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$control.

◆ setCorrelationId()

TYPO3\CMS\Core\DataHandling\DataHandler::setCorrelationId ( CorrelationId  $correlationId)
Parameters
CorrelationId$correlationId

Definition at line 9242 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$correlationId.

◆ setDefaultsFromUserTS()

TYPO3\CMS\Core\DataHandling\DataHandler::setDefaultsFromUserTS (   $userTS)

Initializes default values coming from User TSconfig

Parameters
array$userTS‪User TSconfig array

should only be used from within DataHandler

Definition at line 704 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\applyDefaultsForFieldArray(), and TYPO3\CMS\Core\DataHandling\DataHandler\start().

◆ setHistory()

TYPO3\CMS\Core\DataHandling\DataHandler::setHistory (   $table,
  $id,
  $logId 
)

Setting sys_history record, based on content previously set in $this->historyRecords[$table . ':' . $id] (by compareFieldArrayWithCurrentAndUnset())

This functionality is now moved into the RecordHistoryStore and can be used instead.

Parameters
string$table‪Table name
int$id‪Record ID
int$logIdLog entry ID, important for linking between log and history views

should only be used from within DataHandler

Definition at line 7358 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\getRecordHistoryStore(), and TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\modifyRecord().

Referenced by TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ setMirror()

TYPO3\CMS\Core\DataHandling\DataHandler::setMirror (   $mirror)

Function that can mirror input values in datamap-array to other uid numbers. Example: $mirror[table][11] = '22,33' will look for content in $this->datamap[table][11] and copy it to $this->datamap[table][22] and $this->datamap[table][33]

Parameters
array$mirror‪This array has the syntax $mirror[table_name][uid] = [list of uids to copy data-value TO!]

Definition at line 674 of file DataHandler.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

◆ setNullValues()

TYPO3\CMS\Core\DataHandling\DataHandler::setNullValues ( array  $active,
array &  $haystack 
)
protected

Sets NULL values in haystack array. The general behaviour in the user interface is to enable/activate fields. Thus, this method uses NULL as value to be stored if a field is not active.

Parameters
array$active‪hierarchical array with active elements
array$haystack‪hierarchical array with haystack to be modified

Definition at line 9222 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\controlActiveElements().

◆ setTSconfigPermissions()

array TYPO3\CMS\Core\DataHandling\DataHandler::setTSconfigPermissions (   $fieldArray,
  $TSConfig_p 
)

Setting up perms_* fields in $fieldArray based on TSconfig input Used for new pages

Parameters
array$fieldArray‪Field Array, returned with modifications
array$TSConfig_p‪TSconfig properties
Returns
‪array Modified Field Array
Deprecated:
‪will be removed in TYPO3 v11.0 - Use PagePermissionAssembler instead.

Definition at line 7713 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\assemblePermissions(), and TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger().

◆ start()

TYPO3\CMS\Core\DataHandling\DataHandler::start (   $data,
  $cmd,
  $altUserObject = null 
)

Initializing. For details, see 'TYPO3 Core API' document. This function does not start the processing of data, but merely initializes the object

Parameters
array$data‪Data to be modified or inserted in the database
array$cmd‪Commands to copy, move, delete, localize, versionize records.
BackendUserAuthentication | null$altUserObject‪An alternative userobject you can set instead of the default, which is $GLOBALS['BE_USER']

Definition at line 619 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\$defaultPermissions, $GLOBALS, TYPO3\CMS\Core\DataHandling\Model\CorrelationId\forScope(), TYPO3\CMS\Core\DataHandling\DataHandler\getExcludeListArray(), TYPO3\CMS\Core\Utility\StringUtility\getUniqueId(), and TYPO3\CMS\Core\DataHandling\DataHandler\setDefaultsFromUserTS().

◆ tableAdminOnly()

bool TYPO3\CMS\Core\DataHandling\DataHandler::tableAdminOnly (   $table)

Checks if the $table is only editable by admin-users

Parameters
string$table‪Table name
Returns
‪bool TRUE, if readonly

should only be used from within DataHandler

Definition at line 6781 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkModifyAccessList().

◆ tableReadOnly()

bool TYPO3\CMS\Core\DataHandling\DataHandler::tableReadOnly (   $table)

Checks if the $table is readOnly

Parameters
string$table‪Table name
Returns
‪bool TRUE, if readonly

should only be used from within DataHandler

Definition at line 6768 of file DataHandler.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkForRecordsFromDisallowedTables(), TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ triggerRemapAction()

TYPO3\CMS\Core\DataHandling\DataHandler::triggerRemapAction (   $table,
  $id,
array  $callback,
array  $arguments,
  $forceRemapStackActions = false 
)
protected

Triggers a remap action for a specific record.

Some records are post-processed by the processRemapStack() method (e.g. IRRE children). This method determines whether an action/modification is executed directly to a record or is postponed to happen after remapping data.

Parameters
string$table‪Name of the table
string$id‪Id of the record (can also be a "NEW..." string)
array$callback‪The method to be called
array$arguments‪The arguments to be submitted to the callback method
bool$forceRemapStackActions‪Whether to force to use the stack
See also
processRemapStack

Definition at line 6380 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\addRemapAction().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\localize(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ undeleteRecord()

TYPO3\CMS\Core\DataHandling\DataHandler::undeleteRecord (   $table,
  $uid 
)

Undelete a single record

Parameters
string$table‪Table name
int$uid‪Record UID

should only be used from within DataHandler

Definition at line 4837 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), and TYPO3\CMS\Core\DataHandling\DataHandler\isRecordUndeletable().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord_procBasedOnFieldType(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ unsetElementsToBeDeleted()

array TYPO3\CMS\Core\DataHandling\DataHandler::unsetElementsToBeDeleted ( array  $elements)
protected

Unsets elements (e.g. of the data map) that shall be deleted. This avoids to modify records that will be deleted later on.

Parameters
array$elements‪Elements to be modified
Returns
‪array

Definition at line 9168 of file DataHandler.php.

References TYPO3\CMS\Core\Utility\ArrayUtility\arrayDiffKeyRecursive(), and TYPO3\CMS\Core\DataHandling\DataHandler\getCommandMapElements().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ updateDB()

TYPO3\CMS\Core\DataHandling\DataHandler::updateDB (   $table,
  $id,
  $fieldArray 
)

Update database record Does not check permissions but expects them to be verified on beforehand

Parameters
string$table‪Record table name
int$id‪Record uid
array$fieldArray‪Array of field=>value pairs to insert. FIELDS MUST MATCH the database FIELDS. No check is done.

should only be used from within DataHandler

Definition at line 7114 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\checkStoredRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordHistoryStore(), TYPO3\CMS\Core\DataHandling\DataHandler\getRecordPropertiesFromRow(), TYPO3\CMS\Core\DataHandling\DataHandler\insertUpdateDB_preprocessBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\log(), TYPO3\CMS\Core\DataHandling\History\RecordHistoryStore\modifyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\registerRecordIdForPageCacheClearing(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateRefIndex().

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\fixCopyAfterDuplFields(), TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInPid(), TYPO3\CMS\Core\DataHandling\DataHandler\fixUniqueInSite(), TYPO3\CMS\Core\DataHandling\DataHandler\inlineLocalizeSynchronize(), TYPO3\CMS\Core\DataHandling\DataHandler\placeholderShadowing(), TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap(), TYPO3\CMS\Core\DataHandling\DataHandler\processRemapStack(), TYPO3\CMS\Core\DataHandling\DataHandler\remapListedDBRecords(), and TYPO3\CMS\Core\DataHandling\DataHandler\updateFlexFormData().

◆ updateFlexFormData()

TYPO3\CMS\Core\DataHandling\DataHandler::updateFlexFormData (   $flexFormId,
array  $modifications 
)
protected

◆ updateRefIndex()

TYPO3\CMS\Core\DataHandling\DataHandler::updateRefIndex (   $table,
  $uid,
int  $workspace = null 
)

Register a table/uid combination in current user workspace for reference updating. Should be called on almost any update to a record which could affect references inside the record.

Parameters
string$table‪Table name
int$uid‪Record UID
int$workspace‪Workspace the record lives in

should only be used from within DataHandler

Definition at line 7394 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\deleteRecord_procBasedOnFieldType(), TYPO3\CMS\Core\DataHandling\DataHandler\insertDB(), TYPO3\CMS\Core\DataHandling\DataHandler\updateDB(), TYPO3\CMS\Workspaces\Hook\DataHandlerHook\updateL10nOverlayRecordsOnPublish(), and TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ version_remapMMForVersionSwap()

TYPO3\CMS\Core\DataHandling\DataHandler::version_remapMMForVersionSwap (   $table,
  $id,
  $swapWith 
)

Swaps MM-relations for current/swap record, see version_swap()

Parameters
string$table‪Table for the two input records
int$id‪Current record (about to go offline)
int$swapWith‪Swap record (about to go online)
See also
‪version_swap()

should only be used from within DataHandler

Definition at line 5805 of file DataHandler.php.

References $GLOBALS, TYPO3\CMS\Core\DataHandling\DataHandler\checkValue_flex_procInData(), TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), TYPO3\CMS\Backend\Utility\BackendUtility\getRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\isReferenceField(), TYPO3\CMS\Core\DataHandling\DataHandler\version_remapMMForVersionSwap_execSwap(), and TYPO3\CMS\Core\Utility\GeneralUtility\xml2array().

Referenced by TYPO3\CMS\Workspaces\Hook\DataHandlerHook\version_swap().

◆ version_remapMMForVersionSwap_execSwap()

TYPO3\CMS\Core\DataHandling\DataHandler::version_remapMMForVersionSwap_execSwap (   $table,
  $id,
  $swapWith 
)

Performing the remapping operations found necessary in version_remapMMForVersionSwap() It must be done in three steps with an intermediate "fake" uid. The UID can be something else than -$id (fx. 9999999+$id if you dare... :-)- as long as it is unique.

Parameters
string$table‪Table for the two input records
int$id‪Current record (about to go offline)
int$swapWith‪Swap record (about to go online)
See also
version_remapMMForVersionSwap()

should only be used from within DataHandler

Definition at line 5901 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\version_remapMMForVersionSwap().

◆ version_remapMMForVersionSwap_flexFormCallBack()

TYPO3\CMS\Core\DataHandling\DataHandler::version_remapMMForVersionSwap_flexFormCallBack (   $pParams,
  $dsConf,
  $dataValue,
  $dataValue_ext1,
  $dataValue_ext2,
  $path 
)

Callback function for traversing the FlexForm structure in relation to ...

Parameters
array$pParams‪Array of parameters in num-indexes: table, uid, field
array$dsConf‪TCA field configuration (from Data Structure XML)
string$dataValue‪The value of the flexForm field
string$dataValue_ext1‪Not used.
string$dataValue_ext2‪Not used.
string$path‪Path in flexforms
See also
version_remapMMForVersionSwap()
checkValue_flex_procInData_travDS()

should only be used from within DataHandler

Definition at line 5875 of file DataHandler.php.

References TYPO3\CMS\Core\DataHandling\DataHandler\createRelationHandlerInstance(), and TYPO3\CMS\Core\DataHandling\DataHandler\isReferenceField().

◆ versionizeRecord()

int null TYPO3\CMS\Core\DataHandling\DataHandler::versionizeRecord (   $table,
  $id,
  $label,
  $delete = false 
)

Member Data Documentation

◆ $admin

bool TYPO3\CMS\Core\DataHandling\DataHandler::$admin

Will be set if user is admin

should only be used from within TYPO3 Core

Definition at line 342 of file DataHandler.php.

◆ $autoVersionIdMap

array TYPO3\CMS\Core\DataHandling\DataHandler::$autoVersionIdMap = array( )

Contains mapping of auto-versionized records.

should only be used from within TYPO3 Core

Definition at line 256 of file DataHandler.php.

◆ $BE_USER

BackendUserAuthentication TYPO3\CMS\Core\DataHandling\DataHandler::$BE_USER

The user-object the script uses. If not set from outside, this is set to the current global $BE_USER.

Definition at line 321 of file DataHandler.php.

◆ $bypassAccessCheckForRecords

bool TYPO3\CMS\Core\DataHandling\DataHandler::$bypassAccessCheckForRecords = false

If TRUE, access check, check for deleted etc. for records is bypassed. YOU MUST KNOW what you are doing if you use this feature!

Definition at line 177 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getLocalTCE().

◆ $bypassWorkspaceRestrictions

bool TYPO3\CMS\Core\DataHandling\DataHandler::$bypassWorkspaceRestrictions = false

If TRUE, workspace restrictions are bypassed on edit and create actions (process_datamap()). YOU MUST KNOW what you do if you use this feature!

should only be used from within TYPO3 Core

Definition at line 170 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getLocalTCE().

◆ $cachePrefixNestedElementCalls

string TYPO3\CMS\Core\DataHandling\DataHandler::$cachePrefixNestedElementCalls = 'core-datahandler-nestedElementCalls-'
protected

Prefix for the cache entries of nested element calls since the runtimeCache has a global scope.

Definition at line 580 of file DataHandler.php.

◆ $callBackObj

object TYPO3\CMS\Core\DataHandling\DataHandler::$callBackObj

Object. Call back object for FlexForm traversal. Useful when external classes wants to use the iteration functions inside DataHandler for traversing a FlexForm structure.

should only be used from within TYPO3 Core

Definition at line 239 of file DataHandler.php.

◆ $callFromImpExp

bool TYPO3\CMS\Core\DataHandling\DataHandler::$callFromImpExp = false

Tells, that this DataHandler instance was called from \TYPO3\CMS\Impext\ImportExport. This variable is set by \TYPO3\CMS\Impext\ImportExport

only used within TYPO3 Core

Definition at line 525 of file DataHandler.php.

◆ $checkModifyAccessListHookObjects

array TYPO3\CMS\Core\DataHandling\DataHandler::$checkModifyAccessListHookObjects
protected

◆ $checkSimilar

bool TYPO3\CMS\Core\DataHandling\DataHandler::$checkSimilar = true

If TRUE, only fields which are different from the database values are saved! In fact, if a whole input array is similar, it's not saved then.

should only be used from within TYPO3 Core

Definition at line 116 of file DataHandler.php.

◆ $checkStoredRecords

bool TYPO3\CMS\Core\DataHandling\DataHandler::$checkStoredRecords = true

This will read the record after having updated or inserted it. If anything is not properly submitted an error is written to the log. This feature consumes extra time by selecting records

Definition at line 123 of file DataHandler.php.

◆ $checkStoredRecords_loose

bool TYPO3\CMS\Core\DataHandling\DataHandler::$checkStoredRecords_loose = true

If set, values '' and 0 will equal each other when the stored records are checked.

Definition at line 129 of file DataHandler.php.

◆ $checkValue_currentRecord

array TYPO3\CMS\Core\DataHandling\DataHandler::$checkValue_currentRecord = array( )

Set to "currentRecord" during checking of values.

Definition at line 534 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\checkValueForFlex().

◆ $cmdmap

array TYPO3\CMS\Core\DataHandling\DataHandler::$cmdmap = array( )

Set with incoming cmd array

Definition at line 382 of file DataHandler.php.

◆ $control

array TYPO3\CMS\Core\DataHandling\DataHandler::$control = array( )
protected

Data submitted from the form view, used to control behaviours, e.g. this is used to activate/deactivate fields and thus store NULL values

Definition at line 370 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\setControl().

◆ $copyMappingArray

array TYPO3\CMS\Core\DataHandling\DataHandler::$copyMappingArray = array( )

Used by the copy action to track the ids of new pages so subpages are correctly inserted! THIS is internally cleared for each executed copy operation! DO NOT USE THIS FROM OUTSIDE! Read from copyMappingArray_merged instead which is accumulating this information.

NOTE: This is used by some outside scripts (e.g. hooks), as the results in $copyMappingArray_merged are only available after an action has been completed.

Definition at line 480 of file DataHandler.php.

◆ $copyMappingArray_merged

array TYPO3\CMS\Core\DataHandling\DataHandler::$copyMappingArray_merged = array( )

This array is the sum of all copying operations in this class.

should only be used from within TYPO3 Core

Definition at line 283 of file DataHandler.php.

◆ $copyTree

int TYPO3\CMS\Core\DataHandling\DataHandler::$copyTree = 0

If 0 then branch is NOT copied. If 1 then pages on the 1st level is copied. If 2 then pages on the second level is copied ... and so on

Definition at line 193 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getLocalTCE().

◆ $copyWhichTables

string TYPO3\CMS\Core\DataHandling\DataHandler::$copyWhichTables = '*'

Comma-separated list. This list of tables decides which tables will be copied. If empty then none will. If '*' then all will (that the user has permission to of course)

should only be used from within TYPO3 Core

Definition at line 185 of file DataHandler.php.

◆ $correlationId

CorrelationId null TYPO3\CMS\Core\DataHandling\DataHandler::$correlationId
protected

A string which can be used as correlationId for RecordHistory entries. The string can later be used to rollback multiple changes at once.

Definition at line 246 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getCorrelationId(), and TYPO3\CMS\Core\DataHandling\DataHandler\setCorrelationId().

◆ $data_disableFields

array TYPO3\CMS\Core\DataHandling\DataHandler::$data_disableFields = array( )

If entries are set in this array corresponding to fields for update, they are ignored and thus NOT updated. You could set this array from a series of checkboxes with value=0 and hidden fields before the checkbox with 1. Then an empty checkbox will disable the field.

should only be used from within TYPO3 Core

Definition at line 221 of file DataHandler.php.

◆ $datamap

array TYPO3\CMS\Core\DataHandling\DataHandler::$datamap = array( )

Set with incoming data array

Definition at line 376 of file DataHandler.php.

◆ $dbAnalysisStore

array TYPO3\CMS\Core\DataHandling\DataHandler::$dbAnalysisStore = array( )

For accumulation of MM relations that must be written after new records are created.

Definition at line 454 of file DataHandler.php.

◆ $defaultPermissions

array TYPO3\CMS\Core\DataHandling\DataHandler::$defaultPermissions
Initial value:
= array(
'user' => 'show,edit,delete,new,editcontent',
'group' => 'show,edit,new,editcontent',
'everybody' => ''
)

Can be overridden from $GLOBALS['TYPO3_CONF_VARS']

Deprecated:
‪will be removed in TYPO3 11. use PagePermissionAssembler instead.

Definition at line 349 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\start().

◆ $defaultValues

array TYPO3\CMS\Core\DataHandling\DataHandler::$defaultValues = array( )

[table][fields]=value: New records are created with default values and you can set this array on the form $defaultValues[$table][$field] = $value to override the default values fetched from TCA. If ->setDefaultsFromUserTS is called UserTSconfig default values will overrule existing values in this array (thus UserTSconfig overrules externally set defaults which overrules TCA defaults)

should only be used from within TYPO3 Core

Definition at line 203 of file DataHandler.php.

◆ $deletedRecords

array TYPO3\CMS\Core\DataHandling\DataHandler::$deletedRecords = array( )
protected

Per-table array with UIDs that have been deleted.

Definition at line 289 of file DataHandler.php.

◆ $deleteTree

bool TYPO3\CMS\Core\DataHandling\DataHandler::$deleteTree = false

If this is set, then a page is deleted by deleting the whole branch under it (user must have delete permissions to it all). If not set, then the page is deleted ONLY if it has no branch.

Definition at line 136 of file DataHandler.php.

◆ $disableDeleteClause

bool TYPO3\CMS\Core\DataHandling\DataHandler::$disableDeleteClause = false
protected

Disable delete clause

Definition at line 540 of file DataHandler.php.

◆ $dontProcessTransformations

bool TYPO3\CMS\Core\DataHandling\DataHandler::$dontProcessTransformations = false

If set, then transformations are NOT performed on the input.

Definition at line 154 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\insertNewCopyVersion().

◆ $enableLogging

◆ $errorLog

array TYPO3\CMS\Core\DataHandling\DataHandler::$errorLog = array( )

Errors are collected in this variable.

should only be used from within TYPO3 Core

Definition at line 296 of file DataHandler.php.

◆ $excludedTablesAndFields

array TYPO3\CMS\Core\DataHandling\DataHandler::$excludedTablesAndFields = array( )
protected

The list of

<fields> that cannot be edited by user. This is compiled from TCA/exclude-flag combined with non_exclude_fields for the user.

Definition at line 363 of file DataHandler.php.

◆ $historyRecords

array TYPO3\CMS\Core\DataHandling\DataHandler::$historyRecords = array( )
protected

List of changed old record ids to new records ids

Definition at line 394 of file DataHandler.php.

◆ $isImporting

bool TYPO3\CMS\Core\DataHandling\DataHandler::$isImporting = false

If set, then the TCE class has been instantiated during an import action of a T3D

Definition at line 148 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getLocalTCE().

◆ $isInWebMount_Cache

array TYPO3\CMS\Core\DataHandling\DataHandler::$isInWebMount_Cache = array( )
protected

Caching array for page ids in webmounts

Definition at line 440 of file DataHandler.php.

◆ $isRecordInWebMount_Cache

array TYPO3\CMS\Core\DataHandling\DataHandler::$isRecordInWebMount_Cache = array( )
protected

Caching array for check of whether records are in a webmount

Definition at line 434 of file DataHandler.php.

◆ $mmHistoryRecords

array TYPO3\CMS\Core\DataHandling\DataHandler::$mmHistoryRecords = array( )
protected

List of changed old record ids to new records ids

Definition at line 388 of file DataHandler.php.

◆ $neverHideAtCopy

bool TYPO3\CMS\Core\DataHandling\DataHandler::$neverHideAtCopy = false

If set, then the 'hideAtCopy' flag for tables will be ignored.

Definition at line 142 of file DataHandler.php.

◆ $newRelatedIDs

array TYPO3\CMS\Core\DataHandling\DataHandler::$newRelatedIDs = array( )

Holds the tables and there the ids of newly created child records from IRRE

should only be used from within TYPO3 Core

Definition at line 276 of file DataHandler.php.

◆ $outerMostInstance

TYPO3 CMS Core DataHandling DataHandler TYPO3\CMS\Core\DataHandling\DataHandler::$outerMostInstance
protected

The outer most instance of \TYPO3\CMS\Core\DataHandling\DataHandler: This object instantiates itself on versioning and localization ...

Definition at line 555 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getOuterMostInstance().

◆ $overrideValues

array TYPO3\CMS\Core\DataHandling\DataHandler::$overrideValues = array( )

[table][fields]=value: You can set this array on the form $overrideValues[$table][$field] = $value to override the incoming data. You must set this externally. You must make sure the fields in this array are also found in the table, because it's not checked. All columns can be set by this array!

should only be used from within TYPO3 Core

Definition at line 212 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\copyL10nOverlayRecords(), TYPO3\CMS\Core\DataHandling\DataHandler\copyRecord(), TYPO3\CMS\Core\DataHandling\DataHandler\copySpecificPage(), and TYPO3\CMS\Core\DataHandling\DataHandler\localize().

◆ $pageCache

array TYPO3\CMS\Core\DataHandling\DataHandler::$pageCache = array( )
protected

Used for caching page records in pageInfo()

Definition at line 446 of file DataHandler.php.

◆ $pagePermissionAssembler

PagePermissionAssembler TYPO3\CMS\Core\DataHandling\DataHandler::$pagePermissionAssembler
protected

Definition at line 357 of file DataHandler.php.

◆ $pagetreeNeedsRefresh

bool TYPO3\CMS\Core\DataHandling\DataHandler::$pagetreeNeedsRefresh = false

Indicates whether the pagetree needs a refresh because of important changes

should only be used from within TYPO3 Core

Definition at line 309 of file DataHandler.php.

◆ $pagetreeRefreshFieldsFromPages

array TYPO3\CMS\Core\DataHandling\DataHandler::$pagetreeRefreshFieldsFromPages = array( 'pid', 'sorting', 'deleted', 'hidden', 'title', 'doktype', 'is_siteroot', 'fe_group', 'nav_hide', 'nav_title', 'module', 'starttime', 'endtime', 'content_from_pid', 'extendToSubpages' )

Fields from the pages-table for which changes will trigger a pagetree refresh

Definition at line 302 of file DataHandler.php.

◆ $pMap

array TYPO3\CMS\Core\DataHandling\DataHandler::$pMap
Initial value:
= array(
'show' => 1,
'edit' => 2,
'delete' => 4,
'new' => 8,
'editcontent' => 16
)

Permission mapping

Deprecated:
‪will be removed in TYPO3 11. use PagePermissionAssembler instead.

Definition at line 402 of file DataHandler.php.

◆ $recInsertAccessCache

array TYPO3\CMS\Core\DataHandling\DataHandler::$recInsertAccessCache = array( )
protected

User by function checkRecordInsertAccess() to store whether a record can be inserted on a page id

Definition at line 428 of file DataHandler.php.

◆ $recordPidsForDeletedRecords

array TYPO3\CMS\Core\DataHandling\DataHandler::$recordPidsForDeletedRecords = array( )
staticprotected

Internal cache for pids of records which were deleted. It's not possible to retrieve the parent folder/page at a later stage

Definition at line 568 of file DataHandler.php.

◆ $recordsToClearCacheFor

array TYPO3\CMS\Core\DataHandling\DataHandler::$recordsToClearCacheFor = array( )
staticprotected

Internal cache for collecting records that should trigger cache clearing

Definition at line 561 of file DataHandler.php.

◆ $referenceIndexUpdater

ReferenceIndexUpdater TYPO3\CMS\Core\DataHandling\DataHandler::$referenceIndexUpdater
protected

Registry object to gather reference index update requests and perform updates after main processing has been done. The first call to start() instantiates this object. Recursive sub instances receive this instance via __construct(). The final update() call is done at the end of process_cmdmap() or process_datamap() in the outer most instance.

Definition at line 517 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\__construct().

◆ $registerDBList

array TYPO3\CMS\Core\DataHandling\DataHandler::$registerDBList = array( )

Used for tracking references that might need correction after operations

Definition at line 461 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getVersionizedIncomingFieldArray(), and TYPO3\CMS\Core\DataHandling\DataHandler\process_datamap().

◆ $registerDBPids

array TYPO3\CMS\Core\DataHandling\DataHandler::$registerDBPids = array( )

Used for tracking references that might need correction in pid field after operations (e.g. IRRE)

Definition at line 468 of file DataHandler.php.

◆ $remapStack

array TYPO3\CMS\Core\DataHandling\DataHandler::$remapStack = array( )

Array used for remapping uids and values at the end of process_datamap

Definition at line 487 of file DataHandler.php.

◆ $remapStackActions

array TYPO3\CMS\Core\DataHandling\DataHandler::$remapStackActions = array( )
protected

Array used for executing addition actions after remapping happened (set processRemapStack())

Definition at line 507 of file DataHandler.php.

◆ $remapStackChildIds

array TYPO3\CMS\Core\DataHandling\DataHandler::$remapStackChildIds = array( )
protected

Array used for checking whether new children need to be remapped

Definition at line 501 of file DataHandler.php.

◆ $remapStackRecords

array TYPO3\CMS\Core\DataHandling\DataHandler::$remapStackRecords = array( )

Array used for remapping uids and values at the end of process_datamap (e.g. $remapStackRecords[

[<uid>] = <index in $remapStack>)

Definition at line 495 of file DataHandler.php.

◆ $reverseOrder

bool TYPO3\CMS\Core\DataHandling\DataHandler::$reverseOrder = false

If TRUE, the datamap array is reversed in the order, which is a nice thing if you're creating a whole new bunch of records.

Definition at line 108 of file DataHandler.php.

◆ $runtimeCache

TYPO3 CMS Core Cache Frontend FrontendInterface TYPO3\CMS\Core\DataHandling\DataHandler::$runtimeCache
protected

Runtime Cache to store and retrieve data computed for a single request

Definition at line 574 of file DataHandler.php.

◆ $sortIntervals

int TYPO3\CMS\Core\DataHandling\DataHandler::$sortIntervals = 256

The interval between sorting numbers used with tables with a 'sorting' field defined.

Min 1, should be power of 2

should only be used from within TYPO3 Core

Definition at line 421 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\getSortNumber().

◆ $storeLogMessages

bool TYPO3\CMS\Core\DataHandling\DataHandler::$storeLogMessages = true

If TRUE, the default log-messages will be stored. This should not be necessary if the locallang-file for the log-display is properly configured. So disabling this will just save some database-space as the default messages are not saved.

Definition at line 95 of file DataHandler.php.

◆ $substNEWwithIDs

array TYPO3\CMS\Core\DataHandling\DataHandler::$substNEWwithIDs = array( )

When new elements are created, this array contains a map between their "NEW..." string IDs and the eventual UID they got when stored in database

Definition at line 262 of file DataHandler.php.

◆ $substNEWwithIDs_table

array TYPO3\CMS\Core\DataHandling\DataHandler::$substNEWwithIDs_table = array( )

Like $substNEWwithIDs, but where each old "NEW..." id is mapped to the table it was from.

should only be used from within TYPO3 Core

Definition at line 269 of file DataHandler.php.

◆ $suggestedInsertUids

array TYPO3\CMS\Core\DataHandling\DataHandler::$suggestedInsertUids = array( )

Use this array to validate suggested uids for tables by setting [table]:[uid]. This is a dangerous option since it will force the inserted record to have a certain UID. The value just have to be TRUE, but if you set it to "DELETE" it will make sure any record with that UID will be deleted first (raw delete). The option is used for import of T3D files when synchronizing between two mirrored servers. As a security measure this feature is available only for Admin Users (for now)

Definition at line 231 of file DataHandler.php.

◆ $userid

int TYPO3\CMS\Core\DataHandling\DataHandler::$userid

Will be set to uid of be_user executing this script

should only be used from within TYPO3 Core

Definition at line 328 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\insertNewCopyVersion().

◆ $username

string TYPO3\CMS\Core\DataHandling\DataHandler::$username

Will be set to username of be_user executing this script

should only be used from within TYPO3 Core

Definition at line 335 of file DataHandler.php.

◆ $useTransOrigPointerField

bool TYPO3\CMS\Core\DataHandling\DataHandler::$useTransOrigPointerField = true
protected

Will distinguish between translations (with parent) and localizations (without parent) while still using the same methods to copy the records TRUE: translation of a record connected to the default language FALSE: localization of a record without connection to the default language

Definition at line 162 of file DataHandler.php.

Referenced by TYPO3\CMS\Core\DataHandling\DataHandler\process_cmdmap().

◆ $version_remapMMForVersionSwap_reg

array TYPO3\CMS\Core\DataHandling\DataHandler::$version_remapMMForVersionSwap_reg
protected

Definition at line 548 of file DataHandler.php.