From: patrickalla...@php.net Operating system: Linux PHP version: 6SVN-2009-09-01 (SVN) PHP Bug Type: Unknown/Other Function Bug description: cannot use array returned by tidy_get_config()
Description: ------------ This bug is perfectly similar to #47966 and can be reproduced with ext/tidy/tests/030.phpt. I can't fix it missing karma. The patch is at: http://pallaert.pastebin.com/f27da6f66 Reproduce code: --------------- <?php $buffer = '<html></html>'; $config = array( 'indent' => true, // AutoBool 'indent-attributes' => true, // Boolean 'indent-spaces' => 3, // Integer 'language' => 'de'); // String $tidy = new tidy(); $tidy->parseString($buffer, $config); $c = $tidy->getConfig(); var_dump($c['indent']); var_dump($c['indent-attributes']); var_dump($c['indent-spaces']); var_dump($c['language']); ?> Expected result: ---------------- int(1) bool(true) int(3) %s(2) "de" Actual result: -------------- Notice: Undefined index: indent in ext/tidy/tests/030.php on line 11 NULL Notice: Undefined index: indent-attributes in ext/tidy/tests/030.php on line 12 NULL Notice: Undefined index: indent-spaces in ext/tidy/tests/030.php on line 13 NULL Notice: Undefined index: language in ext/tidy/tests/030.php on line 14 NULL -- Edit bug report at http://bugs.php.net/?id=49428&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=49428&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=49428&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=49428&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=49428&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=49428&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=49428&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=49428&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=49428&r=needscript Try newer version: http://bugs.php.net/fix.php?id=49428&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=49428&r=support Expected behavior: http://bugs.php.net/fix.php?id=49428&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=49428&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=49428&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=49428&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=49428&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=49428&r=dst IIS Stability: http://bugs.php.net/fix.php?id=49428&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=49428&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=49428&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=49428&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=49428&r=mysqlcfg