Answers for "execute shell command from html button node js"

0

execute shell command from html button node js

const { exec } = require('child_process');
exec('ls -lart', (error, stdout, stderr) => {
  if (error) {
    console.error(`exec error: ${error}`);
    return;
  }
  console.log(`stdout: ${stdout}`);
  console.error(`stderr: ${stderr}`);
});
Posted by: Guest on March-19-2022

Code answers related to "execute shell command from html button node js"

Code answers related to "Javascript"

Browse Popular Code Answers by Language