in reply to Useless use of substr in void context
Line 23 is: substr($lines, 0, 1);
I suspect the error you are getting is because you are using the three-argument form of substr(), which returns a portion of the string. Because you are not assigning that value to anything, or using it in an expression, I believe this is why you are getting the "Useless use of substring in void context" message. If you are intending to replace a portion of the value, then you may wish to look at the four-argument form; if you do not, you may wish to look closer to determine if the line is needed or now.
Hope that helps.
|
|---|