[TYPO3-core] RFC: bug #549

Franz Holzinger franz at fholzinger.com
Mon Feb 27 08:29:02 CET 2006


Hello Wolfgang,

> *hiya!*
>
> Type: bugfix
>
> No information about deleted records in the backend log.
> BT reference: http://bugs.typo3.org/view.php?id=549
>
> I badly needed this last week... I was not able to convict
> a client, though I'm sure he deleted the page himself. ;-(
>
> I wonder why nobody integrated that already.. hmmm
>
>
>  
>

Add a comment to the comment of the log function:

>      * @param    integer        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


> $page_propArr

this kind of naming is not wanted here.

You have the line

> $GLOBALS['TYPO3_DB']->exec_DELETEquery($table, 'uid='.intval($uid));

which will call:

>     function DELETEquery($table,$where)    {
>         if (is_string($where))    {
>
>                 // Table and fieldnames should be "SQL-injection-safe"
> when supplied to this function
>             $query = 'DELETE FROM '.$table.
>                 (strlen($where)>0 ? '
>                 WHERE
>                     '.$where : '');
>


And after it you have coded:

> $propArr = $this->getRecordProperties($table, $uid);

which will call

>     function recordInfo($table,$id,$fieldList)    {
>         global $TCA;
>         if (is_array($TCA[$table]))    {
>             $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery($fieldList,
> $table, 'uid='.intval($id));
>             if ($GLOBALS['TYPO3_DB']->sql_num_rows($res))    {
>                 return $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);
>             }
>         }
>     }



So how should this work when the record with this uid has already been
deleted before?


Greets,

Franz









More information about the TYPO3-team-core mailing list