I'm trying to capture the timestamps of some caption files with some luck.
I've managed to get an expression that will partially capture hh:mm:ss.uuu as shown in #910 below, but am unable to figure out how to capture the groups if the optional h:
or hh:
is not present. My work so far is at https://regex101.com/r/4QWySg/1. As you can see, it's only capturing after the first hour is encountered.
Any help is appreciated :)
909
59:48.420 --> 1:00:06.450
THERE SHOULD BE AN OPTION TO UNMUTE DO
910
1:00:06.460 --> 1:00:09.870
YOU SEE A MICROPHONE ICON ANYWHERE ON YOUR TEAMS
(^d+$R)?(d{1,2}(?::d{2}){2}.d{2,3})s*-->s*(d{1,2}(?::d{2}){2}.d{2,3})R((?:[^
]|
?
[^
])*)(?:
?
?
|$)
question from:
https://stackoverflow.com/questions/65912268/php-regex-to-capture-mmss-uuu-and-hhmmss-uuu 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…