library/Garp/Model/Behavior/YouTubeable.php
protected function _getDurationInSeconds($duration) {
        $interval = new \DateInterval($duration);
        return ($interval->d * 24 * 60 * 60) +
            ($interval->h * 60 * 60) +
            ($interval->i * 60) +
            $interval->s;
    }
protected function _getDurationInSeconds($duration) {
        $interval = new \DateInterval($duration);
        return ($interval->d * 24 * 60 * 60) +
            ($interval->h * 60 * 60) +
            ($interval->i * 60) +
            $interval->s;
    }
protected function _getDurationInSeconds ( $ duration ) { $ interval = new \ DateInterval ( $ duration ) ; return ( $ interval -> d * 24 * 60 * 60 ) + ( $ interval -> h * 60 * 60 ) + ( $ interval -> i * 60 ) + $ interval -> s ; }
Convert ISO 8601 duration to seconds

@param  string $duration
@return integer
Convert ISO 8601 duration to seconds