Ok, the issue in the strip_newlines.
The function as shown above is using single ticks (apostrophes) for the variables:
newlines = array(0 => '\r', 1 => '\n', 2 => '\r\n');
Those need to be in double tics (quotes):
newlines = array(0 => "\r", 1 => "\n", 2 => "\r\n");
Then, it will work. But there is a condition that will NEVER get hit. The third "\r\n" will never be encountered so it can be left out and you could use
newlines = array(0 => "\r", 1 => "\n");
That would work properly and give the proper result.
.
__________________
All cookies cleared!
|