#!/usr/bin/php -q $docroot = $docroot ?? $_SERVER['DOCUMENT_ROOT'] ?: '/usr/local/emhttp'; require_once "$docroot/webGui/include/Helpers.php"; extract(parse_plugin_cfg('dynamix',true)); // add translations $_SERVER['REQUEST_URI'] = 'dashboard'; $login_locale = $display['locale']; require_once "$docroot/webGui/include/Translations.php"; function write($message){ $nchan = curl_init(); curl_setopt_array($nchan,[ CURLOPT_URL => 'http://localhost/pub/selectcase?buffer_length=1', CURLOPT_UNIX_SOCKET_PATH => '/var/run/nginx.socket', CURLOPT_POST => 1, CURLOPT_POSTFIELDS => $message, CURLOPT_RETURNTRANSFER => true ]); curl_exec($nchan); curl_close($nchan); } $boot = "/boot/config/plugins/dynamix"; $file = $argv[1]; $exist = is_file("$boot/$file"); $cmodel = $exist ? file_get_contents("$boot/$file") : ''; $style = [""; $script = [""; $html = ["