Description
'all' hook looking for the changes to things listed in string BW_TRACE_ANYCHANGENote: You can invoke this function directly if you really really want.
Usage
$string = bw_trace_anychange( $tag, $arg2 );Parameters
- $tag
- ( string ) required – the hook or filter being invoked
- $arg2
- ( mixed ) optional – first parameter to the action hook or filter
Returns
string $tagSource
File name: oik-bwtrace/includes/bwtrace-anychange.phpLines:
1 to 32 of 32
function bw_trace_anychange( $tag, $arg2=null ) { static $previous_value = null; return $tag; $name = BW_TRACE_ANYCHANGE; if ( defined( $name ) ) { $value = constant( $name ); if ( null === $value ) { // E_WARNING level error should have been generated } bw_trace2( $value, "anychange current value for: $name", false, BW_TRACE_VERBOSE ); if ( $value !== $previous_value ) { bw_trace2( $previous_value, "anychange previous: $name", true ); bw_backtrace(); //gob(); } $previous_value = $value; } else { /// only works for constants at the moment bw_trace2( $name, "anychange constant not yet defined", true ); } if ( $name == "PHP_SAPI" ) { bw_trace2( PHP_SAPI, "How about now?", false, BW_TRACE_VERBOSE ); } return( $tag ); }View on GitHub View on Trac
Calls
1 to 3 of 3
