in reply to Chomping most of a _long_ text string

He said that the emails are automated, so I'm assuming that every email has the marker in it. It would also be easy to modify the code so that the substr is only done if index > -1.

You're probably right though that the savings between regex and substr are minimal enough so that the neater code can be used rather than the most efficient.

  • Comment on Re: Chomping most of a _long_ text string