User:Krams036/PHP Cheatsheet

Essential SublimeText Packages

 * Package Control
 * Color Hints
 * Emmet
 * EmmetCSS
 * Color Picker
 * Color Convert

Excel to PHP Time
 $str_date = time; $toExcel = intval(25569 + $str_date / 86400);   //Convert PHP time to Excel time $frExcel = intval(($toExcel - 25569)*86400 );   //Convert Excel time to PHP time

Count/Sum all in PHP
 $rows = $result->query("SELECT COUNT(*) as count FROM USERIDS"); $row = $rows->fetchArray; $numRows = $row['count'];

Detect Browser
https://stackoverflow.com/questions/2257597/reliable-user-browser-detection-with-php