code: function timeParamToSeconds(param) {
  	var componentValue = function (si) {
  		var regex = new RegExp('(\\d+)' + si);
  		return param.match(regex) ? parseInt(RegExp.$1, 10) : 0;
  	};
  
  	return componentValue('h') * 3600
  		+ componentValue('m') * 60
  		+ componentValue('s');
  }
docs: Converts time in youtube t-param format to seconds