Guest User

Untitled

a guest
Feb 18th, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.29 KB | None | 0 0
  1. $rawTime = substr($tagParts[1], 0, 1)-$_GET['tz-offset'];
  2. $time24 = str_replace('.5',':30', $rawTime);
  3. $time12 = $time24-12;
  4.        
  5. if ($time12 < 0) {
  6.     $time = $b+12;
  7.     tm = "am";
  8. } else if ($time12 == 0) {
  9.     $time = $b+12;
  10.     $tm = "pm";
  11. } else {
  12.     $tm = "pm";
  13. }
  14. $localTime = $time.$tm;
Add Comment
Please, Sign In to add comment