Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

hours to seconds php

$str_time = "2:50";

sscanf($str_time, "%d:%d:%d", $hours, $minutes, $seconds);

$time_seconds = isset($seconds) ? $hours * 3600 + $minutes * 60 + $seconds : $hours * 60 + $minutes;
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #hours #seconds #php
ADD COMMENT
Topic
Name
1+3 =