For starters, I would only use "\n" in the explode as unless you're only supporting Windows as I don't believe the "\r" is always present.
You can use trim per array element to get rid of the "\r" and other white noise.
To get to the second line, after the explode, you need to use a foreach() or just address them individually line text, text, etc. unless I'm misunderstanding the question.
Hard to comment on the rest as your variable is being filtered in your sample, what was that again? Put spaces between the letters or something so we can see what it is.