Ticket #230 (new defect)

Opened 2 years ago

Last modified 1 year ago

eaccelerator_cache_result() not working properly

Reported by: Kirby Assigned to: somebody
Priority: major Milestone: 0.9.6
Component: eAccelerator Version: 0.9.5
Keywords: Cc:

Description

I tried the following code

echo(eaccelerator_cache_result('foobar', 'function A() { return "Hello from function A()"; } return A();'));

But instead of the expected result "Hello from function A()" I got:

Parse error: parse error, unexpected T_FUNCTION in <path/to/script>(lineno) : eval()'d code on line 1

The following code works just fine:

echo(eval('function A() { return "Hello from function A()"; } return A();'));

Change History

08/19/07 19:09:12 changed by bart

  • version set to 0.9.5.
  • milestone set to 0.9.6.