#19440 [Opn]: ob_clean and ob_end_clean are broken

From: Date: Mon, 16 Sep 2002 18:04:39 +0000
Subject: #19440 [Opn]: ob_clean and ob_end_clean are broken
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-19481@lists.php.net to get a copy of this message
ID: 19440 User updated by: madeinlisboa@yahoo.com Reported By: madeinlisboa@yahoo.com Status: Open Bug Type: Output Control Operating System: W2K PHP Version: 4.2.3 New Comment: In the example I removed some elements from the array and forgot to delete last comma. sorry Previous Comments: ------------------------------------------------------------------------ [2002-09-16 13:02:05] madeinlisboa@yahoo.com When any of these 2 functions are called, I get no output or the output is garbled. eg (I run this at the end of printable pages, to remove form fields, etc... Get buffer, change it, then print it): $search = Array( "|<script[^>]*?>.*?</script>|si", "|<a href=\"#topo\">.*?</a>|si", "|<form[^>]*?>.*?</form>|si", "|<a[^>]*?>|si", "|</a\s*>|si", ); $contents = ob_get_contents(); // gets output buffer, empties it and print without forms ob_clean(); echo preg_replace($search, '', $contents); ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=19440&edit=1

« previous php.bugs (#19481) next »