|
|
@@ -41,13 +41,13 @@ function exec_ogp_module() {
|
|
|
$display_public_ip = trim($_POST['display_public_ip']);
|
|
|
|
|
|
if ( empty($rhost_ip) ){
|
|
|
- print_failure( enter_ip_host );
|
|
|
+ print_failure( get_lang("enter_ip_host") );
|
|
|
$view->refresh("?m=server");
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
if ( !isPortValid($rhost_port) ){
|
|
|
- print_failure( enter_valid_ip );
|
|
|
+ print_failure( get_lang("enter_valid_ip") );
|
|
|
$view->refresh("?m=server");
|
|
|
return;
|
|
|
}
|
|
|
@@ -58,13 +58,13 @@ function exec_ogp_module() {
|
|
|
$status = $remote->status_chk();
|
|
|
if($status === 0)
|
|
|
{
|
|
|
- print_failure( agent_offline . "<br>" . could_not_add_server . " " . $rhost_ip );
|
|
|
+ print_failure( get_lang("agent_offline") . "<br>" . get_lang("could_not_add_server") . " " . $rhost_ip );
|
|
|
echo create_back_button($_GET['m']);
|
|
|
return;
|
|
|
}
|
|
|
elseif($status === -1)
|
|
|
{
|
|
|
- print_failure( encryption_key_mismatch . "<br>" . could_not_add_server . " " . $rhost_ip );
|
|
|
+ print_failure( get_lang("encryption_key_mismatch") . "<br>" . get_lang("could_not_add_server") . " " . $rhost_ip );
|
|
|
echo create_back_button($_GET['m']);
|
|
|
return;
|
|
|
}
|
|
|
@@ -75,20 +75,20 @@ function exec_ogp_module() {
|
|
|
$rhost_id = $db->addRemoteServer($rhost_ip,$rhost_name,$rhost_user_name,$rhost_port,$rhost_ftp_ip,$rhost_ftp_port,$encryption_key,$timeout,$use_nat,$display_public_ip);
|
|
|
if ( !$rhost_id )
|
|
|
{
|
|
|
- print_failure( could_not_add_server ." ".$rhost_ip." ". to_db );
|
|
|
+ print_failure( get_lang("could_not_add_server") ." ".$rhost_ip." ". get_lang("to_db") );
|
|
|
$view->refresh("?m=server");
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
- print_success( added_server ." $rhost_ip ". with_port ." $rhost_port ". to_db_succesfully );
|
|
|
+ print_success( get_lang("added_server") ." $rhost_ip ". get_lang("with_port") ." $rhost_port ". get_lang("to_db_succesfully") );
|
|
|
|
|
|
$iplist = $remote->discover_ips();
|
|
|
|
|
|
if ( empty($iplist) )
|
|
|
- print_failure( unable_discover ." ".$rhost_ip.". ". set_ip_manually );
|
|
|
+ print_failure( get_lang("unable_discover") ." ".$rhost_ip.". ". get_lang("set_ip_manually") );
|
|
|
else
|
|
|
{
|
|
|
- print_success( found_ips ." (".implode(",",$iplist).") ". for_remote_server );
|
|
|
+ print_success( get_lang("found_ips") ." (".implode(",",$iplist).") ". get_lang("for_remote_server") );
|
|
|
foreach ( $iplist as $remote_ip )
|
|
|
{
|
|
|
$remote_ip = trim($remote_ip);
|
|
|
@@ -96,7 +96,7 @@ function exec_ogp_module() {
|
|
|
continue;
|
|
|
|
|
|
if ( !$db->addRemoteServerIp($rhost_id,$remote_ip) )
|
|
|
- print_failure( failed_add_ip ." (".$remote_ip.") ". for_remote_server );
|
|
|
+ print_failure( get_lang("failed_add_ip") ." (".$remote_ip.") ". get_lang("for_remote_server") );
|
|
|
}
|
|
|
}
|
|
|
$view->refresh("?m=server");
|