Public Member Functions | |
initArray () | |
Initialize the log table array with header labels. | |
getTimeLabel ($code) | |
Get time label for log listing. | |
getUserLabel ($code) | |
Get user name label for log listing. | |
getTypeLabel ($code) | |
Get type label for log listing. | |
getActionLabel ($code) | |
Get action label for log listing. | |
getDetails ($code, $text, $data, $sys_log_uid=0) | |
Get details for the log entry. | |
reset () | |
Reset all internal "last..." variables to blank string. | |
getErrorFormatting ($sign) | |
Formats input string in red-colored font tags. | |
formatDetailsForList ($row) | |
Formatting details text for the sys_log row inputted. | |
stripPath ($inArr) | |
For all entries in the $inArray (expected to be filepaths) the basename is extracted and set as value (if $this->stripPath is set) This is done for log-entries from the FILE modules. | |
Public Attributes | |
$lastTimeLabel = '' | |
$lastUserLabel = '' | |
$lastTypeLabel = '' | |
$lastActionLabel = '' | |
$detailsOn = 1 | |
$stripPath = 1 | |
$errorSign | |
$be_user_Array = array() |
|
Formatting details text for the sys_log row inputted.
Definition at line 236 of file class.t3lib_bedisplaylog.php. References getDetails(), and stripPath(). 00236 { 00237 $data = unserialize($row['log_data']); 00238 if ($row['type']==2) { 00239 $data=$this->stripPath($data); 00240 } 00241 00242 return $this->getDetails($row['type'].'_'.$row['action'].'_'.$row['details_nr'],$row['details'],$data,$row['uid']).' ('.$row['details_nr'].')'; 00243 }
|
|
Get action label for log listing.
Definition at line 162 of file class.t3lib_bedisplaylog.php. 00162 { 00163 if ($this->lastActionLabel!=$code) { 00164 $this->lastActionLabel=$code; 00165 $label=$GLOBALS['LANG']->getLL('action_'.$code); 00166 return $label ? $label : '['.$code.']'; 00167 } else return '.'; 00168 }
|
|
Get details for the log entry.
Definition at line 180 of file class.t3lib_bedisplaylog.php. Referenced by formatDetailsForList(). 00180 { 00181 // $code is used later on to substitute errormessages with language-corrected values... 00182 if (is_array($data)) { 00183 if ($this->detailsOn) { 00184 if (is_object($GLOBALS['LANG'])) { 00185 $label = $GLOBALS['LANG']->getLL('msg_'.$code); 00186 } else { 00187 list($label) = explode(',',$text); 00188 } 00189 if ($label) {$text=$label;} 00190 $text = sprintf($text, htmlspecialchars($data[0]),htmlspecialchars($data[1]),htmlspecialchars($data[2]),htmlspecialchars($data[3]),htmlspecialchars($data[4])); 00191 } else { 00192 $text = str_replace('%s','',$text); 00193 } 00194 } 00195 00196 // Finding the history for the record 00197 $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid,fieldlist', 'sys_history', 'sys_log_uid='.intval($sys_log_uid)); 00198 $newRow = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res); 00199 if (is_array($newRow)) { 00200 $text.=' Changes in fields: <em>'.$newRow['fieldlist'].'</em>.'; 00201 $text.=' <a href="'.htmlspecialchars($GLOBALS['BACK_PATH'].'show_rechis.php?sh_uid='.$newRow['uid'].'&returnUrl='.rawurlencode(t3lib_div::getIndpEnv('REQUEST_URI'))).'"><b>->His</b></a>'; 00202 } 00203 00204 return $text; 00205 }
|
|
Formats input string in red-colored font tags.
Definition at line 226 of file class.t3lib_bedisplaylog.php. 00226 { 00227 return '<font color="red"><b>'.$sign.'</b></font>'; 00228 }
|
|
Get time label for log listing.
Definition at line 119 of file class.t3lib_bedisplaylog.php. 00119 { 00120 $t=$GLOBALS['SOBE']->doc->formatTime($code,1); 00121 if ($this->lastTimeLabel!=$t) { 00122 $this->lastTimeLabel=$t; 00123 return $t; 00124 } else return '.'; 00125 00126 }
|
|
Get type label for log listing.
Definition at line 148 of file class.t3lib_bedisplaylog.php. 00148 { 00149 if ($this->lastTypeLabel!=$code) { 00150 $this->lastTypeLabel=$code; 00151 $label=$GLOBALS['LANG']->getLL('type_'.$code); 00152 return $label ? $label : '['.$code.']'; 00153 } else return '.'; 00154 }
|
|
Get user name label for log listing.
Definition at line 134 of file class.t3lib_bedisplaylog.php. 00134 { 00135 if ($this->lastUserLabel!=$code) { 00136 $this->lastUserLabel=$code; 00137 $label = $this->be_user_Array[$code]['username']; 00138 return $label ? $label : '['.$code.']'; 00139 } else return '.'; 00140 }
|
|
Initialize the log table array with header labels.
Definition at line 102 of file class.t3lib_bedisplaylog.php. 00102 { 00103 $codeArr=Array(); 00104 $codeArr[0][]='Time'; // Time 00105 $codeArr[0][]='User'; 00106 $codeArr[0][]='Type'; 00107 $codeArr[0][]='E'; 00108 $codeArr[0][]='Action'; 00109 $codeArr[0][]='Details'; 00110 return $codeArr; 00111 }
|
|
Reset all internal "last..." variables to blank string.
Definition at line 212 of file class.t3lib_bedisplaylog.php. 00212 { 00213 $this->lastTimeLabel=''; 00214 $this->lastUserLabel=''; 00215 $this->lastTypeLabel=''; 00216 $this->lastActionLabel=''; 00217 }
|
|
For all entries in the $inArray (expected to be filepaths) the basename is extracted and set as value (if $this->stripPath is set) This is done for log-entries from the FILE modules.
Definition at line 253 of file class.t3lib_bedisplaylog.php. References stripPath(). Referenced by formatDetailsForList(), and stripPath(). 00253 { 00254 if ($this->stripPath && is_array($inArr)) { 00255 while(list($key,$val)=each($inArr)) { 00256 $inArr[$key]=basename($val); 00257 } 00258 } 00259 return $inArr; 00260 }
|
|
Definition at line 95 of file class.t3lib_bedisplaylog.php. |
|
Definition at line 87 of file class.t3lib_bedisplaylog.php. |
|
Initial value: Array(
1 => '!',
2 => 'Sys!',
3 => 'Secur!'
)
Definition at line 89 of file class.t3lib_bedisplaylog.php. |
|
Definition at line 85 of file class.t3lib_bedisplaylog.php. |
|
Definition at line 82 of file class.t3lib_bedisplaylog.php. |
|
Definition at line 84 of file class.t3lib_bedisplaylog.php. |
|
Definition at line 83 of file class.t3lib_bedisplaylog.php. |
|
Definition at line 88 of file class.t3lib_bedisplaylog.php. |