I've been using wterm in my application fork, but now is guess is very old and discontinued. I've try to migrate to jquery-terminal, but I didn't understand well how configure.
With old wterm:
https://github.com/wanderleihuttel/webacula/blob/branch-7.4/application/views/scripts/bconsole/wterminal.phtml
There is a easy mode to configure? And include only the commands I allow?
My current function:
$('#wterm').terminal(function(command, term) {
term.pause();
if(command != ""){
$.post('<?php echo $this->baseUrl, '/bconsole/cmd' ?>', {'bcommand': command, 'command': cmd }).then(function(response) {
term.echo(response,{raw:true}).resume();
});
} else{
term.exec('clear').resume();
} //end if
},
{
greetings: welcome,
prompt: 'bconsole> ',
height: 400,
onBlur: function(){
return false;
}
}
);