I didn’t guess how to use it ?
-
I was trying to test why the following code was not doing as expected (see below), Firstly I tried ‘echo’, but found it isn’t allowed with WP. Then when searching forums I found your Plugin (Hooray!)
I installed it, but didn’t understand the help text (I think it would be better if you added an example).
Then I didn’t know where the output goes. I tried console, then looked at your plugin and found it. (I think it would be better if you explained where to look)$date1 = new DateTime( $list[ 'ga_event_start_date' ] );
// do_action( 'inspect', [ 'variable_name', $date1, FILE, LINE ] ); // for testing
$date2 = new DateTime( "today" );
// do_action( 'inspect', [ 'variable_name', $date2, FILE, LINE ] ); // for testing
if ( $date1 < $date2 ) {
$list[ 'ga_event_start_date' ] = "" . $list[ 'ga_event_start_date' ] . "";Each time I changed & refreshed my test page, I then looked at your output, and only found one line reported.
Then I tried refreshing your output page and found more, but I was never able to output more than one line – even by then I had found your ‘Refresh’ button – it too refreshed and only gave me only one line.So I commented-out lines, but got the same (commented out) line reported. Could your plugin be reading a cached version of my test code, rather than the live?
After eventually outputting the values of $date1 & $date2, I added the following line to the end:
do_action( 'inspect', [ 'variable_name', $list[ 'ga_event_start_date' ], FILE, LINE ] ); // for testing.
It does not seem to work, have I got the variable name correct
$list[ 'ga_event_start_date'
)A BIG thanks for a VERY useful plugin!!
- You must be logged in to reply to this topic.