This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Original by PROXIMO https://gist.github.com/PROX1MO | |
| // Modified by DERGONIC https://gist.github.com/Dergonic | |
| // Changelog : | |
| // Changes relating modification of "ifconfig" structure | |
| // Split -> explode or preg_split (PHP7 compliant) | |
| header("Cache-Control: no-cache, must-revalidate"); | |
| header("Expires: Sat, 26 May 1983 13:00:00 GMT"); | |
| header("Pragma: no-cache"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| mysqllogin=#Mysql_Login | |
| mysqlpassword=#Mysql_Pass | |
| mysqldb=#Mysql_Server | |
| uptime=`cat /proc/uptime | sed "s/ /%/" |cut -d'%' -f1` | |
| sql="INSERT INTO uptime (id,date,value) VALUES ('',NOW(),$uptime);" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function removeWrongValues(values, trustMulti) { | |
| var sValues = values.sort(function(a,b){return a - b;}); | |
| var valCount = sValues.length; //number of items in the table | |
| var q1Arr = (sValues.length % 2 == 0) ? sValues.slice(0, (sValues.length / 2)) : sValues.slice(0,Math.floor(sValues.length / 2)); | |
| var q2Arr = sValues; | |
| var q3Arr = (sValues.length % 2 == 0) ? sValues.slice((sValues.length / 2), sValues.length) : sValues.slice(Math.ceil(sValues.length / 2)); | |
| var q1 = median(q1Arr); | |
| var q2 = median(q2Arr); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # Character for separating values | |
| # (commas are not safe, because some servers return speeds with commas) | |
| speedtestserver=3271 | |
| mysqllogin=#Mysql_Login | |
| mysqlpassword=#Mysql_Pass | |
| mysqldb=#Mysql_Server | |
| pcip="192.168.1.2" #work computer |