Update pgkcp.lnk.php
This commit is contained in:
parent
5707ae8d63
commit
9392b63ef8
|
@ -30,6 +30,18 @@ if(!function_exists("get_pgkcp_config")) {
|
||||||
"g_conf_gw_port" => $g_conf_gw_port,
|
"g_conf_gw_port" => $g_conf_gw_port,
|
||||||
"module_type" => $module_type,
|
"module_type" => $module_type,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// read configuration file
|
||||||
|
$fr = read_storage_file("api.config.pgkcp.json", array(
|
||||||
|
"storage_type" => "payman"
|
||||||
|
));
|
||||||
|
if(!empty($fr)) {
|
||||||
|
$api_config = json_decode($fr, true);
|
||||||
|
$api_config_fields = array("g_conf_gw_url", "g_conf_js_url", "g_conf_site_cd", "g_conf_site_key", "g_conf_site_name");
|
||||||
|
foreach($api_config_fields as $name) {
|
||||||
|
$pgkcp_config[$name] = get_value_in_array($name, $api_config, $pgkcp_config[$name]);
|
||||||
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
set_error("PGKCP configuration file does not exists.");
|
set_error("PGKCP configuration file does not exists.");
|
||||||
show_errors();
|
show_errors();
|
||||||
|
@ -53,8 +65,8 @@ if(!function_exists("get_pgkcp_platform")) {
|
||||||
$platform = false;
|
$platform = false;
|
||||||
|
|
||||||
$exe_files = array(
|
$exe_files = array(
|
||||||
"linux" => $pgkcp_config['g_conf_home_dir'] . "/bin/pp_cli",
|
"default" => $pgkcp_config['g_conf_home_dir'] . "/bin/pp_cli",
|
||||||
"windows" => $pgkcp_config['g_conf_home_dir'] . "/bin/pp_cli.exe"
|
"win32" => $pgkcp_config['g_conf_home_dir'] . "/bin/pp_cli.exe"
|
||||||
);
|
);
|
||||||
|
|
||||||
foreach($exe_files as $k=>$v) {
|
foreach($exe_files as $k=>$v) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user