diff options
Diffstat (limited to 'ncp-web/ncp-launcher.php')
-rw-r--r-- | ncp-web/ncp-launcher.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/ncp-web/ncp-launcher.php b/ncp-web/ncp-launcher.php index 4d720ced..8590b066 100644 --- a/ncp-web/ncp-launcher.php +++ b/ncp-web/ncp-launcher.php @@ -148,6 +148,21 @@ else if ( $_POST['action'] == "cfg-ui" ) } // +// path field +// +else if ( $_POST['action'] == "path-exists" ) +{ + if (file_exists($_POST['value'])) + $ret = 0; + else + $ret = 1; + + // return JSON + echo '{ "token": "' . getCSRFToken() . '",'; // Get new token + echo ' "ret": "' . $ret . '" }'; +} + +// // poweroff // else if ( $_POST['action'] == "poweroff" ) |