I need help cleaning up a text file using PHP. The file is being processed afterwards by another function that requires the text to be formatted in a certain way.
Original closed caption text:
1
00:00:22,767 --> 00:00:24,634
line text 1
line text 2
line text 3
2
00:00:26,767 --> 00:00:28,634
line text 1
line text 2
line text 3
I need the line text all on one line. eg.
1
00:00:22,767 --> 00:00:24,634
line text 1 line text 2 line text 3
2
00:00:26,767 --> 00:00:28,634
line text 1 line text 2 line text 3
I would love some help/input. I am just having trouble gettign into the right head space. Thanks.