Open GoogleCodeExporter opened 9 years ago
After replacing 'reg_replace' with 'preg_replace' it works but still leaves a
space after the remaining class name so I've added a 'trim';
I've changed Line 1509 from:
$class = reg_replace('`\b'.preg_quote($c).'\b`si', '', $class);
to:
$class = trim(preg_replace('`\b'.preg_quote($c).'\b`si', '', $class));
Probably it can be done with regex but it was easier for me with trim.
Original comment by ktork...@gmail.com
on 31 Jul 2013 at 1:04
Your solution leave an extra white space if you need to remove 'bar' from 'foo
bar foobar'.
Can be fixed with:
$class = rtrim(preg_replace('`\b'.preg_quote($c).'\b\s?`si', '', $class));
Original comment by stef...@balocco.name
on 2 Sep 2013 at 10:19
Original issue reported on code.google.com by
ktork...@gmail.com
on 31 Jul 2013 at 12:53