--- alx-src/branches/alx-web-070/show.php 2015/09/11 15:16:23 7120 +++ alx-src/branches/alx-web-070/show.php 2015/09/11 15:35:13 7124 @@ -6,8 +6,8 @@ // INCLUDE CURRENT-PROBLEMS include('include/current-problems.php'); -$tabs = array('cfg_graphic', 'cfg_network', 'cfg_input', 'client_auth', 'cfg_autostart', 'client_serials', 'cfg_comments', 'cfg_printers', 'cfg_sessions', 'cfg_modules', 'cfg_other_menuitems', 'cfg_screensaver', 'client_version', 'cfg_plugins'); -$multi= array( 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1); +$tabs = array('cfg_graphic', 'cfg_network', 'cfg_input', 'client_auth', 'cfg_autostart', 'client_serials', 'cfg_comments', 'cfg_printers', 'cfg_sessions', 'cfg_modules', 'cfg_other_menuitems', 'cfg_screensaver', 'client_version'); +$multi= array( 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0); $data = array(); // get alx version info for @@ -90,14 +90,6 @@ $drop['wireless_key'] = 'password'; $drop['wireless_key_ascii'] = 'password'; -// plugin support -for ($i=0; $i<999; $i++) { $drop['cfg_plugins_'.$i.'_plugin'] = 'pluginconfig'; } -for ($i=0; $i<999; $i++) -{ - $drop['cfg_plugins_'.$i.'_plugin_array'] = sqlarr('SELECT plugin FROM avail_plugins', '', 'plugin'); - array_unshift($drop['cfg_plugins_'.$i.'_plugin_array'], ""); -} - // get current citrix sessions // split all citrix server into an array to get the first server from list $citrix_query_browser = split(";", $citrix_browseradrs); @@ -119,7 +111,6 @@ else if($what=='MODULE') sqladd('cfg_modules', array('serial'=>$id)); else if($what=='SESSION') sqladd('cfg_sessions', array('domain'=>$citrix_domain_name, 'browseradrs'=>$citrix_browseradrs, 'serial'=>$id)); else if($what=='MENUITEM') sqladd('cfg_other_menuitems', array('serial'=>$id)); - else if($what=='PLUGIN') sqladd('cfg_plugins', array('serial'=>$id)); } @@ -231,19 +222,6 @@ else if($d=='hidden') echo ''; else if($d=='1') echo ''; else if($d=='monitorid') echo ''.$k2.'= '; - else if($d=='pluginconfig') - { - $dplugin = $drop[$name.'_'.$k.'_array']; if($dplugin==null) $dplugin = $drop[$k]; - if(is_array($dplugin)) - { - echo ''.$k2.'= '; - } - // $v contains the pluginname, get the configure flag - $pflag = sqlfirst('SELECT configflag FROM avail_plugins WHERE plugin="'.$v.'"'); - if ($pflag[configflag]==1) echo 'configure= '; - } else if($d=='bold') echo ''.$k2.'= '; else if($d=='filename') echo 'filename= '; else if($d=='show') echo ''.$k2.'= '.$v.''; @@ -285,7 +263,6 @@ var $url = url.split("?"); $.ajax({type:""+typ+"",url:$url[0],data:$url[1],cache:false,success:function(data){ alert(data); }}); } - function plugin(name,id) { window.open('plugin.php?plugin='+name+'&id='+id, '', 'width=350,height=180'); } /* ignore this atm, not always working, sometime open does not work function openclose(nummer, act) @@ -377,7 +354,16 @@ $state = 'Off'; if(count($conn)>0) { - if($retval==0) $state = 'On'; + if($retval==0) + { + // first try mcore, then get ssh + $ping_retval = ping_host($conn['ip'],$mcore_port,$ping_timeout); + if($ping_retval==1) $ping_retval = ping_host($dat['ip'],$ssh_port,$ping_timeout); + if($ping_retval==0) + { + $state = 'On'; + } + } } echo '

'; @@ -389,10 +375,6 @@ echo '
'; echo '
'; echo '
'; - if($alxos >= '0.6.0') - { - echo '
'; - } echo '
'; if($id>0) $KILLCAP='DEACTIVATE'; else $KILLCAP='ACTIVATE';