ID: 48760 User updated by: scottq at iserve dot net dot nz -Summary: <?= no longer prints output when outputting an array Reported By: scottq at iserve dot net dot nz Status: Bogus Bug Type: Output Control Operating System: CentOS 5.3 PHP Version: 5.3.0 New Comment:
Sorry, <?= 'output'; ?> doesn't get picked up by php at all. The "action->getRequest('foo', NULL)]['value1']; ?>" was coming from by browser. It simply outputs "<?= 'output'; ?>". Previous Comments: ------------------------------------------------------------------------ [2009-07-01 20:30:32] ras...@php.net Unable to reproduce. You probably don't have short_open_tag turned on in your config anymore. ------------------------------------------------------------------------ [2009-07-01 20:25:28] scottq at iserve dot net dot nz Description: ------------ In php versions up to 5.3.0RC4 <?= 'output'; ?> would print the word output to the screen. As of 5.3 this no longer works, instead outputs chunks of code to the screen. Reproduce code: --------------- class action { private $request = array('foo' => 'bar'); public function getRequest($key, $default) { return isset($request[$key]) ? $request[$key] : $default; } } ... some other stuff... $array = ('key' => array('bar' => array('value' => 'foo'))); <?= 'output'; ?> <?= $array['key'][$action->getRequest('foo', NULL)]['value']; ?> Expected result: ---------------- output bar Actual result: -------------- action->getRequest('foo', NULL)]['value1']; ?> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=48760&edit=1