Jump to content
buddy

Directive 'allow_call_time_pass_reference' is no longer available in PHP

Recommended Posts

Hi all,

I've just deployed my ProcessWire-based app to a new web server running PHP 5.4.5, and started noticing this error showing up in the logs:

[url]/processwire/page/edit/ 
Core Error Directive
'allow_call_time_pass_reference' is no longer available in PHP (line 0 of Unknown)

The error sometimes will cause a page inside the CMS admin panel to not load (with a blank "error has been logged" screen), but usually hitting back or reload will render the page just fine. The allow_call_time_pass_reference directive in PHP has been deprecated for a while, but finally removed in PHP 5.4, so that's clearly what's causing the error.

The problem is that I have no idea why ProcessWire is triggering this error. There's no line number, and from what I can tell "allow_call_time_pass_reference" doesn't appear in any PW source code. Despite that, I think it is somehow the PW code which is causing this, since I haven't seen this error in any of my custom code, and it only shows up while using the PW admin panel.

Any guesses?

Thanks!

Share this post


Link to post
Share on other sites

I've never even heard of allow_call_time_pass_reference, so haven't ever put it into PW's code anywhere. Though wondering if some kind of '&' usage is triggering it or something. Is there any specific page that it's occurring on, or does it appear random? I'm also wondering PHP might be picking this up from a php.ini or .htaccess file somewhere on your server (given that it says line 0 of Unknown)?

Share this post


Link to post
Share on other sites

Hi guys,

Yes I'm also seeing this error in the admin side using MAMP running PHP 5.4.3 this does not happen in PHP 5.3

Really strange...

post-389-0-04832100-1347313706_thumb.png

Share this post


Link to post
Share on other sites

OK. I think you mean this suggestion, right?

You should comment out allow_call_time_pass_reference in php.ini, because it's no longer available. The following should fix it:

But... what does that mean? How do I do that? Once I copy/paste that line into the php.ini field, it doesnt work.

Sorry, no php nerd here, but only a web designer...  :-[

Share this post


Link to post
Share on other sites

By putting a semi-colon in front of the line in your php.ini...i.e.

; Example - this line is commented out. Comment out the below line..
; allow_call_time_pass_reference//comment this out; deprecated and now removed in php 5.4

The directive has been removed from PHP 5.4. Hence, comment it out as suggested. Have a read here:

http://uk1.php.net/manual/en/ini.core.php#ini.allow-call-time-pass-reference

Share this post


Link to post
Share on other sites

THX. Had to contact my ISP to get it done. But for now it seems to work! THX! :)

Share this post


Link to post
Share on other sites

Thanks! I commented this line out from PHP.INI and it worked like a charm!  :rolleyes:

 

Thanks for the help guys!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...