I've searched and found nothing similar.
What I'm trying to achieve is creating a simple PHP/js/jq script that can add or subtract seconds from a .srt file. I'm not sure if regex is something I should go with to achieve it or something else.
The user will upload/copy the text of the srt file and then add the number of seconds to an input box that they want to add or subtract seconds from SRT.
For example if user adds +4 seconds to the following srt file:
0
00:00:04,594 --> 00:00:10,594
this is a subtitle
1
00:00:40,640 --> 00:00:46,942
this is another subtitle
2
00:02:05,592 --> 00:02:08,694
this is one more subtitle
It should look like this:
0
00:00:08,594 --> 00:00:14,594
this is a subtitle
1
00:00:44,640 --> 00:00:50,942
this is another subtitle
2
00:02:09,592 --> 00:02:12,694
this is one more subtitle