| | |
| | | +-----------------------------------------------------------------------+ |
| | | */ |
| | | |
| | | define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' ); |
| | | define('INSTALL_PATH', realpath(__DIR__ . '/..') . '/' ); |
| | | require INSTALL_PATH.'program/include/clisetup.php'; |
| | | |
| | | if ($argc < 2) { |
| | |
| | | |
| | | EOF; |
| | | |
| | | $output = sprintf($header, $lang, $varname.'.inc', date('Y'), $texts['_translator'], $varname); |
| | | $author = preg_replace('/\s*<Unknown>/i', '', $texts['_translator']); |
| | | $output = sprintf($header, $lang, $varname.'.inc', date('Y'), $author, $varname); |
| | | |
| | | foreach ($texts as $label => $value) { |
| | | if (is_array($value)) { var_dump($outfn, $label, $value); exit; } |
| | | if (is_array($value)) { var_dump($outfn, $label, $value); exit; } |
| | | if ($label[0] != '_' && strlen($value)) |
| | | $output .= sprintf("\$%s['%s'] = '%s';\n", $varname, $label, strtr(addcslashes($value, "'"), array("\r" => '', "\n" => '\n'))); |
| | | } |
| | |
| | | foreach ($dests as $dest) { |
| | | list($file, $label) = explode(':', $dest); |
| | | $out[$file][$label] = $msgstr; |
| | | $out[$file]['_translator'] = $translator; |
| | | } |
| | | } |
| | | |