$file_list = 'file_list.json'; $c['{collapsible}'] = 'false'; $use_current = isset($_POST['use_current']) && $_POST['use_current'] == 'on'; $lang['{use_this}'] = '<br/><input type="checkbox" name="use_current" class="use" ' . ($use_current ? 'checked' : '') . '> Использовать текущую?'; $c['{install_path}'] = DIR; if (!$i->check('e|w', DIR . 'tmp')) { mkdir(DIR . 'tmp'); } if (!isset($_POST['app_name']) || !isset($_POST['install_path'])) { $c['{app}'] = $lang['{app}']; $c['{install_path}'] = DIR . 'tmp/'; } else { $c['{app}'] = $_POST['app_name']; $c['{install_path}'] = $_POST['install_path']; } $i->check('em', $c['{app}']) ? $i->step('app_name', true) : $i->step('app_name', false); $c = listResult('options', $i, $c); $i->check('e|w', $c['{install_path}']) ? $i->step('install_path', true) : $i->step('install_path', false); $c = listResult('perms', $i, $c); if (!$i->check('e|r|f', DIR . $file_list)) { $d->get($file_list, DIR); } if ($i->check('e|r|f', DIR . $file_list)) { $i->step('dist', true); $files = json_decode(file_get_contents(DIR . $file_list), 1); if (!$i->check('e|r|f', $files['files'])) { //TODO: add button download files $d->get($files['files'], DIR); $i->check('e|r|f', $files['files']); } } else {