diff options
Diffstat (limited to 'home.php')
| -rw-r--r-- | home.php | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/home.php b/home.php new file mode 100644 index 00000000..7fcd4f14 --- /dev/null +++ b/home.php @@ -0,0 +1,29 @@ +<?php +//$cmd="/usr/bin/dot -Tpng -o $figfile $grfilenametemp"; +//system($cmd); +$cmd="top -b -n 2 -u apache|grep ^Cpu|cut -d',' -f1|cut -d':' -f2|cut -d'%' -f1>datafile"; +system($cmd); + +$cpu=file_get_contents("datafile"); +$str_arrmat=array(); +$str_arrmat=explode("\n",$cpu); + +if($str_arrmat[1]>70.0) +{ + +?> +<script> +window.open("http://bnw.genenetwork.org/BNW_1.01/sourcecodes/home.php",'_self',false); +</script> +<?php +} +else +{ +?> +<script> +window.open("http://compbio.uthsc.edu/BNW_1.01/sourcecodes/home.php",'_self',false); +</script> + +<?php +} +?> |
