ZF-2427: Filter dropping new lines
Description
A filter dropping new line control characters (\n, \r\n, \r) would be nice, maybe something like that:
<?php
require_once 'Zend/Filter/Interface.php';
class Zend_Filter_DropNewLines implements Zend_Filter_Interface
{
public function filter($value)
{
return str_replace(array("\n", "\n\r", "\r"), '', $value);
}
}
Comments
Posted by Martin Hujer (mhujer) on 2008-01-23T15:09:53.000+0000
I'll submit the proposal on tomorrow afternoon (GMT+1) and code with unit tests.
Posted by Martin Hujer (mhujer) on 2008-01-24T08:29:55.000+0000
Proposal is here: http://framework.zend.com/wiki/display/…
Posted by Martin Hujer (mhujer) on 2008-07-02T00:33:24.000+0000
Filter has been accepted to incubator.
Posted by Martin Hujer (mhujer) on 2008-08-07T01:44:37.000+0000
Filter is in the trunk and in 1.6 release branch.
Posted by Ralph Schindler (ralph) on 2008-08-07T06:59:43.000+0000
Fixed in ZF-3793.
Resolved at r10539 in trunk. Resolved at r10637 in release 1.6 branch.