1

Possible Duplicate:
PHP 5.4 Call-time pass-by-reference - Easy fix available?

I'm currently modifying someone's webpage which uses call-time references in PHP scripts. Locally I'm using PHP 5.4 which removed those type of calls.

Is there any chance I can re-enable that feature again without downgrading to a previous version?

Unfortunately I'm not allowed to change the original source files so I'm stuck with that.

Community
  • 1
  • 1
stschindler
  • 937
  • 7
  • 28
  • @Gordon Yes, but I'm really interested in a workaround, because I'm not able to change the original sources and fix the issues. – stschindler Jun 28 '12 at 11:56
  • 2
    I guess your only solution then is to stay at PHP 5.3 or lower forever and accept that you are dealing with Legacy code on this project. – Gordon Jun 28 '12 at 11:58
  • @Gordon If you add that as an answer I'll approve it, as the only real option is to downgrade. – stschindler Jun 28 '12 at 16:51
  • Informative: http://www.php.net/manual/en/ini.core.php#ini.allow-call-time-pass-reference – hakre Jun 28 '12 at 19:20
  • @hakre Like the page says, it got removed in PHP 5.4. Worst thing is that PHP didn't even throw an error in my case (with all possible error settings enabled). But thanks anyway. – stschindler Jun 29 '12 at 07:33
  • @Tank: Sounds like you skipped upgrading to PHP 5.3 first and went to PHP 5.4 directly. It's probably one of the cases you've found to move to PHP 5.3 first before moving to PHP 5.4. – hakre Apr 29 '13 at 09:08

1 Answers1

1

If you cannot change the code (as suggested in PHP 5.4 Call-time pass-by-reference - Easy fix available?), your only solution is to stay at PHP < 5.4 and accept that you are dealing with Legacy code on this project.

Community
  • 1
  • 1
Gordon
  • 312,688
  • 75
  • 539
  • 559