Bug #51961 [NEW]: ob_start w/ str_ireplace
| From: | zane at zanehooper dot com | Date: | Tue, 01 Jun 2010 04:02:15 +0000 |
| Subject: | Bug #51961 [NEW]: ob_start w/ str_ireplace | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-150979@lists.php.net to get a copy of this message | ||
From:
Operating system: Apache
PHP version: 5.2.13
Package: Output Control
Bug Type: Bug
Bug description:ob_start w/ str_ireplace
Description:
------------
I am making a bad word replacer using certain profanity settings.
Basically, when
I use str_ireplace inside of ob_start, a lot of the capitals on the page
are
removed (I didn't see any capitals added).
I'm not sure why it is happening, but I really need this fixed.
Test script:
---------------
function optimizeHTML( $html )
{
$html = str_ireplace( $badwords_array, $replacement, $html );
return $html;
}
ob_start( 'optimizeHTML' );
Expected result:
----------------
A regular page with $badwords_array replaced by $replacement
Actual result:
--------------
Some capitals on the page are removed
--
Edit bug report at http://bugs.php.net/bug.php?id=51961&edit=1
--
Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=51961&r=trysnapshot52
Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=51961&r=trysnapshot53
Try a snapshot (trunk): http://bugs.php.net/fix.php?id=51961&r=trysnapshottrunk
Fixed in SVN: http://bugs.php.net/fix.php?id=51961&r=fixed
Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=51961&r=needdocs
Fixed in release: http://bugs.php.net/fix.php?id=51961&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=51961&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=51961&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=51961&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=51961&r=support
Expected behavior: http://bugs.php.net/fix.php?id=51961&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=51961&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=51961&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=51961&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=51961&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=51961&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=51961&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=51961&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=51961&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=51961&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=51961&r=mysqlcfg