TYPO3  7.6
Static Public Member Functions | List of all members
DebugUtility Class Reference

Static Public Member Functions

static debug ($var= '', $header= '', $group= 'Debug')
 
static convertVariableToString ($variable)
 
static debugInPopUpWindow ($debugVariable, $header= 'Debug', $group= 'Debug')
 
static debugTrail ()
 
static debugRows ($rows, $header= '', $returnHTML=false)
 
static ordinalValue ($string, $characters=100)
 
static viewArray ($array_in)
 
static printArray ($array_in)
 

Detailed Description

Class to handle debug

Definition at line 21 of file DebugUtility.php.

Member Function Documentation

static convertVariableToString (   $variable)
static

Converts a variable to a string

Parameters
mixed$variable
Returns
string

Definition at line 67 of file DebugUtility.php.

References elseif.

static debug (   $var = '',
  $header = '',
  $group = 'Debug' 
)
static

Debug

Parameters
string$var
string$header
string$group
Returns
void

Definition at line 31 of file DebugUtility.php.

References GeneralUtility\quoteJSvalue(), and GeneralUtility\wrapJS().

Referenced by GeneralUtility\deprecationLog().

static debugInPopUpWindow (   $debugVariable,
  $header = 'Debug',
  $group = 'Debug' 
)
static

Opens a debug message inside a popup window

Parameters
mixed$debugVariable
string$header
string$group

Definition at line 88 of file DebugUtility.php.

References GeneralUtility\quoteJSvalue(), and GeneralUtility\wrapJS().

static debugRows (   $rows,
  $header = '',
  $returnHTML = false 
)
static

Displays an array as rows in a table. Useful to debug output like an array of database records.

Parameters
mixed$rowsArray of arrays with similar keys
string$headerTable header
bool$returnHTMLIf TRUE, will return content instead of echo'ing out. Deprecated since TYPO3 CMS 7, will be removed in TYPO3 CMS 8
Returns
void Outputs to browser.

Definition at line 158 of file DebugUtility.php.

References debug(), GeneralUtility\deprecationLog(), and DebuggerUtility\var_dump().

static debugTrail ( )
static

Displays the "path" of the function call stack in a string, using debug_backtrace

Returns
string

Definition at line 133 of file DebugUtility.php.

References PathUtility\stripPathSitePrefix().

Referenced by GeneralUtility\logDeprecatedFunction().

static ordinalValue (   $string,
  $characters = 100 
)
static

Returns a string with a list of ascii-values for the first $characters characters in $string

Parameters
string$stringString to show ASCII value for
int$charactersNumber of characters to show
Returns
string The string with ASCII values in separated by a space char.

Definition at line 173 of file DebugUtility.php.

static printArray (   $array_in)
static

Prints an array

Parameters
mixed$array_inArray to print visually (in a table).
Returns
void
See Also
viewArray()

Definition at line 205 of file DebugUtility.php.

static viewArray (   $array_in)
static

Returns HTML-code, which is a visual representation of a multidimensional array use ::print_array() in order to print an array Returns FALSE if $array_in is not an array

Parameters
mixed$array_inArray to view
Returns
string HTML output

Definition at line 193 of file DebugUtility.php.

References DebuggerUtility\var_dump().

Referenced by ContentObjectRenderer\getData(), and GeneralUtility\makeInstanceService().