Project

General

Profile

Bug #15248 » delete_patch_2.txt

Administrator Admin, 2008-08-29 12:11

 
diff -ru typo3.orig/class.db_list_extra.inc typo3/class.db_list_extra.inc
--- typo3.orig/class.db_list_extra.inc 2008-06-11 10:15:21.000000000 +0200
+++ typo3/class.db_list_extra.inc 2008-08-29 12:09:21.000000000 +0200
@@ -1031,8 +1031,14 @@
if (
($table=='pages' && ($localCalcPerms&4)) || ($table!='pages' && ($this->calcPerms&16))
) {
+ $titleOrig = htmlspecialchars(t3lib_BEfunc::getRecordTitle($table,$row,FALSE,TRUE));
+ $titleLength = $GLOBALS['BE_USER']->uc['titleLen'];
+ if (!$titleLength || !t3lib_div::testInt($titleLength) || $titleLength < 0) {
+ $titleLength = 31;
+ }
+ $title = htmlspecialchars(t3lib_div::fixed_lgd_cs($titleOrig, $titleLength));
$params='&cmd['.$table.']['.$row['uid'].'][delete]=1';
- $cells['delete']='<a href="#" onclick="'.htmlspecialchars('if (confirm('.$LANG->JScharCode($LANG->getLL('deleteWarning').t3lib_BEfunc::referenceCount($table,$row['uid'],' (There are %s reference(s) to this record!)')).')) {jumpToUrl(\''.$SOBE->doc->issueCommand($params,-1).'\');} return false;').'">'.
+ $cells['delete']='<a href="#" onclick="'.htmlspecialchars('if (confirm('.$LANG->JScharCode($LANG->getLL('deleteWarning').' "'. $title.'" '.t3lib_BEfunc::referenceCount($table,$row['uid'],' (There are %s reference(s) to this record!)')).')) {jumpToUrl(\''.$SOBE->doc->issueCommand($params,-1).'\');} return false;').'">'.
'<img'.t3lib_iconWorks::skinImg($this->backPath,'gfx/garbage.gif','width="11" height="12"').' title="'.$LANG->getLL('delete',1).'" alt="" />'.
'</a>';
} elseif(!$this->table) {
(2-2/3)