This error is displayed when the data returned (via AJAX) by the command is empty.
Did you try to select another PHP function for command execution in the “Settings” tab?
1. Go to the “settings” tab, select “system” for the PHP function and save the settings.
2. Open “wpterm.php” and locate this line:
// Run the command:
list( $res, $ret_var ) = @run_command( $command, trim( $_POST['exec'] ) );
Right below, add this code:
@file_put_contents( '/full/path/to/debug.txt', "-\$res = {$res}\n=========\n-\$ret_var = {$ret_var}\n" );
3. Replace /full/path/to/debug.txt
with the full path to the debug log you want to create (it must be writable).
4. Go back to the terminal and enter the uname
shell command.
5. Check the debug.txt
log and paste its content here.
6. After your test, remove the line you added to the “wpterm.php” file.
]]>-$res = SunOS
[-{–}-]
=========
-$ret_var = 0
$PWD
environment variable defined. WPTerm uses it to retrieve the current working directory.pwd
command instead.
1. Search and remove this line of code:
$command = sprintf( "ABSPATH=%s;cd %s;%s 2>&1;echo [-{-%s-}-]", $abs, $cwd, $cmd, '$PWD' );
2. Replace it with this line:
$command = sprintf( 'ABSPATH=%s;cd %s;%s 2>&1;echo [-{-$(pwd)-}-]', $abs, $cwd, $cmd );
If it works, I’ll make the change to the next update of WPTerm.
]]>something changed. The error message is now:
WPTerm: error 2
Sorry, Oliver
]]>-$res = Array
=========
-$ret_var = 2
Best regards
Oliver
]]>